Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 1 | # makefile for libpng.a and libpng14.so, SGI IRIX with 'cc' |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 2 | # Copyright (C) 2001-2002, 2006 Glenn Randers-Pehrson |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 3 | # Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc. |
| 4 | # For conditions of distribution and use, see copyright notice in png.h |
| 5 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 6 | # Library name: |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 7 | LIBNAME=libpng14 |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 8 | PNGMAJ = 0 |
Glenn Randers-Pehrson | b3870ab | 2006-05-11 09:43:09 -0500 | [diff] [blame^] | 9 | PNGMIN = 1.4.0beta4 |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 10 | PNGVER = $(PNGMAJ).$(PNGMIN) |
| 11 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 12 | # Shared library names: |
| 13 | LIBSO=$(LIBNAME).so |
| 14 | LIBSOMAJ=$(LIBNAME).so.$(PNGMAJ) |
| 15 | LIBSOVER=$(LIBNAME).so.$(PNGVER) |
| 16 | OLDSO=libpng.so |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 17 | |
| 18 | # Utilities: |
| 19 | AR_RC=ar rc |
| 20 | CC=cc |
| 21 | MKDIR_P=mkdir -p |
| 22 | LN_SF=ln -sf |
| 23 | RANLIB=echo |
| 24 | RM_F=/bin/rm -f |
| 25 | |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 26 | # Where make install puts libpng.a, libpng14.so, and libpng14/png.h |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 27 | # Prefix must be a full pathname. |
| 28 | |
Glenn Randers-Pehrson | 5c6aeb2 | 1998-12-29 11:47:59 -0600 | [diff] [blame] | 29 | prefix=/usr/local |
Glenn Randers-Pehrson | ad31054 | 2006-04-18 05:31:20 -0500 | [diff] [blame] | 30 | exec_prefix=$(prefix) |
Glenn Randers-Pehrson | 5c6aeb2 | 1998-12-29 11:47:59 -0600 | [diff] [blame] | 31 | |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 32 | # Where the zlib library and include files are located |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 33 | #ZLIBLIB=/usr/local/lib32 |
| 34 | #ZLIBINC=/usr/local/include |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 35 | #ZLIBLIB=/usr/local/lib |
| 36 | #ZLIBINC=/usr/local/include |
| 37 | ZLIBLIB=../zlib |
| 38 | ZLIBINC=../zlib |
| 39 | |
Glenn Randers-Pehrson | b182893 | 2001-06-23 08:03:17 -0500 | [diff] [blame] | 40 | # ABI can be blank to use default for your system, -32, -o32, -n32, or -64 |
| 41 | # See "man abi". zlib must be built with the same ABI. |
| 42 | ABI= |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 43 | |
Glenn Randers-Pehrson | b182893 | 2001-06-23 08:03:17 -0500 | [diff] [blame] | 44 | WARNMORE=-fullwarn |
| 45 | # Note: -KPIC is the default anyhow |
Glenn Randers-Pehrson | b3870ab | 2006-05-11 09:43:09 -0500 | [diff] [blame^] | 46 | #CFLAGS= $(ABI) -I$(ZLIBINC) -O $(WARNMORE) -KPIC # -g -DPNG_DEBUG=5 |
| 47 | CFLAGS=$(ABI) -I$(ZLIBINC) -O $(WARNMORE) |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 48 | LDFLAGS_A=$(ABI) -L. -L$(ZLIBLIB) -lpng14 -lz -lm |
Glenn Randers-Pehrson | b182893 | 2001-06-23 08:03:17 -0500 | [diff] [blame] | 49 | LDFLAGS=$(ABI) -L. -L$(ZLIBLIB) -lpng -lz -lm |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 50 | LDSHARED=cc $(ABI) -shared -soname $(LIBSOMAJ) \ |
Glenn Randers-Pehrson | 0cc2f95 | 2002-10-03 06:32:37 -0500 | [diff] [blame] | 51 | -set_version sgi$(PNGMAJ).0 |
Glenn Randers-Pehrson | b182893 | 2001-06-23 08:03:17 -0500 | [diff] [blame] | 52 | # See "man dso" for info about shared objects |
Glenn Randers-Pehrson | 837a3d1 | 2002-05-10 20:19:58 -0500 | [diff] [blame] | 53 | |
Glenn Randers-Pehrson | ae498dc | 2001-11-24 14:53:31 -0600 | [diff] [blame] | 54 | INCPATH=$(prefix)/include |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 55 | LIBPATH=$(exec_prefix)/lib |
| 56 | #LIBPATH=$(exec_prefix)/lib32 |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 57 | MANPATH=$(prefix)/man |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 58 | BINPATH=$(exec_prefix)/bin |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 59 | |
| 60 | # override DESTDIR= on the make install command line to easily support |
| 61 | # installing into a temporary location. Example: |
| 62 | # |
| 63 | # make install DESTDIR=/tmp/build/libpng |
| 64 | # |
| 65 | # If you're going to install into a temporary location |
Glenn Randers-Pehrson | 07748d1 | 2002-05-25 11:12:10 -0500 | [diff] [blame] | 66 | # via DESTDIR, $(DESTDIR)$(prefix) must already exist before |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 67 | # you execute make install. |
| 68 | DESTDIR= |
Glenn Randers-Pehrson | ae498dc | 2001-11-24 14:53:31 -0600 | [diff] [blame] | 69 | |
Glenn Randers-Pehrson | 07748d1 | 2002-05-25 11:12:10 -0500 | [diff] [blame] | 70 | DB=$(DESTDIR)$(BINPATH) |
| 71 | DI=$(DESTDIR)$(INCPATH) |
| 72 | DL=$(DESTDIR)$(LIBPATH) |
| 73 | DM=$(DESTDIR)$(MANPATH) |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 74 | |
Glenn Randers-Pehrson | 1909560 | 2001-03-14 07:08:39 -0600 | [diff] [blame] | 75 | OBJS = pnggccrd.o png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \ |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 76 | pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \ |
| 77 | pngwtran.o pngmem.o pngerror.o pngpread.o |
| 78 | |
Glenn Randers-Pehrson | 07748d1 | 2002-05-25 11:12:10 -0500 | [diff] [blame] | 79 | all: libpng.a pngtest shared libpng.pc libpng-config |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 80 | |
Glenn Randers-Pehrson | b3870ab | 2006-05-11 09:43:09 -0500 | [diff] [blame^] | 81 | pngconf.h.in: |
| 82 | cat pngconf.h > pngconf.h.in |
| 83 | |
| 84 | pngconf.h: pngconf.h.in |
| 85 | sed "/Makefile-supplied defines go here:/q" pngconf.h.in > pngconf.h |
| 86 | |
| 87 | /* if you don't want to use the intel MMX code, uncomment this */ |
| 88 | # echo "#define PNG_NO_MMX_CODE" >> pngconf.h |
| 89 | |
| 90 | /* if you don't need thread safety you can uncomment this */ |
| 91 | # echo "#define PNG_THREAD_UNSAFE_OK" >> pngconf.h |
| 92 | |
| 93 | sed "1,/Makefile-supplied defines go here:/d" pngconf.h.in >> pngconf.h |
| 94 | |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 95 | libpng.a: $(OBJS) |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 96 | $(AR_RC) $@ $(OBJS) |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 97 | $(RANLIB) $@ |
| 98 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 99 | shared: $(LIBSOVER) |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 100 | |
| 101 | libpng.pc: |
| 102 | cat scripts/libpng.pc.in | sed -e s\!@PREFIX@!$(prefix)! > libpng.pc |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 103 | |
Glenn Randers-Pehrson | 837a3d1 | 2002-05-10 20:19:58 -0500 | [diff] [blame] | 104 | libpng-config: |
| 105 | ( cat scripts/libpng-config-head.in; \ |
| 106 | echo prefix=\"$(prefix)\"; \ |
Glenn Randers-Pehrson | 5ff38d3 | 2002-09-17 23:38:46 -0500 | [diff] [blame] | 107 | echo I_opts=\"-I$(INCPATH)/$(LIBNAME)\"; \ |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 108 | echo cppflags=\"-DPNG_USE_PNGGCCRD -DPNG_NO_MMX_CODE\"; \ |
Glenn Randers-Pehrson | 5ff38d3 | 2002-09-17 23:38:46 -0500 | [diff] [blame] | 109 | echo ccopts=\"$(ABI)\"; \ |
| 110 | echo ldopts=\"$(ABI)\"; \ |
Glenn Randers-Pehrson | 0cc2f95 | 2002-10-03 06:32:37 -0500 | [diff] [blame] | 111 | echo L_opts=\"-L$(LIBPATH)\"; \ |
| 112 | echo libdir=\"$(LIBPATH)\"; \ |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 113 | echo libs=\"-lpng14 -lz -lm\"; \ |
Glenn Randers-Pehrson | 837a3d1 | 2002-05-10 20:19:58 -0500 | [diff] [blame] | 114 | cat scripts/libpng-config-body.in ) > libpng-config |
| 115 | chmod +x libpng-config |
| 116 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 117 | $(LIBSO): $(LIBSOMAJ) |
| 118 | $(LN_SF) $(LIBSOMAJ) $(LIBSO) |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 119 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 120 | $(LIBSOMAJ): $(LIBSOVER) |
| 121 | $(LN_SF) $(LIBSOVER) $(LIBSOMAJ) |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 122 | |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 123 | $(LIBSOVER): $(OBJS) |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 124 | $(LDSHARED) -o $@ $(OBJS) |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 125 | $(RM_F) $(LIBSO) $(LIBSOMAJ) |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 126 | |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 127 | pngtest: pngtest.o libpng.a |
Glenn Randers-Pehrson | ea3bcd7 | 1998-03-07 14:33:00 -0600 | [diff] [blame] | 128 | $(CC) -o pngtest $(CFLAGS) pngtest.o $(LDFLAGS) |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 129 | |
| 130 | test: pngtest |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 131 | echo |
| 132 | echo Testing local static library. |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 133 | ./pngtest |
| 134 | |
Glenn Randers-Pehrson | c1bfe68 | 2002-03-06 22:08:00 -0600 | [diff] [blame] | 135 | install-headers: png.h pngconf.h |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 136 | -@if [ ! -d $(DI) ]; then $(MKDIR_P) $(DI); fi |
| 137 | -@if [ ! -d $(DI)/$(LIBNAME) ]; then $(MKDIR_P) $(DI)/$(LIBNAME); fi |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 138 | cp png.h pngconf.h $(DI)/$(LIBNAME) |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 139 | chmod 644 $(DI)/$(LIBNAME)/png.h $(DI)/$(LIBNAME)/pngconf.h |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 140 | -@$(RM_F) $(DI)/png.h $(DI)/pngconf.h |
| 141 | -@$(RM_F) $(DI)/libpng |
| 142 | (cd $(DI); $(LN_SF) $(LIBNAME) libpng; $(LN_SF) $(LIBNAME)/* .) |
Glenn Randers-Pehrson | c1bfe68 | 2002-03-06 22:08:00 -0600 | [diff] [blame] | 143 | |
| 144 | install-static: install-headers libpng.a |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 145 | -@if [ ! -d $(DL) ]; then $(MKDIR_P) $(DL); fi |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 146 | cp libpng.a $(DL)/$(LIBNAME).a |
| 147 | chmod 644 $(DL)/$(LIBNAME).a |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 148 | -@$(RM_F) $(DL)/libpng.a |
| 149 | (cd $(DL); $(LN_SF) $(LIBNAME).a libpng.a) |
Glenn Randers-Pehrson | c1bfe68 | 2002-03-06 22:08:00 -0600 | [diff] [blame] | 150 | |
Glenn Randers-Pehrson | d60b8fa | 2006-04-20 21:31:14 -0500 | [diff] [blame] | 151 | install-shared: install-headers $(LIBSOVER) libpng.pc |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 152 | -@if [ ! -d $(DL) ]; then $(MKDIR_P) $(DL); fi |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 153 | -@$(RM_F) $(DL)/$(LIBSOVER)* $(DL)/$(LIBSO) |
| 154 | -@$(RM_F) $(DL)/$(LIBSOMAJ) |
| 155 | -@$(RM_F) $(DL)/$(OLDSO) |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 156 | cp $(LIBSOVER) $(DL) |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 157 | chmod 755 $(DL)/$(LIBSOVER) |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 158 | (cd $(DL); \ |
Glenn Randers-Pehrson | 4deeb79 | 2006-03-22 16:21:59 -0600 | [diff] [blame] | 159 | $(LN_SF) $(LIBSOVER) $(LIBSOMAJ); \ |
Glenn Randers-Pehrson | d60b8fa | 2006-04-20 21:31:14 -0500 | [diff] [blame] | 160 | $(LN_SF) $(LIBSOMAJ) $(LIBSO); \ |
| 161 | $(LN_SF) $(OLDSO) $(LIBSO)) |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 162 | -@if [ ! -d $(DL)/pkgconfig ]; then $(MKDIR_P) $(DL)/pkgconfig; fi |
| 163 | -@$(RM_F) $(DL)/pkgconfig/$(LIBNAME).pc |
| 164 | -@$(RM_F) $(DL)/pkgconfig/libpng.pc |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 165 | cp libpng.pc $(DL)/pkgconfig/$(LIBNAME).pc |
| 166 | chmod 644 $(DL)/pkgconfig/$(LIBNAME).pc |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 167 | (cd $(DL)/pkgconfig; $(LN_SF) $(LIBNAME).pc libpng.pc) |
Glenn Randers-Pehrson | c1bfe68 | 2002-03-06 22:08:00 -0600 | [diff] [blame] | 168 | |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 169 | install-man: libpng.3 libpngpf.3 png.5 |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 170 | -@if [ ! -d $(DM) ]; then $(MKDIR_P) $(DM); fi |
| 171 | -@if [ ! -d $(DM)/man3 ]; then $(MKDIR_P) $(DM)/man3; fi |
| 172 | -@$(RM_F) $(DM)/man3/libpng.3 |
| 173 | -@$(RM_F) $(DM)/man3/libpngpf.3 |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 174 | cp libpng.3 $(DM)/man3 |
| 175 | cp libpngpf.3 $(DM)/man3 |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 176 | -@if [ ! -d $(DM)/man5 ]; then $(MKDIR_P) $(DM)/man5; fi |
| 177 | -@$(RM_F) $(DM)/man5/png.5 |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 178 | cp png.5 $(DM)/man5 |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 179 | |
Glenn Randers-Pehrson | 837a3d1 | 2002-05-10 20:19:58 -0500 | [diff] [blame] | 180 | install-config: libpng-config |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 181 | -@if [ ! -d $(DB) ]; then $(MKDIR_P) $(DB); fi |
| 182 | -@$(RM_F) $(DB)/libpng-config |
| 183 | -@$(RM_F) $(DB)/$(LIBNAME)-config |
Glenn Randers-Pehrson | cfbed9b | 2002-05-21 18:06:08 -0500 | [diff] [blame] | 184 | cp libpng-config $(DB)/$(LIBNAME)-config |
| 185 | chmod 755 $(DB)/$(LIBNAME)-config |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 186 | (cd $(DB); $(LN_SF) $(LIBNAME)-config libpng-config) |
Glenn Randers-Pehrson | 03008a0 | 2002-04-27 10:11:25 -0500 | [diff] [blame] | 187 | |
Glenn Randers-Pehrson | 704228f | 2002-05-02 20:49:40 -0500 | [diff] [blame] | 188 | install: install-static install-shared install-man install-config |
Glenn Randers-Pehrson | be9de0f | 2001-01-22 08:52:16 -0600 | [diff] [blame] | 189 | |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 190 | # If you installed in $(DESTDIR), test-installed won't work until you |
Glenn Randers-Pehrson | a4981d4 | 2004-08-25 22:00:45 -0500 | [diff] [blame] | 191 | # move the library to its final location. Use test-dd to test it |
| 192 | # before then. |
| 193 | |
| 194 | test-dd: |
| 195 | echo |
| 196 | echo Testing installed dynamic shared library in $(DL). |
| 197 | $(CC) -I$(DI) -I$(ZLIBINC) \ |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 198 | `$(BINPATH)/$(LIBNAME)-config --cflags` pngtest.c \ |
Glenn Randers-Pehrson | a4981d4 | 2004-08-25 22:00:45 -0500 | [diff] [blame] | 199 | -L$(DL) -L$(ZLIBLIB) \ |
| 200 | -rpath $(ZLIBLIB):$(DL) \ |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 201 | -o pngtestd `$(BINPATH)/$(LIBNAME)-config --ldflags` |
Glenn Randers-Pehrson | a4981d4 | 2004-08-25 22:00:45 -0500 | [diff] [blame] | 202 | ./pngtestd pngtest.png |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 203 | |
| 204 | test-installed: |
| 205 | echo |
| 206 | echo Testing installed dynamic shared library. |
| 207 | $(CC) -I$(ZLIBINC) \ |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 208 | `$(BINPATH)/$(LIBNAME)-config --cflags` pngtest.c \ |
Glenn Randers-Pehrson | a4981d4 | 2004-08-25 22:00:45 -0500 | [diff] [blame] | 209 | -L$(ZLIBLIB) \ |
Glenn Randers-Pehrson | 5c60b23 | 2006-03-07 07:09:22 -0600 | [diff] [blame] | 210 | -rpath $(ZLIBLIB):`$(BINPATH)/$(LIBNAME)-config --libdir` \ |
| 211 | -o pngtesti `$(BINPATH)/$(LIBNAME)-config --ldflags` |
Glenn Randers-Pehrson | 2ae022d | 2002-07-01 22:23:46 -0500 | [diff] [blame] | 212 | ./pngtesti pngtest.png |
Glenn Randers-Pehrson | d1e8c86 | 2002-06-20 06:54:34 -0500 | [diff] [blame] | 213 | |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 214 | clean: |
Glenn Randers-Pehrson | d60b8fa | 2006-04-20 21:31:14 -0500 | [diff] [blame] | 215 | $(RM_F) *.o libpng.a pngtest pngtesti pngout.png libpng.pc |
| 216 | libpng-config $(LIBSO) $(LIBSOMAJ)* so_locations |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 217 | |
Glenn Randers-Pehrson | 166c5a3 | 1999-12-10 09:43:02 -0600 | [diff] [blame] | 218 | DOCS = ANNOUNCE CHANGES INSTALL KNOWNBUG LICENSE README TODO Y2KINFO |
| 219 | writelock: |
| 220 | chmod a-w *.[ch35] $(DOCS) scripts/* |
| 221 | |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 222 | # DO NOT DELETE THIS LINE -- make depend depends on it. |
| 223 | |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 224 | png.o: png.h pngconf.h pngintrn.h |
| 225 | pngerror.o: png.h pngconf.h pngintrn.h |
| 226 | pngrio.o: png.h pngconf.h pngintrn.h |
| 227 | pngwio.o: png.h pngconf.h pngintrn.h |
| 228 | pngmem.o: png.h pngconf.h pngintrn.h |
| 229 | pngset.o: png.h pngconf.h pngintrn.h |
| 230 | pngget.o: png.h pngconf.h pngintrn.h |
Glenn Randers-Pehrson | b3870ab | 2006-05-11 09:43:09 -0500 | [diff] [blame^] | 231 | pnggccrd.o: png.h pngconf.h pngintrn.h |
Glenn Randers-Pehrson | 1721829 | 2006-04-20 07:20:46 -0500 | [diff] [blame] | 232 | pngread.o: png.h pngconf.h pngintrn.h |
| 233 | pngrtran.o: png.h pngconf.h pngintrn.h |
| 234 | pngrutil.o: png.h pngconf.h pngintrn.h |
| 235 | pngtest.o: png.h pngconf.h pngintrn.h |
| 236 | pngtrans.o: png.h pngconf.h pngintrn.h |
| 237 | pngwrite.o: png.h pngconf.h pngintrn.h |
| 238 | pngwtran.o: png.h pngconf.h pngintrn.h |
| 239 | pngwutil.o: png.h pngconf.h pngintrn.h |
| 240 | pngpread.o: png.h pngconf.h pngintrn.h |
| 241 | pnggccrd.o: png.h pngconf.h pngintrn.h |
Glenn Randers-Pehrson | c4a2ae6 | 1998-01-16 22:06:18 -0600 | [diff] [blame] | 242 | |