automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cannot specify -o with -c or -S


From: rrlangly
Subject: cannot specify -o with -c or -S
Date: Wed, 24 Feb 2010 21:16:17 -0800 (PST)

Does anyone have an idea as to why I'd get the following error when compiling
my program using autotools. This used to compile and run, then I added new
code and linked against a new library, and now I get this.

g++ -DHAVE_CONFIG_H -I. -I../../GXT/src -I..  -I../../GXT/include
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I
/usr/include/festival -I /usr/include/speech-tools -I/usr/include/boost -I
/usr/local/include -I /usr/local/include/OGRE/Terrain
-I/usr/local/include/OGRE/Paging -I/usr/local/include/OGRE -I
/opt/ion-inb-1.1.0/include -I/home/priggy/Projects/subA/libbern
/home/priggy/Projects/subA/asn.1/bern-sn.h
/home/priggy/Projects/subA/util/bern-ut.h
/home/priggy/Projects/subA/util/bern-no.h
/home/priggy/Projects/subA/util/bern-res.h
/home/priggy/Projects/subA/util/bern-am.h
/home/priggy/Projects/subA/util/bern-da.h
/home/priggy/Projects/subA/util/bern-v.h
/home/priggy/Projects/subA/util/bern-ver.h
/home/priggy/Projects/subA/libbbc/bbc-c.h  -pthread -I/usr/local/include
-I/usr/local/include/OGRE   -I/usr/include/OIS   -g -O2 -MT gtx-main.o -MD
-MP -MF .deps/gtx-main.Tpo -c -o gtx-main.o `test -f 'main.cpp' || echo
'../../GXT/src/'`main.cpp
g++: cannot specify -o with -c or -S with multiple files
make[3]: *** [gtx-main.o] Error 1


This isn't the exact Makefile (which I don't have access to now), but it
contains the very same macros, or not sure what they're called (e.g.
_SOURCES, _CPPFLAGS, _LDADD, etc...).

--- Makefile.am ---
bin_PROGRAMS = myprog

myprog_SOURCES =        \
    main.cpp       \
    classb.cpp       \
    classc.cpp       \
    classd.cpp            

myprog_CXXFLAGS= $(OGRE_CFLAGS) $(OIS_CFLAGS)

myprog_CPPFLAGS = -I$(top_srcdir)/include 

myprog_LDFLAGS = -L/usr/lib64 -L/usr/local/lib64 -L/usr/local/lib 

myprog_LDADD = $(OGRE_LIBS) $(OIS_LIBS) -lopenal 

SUBDIRS= libs



Any helpl much appreciated.
-- 
View this message in context: 
http://old.nabble.com/cannot-specify--o-with--c-or--S-tp27714351p27714351.html
Sent from the Gnu - Automake - General mailing list archive at Nabble.com.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]