annotate main/fixed/src/Makefile @ 9929:df50d0ae107f octave-forge

Add HDF5 linking flags
author jordigh
date Fri, 30 Mar 2012 15:02:12 +0000
parents d84d2fea3c90
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
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
9929
df50d0ae107f Add HDF5 linking flags
jordigh
parents: 9481
diff changeset
3 HDF5_LIBS := $(shell grep "\#define OCTAVE_CONF_HDF5_LIBS" $(shell mkoctfile -p OCTINCLUDEDIR)/oct-conf.h | sed "s/^.*LIBS //" )
df50d0ae107f Add HDF5 linking flags
jordigh
parents: 9481
diff changeset
4
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
5 FIXEDVERTARGET = fixedversion.h
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
6 FIXEDTARGET = fixed.oct
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
7
3065
c9748be75a06 Implement symbol export mechanism similar to octave, for MSVC
goffioul
parents: 2745
diff changeset
8 DLLDEF =
4797
40467ad5cada Mingw build fix (For Tatsuro Matsuoka)
adb014
parents: 4632
diff changeset
9 ADD_FLAGS =
4418
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
10 ifneq (,$(findstring cygwin,$(canonical_host_type)))
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
11 DLLDEF = -DFIXED_DLL
4797
40467ad5cada Mingw build fix (For Tatsuro Matsuoka)
adb014
parents: 4632
diff changeset
12 ADD_FLAGS = -Wl,--out-implib=libfixed.a
4418
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
13 endif
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
14 ifneq (,$(findstring mingw,$(canonical_host_type)))
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
15 DLLDEF = -DFIXED_DLL
4797
40467ad5cada Mingw build fix (For Tatsuro Matsuoka)
adb014
parents: 4632
diff changeset
16 ADD_FLAGS = -Wl,--out-implib=libfixed.a
4418
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
17 endif
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
18 ifneq (,$(findstring msdosmsvc,$(canonical_host_type)))
5c46c15f6053 MinGW build fix (For Tatsuro Matsuoka)
adb014
parents: 4309
diff changeset
19 DLLDEF = -DFIXED_DLL
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
20 endif
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
21
4631
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
22 FIXEDSOURCES = fixedColVector.cc fixedRowVector.cc \
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
23 fixedMatrix.cc fixedComplex.cc fixedCColVector.cc fixedCRowVector.cc \
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
24 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
25 fixedNDArray.cc fixedCNDArray.cc \
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
26 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
27 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
28 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
29 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
30 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
31 fixed-var.cc fixed.cc
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
32 FIXEDOBJECTS = int/fixed.o $(patsubst %.cc,%.o,$(FIXEDSOURCES))
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
33 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
34
4631
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
35 TARGETS = $(FIXEDTARGET)
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
36 OBJECTS = $(FIXEDOBJECTS)
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
37
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
38 ifeq ($(MAKECMDGOALS),all)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
39 DEPENDS = $(FIXEDDEPENDS)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
40 endif
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
41 ifeq ($(MAKECMDGOALS),)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
42 DEPENDS = $(FIXEDDEPENDS)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
43 endif
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
44
4631
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
45 DELETES = $(OBJECTS) $(FIXEDDEPENDS) $(TARGETS) $(FIXEDVERTARGET) \
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
46 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
47 int/fixed.d-t FILES
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
48
4631
1b0a2d6110ca attempt at build fix for fixed package
adb014
parents: 4527
diff changeset
49 DEFINES = -DOCTAVE_FORGE $(DLLDEF)
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
50 MOFLAGS =
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
51
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
52 .PHONY: all clean count
2383
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 .SUFFIXES:
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
55
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
56 .PRECIOUS: %.d %.o
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
57
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
58 all : $(TARGETS)
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
59 @if [ -f FILES ]; then \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
60 $(RM) -f FILES; \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
61 fi; \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
62 touch FILES; \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
63 for _f in $(TARGETS); do \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
64 echo $$_f >> FILES; \
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
65 done
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
66
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
67 ifndef OCTAVE_FORGE
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
68 install :
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
69 @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
70 else
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
71 install :
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
72 @$(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
73
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
74 $(FIXEDOBJECTS) $(FIXEDDEPENDS): DEFINES := $(DEFINES) $(DLLDEF)
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
75 endif
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
76
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
77 $(FIXEDTARGET) : $(DEPENDS) $(FIXEDOBJECTS)
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
78 @echo "Linking $@";
9929
df50d0ae107f Add HDF5 linking flags
jordigh
parents: 9481
diff changeset
79 $(MKOCTFILE) $(ADD_FLAGS) $(MOFLAGS) $(FIXEDOBJECTS) $(EXTRALIBS) $(HDF5_LIBS) -o $@
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
80
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
81 $(FIXEDVERTARGET) :
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
82 @echo "Creating $@"; $(RM) -f $@;
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
83 echo "#define OCTAVEFIXEDVERSION \"$(OCTAVEFIXEDVERSION)\"" > $@
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
84
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
85 ifneq (,$(DEPENDS))
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
86 sinclude $(DEPENDS)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
87 endif
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
88
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
89 int/fixed.d : int/fixed.cc
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
90 @echo "Depending $<";
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
91 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -M int/fixed.cc;
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
92
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
93 fixed-var.d : $(FIXEDVERTARGET)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
94
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
95 int/fixed.o : int/fixed.cc int/fixed.d
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
96 @echo "Compiling $@ from $<"
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
97 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -c -o $@ $<
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
98
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
99 %.d: %.cc
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
100 @echo "Depending $<"
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
101 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -M $<
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
102
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
103 %.o:%.cc
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
104 %.o:%.cc %.d
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
105 @echo "Compiling $@"
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
106 $(MKOCTFILE) $(MOFLAGS) $(DEFINES) -c $<
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
107
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
108 clean:
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
109 @echo "Cleaning..."
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
110 $(RM) -f $(DELETES)
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
111
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
112 realclean:
9481
d84d2fea3c90 Re-enable compilation of fixed package
jordigh
parents: 4797
diff changeset
113 @echo "Cleaning..."
4632
9de4481b4710 Extra clean targets (For Rafael Laboissiere)
adb014
parents: 4631
diff changeset
114 $(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
115
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
116 dist:
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
117
2745
4b4fbe3a7c2b Get rid of redundant build code. Fixes build issue on Solaris
adb014
parents: 2400
diff changeset
118 count:
2383
d1930f8af7ca Changed the directory structure of fixed to match the package system
hauberg
parents:
diff changeset
119 wc *{.cc,.h,.m} int/*.{cc,h}