Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22070

CPU you selected doesn't support x86-64 instruction set

$
0
0

I want to compile a program which has lots of 32-bit static libraries which I cannot recompile to 64-bit because the lack of makefiles but there are some libraries that I should compile to obtain some static libraries to use alongside them.

One of the libraries that I want to compile has a Makefile as follows :

CC = c++BIN_DIR = ../libBIN = $(BIN_DIR)/libsql.aCFLAGS = -w -O3 -ggdb3 -g3 -std=c++14 -pipe -mtune=i386 -fstack-protector -staticCPP=AsyncSQL.cpp Semaphore.cpp Statement.cpp Tellwait.cppall: $(BIN)clean:    @echo Delete .obj files    @rm -f *.o%.o: %.cpp    @echo -e "\033[0;32m [OK] \033[0m" $<    @$(CXX) $(CFLAGS) -c $^ -o $@$(BIN): $(CPP:%.cpp=%.o)    @ar cru $(BIN) $^    @ranlib $(BIN)    @rm -rf *.o

Which results in the following output :

 cc1plus: error: CPU you selected does not support x86-64 instruction set

If I omit the option -mtune=i386 it would compile successfully but then I should compile the rest of the libraries as 64-bit binaries and at the end I won't be able to link against those static 32-bit ones.

How can I eliminate that error?

Any suggestion would be appreciated.


Viewing all articles
Browse latest Browse all 22070

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>