Browse code

- added tools version in INSTALL (e.g. gmake >=3.79) - fixed test -e to test -f in Makefile (install-cfg) - INSTALL, TAR, BASEDIR are now setable in the environment (also PREFIX, LOCALBASE, CC, LEX, YACC)

Andrei Pelinescu-Onciul authored on 07/04/2003 11:57:09
Showing 3 changed files
... ...
@@ -55,7 +55,7 @@ Requirements:
55 55
 - bison or yacc (Berkley yacc)
56 56
 - flex
57 57
 - GNU make (on Linux this is the standard "make", on FreeBSD and Solaris is
58
- called "gmake")
58
+ called "gmake") version >= 3.79.
59 59
 - sed and tr (used in the makefiles)
60 60
 - GNU tar ("gtar" on Solaris) and gzip if you want "make tar" to work
61 61
 - GNU install or BSD install (on Solaris "ginstall") if you want "make
... ...
@@ -170,7 +170,7 @@ install-cfg: $(cfg-prefix)/$(cfg-dir)
170 170
 		sed -e "s#/usr/lib/ser/modules/#$(modules-target)#g" \
171 171
 			< etc/ser.cfg > $(cfg-prefix)/$(cfg-dir)ser.cfg.default
172 172
 		chmod 644 $(cfg-prefix)/$(cfg-dir)ser.cfg.default
173
-		if [ ! -e $(cfg-prefix)/$(cfg-dir)ser.cfg ]; then \
173
+		if [ ! -f $(cfg-prefix)/$(cfg-dir)ser.cfg ]; then \
174 174
 			cp -p $(cfg-prefix)/$(cfg-dir)ser.cfg.default \
175 175
 				$(cfg-prefix)/$(cfg-dir)ser.cfg; \
176 176
 		fi
... ...
@@ -2,6 +2,9 @@
2 2
 #
3 3
 # makefile defs (CC, LD,a.s.o)
4 4
 #
5
+# Environment variables:
6
+#   PREFIX, LOCALBASE, BASEDIR
7
+#   INSTALL, TAR , CC, LEX, YACC
5 8
 #
6 9
 # History:
7 10
 # --------
... ...
@@ -34,7 +37,9 @@ prefix = $(PREFIX)
34 37
 #  creating a bin. archive in /tmp, which unpacks in /usr/local
35 38
 #  basedir=/tmp
36 39
 #  prefix=/usr/local
37
-basedir = 
40
+
41
+BASEDIR ?=
42
+basedir = $(BASEDIR)
38 43
 # install prefixes for various stuff
39 44
 cfg-prefix = $(basedir)$(prefix)
40 45
 bin-prefix = $(basedir)$(prefix)
... ...
@@ -67,11 +72,11 @@ modules-target = $(prefix)/$(modules-dir)
67 72
 
68 73
 ifeq ($(OS), solaris)
69 74
 #use GNU versions
70
-INSTALL = ginstall
71
-TAR = gtar
75
+INSTALL ?= ginstall
76
+TAR ?= gtar
72 77
 else
73
-INSTALL = install 
74
-TAR= tar
78
+INSTALL ?= install 
79
+TAR ?= tar
75 80
 endif
76 81
 
77 82
 # INSTALL-CFG = $(INSTALL) -m 644