annotate src/libbiosig.mk @ 5067:01ced4433575

libbiossig: added new package * src/libbiosig-1-fixes.patch: new file * src/libbiosig.mk: new file * dist-files.mk: new file * index.html * binary-dist-rules.mk: add libbiosig as windows dist dependancy
author John Donoghue
date Thu, 09 May 2019 13:43:05 -0400
parents
children ba71349b1542
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5067
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
1 # This file is part of MXE.
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
2 # See index.html for further information.
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
3
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
4 PKG := libbiosig
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
5 $(PKG)_WEBSITE := http://biosig.sf.net/
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
6 $(PKG)_IGNORE :=
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
7 $(PKG)_VERSION := 1.9.4
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
8 $(PKG)_CHECKSUM := 03471cbc9b1a15bd646e7b0b98499964f6246149
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
9 $(PKG)_SUBDIR := biosig4c++-$($(PKG)_VERSION)
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
10 $(PKG)_FILE := biosig4c++-$($(PKG)_VERSION).src.tar.gz
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
11 $(PKG)_URL := https://sourceforge.net/projects/biosig/files/BioSig%20for%20C_C%2B%2B/src/$($(PKG)_FILE)/download
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
12 $(PKG)_DEPS := suitesparse zlib libiberty libiconv lapack
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
13
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
14 define $(PKG)_UPDATE
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
15 $(WGET) -q -O- 'http://biosig.sourceforge.net/download.html' | \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
16 $(SED) -n 's_.*>libbiosig, version \([0-9]\.[0-9]\.[0-9]\).*tar.gz_\1_ip' | \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
17 head -1
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
18 endef
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
19
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
20 define $(PKG)_BUILD_PRE
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
21
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
22 cd '$(1)' && ./configure \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
23 ac_cv_func_malloc_0_nonnull=yes \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
24 ac_cv_func_realloc_0_nonnull=yes \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
25 --prefix=$(HOST_PREFIX) \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
26 $(HOST_AND_BUILD_CONFIGURE_OPTIONS)
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
27
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
28 # make sure NDEBUG is defined
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
29 $(SED) -i '/NDEBUG/ s|#||g' '$(1)'/Makefile
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
30
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
31 ### disables declaration of sopen from io.h (imported through unistd.h)
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
32 if [ "$(MXE_SYSTEM)" == "mingw" ]; then \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
33 $(SED) -i '/ sopen/ s#^/*#//#g' $(HOST_INCDIR)/io.h; \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
34 fi
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
35
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
36 #$(SED) -i 's| -fstack-protector | |g' '$(1)'/Makefile
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
37 #$(SED) -i 's| -D_FORTIFY_SOURCE=2 | |g' '$(1)'/Makefile
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
38 #$(SED) -i 's| -lssp | |g' '$(1)'/Makefile
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
39
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
40 TARGET='$(TARGET)' $(MAKE) -C '$(1)' clean
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
41 TARGET='$(TARGET)' $(MAKE) -C '$(1)' -j '$(JOBS)' \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
42 libbiosig.a libgdf.a libphysicalunits.a
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
43 endef
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
44
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
45 define $(PKG)_BUILD_POST
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
46
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
47 $(INSTALL) -m644 '$(1)/biosig.h' '$(HOST_INCDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
48 $(INSTALL) -m644 '$(1)/biosig2.h' '$(HOST_INCDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
49 $(INSTALL) -m644 '$(1)/gdftime.h' '$(HOST_INCDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
50 $(INSTALL) -m644 '$(1)/biosig-dev.h' '$(HOST_INCDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
51
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
52 $(INSTALL) -m644 '$(1)/libbiosig.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
53 #$(INSTALL) -m644 '$(1)/libbiosig.def' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
54 #$(INSTALL) -m644 '$(1)/libbiosig.dll.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
55 #$(INSTALL) -m644 '$(1)/libbiosig.dll' '$(PREFIX)/$(TARGET)/bin/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
56
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
57 $(INSTALL) -m644 '$(1)/libgdf.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
58 #$(INSTALL) -m644 '$(1)/libgdf.def' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
59 #$(INSTALL) -m644 '$(1)/libgdf.dll.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
60 #$(INSTALL) -m644 '$(1)/libgdf.dll' '$(HOST_BINDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
61
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
62
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
63 $(INSTALL) -m644 '$(1)/physicalunits.h' '$(HOST_INCDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
64 $(INSTALL) -m644 '$(1)/libphysicalunits.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
65 #$(INSTALL) -m644 '$(1)/libphysicalunits.def' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
66 #$(INSTALL) -m644 '$(1)/libphysicalunits.dll.a' '$(HOST_LIBDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
67 #$(INSTALL) -m644 '$(1)/libphysicalunits.dll' '$(HOST_BINDIR)/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
68
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
69 if [ "$(MXE_WINDOWS_BUILD)" == "yes" ]; then \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
70 $(SED) -i '/^Libs:/ s/$$/ -liconv -lws2_32/' $(1)/libbiosig.pc; \
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
71 fi
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
72 $(INSTALL) -m644 '$(1)/libbiosig.pc' '$(HOST_LIBDIR)/pkgconfig/'
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
73
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
74 endef
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
75
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
76
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
77 define $(PKG)_BUILD
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
78 $($(PKG)_BUILD_PRE)
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
79 TARGET=$(TARGET) CROSS=$(TARGET) $(MAKE) -C '$(1)' libbiosig
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
80 $($(PKG)_BUILD_POST)
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
81 endef
01ced4433575 libbiossig: added new package
John Donoghue
parents:
diff changeset
82