warning: unknown architecture of input file *** incompatible with i386 output
Hi.
Trying to compile a seismic format conversion program ms2sac on a 32-bit machine running Mandrake 9.2. The compiler is the cc compiler. Getting the following error messages: [jp@seismic ms2sac]$ make (cd ../qlib2; make) make[1]: Entering directory `/home/jp/ms2sac/qlib2' make[1]: Nothing to be done for `all'. make[1]: Leaving directory `/home/jp/ms2sac/qlib2' cc -g -I../qlib2 -DDEFAULT_COORD_FILE=\"/usr/contrib/data/bdsn/bdsn.coord\" -o ms2sac ms2sac.o read_mseed_data.o get_stn_evt_info.o init_sac_header.o write_sac.o ../qlib2/libqlib2.a -lm /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(qlib2_version.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(ms_utils.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(ms_unpack.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(qtime.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(sdr_utils.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(unpack.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(qutils.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(drm_utils.o)' is incompatible with i386 output /usr/bin/ld: warning: unknown architecture of input file `../qlib2/libqlib2.a(qda_utils.o)' is incompatible with i386 output /usr/bin/ld: BFD 2.14.90.0.5 20030722 internal error, aborting at elf32-i386.c line 2242 in elf_i386_relocate_section /usr/bin/ld: Please report this bug. collect2: ld returned 1 exit status make: *** [ms2sac] Error 1 So this is some kind of 64-bit / 32-bit clash? The relevant part of the Makefile is: ######################################################################## TARGET = ms2sac SRCS = $(TARGET).c read_mseed_data.c get_stn_evt_info.c \ init_sac_header.c write_sac.c OBJS = $(SRCS:%.c=%.o) COORD_FILE = \"/usr/contrib/data/bdsn/stat.db.coord\" IQLIB2 = -I../qlib2 QLIB2 = ../qlib2/libqlib2.a LIBS = $(QLIB2) -lm .PRECIOUS: $(QLIB2) BINDIR = /usr/local/bin MANDIR = /usr/local/man MANEXT = 1 CC = cc COPT = -g CFLAGS = $(COPT) $(IQLIB2) -DDEFAULT_COORD_FILE=$(COORD_FILE) ######################################################################## The ms2sac program needs qlib2 stuff...which does compile ok - see above. Any help with sorting this out would be much appreciated...I don't really know much at all about different architecture issues. Thanks. |
It seems libqlib2.a has been compiled previously for another OS (like SUN or any other). Indeed, the following lines tell that qlib2 has not been compiled from your system, because the binaries were already there!
Code:
make[1]: Entering directory `/home/jp/ms2sac/qlib2' Code:
make clean Code:
make |
It seems libqlib2.a has been compiled previously for another OS (like SUN or any other). Indeed, the following lines tell that qlib2 has not been compiled from your system, because the binaries were already there!
Code: make[1]: Entering directory `/home/jp/ms2sac/qlib2' make[1]: Nothing to be done for `all'. Unfortunatley that isn't the problem! When I first downloaded the qlib2 package there were binaries included but they would not execute...most likely for the reason you say. So I deleted them and ran make in the qlib2 directory - then went on to the ms2sac directory. That's why the Nothing to be done for 'all' is there at the top. There was a ms2sac binary as well but of course this didn't execute either... Thanks anyway! |
Quote:
|
Tried that but getting same errors! One other thing...at the end of the makefile there's a list of the object files and their dependencies:
Code:
....................................................... Code:
make: *** No rule to make target `/usr/include/sys/feature_tests.h', needed by `ms2sac.o'. Stop. So all in all I'm still stuck! |
Indeed, some of the header files are not from Linux... they are usually installed on SUN Solaris! If this incompatibility is for header files only, you can get them from a SUN machine (if available) and hopefully they will be recognized from the compiler. It is likely at this point that the software has been developed for a SUN OS. However I see no apparent reason for the qlib2 you have (successfully?) compiled on your system to be addicted as "incompatible for i386".
Edit: just another hint: check if in the Makefile of qlib2 there is a flag regarding the endianity, since SUN OS are generally installed on BIG ENDIAN architectures, while Linux is generally on LITTLE ENDIAN machines. |
All times are GMT -5. The time now is 01:25 PM. |