Mercurial > forge
annotate main/fixed/src/Makefile @ 9481:d84d2fea3c90 octave-forge
Re-enable compilation of fixed package
author | jordigh |
---|---|
date | Wed, 22 Feb 2012 22:07:33 +0000 |
parents | 40467ad5cada |
children | df50d0ae107f |
rev | line source |
---|---|
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
1 sinclude Makeconf |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
2 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
3 FIXEDVERTARGET = fixedversion.h |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
4 FIXEDTARGET = fixed.oct |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
5 |
3065
c9748be75a06
Implement symbol export mechanism similar to octave, for MSVC
goffioul
parents:
2745
diff
changeset
|
6 DLLDEF = |
4797 | 7 ADD_FLAGS = |
4418 | 8 ifneq (,$(findstring cygwin,$(canonical_host_type))) |
9 DLLDEF = -DFIXED_DLL | |
4797 | 10 ADD_FLAGS = -Wl,--out-implib=libfixed.a |
4418 | 11 endif |
12 ifneq (,$(findstring mingw,$(canonical_host_type))) | |
13 DLLDEF = -DFIXED_DLL | |
4797 | 14 ADD_FLAGS = -Wl,--out-implib=libfixed.a |
4418 | 15 endif |
16 ifneq (,$(findstring msdosmsvc,$(canonical_host_type))) | |
17 DLLDEF = -DFIXED_DLL | |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
18 endif |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
19 |
4631 | 20 FIXEDSOURCES = fixedColVector.cc fixedRowVector.cc \ |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
21 fixedMatrix.cc fixedComplex.cc fixedCColVector.cc fixedCRowVector.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
22 fixedCMatrix.cc Array-f.cc fixed-conv.cc ov-fixed.cc ov-fixed-mat.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
23 fixedNDArray.cc fixedCNDArray.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
24 ov-fixed-complex.cc ov-fixed-cx-mat.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
25 op-fs-fs.cc op-fs-fm.cc op-fm-fs.cc op-fm-fm.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
26 op-fs-fcs.cc op-fs-fcm.cc op-fm-fcs.cc op-fm-fcm.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
27 op-fcs-fs.cc op-fcs-fm.cc op-fcm-fs.cc op-fcm-fm.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
28 op-fcs-fcs.cc op-fcs-fcm.cc op-fcm-fcs.cc op-fcm-fcm.cc \ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
29 fixed-var.cc fixed.cc |
9481 | 30 FIXEDOBJECTS = int/fixed.o $(patsubst %.cc,%.o,$(FIXEDSOURCES)) |
31 FIXEDDEPENDS = int/fixed.d $(patsubst %.cc,%.d,$(FIXEDSOURCES)) | |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
32 |
4631 | 33 TARGETS = $(FIXEDTARGET) |
34 OBJECTS = $(FIXEDOBJECTS) | |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
35 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
36 ifeq ($(MAKECMDGOALS),all) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
37 DEPENDS = $(FIXEDDEPENDS) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
38 endif |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
39 ifeq ($(MAKECMDGOALS),) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
40 DEPENDS = $(FIXEDDEPENDS) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
41 endif |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
42 |
4631 | 43 DELETES = $(OBJECTS) $(FIXEDDEPENDS) $(TARGETS) $(FIXEDVERTARGET) \ |
44 core octave-core *~ *.d-t int/fixed.o int/fixed.d \ | |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
45 int/fixed.d-t FILES |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
46 |
4631 | 47 DEFINES = -DOCTAVE_FORGE $(DLLDEF) |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
48 MOFLAGS = |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
49 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
50 .PHONY: all clean count |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
51 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
52 .SUFFIXES: |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
53 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
54 .PRECIOUS: %.d %.o |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
55 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
56 all : $(TARGETS) |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
57 @if [ -f FILES ]; then \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
58 $(RM) -f FILES; \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
59 fi; \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
60 touch FILES; \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
61 for _f in $(TARGETS); do \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
62 echo $$_f >> FILES; \ |
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
63 done |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
64 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
65 ifndef OCTAVE_FORGE |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
66 install : |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
67 @echo "Where exactly do you want me to install to!!!" |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
68 else |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
69 install : |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
70 @$(INSTALL) -d $(DESTDIR)$(MPATH)/fixed |
3359
4f23e9c5957a
merge octave_fixed.dll into fixed.oct to avoid installing files (DLL) outside of the normal package directory [Win32/MSVC]
goffioul
parents:
3065
diff
changeset
|
71 |
4f23e9c5957a
merge octave_fixed.dll into fixed.oct to avoid installing files (DLL) outside of the normal package directory [Win32/MSVC]
goffioul
parents:
3065
diff
changeset
|
72 $(FIXEDOBJECTS) $(FIXEDDEPENDS): DEFINES := $(DEFINES) $(DLLDEF) |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
73 endif |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
74 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
75 $(FIXEDTARGET) : $(DEPENDS) $(FIXEDOBJECTS) |
9481 | 76 @echo "Linking $@"; |
4418 | 77 $(MKOCTFILE) $(ADD_FLAGS) $(MOFLAGS) $(FIXEDOBJECTS) $(EXTRALIBS) -o $@ |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
78 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
79 $(FIXEDVERTARGET) : |
9481 | 80 @echo "Creating $@"; $(RM) -f $@; |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
81 echo "#define OCTAVEFIXEDVERSION \"$(OCTAVEFIXEDVERSION)\"" > $@ |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
82 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
83 ifneq (,$(DEPENDS)) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
84 sinclude $(DEPENDS) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
85 endif |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
86 |
9481 | 87 int/fixed.d : int/fixed.cc |
88 @echo "Depending $<"; | |
89 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -M int/fixed.cc; | |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
90 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
91 fixed-var.d : $(FIXEDVERTARGET) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
92 |
9481 | 93 int/fixed.o : int/fixed.cc int/fixed.d |
94 @echo "Compiling $@ from $<" | |
95 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -c -o $@ $< | |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
96 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
97 %.d: %.cc |
9481 | 98 @echo "Depending $<" |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
99 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -M $< |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
100 |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
101 %.o:%.cc |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
102 %.o:%.cc %.d |
9481 | 103 @echo "Compiling $@" |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
104 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -c $< |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
105 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
106 clean: |
9481 | 107 @echo "Cleaning..." |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
108 $(RM) -f $(DELETES) |
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
109 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
110 realclean: |
9481 | 111 @echo "Cleaning..." |
4632 | 112 $(RM) -f $(DELETES) Makeconf config.log config.status |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
113 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
114 dist: |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
115 |
2745
4b4fbe3a7c2b
Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents:
2400
diff
changeset
|
116 count: |
2383
d1930f8af7ca
Changed the directory structure of fixed to match the package system
hauberg
parents:
diff
changeset
|
117 wc *{.cc,.h,.m} int/*.{cc,h} |