Skip to content

Commit ba2a864

Browse files
committed
Makefile improvements.
* makefile (include makeconf): precede with '-', to suppress worrying warning. (install-*): don't define --project-subdir (made it impossible to uninstall). (uninstall): new. (upload-docs): removed, not needed since move to Github. * README.md: add gprbuild to prerequisites.
1 parent 61634c8 commit ba2a864

2 files changed

Lines changed: 31 additions & 46 deletions

File tree

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ The GUI developer RAPID does not depend on these unsupported features.
5656

5757
You need an Ada compiler. The instructions here are based on GNAT, though other compilers have been used and there is nothing GNAT-specific about TASH (there are GNAT-isms in the build support files).
5858

59+
You need `gprbuild`; many GNAT packages provide it by default, but it's a separate package under Debian.
60+
5961
You also need Tcl/Tk with working `tclsh` and `wish`. On macOS, you may need to use ActiveState's [Community Edition](https://www.activestate.com/products/tcl/downloads/) (Apple may cease Tcl/Tk support after Catalina).
6062

6163
On Unix systems, this should be all, aside from the usual development environment (`bash`/`sh`, `make` etc).

makefile

Lines changed: 29 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,7 @@
2727
# install"). If you want to install the TASH library elsewhere, say
2828
# $ make install prefix=/where/ever
2929

30-
makeconf:
31-
./setup.tcl --nogui
32-
include makeconf
30+
-include makeconf
3331

3432
SUBDIRS = src tests demos apps
3533

@@ -45,36 +43,42 @@ clean:
4543
$(FOR_ALL_SUBUNITS)
4644
rm -f makeconf tash_options.gpr
4745

46+
makeconf:
47+
./setup.tcl --nogui
48+
4849
# Rule "install" does not depend on rule "all":
49-
# "make install" should be executed as root but not necessarily "make all".
50+
# "make install" should be executed as root but "make all" need not be.
5051
install: install-static install-relocatable
5152

5253
install-static: src/lib-static-stamp
53-
gprinstall \
54-
-f \
55-
--prefix=$(prefix) \
56-
-P tash.gpr \
57-
--install-name=tash \
58-
--project-subdir=$(GPR_INSTALL_SUBDIR) \
59-
-XLIBRARY_TYPE=static \
60-
--mode=dev \
61-
--create-missing-dirs \
62-
--build-var=LIBRARY_TYPE \
54+
gprinstall \
55+
-f \
56+
--prefix=$(prefix) \
57+
-P tash.gpr \
58+
--install-name=tash \
59+
-XLIBRARY_TYPE=static \
60+
--mode=dev \
61+
--create-missing-dirs \
62+
--build-var=LIBRARY_TYPE \
6363
--build-name=static
6464

6565
install-relocatable: src/lib-relocatable-stamp
66-
gprinstall \
67-
-f \
68-
--prefix=$(prefix) \
69-
-P tash.gpr \
70-
--install-name=tash \
71-
--project-subdir=$(GPR_INSTALL_SUBDIR) \
72-
-XLIBRARY_TYPE=relocatable \
73-
--mode=dev \
74-
--create-missing-dirs \
75-
--build-var=LIBRARY_TYPE \
66+
gprinstall \
67+
-f \
68+
--prefix=$(prefix) \
69+
-P tash.gpr \
70+
--install-name=tash \
71+
-XLIBRARY_TYPE=relocatable \
72+
--mode=dev \
73+
--create-missing-dirs \
74+
--build-var=LIBRARY_TYPE \
7675
--build-name=relocatable
7776

77+
uninstall:
78+
gprinstall \
79+
--prefix=$(prefix) \
80+
--uninstall tash
81+
7882
# Rules for constructing a distribution.
7983

8084
DATE = $(shell date +%Y%m%d)
@@ -109,25 +113,4 @@ $(DIST).tgz: dist-src
109113
-rm $@
110114
tar zcvf $@ $(DIST)
111115

112-
# Rules for maintaining the SourceForge web pages.
113-
114-
# RSYNC ?= rsync
115-
116-
# SFUSER ?= simonjwright
117-
118-
# upload-docs:
119-
# $(RSYNC) \
120-
# --compress \
121-
# --copy-unsafe-links \
122-
# --cvs-exclude \
123-
# --perms \
124-
# --recursive \
125-
# --rsh=ssh \
126-
# --times \
127-
# --update \
128-
# --verbose \
129-
# web/* \
130-
# $(SFUSER),tcladashell@web.sourceforge.net:htdocs/
131-
132-
.PHONY: clean dist dist-src dist-zip dist-tgz force install rpm \
133-
test upload-docs
116+
.PHONY: clean dist dist-src dist-zip dist-tgz force install test uninstall

0 commit comments

Comments
 (0)