Skip to content

Detect aarch64 and stop emitting AIX-only -maix64 on non-AIX targets#29

Open
cvanaret wants to merge 2 commits into
ampl:masterfrom
cvanaret:patch-2
Open

Detect aarch64 and stop emitting AIX-only -maix64 on non-AIX targets#29
cvanaret wants to merge 2 commits into
ampl:masterfrom
cvanaret:patch-2

Conversation

@cvanaret

@cvanaret cvanaret commented Jun 16, 2026

Copy link
Copy Markdown

How to reproduce the error:

# 1. aarch64 cross-compiler (Debian/Ubuntu)
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu cmake

# 2. minimal aarch64 cross toolchain file
cat > aarch64.cmake <<'EOF'
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR aarch64)
set(CMAKE_C_COMPILER   aarch64-linux-gnu-gcc)
set(CMAKE_CXX_COMPILER aarch64-linux-gnu-g++)
EOF

# 3. configure + build
cmake -S . -B build -DCMAKE_TOOLCHAIN_FILE=aarch64.cmake -DBUILD_SHARED_LIBS=ON
cmake --build build --target asl2

The error reads:

aarch64-linux-gnu-gcc: error: unrecognized command-line option ‘-m64’

See JuliaPackaging/Yggdrasil#13950

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant