clang: cancel effect of the -x option for subsequent files -


clang has option, -x, can used specify language of subsequent source files passed it. caused problems when used this:

clang -x c++ one.cc a.o b.o c.o 

clang try interpret object files a.o, b.o, c.o source code.

is there way cancel effect of -x option can pass object files on same command line?

clang -x c++ one.cc someoption a.o b.o c.o 

what should someoption allow clang interpret .o files object files?

i need use convoluted command line because using system calls compiler automatically compile code generates , there limits how can hacked.

could put arguments other way 'round

clang a.o b.o c.o -x c++ one.cc  

or compile each file , link them in later run

clang -x c++ one.cc -o one.cc.o clang a.o b.o c.o one.cc.o 

this how in experience actualy used.


Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - Bypass Geo Redirect for specific directories -

php - .htaccess mod_rewrite for dynamic url which has domain names -