TOPDIR	:= $(shell if [ "$$PWD" != "" ]; then echo $$PWD; else pwd; fi)

all: libs utils
libs: rawfiles.o
utils: ../../../bin/rawfilesgen

../../../bin/rawfilesgen: rawfilesgen.cpp
	g++ $(OPTS) -o ../../../bin/rawfilesgen -I/usr/include/g++-include -I../../../include rawfilesgen.cpp `find ../../.. -type f -name "*.o" -print`

rawfiles.o: rawfiles.cpp ../../../include/swcom.h ../../../include/rawfiles.h
	g++ $(OPTS) -c -I/usr/include/g++-include -I../../../include rawfiles.cpp
