diff options
author | Tomasz Kramkowski <tk@the-tk.com> | 2021-08-05 18:30:33 +0100 |
---|---|---|
committer | Tomasz Kramkowski <tk@the-tk.com> | 2021-08-05 20:17:48 +0100 |
commit | 8c58e5683cbd90d529eb1ea86fce019e553b2248 (patch) | |
tree | b31e8754a56ab0a87170bfecffca3ef434850826 /README.md | |
parent | 7e7bdc19e76a5f87bccf7a84872f8d45295ee5b7 (diff) | |
download | pack-8c58e5683cbd90d529eb1ea86fce019e553b2248.tar.gz pack-8c58e5683cbd90d529eb1ea86fce019e553b2248.tar.xz pack-8c58e5683cbd90d529eb1ea86fce019e553b2248.zip |
Cross compilation support
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -48,6 +48,22 @@ linker for certain math.h functions. Run `redo all` to build the library and tests. +### Cross Compilation + +To cross compile, run `./configure` as normal and edit the resulting `config.rc` +to set `TCC` to the target compiler. Additional flags can be passed via the +arrays `TCFLAGS`, `TCPPFLAGS`, `TLDFLAGS`, and `TLDLIBS`. Host specific flags +can be passed via the corresponding `H<name>` arrays. + +For example, to cross compile for windows using `i686-w64-mingw32-gcc` as the +target compiler and `clang` as the host compiler: + +``` +$ CC=clang ./configure +$ echo TCC=i686-w64-mingw32-gcc >>config.rc +$ redo all +``` + Testing ------- |