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

"ar" invocation failure for android build atop OS X #11229

Closed
pnkfelix opened this issue Dec 31, 2013 · 2 comments
Closed

"ar" invocation failure for android build atop OS X #11229

pnkfelix opened this issue Dec 31, 2013 · 2 comments
Labels
O-android Operating system: Android O-macos Operating system: macOS

Comments

@pnkfelix
Copy link
Member

My best attempt today to try to build a rustc targetting Android, based on the instructions at building for android

This is using the OS X android-ndk-r9c

Configure invocation:
../configure --target=arm-linux-androideabi --android-cross-path=$HOME/opt/ndk_standalone --prefix=~/opt/rust-droid

Build invocation:
time remake -j1 --trace

Failing rustc invocation:

% x86_64-apple-darwin/stage2/bin/rustc --cfg stage2  -O --cfg rtopt --cfg debug -Z no-debug-borrows --target=arm-linux-androideabi --android-cross-path=/Users/fklock/opt/ndk_standalone -D warnings --out-dir x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib /Users/fklock/Dev/Mozilla/rust.git/src/libstd/lib.rs
error: ar r x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd-04ff901e-0.9-pre.rlib failed with: exit code: 1
note: stdout ---

note: stderr ---
ar: no archive members specified
usage:  ar -d [-TLsv] archive file ...
    ar -m [-TLsv] archive file ...
    ar -m [-abiTLsv] position archive file ...
    ar -p [-TLsv] archive [file ...]
    ar -q [-cTLsv] archive file ...
    ar -r [-cuTLsv] archive file ...
    ar -r [-abciuTLsv] position archive file ...
    ar -t [-TLsv] archive [file ...]
    ar -x [-ouTLsv] archive [file ...]

error: aborting due to previous error
task 'rustc' failed at 'explicit failure', /Users/fklock/Dev/Mozilla/rust.git/src/libsyntax/diagnostic.rs:102
task '<main>' failed at 'explicit failure', /Users/fklock/Dev/Mozilla/rust.git/src/librustc/lib.rs:441

More elaborate Failure Output from make invocation itself (when debugging via remake)

...
Invoking recipe from /Users/fklock/Dev/Mozilla/rust.git/mk/target.mk:188 to update target `x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so'.
##>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
echo  compile_and_link: x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so
##<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
compile_and_link: x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so
##>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
MATCHES=""; if [ -n "$MATCHES" ] ; then rm $MATCHES ; fi
##<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
##>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
MATCHES="x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib//libstd-04ff901e-0.9-pre.rlib"; if [ -n "$MATCHES" ] ; then rm $MATCHES ; fi
##<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
##>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
x86_64-apple-darwin/stage2/bin/rustc --cfg stage2  -O --cfg rtopt --cfg debug -Z no-debug-borrows --target=arm-linux-androideabi --android-cross-path=/Users/fklock/opt/ndk_standalone -D warnings --out-dir x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib /Users/fklock/Dev/Mozilla/rust.git/src/libstd/lib.rs && touch x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so
##<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
error: ar r x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd-04ff901e-0.9-pre.rlib failed with: exit code: 1
note: stdout ---

note: stderr ---
ar: no archive members specified
usage:  ar -d [-TLsv] archive file ...
    ar -m [-TLsv] archive file ...
    ar -m [-abiTLsv] position archive file ...
    ar -p [-TLsv] archive [file ...]
    ar -q [-cTLsv] archive file ...
    ar -r [-cuTLsv] archive file ...
    ar -r [-abciuTLsv] position archive file ...
    ar -t [-TLsv] archive [file ...]
    ar -x [-ouTLsv] archive [file ...]

error: aborting due to previous error
task 'rustc' failed at 'explicit failure', /Users/fklock/Dev/Mozilla/rust.git/src/libsyntax/diagnostic.rs:102
task '<main>' failed at 'explicit failure', /Users/fklock/Dev/Mozilla/rust.git/src/librustc/lib.rs:441
/Users/fklock/Dev/Mozilla/rust.git/mk/target.mk:188: *** [x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so] Error 101

#0  x86_64-apple-darwin/stage2/lib/rustc/arm-linux-androideabi/lib/libstd.so at /Users/fklock/Dev/Mozilla/rust.git/mk/target.mk:188
#1  all-target-arm-linux-androideabi-host-x86_64-apple-darwin at /Users/fklock/Dev/Mozilla/rust.git/objdir-optdroid/Makefile:633
#2  all at /Users/fklock/Dev/Mozilla/rust.git/objdir-optdroid/Makefile:641
Command-line invocation:
    "/Users/fklock/opt/remake/bin/remake -j1 --trace"

real    6m20.398s
user    5m32.640s
sys 0m30.859s

Compilation exited abnormally with code 2 at Mon Dec 30 21:15:18
@alexcrichton
Copy link
Member

This will be closed by #10900

@alexcrichton
Copy link
Member

Closed by #10900

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-android Operating system: Android O-macos Operating system: macOS
Projects
None yet
Development

No branches or pull requests

2 participants