Changeset 909 for trunk/MagicSoft/Cosy/Makefile
- Timestamp:
- 08/15/01 12:39:04 (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Cosy/Makefile
r808 r909 11 11 12 12 # 13 # ----->>> settings for compiler 13 # please change all system depend values in the 14 # config.mk.${OSTYPE} file 15 # 16 # 17 include Makefile.conf.$(OSTYPE) 18 include Makefile.conf.general 19 14 20 # 15 21 16 CC = gcc 17 CXX = g++ 18 AR = ar -rc 19 AS = as 20 LD = ld 21 RANLIB = ranlib 22 23 # 24 # ----->>> settings for compilation 25 # 26 27 PROGRAMS = cosy starg 28 29 ROOTFLAGS = `root-config --cflags` 30 ROOTGLIBS = `root-config --glibs` 22 PROGRAMS = cosy starg 23 SOLIB = 24 CINT = M 25 INCLUDES = -I. -Iincl -Ibase -Igui -Idevdrv -Icandrv -Ivideodev -Icatalog 26 LIBS = -lpng -lz -L/usr/X11R6/lib 31 27 32 28 # … … 34 30 # 35 31 # WARNING: the result (whether the linkage works or not) depends on the 36 # order of the libraries 32 # order of the libraries. It seems, that the most base library 33 # must be the last one 37 34 # 38 #39 #LIBS = -L. -L/usr/lib -lstdc++ -lpthread40 INCLUDES = -I. -I/usr/X11R6/include -Icandrv -Idevdrv -Ibase -Igui -Iincl -Islalib -Ivideodev -Icatalog41 LIBS = -L. -L/usr/X11R6/lib -lpthread -lpng -lz42 #INCLUDES = -I. -Ibase -Igui -Islalib43 44 WARNING = -Wall -fno-rtti -fno-exceptions45 OPTIM = -O246 DEBUG = -g47 DEFINES = -DCPU=486 -DBUS_LITTLE_ENDIAN -DDEBUG=0 -DLINUX -DSHOW48 49 CFLAGS = $(OPTIM) $(DEBUG) $(WARNING) $(INCLUDES) $(ROOTFLAGS) $(DEFINES)50 CXXFLAGS = $(CFLAGS)51 52 CINT = M53 35 54 36 # 55 37 # ----->>> mars libraries 56 38 # 39 SUBDIRS = \ 40 candrv \ 41 catalog \ 42 devdrv \ 43 gui \ 44 videodev \ 45 base \ 46 slalib 47 48 LIBRARIES = $(SUBDIRS:=.a) 57 49 58 50 #------------------------------------------------------------------------------ 59 .SILENT:60 51 61 52 .SUFFIXES: .c .cc .h .o 62 53 63 SLASRC = slalib/cldj.c slalib/dranrm.c slalib/mappa.c slalib/aoppa.c \ 64 slalib/mapqk.c slalib/aopqk.c slalib/epj.c slalib/evp.c \ 65 slalib/dvn.c slalib/prenut.c slalib/geoc.c slalib/refco.c \ 66 slalib/eqeqx.c slalib/dcs2c.c slalib/dvdv.c slalib/dmxv.c \ 67 slalib/dcc2s.c slalib/refz.c slalib/refro.c slalib/prec.c \ 68 slalib/nut.c slalib/dmxm.c slalib/nutc.c slalib/range.c \ 69 slalib/aoppat.c slalib/deuler.c slalib/drange.c slalib/daf2r.c \ 70 slalib/dh2e.c slalib/gmst.c slalib/de2h.c slalib/altaz.c \ 71 slalib/gmsta.c slalib/dat.c slalib/dtt.c slalib/oapqk.c \ 72 slalib/ampqk.c slalib/dimxv.c slalib/mapqkz.c slalib/dr2af.c \ 73 slalib/dd2tf.c 74 75 SLAOBJ = $(SLASRC:.c=.o) 76 77 SRCFILES = candrv/vmodican.cc \ 78 candrv/canopen.cc \ 79 candrv/network.cc \ 80 candrv/nodedrv.cc \ 81 candrv/sdolist.cc \ 82 devdrv/shaftencoder.cc \ 83 devdrv/macs.cc \ 84 gui/MGCosy.cc \ 85 gui/MGImage.cc \ 86 gui/MGCoordinate.cc \ 87 gui/MGCoordinates.cc \ 88 base/timer.cc \ 89 base/msgqueue.cc \ 90 base/File.cc \ 91 base/MStopwatch.cc \ 92 catalog/SaoFile.cc \ 93 catalog/StarCatalog.cc \ 94 catalog/Slalib.cc \ 95 videodev/Camera.cc \ 96 videodev/Filter.cc \ 97 videodev/Writer.cc \ 98 MStarguider.cc \ 99 MCosy.cc \ 100 Starguider.cc 54 SRCFILES = MCosy.cc Starguider.cc 101 55 102 56 SRCS = $(SRCFILES) … … 106 60 ############################################################ 107 61 108 all: $(PROGRAMS)62 all: rmlib $(PROGRAMS) $(SOLIB) 109 63 110 $(SLAOBJ): 111 echo 'Compiling $*.c' 112 $(CC) -c $(CFLAGS) -pedantic $*.c -o $*.o 64 # Use $(CXX) -v ... for a more verbose output 65 # 66 # We could link mars.so instead of all libraries. This would need 67 # some MBs less space on the HD. But this means, that the Shared 68 # Library Path in your system must be set properly to be able to start 69 # 'mars' 70 # 71 $(PROGRAMS): $(LIBRARIES) $(OBJS) $(HEADERS) $(PROGRAMS:=.o) 72 @echo " Linking $@ ..." 73 $(CXX) $(CXXFLAGS) $(LIBS) $@.o $(OBJS) $(MARS_LIB) $(ROOTGLIBS) -o $@ 113 74 114 #$(PROGRAMS): $(PROGRAMS:=.o) $(OBJS) $(SLAOBJ) 115 # @echo " Linking $@ ..." 116 # $(CXX) $(CXXFLAGS) $@.o $(LIBS) $(ROOTGLIBS) -o $@ 117 $(PROGRAMS): $(SLAOBJ) $(OBJS) $(PROGRAMS:=.o) 118 @echo " Linking $@ ..." 119 $(CXX) $(CXXFLAGS) $(LIBS) $(SLAOBJ) $(OBJS) $(ROOTGLIBS) -o $@ $@.o 75 $(SOLIB): $(LIBRARIES) $(OBJS) $(HEADERS) MCint.o 76 @echo " Linking $(SOLIB) ..." 77 $(CXX) -shared $(CXXFLAGS) $(SUBDIRS:=/*.o) $(ROOTGLIBS) -o $@ 78 mv cosy.so lib 120 79 121 #dox: 122 # @echo " Creating html documentation:" 123 # root -b -q dohtml.C 80 $(LIBRARIES): 81 @echo " " 82 @echo " Creating lib$@:" 83 (cd $*; make -f Makefile; cd ..; mv $*/$@ lib/lib$@) 124 84 85 dox: 86 @echo " Creating html documentation:" 87 root -b -q dohtml.C 125 88 126 89 include Makefile.rules 127 90 128 clean: rm cint rmobjs rmcore rmbin rmbak91 clean: rmlib rmcint rmobjs rmcore rmbin 129 92 130 tar: clean 93 mrproper: clean rmbak 94 @rm -f macros/*~ 95 @rm -rf htmldoc 96 @echo "cd base" 97 @cd base; make mrproper; cd .. 98 @echo "cd .." 99 @echo "cd candrv" 100 @cd candrv; make mrproper; cd .. 101 @echo "cd .." 102 @echo "cd devdrv" 103 @cd devdrv; make mrproper; cd .. 104 @echo "cd .." 105 @echo "cd gui" 106 @cd gui; make mrproper; cd .. 107 @echo "cd .." 108 @echo "cd videodev" 109 @cd videodev; make mrproper; cd .. 110 @echo "cd .." 111 @echo "cd catalog" 112 @cd videodev; make mrproper; cd .. 113 @echo "cd .." 114 115 tar: mrproper 131 116 @echo "Making tar-file" 132 117 @tar -cvf ../cosy.tar *
Note:
See TracChangeset
for help on using the changeset viewer.