I'm a newbie in the context of programming with a console. My operating system is Snow Leopard.
To compile some systemC files I need the following Makefile:
thanks for your suggestion. I found following information:
-arch arch_name
Specifies which architecture (e.g. ppc, ppc64, i386, x86_64) the output file should be.
So i typed: $(CC) -arch i386 $(CFLAGS) $(INCDIR) $(LIBDIR) -o $@ $(OBJS) $(LIBS)
The new output is:
#g++ -g -Wno-deprecated -Wall -I. -I.. -I/Library/SystemC/systemc-2.2.0/include -L. -L.. -L/Library/SystemC/systemc-2.2.0/lib-macosx -o run main.o -lsystemc -lm
g++ -arch i386 -g -Wno-deprecated -Wall -I. -I.. -I/Library/SystemC/systemc-2.2.0/include -L. -L.. -L/Library/SystemC/systemc-2.2.0/lib-macosx -o run main.o -lsystemc -lm
ld: warning: in main.o, file was built for unsupported file format which is not the architecture being linked (i386)
Undefined symbols:
"_sc_main", referenced from:
_sc_elab_and_sim in libsystemc.a(sc_main_main.o)
ld: symbol(s) not found
collect2: ld returned 1 exit status
make: *** [run] Error 1