Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1088291
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T23:03:11+00:00 2026-05-16T23:03:11+00:00

I am trying to cross-compile Erlang and running into a weird bug. The commands

  • 0

I am trying to cross-compile Erlang and running into a weird bug. The commands used are

make clean

./otp_build configure --host=arm-none-linux-gnueabi --build=i686-pc-linux-gnu 
--prefix=/opt/erlang erl_xcomp_sysroot=~/sbctools/arm-2007q3 --disable-hipe 
--disable-threads --disable-smp --disable-megaco-flex-scanner-lineno 
--disable-megaco-reentrant-flex-scanner --disable-dynamic-ssl-lib 
--without-termcap --without-javac --without-ssl

./otp_build boot

Their output can be seen at http://gist.github.com/576199 (it’s too big to paste here), but the error which ends the process is

/home/aromanov/sbctools/arm-2007q3/bin/../lib/gcc/arm-none-linux-gnueabi/4.2.1/../../../../arm-none-linux-gnueabi/bin/ld: /home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a(adler32.o): Relocations in generic ELF (EM: 3)
/home/aromanov/sbctools/arm-2007q3/bin/../lib/gcc/arm-none-linux-gnueabi/4.2.1/../../../../arm-none-linux-gnueabi/bin/ld: /home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a(adler32.o): Relocations in generic ELF (EM: 3)
/home/aromanov/sbctools/arm-2007q3/bin/../lib/gcc/arm-none-linux-gnueabi/4.2.1/../../../../arm-none-linux-gnueabi/bin/ld: /home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a(adler32.o): Relocations in generic ELF (EM: 3)
/home/aromanov/sbctools/arm-2007q3/bin/../lib/gcc/arm-none-linux-gnueabi/4.2.1/../../../../arm-none-linux-gnueabi/bin/ld: /home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a(adler32.o): Relocations in generic ELF (EM: 3)
/home/aromanov/sbctools/arm-2007q3/bin/../lib/gcc/arm-none-linux-gnueabi/4.2.1/../../../../arm-none-linux-gnueabi/bin/ld: /home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a(adler32.o): Relocations in generic ELF (EM: 3)
/home/aromanov/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make[3]: *** [/home/aromanov/otp_src/bin/arm-none-linux-gnueabi/beam] Error 1
make[3]: Leaving directory `/home/aromanov/otp_src/erts/emulator'
make[2]: *** [opt] Error 2
make[2]: Leaving directory `/home/aromanov/otp_src/erts/emulator'
make[1]: *** [opt] Error 2
make[1]: Leaving directory `/home/aromanov/otp_src/erts'
make: *** [emulator] Error 2

Indeed, viewing ~/otp_src/erts/emulator/zlib/obj/arm-none-linux-gnueabi/opt/libz.a shows it’s compiled for Intel 30386. But why? And how can I avoid it?

EDIT: ~/sbctools/arm-2007q3/bin is the first directory in the PATH. Do I perhaps need to add other toolchain directories as well?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T23:03:11+00:00Added an answer on May 16, 2026 at 11:03 pm

    make[4]: Entering directory /home/aromanov/otp_src/erts/emulator/zlib'
    make -f arm-none-linux-gnueabi/Makefile TYPE=opt
    make[5]: Entering directory/home/aromanov/otp_src/erts/emulator/zlib'
    make[5]: Nothing to be done for all'.
    make[5]: Leaving directory/home/aromanov/otp_src/erts/emulator/zlib'
    make[4]: Leaving directory `/home/aromanov/otp_src/erts/emulator/zlib'
    

    Looks like you've built zlib part before... when it was not correctly configured.
    Try make clean or make distclean and then recompile.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to cross compile a helloworld kernel module with specifications: host: intel x86
I am trying to configure util-linux to cross compile using arm-none-linux-gnueabi from CodeSourcery. My
On my Linux x86_64 host, I am trying to cross-compile some additional Python modules
I am trying to cross-compile GCC on Mac OS 10.5.7. I used this command
I'm trying to configure Android.mk to cross compile native code to support different chipset
I'm trying to cross-compile a Realtek wifi driver for an Airlink AWLL6075 wireless n
Trying to make a cross protocol, same domain request from https to http. I
I'm trying to cross-compile dropbear for android. The files appear to compile find, but
I'm trying to cross compile an in house language(ihl) to Python. One of the
I've making a shared library (cross-platform), but when trying to compile the Windows build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.