summaryrefslogtreecommitdiffstats
path: root/tkimg/Makefile.in
blob: fa5b912dd3c3dd333073d9d79b8214465c91b248 (plain)
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
#

# This file is a Makefile for IMG.  If it has the name "Makefile.in"

# then it is a template for a Makefile;  to generate the actual Makefile,

# run "./configure", which is a configuration script generated by the

# "autoconf" program (constructs like "@foo@" will get replaced in the

# actual Makefile.


# This is the master makefile to compile all the packages in this

# extensions in one go.


PACKAGE_NAME	=	@PACKAGE_NAME@
PACKAGE_VERSION	=	@PACKAGE_VERSION@
CYGPATH		=	@CYGPATH@
SUBDIRS		=	@subdirs@

#

#----------------------------------------------------------------

# Things you can change to personalize the Makefile for your own

# site (you can make these changes in either Makefile.in or

# Makefile, but changes to Makefile will get lost if you re-run

# the configuration script).

#----------------------------------------------------------------


# Directory in which the source of this extension can be found

srcdir		=	@srcdir@

# Default top-level directories in which to install architecture-

# specific files (exec_prefix) and machine-independent files such

# as scripts (prefix).  The values specified here may be overridden

# at configure-time with the --exec-prefix and --prefix options

# to the "configure" script.


prefix		= @prefix@
exec_prefix	= @exec_prefix@
libdir      = @libdir@
datarootdir	= @datarootdir@
includedir  = @includedir@
mandir      = @mandir@

# Directory containing scripts supporting the work of this makefile

tool		=	$(srcdir)/tools

INSTALL_OPTIONS =
INSTALL		= $(SHELL) $(srcdir)/tclconfig/install-sh -c ${INSTALL_OPTIONS}
INSTALL_DATA_DIR = ${INSTALL} -d -m 755
INSTALL_PROGRAM	= ${INSTALL} -m 755
INSTALL_DATA	= ${INSTALL} -m 644
INSTALL_SCRIPT	= ${INSTALL_PROGRAM}
INSTALL_LIBRARY	= ${INSTALL_DATA}


# The following definition can be set to non-null for special systems

# like AFS with replication.  It allows the pathnames used for installation

# to be different than those used for actually reference files at

# run-time.  INSTALL_ROOT is prepended to $prefix and $exec_prefix

# when installing files.

INSTALL_ROOT =

# Directory where libimg.a is at run-time:

LIB_RUNTIME_DIR =	$(libdir)/$(PACKAGE_NAME)$(PACKAGE_VERSION)

# Directory in which to install the archive libimg.a:

LIB_INSTALL_DIR =	$(INSTALL_ROOT)$(LIB_RUNTIME_DIR)

# Directory in which to install the extended shell tclsh:

BIN_INSTALL_DIR =	$(INSTALL_ROOT)$(exec_prefix)/bin

# Directory in which to install the include file transform.h:

INCLUDE_INSTALL_DIR =	$(INSTALL_ROOT)$(prefix)/include

# Top-level directory in which to install manual entries:

MAN_INSTALL_DIR =	$(INSTALL_ROOT)$(mandir)

# Directory where libz, libpng and libjpeg are (or will be) installed.

IMG_INSTALL_DIR	=	$(INSTALL_ROOT)$(IMG_RUNTIME_DIR)

# Some versions of make, like SGI's, use the following variable to

# determine which shell to use for executing commands:

SHELL =		/bin/sh

#----------------------------------------------------------------

# The information below is modified by the configure script when

# Makefile is generated from Makefile.in.  You shouldn't normally

# modify any of this stuff by hand.

#----------------------------------------------------------------


INSTALL_SHLIB =		$(INSTALL) -m 555
RANLIB =		@RANLIB@
SHLIB_SUFFIX =		@SHLIB_SUFFIX@
SHARED_BUILD	= @SHARED_BUILD@

#----------------------------------------------------------------


#-------------------------------------------------------#


default:	all

all:
	for sub in $(SUBDIRS) ; \
	do	\
		here=`pwd` && \
		cd $$sub && \
		$(MAKE) all || exit $$? && \
		cd $$here ; \
	done

test:	all
	for sub in $(SUBDIRS) ; \
	do	\
		here=`pwd` && \
		cd $$sub && \
		$(MAKE) top_builddir=$$here test || exit $$? && \
		cd $$here ; \
	done

install-man:
	mkdir -p $(MAN_INSTALL_DIR)/mann
	for i in $(srcdir)/doc/*.man ; \
	do	\
		dtplite -ext n -o $(MAN_INSTALL_DIR)/mann nroff $$i ; \
	done

collate: all
	rm -f pkgIndex.tcl
	touch pkgIndex.tcl
	for sub in $(SUBDIRS) ; \
	do	\
		here=`pwd` && \
		cd $$sub && \
		$(MAKE) install \
			exec_prefix=$$here/Img/exec_prefix		\
			prefix=$$here/Img/prefix			\
			pkglibdir=$$here/Img/exec_prefix/lib/Img	\
			libdir=$$here/Img/exec_prefix/lib		\
			includedir=$$here/Img/prefix/include		\
			DESTDIR=					\
			|| exit $$? &&					\
		cd $$here && \
		if test "x$(SHARED_BUILD)" = "x1"; then \
		cat Img/exec_prefix/lib/Img/pkgIndex.tcl >> pkgIndex.tcl ; \
		fi ; \
	done
	chmod ugo+w     Img/exec_prefix/lib/Img/pkgIndex.tcl
	mv pkgIndex.tcl Img/exec_prefix/lib/Img/pkgIndex.tcl
	chmod ugo+w     Img/exec_prefix/lib/Img/pkgIndex.tcl
	for p in Img/exec_prefix/lib/*.sh ; do \
		sed -e 's#$(libdir)/[^/ ]*\([/ ]\)#$(LIB_RUNTIME_DIR)\1#' \
			$$p > $$p.1 && mv -f $$p.1 $$p ; \
	done

install-libraries: collate
	mkdir -p    $(INSTALL_ROOT)$(LIB_RUNTIME_DIR)
	for p in Img/exec_prefix/lib/Img/* ; do \
		$(INSTALL_PROGRAM) $$p $(INSTALL_ROOT)$(LIB_RUNTIME_DIR)/`basename $$p` ; \
	done
	mkdir -p $(INSTALL_ROOT)$(libdir)
	for p in Img/exec_prefix/lib/*.sh ; do \
		$(INSTALL_PROGRAM) $$p $(INSTALL_ROOT)$(libdir)/`basename $$p` ; \
	done
	if [ -n "`ls Img/prefix/include`" ]; then \
	mkdir -p $(INSTALL_ROOT)$(includedir) && \
	for p in Img/prefix/include/* ; do \
		$(INSTALL_DATA) $$p $(INSTALL_ROOT)$(includedir)/`basename $$p` ; \
	done; fi

install: install-libraries install-man

bindist:

#-------------------------------------------------------#


clean:
	for sub in $(SUBDIRS) ; \
	do	\
		here=`pwd` && \
		cd $$sub && \
		$(MAKE) clean || exit $$? && \
		cd $$here ; \
	done
	rm -rf Img

distclean:	clean
	rm -f config.* $(jpegdir)/config.log $(jpegdir)/config.status
	rm -f Makefile
	for sub in $(SUBDIRS) ; \
	do	\
		here=`pwd` && \
		cd $$sub && \
		$(MAKE) distclean || exit $$? && \
		cd $$here ; \
	done

#-------------------------------------------------------#

# DO NOT DELETE THIS LINE -- make depend depends on it.