Skip to content

Commit

Permalink
document cross-compiling of xtc68
Browse files Browse the repository at this point in the history
  • Loading branch information
stronnag committed Sep 1, 2022
1 parent ac8e167 commit ea0df98
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ sudo ./sdk-install.sh

Note `sudo` is required for a non-root user to install to `/usr/local`.

### Cross compiling

The `cross/mkcross.sh` script supports cross-compilation hosted on Linux for MacOS and Windows (as well as generating the Linux archive). Note that the MacOS recipe has a dependency on a local path for the MacOS cross-compiler).

## Integration with native make (i.e. GNU Make)

* The installation provides `ql.mk`, which it will copy to `$PREFIX/share/qdos/etc/ql.mk`
Expand Down
4 changes: 4 additions & 0 deletions cross/mkcross.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
PLAT=${1:-win:mac}
BASE=${2:-/tmp/xtc68}

# There are only used for building, the prefix is not embedded in release build
# binaries i.e. when `-Drelbuild=true` is provided to the meson setup stage.

WINPFX=$BASE/windows/xtc68
MACPFX=$BASE/macos/xtc68
LINPFX=$BASE/linux/xtc68
Expand Down Expand Up @@ -30,6 +33,7 @@ mkarchive() {
}

if [[ "$PLAT" =~ "lin" ]] ; then
# oldest libc on site, in order to maximise cross-distro compatibility
echo -e "\a\n*** Do the Linux release builds on Debian Stable ***\n"
rm -rf build-linux $BASE/linux
meson build-linux --prefix=$LINPFX --strip -Drelbuild=true
Expand Down

0 comments on commit ea0df98

Please # to comment.