Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for cross compilation #48

Open
firasuke opened this issue Mar 30, 2024 · 2 comments
Open

Support for cross compilation #48

firasuke opened this issue Mar 30, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@firasuke
Copy link

firasuke commented Mar 30, 2024

Hey there,

I was wondering if it is possible to support cross compilation for yash.

Currently, it only works if makesignum was built using the host's compiler ($HOSTCC which is often gcc) (not the cross-compilation toolchain's compiler as yash later expects ./makesignum to run on the host):

$MAKE \
  CC=$HOSTCC \
  makesignum

I am also disabling tryexec ():

tryexec () {
    :
}
@firasuke firasuke added the enhancement New feature or request label Mar 30, 2024
@magicant
Copy link
Owner

This is not the first time I receive a request for cross compilation support. https://osdn.net/projects/yash/ticket/38274

There are many that need to be resolved to make cross compilation possible.

I don't know how autotools supports cross-compilation, and I need to find a way to do the same thing in yash configure.

Much of the configuration process depends on running programs compiled on the fly, which assumes that the host environment is the same as the target environment. We would need a different approach to configuration to allow us to specify parameters that have been prepared for the target. makesignum is one such part, but there are many similar parts in configure.

@rofl0r
Copy link

rofl0r commented Apr 14, 2024

in case it helps, i've written a quite comprehensive article about supporting cross-compiling https://sabotage-linux.neocities.org/blog/5/

as for makesignum, maybe it could just be executed on yash startup instead of build time.
but then i don't understand why the code can't just switch on case SIGINT: ... in the regular yash runtime code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants