1 # Top-level Makefile for wxGTK by Wolfram Gloger
2 # based on the version for wx-Xt by Martin Sperl
6 #if DIRS are defind make only executes in these diretories
8 @if
test "x$(DIRS)" = x
; then \
9 for i in src samples utils user
; do \
10 echo
"entering directory $$i building $@"; \
11 (cd
$$i; ${MAKE} -k
$@
); \
14 for i in
$(DIRS
) xxx
; do \
15 if
test "$$i" != xxx
; then \
16 echo
"entering directory $$i building $@"; \
17 (cd
$$i; ${MAKE} -k
$@
); \
22 # what to do if a target is not understood:
23 # pass it on to all the children...
26 @if
test "x$(DIRS)" = x
; then \
27 for i in src samples utils user
; do \
28 echo
"entering directory $$i building $@"; \
29 (cd
$$i; ${MAKE} -k
$@
); \
32 for i in
$(DIRS
) xxx
; do \
33 if
test "$$i" != xxx
; then \
34 echo
"entering directory $$i building $@"; \
35 (cd
$$i; ${MAKE} -k
$@
); \
41 @echo
"entering directory src building all"
45 @echo
"entering directory samples building all"
46 @cd samples
; ${MAKE} all
49 @echo
"entering directory utils building all"
50 @cd utils
; ${MAKE} all
53 @echo
"entering directory user building all"
57 @echo
"entering directory src for installing"
58 @cd src
; ${MAKE} install
59 @echo
"entering directory utils for installing"
60 @cd utils
; ${MAKE} install
62 # the following ones recreate all Makefiles.
67 @setup
/general
/createall
69 # the following ones define what needs to be done to distribute the
70 # library and its components
73 distrib
:: distrib_base distrib_user join_utils join_samples
76 @echo
"entering directory samples creating distribution files"
77 @
(cd samples
; ${MAKE} -k distrib
)
80 @echo
"entering directory user creating distribution files"
81 @
(cd user
; ${MAKE} -k distrib
)
84 @echo
"entering directory utils creating distribution files"
85 @
(cd utils
; ${MAKE} -k distrib
)
87 join_utils
:: distrib_utils
90 FILES
=`echo distrib/utils/*.tgz `
92 join_samples
:: distrib_samples
95 FILES
=`echo distrib/samples/*.tgz `
97 join_user
:: distrib_user
100 FILES
=`echo distrib/user/*.tgz `
103 @
# needed are BASEDIR and FILES
104 @if
test "x$$BASEDIR" = x
; then\
105 echo
"BASEDIR not specified.";\
108 @if
test "x$$FILES" != x
; then \
109 echo
"putting all seperate distribution files:";\
111 echo
"into distrib/$(BASEDIR).tgz";\
112 src
/gtk
/setup
/general
/jointar
$(BASEDIR
) $$FILES distrib
/$(BASEDIR
).tgz
; \
114 echo
"Nothing to join - deleting..."; \
115 echo
"This may be the case, if you have not specified FILES."\
116 rm -f distrib
/$(BASEDIR
).tgz
; \
120 @if
test ! -d distrib
; then mkdir distrib
; fi
;
121 @if
test ! -f system.list
; then \
122 echo
"dummy" > system.list
;\
124 @
(curr
=`pwd`; direc
=`basename $$curr`;\
126 echo creating distrib
/$$direc.
tar from the current directory
;\
127 tar -cf
/tmp
/$$direc.
tar \
131 $$direc/template.mak\
133 $$direc/configure.in\
134 $$direc/config.guess\
137 $$direc/user
/Makefile \
138 $$direc/utils
/Makefile \
139 $$direc/samples
/Makefile \
141 sed
"s|^\(.*\)$$|/\1/|g" $$direc/system.list \
142 | uniq
> /tmp
/$$direc.list
; \
143 echo
"/RCS/" >> /tmp
/$$direc.list
; \
144 for each in misc docs wx src setup
; do \
145 tar -uf
/tmp
/$$direc.
tar \
147 find $$direc/$$each \( -type f -o -type l \) -print \
148 | fgrep -vf /tmp/$$direc.list \
152 echo compressing
$$direc.
tar to
$$direc.tgz
;\
153 gzip
-9 -c
/tmp
/$$direc.
tar > $$direc/distrib
/$$direc.tgz
;\
154 rm /tmp
/$$direc.
tar /tmp
/$$direc.list
;\
158 # the following ones are only needed if configure.in has changed
159 # and needs to be updated...
166 | sed
"s/config.cache/\$$OSTYPE.config.cache/g" \
167 | sed
"s/config.status/\$$OSTYPE.config.status/g" \
168 | sed
"s/\*\*--/ --/g" \
170 @chmod a
+x configure1
171 @mv configure1 configure