Package: pluto-lunar / 0.0~git20180825.e34c1d1-1

completeMakefile.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
Index: pluto-lunar/makefile
===================================================================
--- pluto-lunar.orig/makefile
+++ pluto-lunar/makefile
@@ -26,11 +26,9 @@ CFLAGS ?= -Wextra -Wall -O3 -pedantic -W
 # (with root privileges) you can install them to /usr/local/include
 # and /usr/local/lib for all to enjoy.
 
-ifdef GLOBAL
-	INSTALL_DIR=/usr/local
-else
-	INSTALL_DIR=~
-endif
+PREFIX=usr
+DESTDIR=/
+INSTALL_DIR=$(DESTDIR)$(PREFIX)
 
 ifdef CLANG
 	CC=clang
@@ -59,7 +57,7 @@ ifdef XCOMPILE
    LIBSADDED=-L $(LIB_DIR) -mwindows
 endif
 
-all: adestest$(EXE) astcheck$(EXE) astephem$(EXE) calendar$(EXE) cgicheck$(EXE)  \
+all: liblunar.a adestest$(EXE) astcheck$(EXE) astephem$(EXE) calendar$(EXE) cgicheck$(EXE)  \
    colors$(EXE) colors2$(EXE) cosptest$(EXE) dist$(EXE) easter$(EXE) \
    get_test$(EXE) htc20b$(EXE) integrat$(EXE) jd$(EXE) \
    jevent$(EXE) jpl2b32$(EXE) jsattest$(EXE) lun_test$(EXE) \
@@ -67,7 +65,7 @@ all: adestest$(EXE) astcheck$(EXE) astep
    prectest$(EXE) prectes2$(EXE) ps_1996$(EXE) ssattest$(EXE) tables$(EXE) \
    test_ref$(EXE) testprec$(EXE) uranus1$(EXE) utc_test$(EXE)
 
-install:
+install: all liblunar.a
 	$(MKDIR) $(INSTALL_DIR)/include
 	cp afuncs.h   $(INSTALL_DIR)/include
 	cp cgi_func.h $(INSTALL_DIR)/include
@@ -84,7 +82,7 @@ install:
 	$(MKDIR) $(HOME)/bin
 	cp astcheck $(HOME)/bin
 
-install_integrat:
+install_integrat: integrat
 	cp integrat $(HOME)/bin
 
 uninstall: