Skip to content

Commit

Permalink
Re-enable solaris targets.
Browse files Browse the repository at this point in the history
Fixes the solaris targets, and re-enables them in CI. Related to cross-rs#534 and cross-rs#609.
  • Loading branch information
Alexhuszagh authored and Emilgardis committed Jun 24, 2022
1 parent 953c23e commit 88df58d
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 16 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,8 @@ jobs:
- { target: i686-unknown-freebsd, os: ubuntu-latest, dylib: 1, std: 1 }
- { target: x86_64-unknown-freebsd, os: ubuntu-latest, dylib: 1, std: 1 }
- { target: x86_64-unknown-netbsd, os: ubuntu-latest, cpp: 1, dylib: 1, std: 1 }
# Disabled, see #534
#-{ target: sparcv9-sun-solaris, os: ubuntu-latest, cpp: 1, dylib: 1, std: 1 }
#-{ target: x86_64-sun-solaris, os: ubuntu-latest, cpp: 1, dylib: 1, std: 1 }
- { target: sparcv9-sun-solaris, os: ubuntu-latest, cpp: 1, dylib: 1, std: 1 }
- { target: x86_64-sun-solaris, os: ubuntu-latest, cpp: 1, dylib: 1, std: 1 }
- { target: thumbv6m-none-eabi, os: ubuntu-latest, std: 1 }
- { target: thumbv7em-none-eabi, os: ubuntu-latest, std: 1 }
- { target: thumbv7em-none-eabihf, os: ubuntu-latest, std: 1 }
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).

### Changed

- #838 - re-enabled the solaris targets.
- #807 - update Qemu to 6.1.0 on images using Ubuntu 18.04+ with python3.6+.
- #775 - forward Cargo exit code to host
- #762 - re-enabled `x86_64-unknown-dragonfly` target.
Expand Down
31 changes: 18 additions & 13 deletions docker/solaris.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ main() {
local arch="${1}"

local binutils=2.28.1 \
gcc=6.4.0 \
gcc=8.4.0 \
target="${arch}-sun-solaris2.10"

install_packages bzip2 \
Expand Down Expand Up @@ -58,18 +58,21 @@ main() {
add-apt-repository -y 'deb http://apt.dilos.org/dilos dilos2-testing main'
dpkg --add-architecture "${apt_arch}"
apt-get update
apt-cache depends --recurse --no-replaces \
"libc:${apt_arch}" \
"libdl-dev:${apt_arch}" \
"libm-dev:${apt_arch}" \
"libnsl-dev:${apt_arch}" \
"libpthread-dev:${apt_arch}" \
"libresolv-dev:${apt_arch}" \
"librt:${apt_arch}" \
"libsocket-dev:${apt_arch}" \
"system-crt:${apt_arch}" \
"system-header:${apt_arch}" \
| grep "^\w" | xargs apt-get download
# shellcheck disable=SC2046
apt-get download $(apt-cache depends --recurse --no-replaces \
"libc:${apt_arch}" \
"liblgrp-dev:${apt_arch}" \
"liblgrp:${apt_arch}" \
"libm-dev:${apt_arch}" \
"libpthread:${apt_arch}" \
"libresolv:${apt_arch}" \
"librt:${apt_arch}" \
"libsendfile-dev:${apt_arch}" \
"libsendfile:${apt_arch}" \
"libsocket:${apt_arch}" \
"system-crt:${apt_arch}" \
"system-header:${apt_arch}" \
| grep "^\w")

for deb in *"${apt_arch}.deb"; do
dpkg -x "${deb}" "${td}/solaris"
Expand Down Expand Up @@ -102,6 +105,8 @@ EOF
ln -s usr/include "${destdir}/sys-include"
ln -s usr/include "${destdir}/include"

# note: solaris2.10 is obsolete, so we can't upgrade to GCC 10 till then.
# for gcc 9.4.0, need `--enable-obsolete`
cd gcc-build
../gcc/configure \
--disable-libada \
Expand Down

0 comments on commit 88df58d

Please sign in to comment.