annotate src/cfitsio.mk @ 7207:9ed6500e56d3 default tip @

maint: Merge release to default.
author Markus Mützel <markus.muetzel@gmx.de>
date Fri, 17 May 2024 20:16:41 +0200
parents ee9e63cb789d
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3163
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
1 # This file is part of MXE.
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
2 # See index.html for further information.
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
3
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
4 PKG := cfitsio
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
5 $(PKG)_IGNORE :=
7091
ee9e63cb789d * src/cfitsio.mk: update to v4.4.0
John Donoghue <john.donoghue@ieee.org>
parents: 6980
diff changeset
6 $(PKG)_VERSION := 4.4.0
ee9e63cb789d * src/cfitsio.mk: update to v4.4.0
John Donoghue <john.donoghue@ieee.org>
parents: 6980
diff changeset
7 $(PKG)_CHECKSUM := c308310db7541b5c43e5a3d06f1255344b505a2c
6236
d3d051b4515f cfitsio: update to v4.1.0
John Donoghue <john.donoghue@ieee.org>
parents: 5454
diff changeset
8 $(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
d3d051b4515f cfitsio: update to v4.1.0
John Donoghue <john.donoghue@ieee.org>
parents: 5454
diff changeset
9 $(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.gz
5182
1ed1841b0adc * src/cfitsio.mk: update download url
John Donoghue
parents: 4997
diff changeset
10 $(PKG)_URL := https://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/$($(PKG)_FILE)
5454
cd41c2d17ef3 Update dependancies on packages
John Donoghue <john.donoghue@ieee.org>
parents: 5390
diff changeset
11 $(PKG)_DEPS := curl
3163
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
12
3182
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
13 $(PKG)_MAKE_FLAGS :=
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
14 ifeq ($(BUILD_SHARED),yes)
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
15 $(PKG)_MAKE_FLAGS += shared
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
16 endif
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
17
4997
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
18 $(PKG)_CONFIGURE_FLAGS :=
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
19 ifeq ($(MXE_SYSTEM),mingw)
6811
c04e1789dc7a cfitsio: update to v4.3.0
John Donoghue <john.donoghue@ieee.org>
parents: 6533
diff changeset
20 $(PKG)_CONFIGURE_FLAGS += --disable-curl
4997
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
21 endif
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
22
3163
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
23 define $(PKG)_UPDATE
3708
d95b8b84cea7 enable additional $(PKG)_UPDATE targets.
John W. Eaton <jwe@octave.org>
parents: 3694
diff changeset
24 $(WGET) -q -O- "http://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/?C=M;O=D" | \
d95b8b84cea7 enable additional $(PKG)_UPDATE targets.
John W. Eaton <jwe@octave.org>
parents: 3694
diff changeset
25 grep -i '<a href="cfitsio.*tar' | \
6236
d3d051b4515f cfitsio: update to v4.1.0
John Donoghue <john.donoghue@ieee.org>
parents: 5454
diff changeset
26 $(SED) -n 's,.*cfitsio-\([0-9\.][^>]*\)\.tar.*,\1,p' | \
3708
d95b8b84cea7 enable additional $(PKG)_UPDATE targets.
John W. Eaton <jwe@octave.org>
parents: 3694
diff changeset
27 head -1
3163
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
28 endef
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
29
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
30 ifeq ($(MXE_SYSTEM),msvc)
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
31 define $(PKG)_BUILD
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
32 $(SED) -i 's/cfitsio\.dll/$(LIBRARY_PREFIX)cfitsio$(LIBRARY_SUFFIX).dll/g' '$(1)/makefile.vcc'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
33 cd '$(1)' && env -u MAKE -u MAKEFLAGS nmake -f makefile.vcc
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
34 $(SED) -e 's#@prefix@#$(HOST_PREFIX)#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
35 -e 's#@exec_prefix@#$${prefix}#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
36 -e 's#@libdir@#$${exec_prefix}/lib#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
37 -e 's#@includedir@#$${prefix}/include#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
38 -e 's#@LIBS@##' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
39 -e '/^Libs\.private:/ { s#-lm\>##; }' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
40 -e 's#@CFITSIO_MAJOR@#$(word 1,$(subst ., ,$($(PKG)_VERSION)))#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
41 -e 's#@CFITSIO_MINOR@#$(word 2,$(subst ., ,$($(PKG)_VERSION)))#' \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
42 '$(1)/cfitsio.pc.in' > '$(1)/cfitsio.pc'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
43 $(INSTALL) -d '$(HOST_BINDIR)'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
44 $(INSTALL) '$(1)/$(LIBRARY_PREFIX)cfitsio$(LIBRARY_SUFFIX).dll' '$(HOST_BINDIR)'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
45 $(INSTALL) -d '$(HOST_LIBDIR)'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
46 $(INSTALL) '$(1)/cfitsio.lib' '$(HOST_LIBDIR)'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
47 $(INSTALL) -d '$(HOST_LIBDIR)/pkgconfig'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
48 $(INSTALL) '$(1)/cfitsio.pc' '$(HOST_LIBDIR)/pkgconfig'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
49 $(INSTALL) -d '$(HOST_INCDIR)'
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
50 for f in fitsio.h fitsio2.h longnam.h drvrsmem.h; do \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
51 $(INSTALL) "$(1)/$$f" '$(HOST_INCDIR)'; \
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
52 done
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
53 endef
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
54 else
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
55 define $(PKG)_BUILD
4997
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
56 cd '$(1)' && autoreconf -fi && '$(1)/configure' \
3182
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
57 $(CONFIGURE_CPPFLAGS) $(CONFIGURE_LDFLAGS) \
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
58 $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \
4997
97fc509bb1df cfitsio: update tp v3.45
John Donoghue
parents: 4433
diff changeset
59 $($(PKG)_CONFIGURE_FLAGS) \
3182
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
60 --prefix='$(HOST_PREFIX)'
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
61 $(MAKE) -C '$(1)' -j '$(JOBS)' $($(PKG)_MAKE_FLAGS)
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
62 $(MAKE) -C '$(1)' -j 1 install
23a5b6df3061 Update cfitsio for mingw build
John Donoghue <john.donoghue@ieee.org>
parents: 3163
diff changeset
63
4299
920efecee003 * src/cfitsio.mk: copy dll to bin dir
John D
parents: 4142
diff changeset
64 if [ "$(MXE_SYSTEM)" == "mingw" ]; then \
920efecee003 * src/cfitsio.mk: copy dll to bin dir
John D
parents: 4142
diff changeset
65 $(INSTALL) '$(1)/libcfitsio$(LIBRARY_SUFFIX).dll' '$(HOST_BINDIR)'; \
5390
a4de1bcb9612 * src/cfitsio.mk: remove dll from lib directory
John Donoghue <john.donoghue@ieee.org>
parents: 5182
diff changeset
66 rm -f $(HOST_LIBDIR)/libcfitsio$(LIBRARY_SUFFIX).dll; \
4299
920efecee003 * src/cfitsio.mk: copy dll to bin dir
John D
parents: 4142
diff changeset
67 fi
3163
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
68 endef
18c5fa5ce861 Add CFITSIO module (currently only compiles with MSVC)
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff changeset
69 endif