Revision 1418 trunk/contrib/GNUmakefile

GNUmakefile (revision 1418)
1 1
ifeq ($(SHELL),sh.exe)
2
  OBJSDIR=..\..\build\objects\dist
3
  OBJSDIR:=$(addsuffix \,$(OBJSDIR))
2
  OBJS_DIR=..\..\build\objects\dist
3
  OBJS_DIR:=$(addsuffix \,$(OBJS_DIR))
4
  OBJS_DIR2=..\build\objects\dist
5
  OBJS_DIR2:=$(addsuffix \,$(OBJS_DIR2))
4 6
  ifndef DIST
5 7
    DIST=..\build\dist
6 8
  endif
7
  CONTRIBDIR=$(addsuffix \contrib\,$(DIST))
9
  CONTRIB_DIR=..\$(addsuffix \contrib,$(DIST))
10
  CONTRIB_LIB=$(addsuffix \contrib\lib\,$(DIST))
8 11
else
9
  OBJSDIR=../../build/objects/dist
10
  OBJSDIR:=$(addsuffix /,$(OBJSDIR))
12
  OBJS_DIR=../../build/objects/dist/
13
  OBJS_DIR2=../build/objects/dist/
11 14
  ifndef DIST
12 15
    DIST=../build/dist
13 16
  endif
14
  CONTRIBDIR=$(addsuffix /contrib/,$(DIST))
17
  CONTRIB_DIR=../$(addsuffix /contrib,$(DIST))
18
  CONTRIB_LIB=$(addsuffix /contrib/lib/,$(DIST))
15 19
endif
16 20

  
17
all: libs build-ad2csv
21
all: libs contrib-ad2csv
18 22

  
19
libs: build-gdbprintlib build-statslib build-ecolib build-qfclib build-src
20
ifeq ($(SHELL),sh.exe)
21
	$(AR) -rs $(CONTRIBDIR)lib\libcontrib.a ..\build\objects\dist\saflp-contrib-*.obj
22
	$(AR) -rs $(CONTRIBDIR)lib\libcontribo.a ..\build\objects\dist\optlp-contrib-*.obj
23
else
24
	$(AR) -rs $(CONTRIBDIR)lib/libcontrib.a ../build/objects/dist/saflp-contrib-*.obj
25
	$(AR) -rs $(CONTRIBDIR)lib/libcontribo.a ../build/objects/dist/optlp-contrib-*.obj
26
endif
23
libs: contrib-gdbprintlib contrib-statslib contrib-ecolib contrib-qfclib contrib-src
24
	$(AR) -rs $(CONTRIB_LIB)libcontrib.a $(OBJS_DIR2)saflp-contrib-*.obj
25
	$(AR) -rs $(CONTRIB_LIB)libcontribo.a $(OBJS_DIR2)optlp-contrib-*.obj
27 26

  
28
build-gdbprintlib:
29
	$(MAKE) --directory=gdbprintlib PREFIX_OBJ=$(OBJSDIR)saflp-contrib-gdbprintlib-
30
	$(MAKE) --directory=gdbprintlib PREFIX_OBJ=$(OBJSDIR)optlp-contrib-gdbprintlib-
31
ifeq ($(SHELL),sh.exe)
32
	copy gdbprintlib\gdbprintlib.h $(CONTRIBDIR)include
33
else
34
	cp gdbprintlib/gdbprintlib.h $(CONTRIBDIR)include
35
endif
27
contrib-gdbprintlib:
28
	$(MAKE) --directory=gdbprintlib PREFIX=$(OBJS_DIR)saflp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
29
	$(MAKE) --directory=gdbprintlib OPTION=-f PREFIX=$(OBJS_DIR)optlp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
36 30

  
37
build-statslib:
38
	$(MAKE) --directory=statslib PREFIX_OBJ=$(OBJSDIR)saflp-contrib-statslib-
39
	$(MAKE) --directory=statslib OPTION=-f PREFIX_OBJ=$(OBJSDIR)optlp-contrib-statslib-
40
ifeq ($(SHELL),sh.exe)
41
	copy statslib\statsLib.h $(CONTRIBDIR)include
42
else
43
	cp statslib/statsLib.h $(CONTRIBDIR)include
44
endif
31
contrib-statslib:
32
	$(MAKE) --directory=statslib PREFIX=$(OBJS_DIR)saflp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
33
	$(MAKE) --directory=statslib OPTION=-f PREFIX=$(OBJS_DIR)optlp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
45 34

  
46
build-ecolib:
47
	$(MAKE) --directory=ecolib PREFIX_OBJ=$(OBJSDIR)saflp-contrib-ecolib-
48
	$(MAKE) --directory=ecolib OPTION=-f PREFIX_OBJ=$(OBJSDIR)optlp-contrib-ecolib-
49
ifeq ($(SHELL),sh.exe)
50
	copy ecolib\ecolib.h $(CONTRIBDIR)include
51
else
52
	cp ecolib/ecolib.h $(CONTRIBDIR)include
53
endif
35
contrib-ecolib:
36
	$(MAKE) --directory=ecolib PREFIX=$(OBJS_DIR)saflp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
37
	$(MAKE) --directory=ecolib OPTION=-f PREFIX=$(OBJS_DIR)optlp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
54 38

  
55
build-qfclib:
56
	$(MAKE) --directory=qfclib PREFIX_OBJ=$(OBJSDIR)saflp-contrib-qfclib-
57
	$(MAKE) --directory=qfclib OPTION=-f PREFIX_OBJ=$(OBJSDIR)optlp-contrib-qfclib-
58
ifeq ($(SHELL),sh.exe)
59
	copy qfclib\qfclib.h $(CONTRIBDIR)include
60
else
61
	cp qfclib/qfclib.h $(CONTRIBDIR)include
62
endif
39
contrib-qfclib:
40
	$(MAKE) --directory=qfclib PREFIX=$(OBJS_DIR)saflp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
41
	$(MAKE) --directory=qfclib OPTION=-f PREFIX=$(OBJS_DIR)optlp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
63 42

  
64
build-ad2csv:
65
	$(MAKE) --directory=ad2csv
43
contrib-src:
44
	$(MAKE) --directory=src PREFIX=$(OBJS_DIR)saflp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
45
	$(MAKE) --directory=src OPTION=-f PREFIX=$(OBJS_DIR)optlp-$@- CONTRIB_DIR=$(CONTRIB_DIR)
66 46

  
47
contrib-ad2csv:
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff