Imported from libpng-1.0.9beta1.tar

This commit is contained in:
Glenn Randers-Pehrson
2000-11-10 12:26:19 -06:00
parent 32fc5ceb91
commit 5e5c1e1f56
71 changed files with 6731 additions and 4008 deletions

View File

@@ -31,7 +31,7 @@ RANLIB=ranlib
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
# where make install puts libpng.a, libpng.so*, and png.h

View File

@@ -22,13 +22,6 @@ ZLIBINC=${prefix}/include
#ZLIBLIB=../zlib
#ZLIBINC=../zlib
SHAREDLIB=libpng.dll
STATLIB=libpng.a
IMPLIB=libpng.dll.a
SHAREDDEF=libpng.def
LIBS=$(SHAREDLIB) $(STATLIB)
EXE=.exe
ALIGN=
# for i386:
#ALIGN=-malign-loops=2 -malign-functions=2
@@ -42,6 +35,19 @@ WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
CFLAGS=-I$(ZLIBINC) -Wall -O3 $(ALIGN) -funroll-loops \
-fomit-frame-pointer
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
SHAREDLIB=cygpng$(PNGMAJ).dll
STATLIB=libpng.a
IMPLIB=libpng.dll.a
SHAREDDEF=libpng.def
LIBS=$(SHAREDLIB) $(STATLIB)
EXE=.exe
LDFLAGS=-L. -L$(ZLIBLIB) -lpng -lz
LDSHARED=gcc -shared -Wl,--enable-auto-image-base
LDEXTRA=-Wl,--out-implib=$(IMPLIB) $(SHAREDDEF)
@@ -49,19 +55,12 @@ LDEXTRA=-Wl,--out-implib=$(IMPLIB) $(SHAREDDEF)
RANLIB=ranlib
#RANLIB=echo
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8beta3
PNGVER = $(PNGMAJ).$(PNGMIN)
INCPATH=$(prefix)/include
LIBPATH=$(prefix)/lib
BINPATH=$(prefix)/bin
MANPATH=$(prefix)/man
MAN3PATH=$(MANPATH)/man3
DOCPATH=$(prefix)/doc/libpng-$(PNGMIN)
CYGDOCPATH=$(prefix)/doc/Cygwin
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
@@ -77,7 +76,15 @@ OBJSDLL = $(OBJS:.o=.pic.o)
%.pic.o : %.c
$(CC) -c $(CFLAGS) -DPNG_BUILD_DLL -o $@ $<
all: $(SHAREDLIB) $(STATLIB) pngtest$(EXE) pngtest-stat$(EXE)
all: all-static all-shared
static: all-static
shared: all-shared
all-static: $(STATLIB) pngtest-stat$(EXE)
all-shared: $(SHAREDLIB) pngtest$(EXE)
pnggccrd.o: png.h pngconf.h pngasmrd.h
@echo ""
@@ -91,7 +98,7 @@ pnggccrd.pic.o: png.h pngconf.h pngasmrd.h
@echo ' You can ignore the single "control reaches end of non-void function"'
@echo ' warning and multiple "<variable> defined but not used" warnings:'
@echo ""
$(CC) -c $(CFLAGS) -o $@ pnggccrd.c
$(CC) -c $(CFLAGS) -DPNG_BUILD_DLL -o $@ pnggccrd.c
$(STATLIB): $(OBJS)
ar rc $@ $(OBJS)
@@ -115,24 +122,36 @@ pngtest.pic.o: pngtest.c
pngtest.o: pngtest.c
$(CC) $(CFLAGS) -DPNG_STATIC -DZLIB_STATIC -c $< -o $@
test: test-dll test-stat
test: test-static test-shared
test-stat: pngtest-stat$(EXE)
test-static: pngtest-stat$(EXE)
./pngtest-stat
test-dll: pngtest$(EXE)
test-shared: pngtest$(EXE)
./pngtest
install: $(STATLIB) $(SHAREDLIB)
-@if [ ! -d $(INCPATH) ]; then mkdir -p $(INCPATH); fi
install: install-static install-shared
install-static: $(STATLIB) install-headers install-docs install-man
-@if [ ! -d $(LIBPATH) ]; then mkdir -p $(LIBPATH); fi
install -m 755 $(STATLIB) $(LIBPATH)
install-shared: $(SHAREDLIB) install-headers install-docs install-man
-@if [ ! -d $(LIBPATH) ]; then mkdir -p $(LIBPATH); fi
-@if [ ! -d $(BINPATH) ]; then mkdir -p $(BINPATH); fi
-@if [ ! -d $(MAN3PATH) ]; then mkdir -p $(MAN3PATH); fi
-@if [ ! -d $(DOCPATH) ]; then mkdir -p $(DOCPATH); fi
install -m 644 png.h pngconf.h $(INCPATH)
install -m 755 $(STATLIB) $(IMPLIB) $(LIBPATH)
install -m 755 $(IMPLIB) $(LIBPATH)
install -s -m 755 $(SHAREDLIB) $(BINPATH)
install-headers:
-@if [ ! -d $(INCPATH) ]; then mkdir -p $(INCPATH); fi
install -m 644 png.h pngconf.h $(INCPATH)
install-docs:
-@if [ ! -d $(DOCPATH) ]; then mkdir -p $(DOCPATH); fi
install -m 644 $(DOCS) $(DOCPATH)
install-man:
-@if [ ! -d $(MAN3PATH) ]; then mkdir -p $(MAN3PATH); fi
install -m 644 libpngpf.3 libpng.3 $(MAN3PATH)
clean:

View File

@@ -1,9 +1,12 @@
# makefile for libpng on DEC Alpha Unix
# Copyright (C) 2000 Glenn Randers-Pehrson
# Copyright (C) 1995 Guy Eric Schalnat, Group 42, Inc.
# For conditions of distribution and use, see copyright notice in png.h
# where make install puts libpng.a and png.h
prefix=/usr/local
INCPATH=$(prefix)/include
LIBPATH=$(prefix)/lib
# Where the zlib library and include files are located
#ZLIBLIB=/usr/local/lib
@@ -14,7 +17,7 @@ ZLIBINC=../zlib
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
CC=cc
@@ -24,7 +27,6 @@ LDFLAGS=-L. -L$(ZLIBLIB) -lpng -lz -lm
#RANLIB=echo
RANLIB=ranlib
OBJS = png.o pngset.o pngget.o pngrutil.o pngtrans.o pngwutil.o \
pngread.o pngrio.o pngwio.o pngwrite.o pngrtran.o \
pngwtran.o pngmem.o pngerror.o pngpread.o
@@ -51,18 +53,18 @@ test: pngtest
./pngtest
install: libpng.a libpng.so.$(PNGVER)
-@mkdir $(prefix)/include
-@mkdir $(prefix)/lib
cp png.h $(prefix)/include
cp pngconf.h $(prefix)/include
chmod 644 $(prefix)/include/png.h
chmod 644 $(prefix)/include/pngconf.h
cp libpng.a $(prefix)/lib
cp libpng.so.$(PNGVER) $(prefix)/lib
chmod 644 $(prefix)/lib/libpng.a
chmod 644 $(prefix)/lib/libpng.so.$(PNGVER)
-@mkdir $(INCPATH)
-@mkdir $(LIBPATH)
cp png.h $(INCPATH)
cp pngconf.h $(INCPATH)
chmod 644 $(INCPATH)/png.h
chmod 644 $(INCPATH)/pngconf.h
cp libpng.a $(LIBPATH)
cp libpng.so.$(PNGVER) $(LIBPATH)
chmod 644 $(LIBPATH)/libpng.a
chmod 644 $(LIBPATH)/libpng.so.$(PNGVER)
-@/bin/rm -f $(LIBPATH)/libpng.so.$(PNGMAJ) $(LIBPATH)/libpng.so
(cd $(LIBPATH); ln -f -s libpng.so.$(PNGVER) libpng.so.$(PNGMAJ); \
(cd $(LIBPATH)); ln -f -s libpng.so.$(PNGVER) libpng.so.$(PNGMAJ); \
ln -f -s libpng.so.$(PNGMAJ) libpng.so)
clean:

View File

@@ -29,6 +29,7 @@ WARNMORE=-Wwrite-strings -Wpointer-arith -Wshadow \
CFLAGS=-DPNG_USE_PNGGCCRD -I$(ZLIBINC) -Wall -O3 $(ALIGN) -funroll-loops \
-fomit-frame-pointer # $(WARNMORE) -g -DPNG_DEBUG=5
LDFLAGS=-L. -Wl,-rpath,. -L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) -lpng -lz -lm
LDFLAGS_A=-L$(ZLIBLIB) -Wl,-rpath,$(ZLIBLIB) libpng.a -lz -lm
RANLIB=ranlib
#RANLIB=echo
@@ -36,7 +37,7 @@ RANLIB=ranlib
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
INCPATH=$(prefix)/include
@@ -53,7 +54,7 @@ OBJSDLL = $(OBJS:.o=.pic.o)
.c.pic.o:
$(CC) -c $(CFLAGS) -fPIC -o $@ $*.c
all: libpng.a libpng.so pngtest
all: libpng.a libpng.so pngtest pngtest-static
pnggccrd.o: pnggccrd.c png.h pngconf.h pngasmrd.h
@echo ""
@@ -86,8 +87,18 @@ libpng.so.$(PNGVER): $(OBJSDLL)
pngtest: pngtest.o libpng.so
$(CC) -o pngtest $(CFLAGS) pngtest.o $(LDFLAGS)
test: pngtest
pngtest-static: pngtest.o libpng.a
$(CC) -o pngtest-static $(CFLAGS) pngtest.o $(LDFLAGS_A)
test: pngtest pngtest-static
@echo ""
@echo " Testing dynamically linked version:"
@echo ""
./pngtest
@echo ""
@echo " Testing statically linked version:"
@echo ""
./pngtest-static
install: libpng.a libpng.so.$(PNGVER)
-@if [ ! -d $(INCPATH) ]; then mkdir $(INCPATH); fi

View File

@@ -18,7 +18,7 @@ RANLIB=ranlib
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
# where make install puts libpng.a and png.h
@@ -67,7 +67,7 @@ install: libpng.a
cp libpng.a libpng.sl.$(PNGVER) $(prefix)/lib
chmod 644 $(prefix)/lib/libpng.a
chmod 755 $(prefix)/lib/libpng.sl.$(PNGVER)
(cd $(prefix)/lib; ln -f -s libpng.sl.$(PNGVER) libpng.sl.$(MNGMAJ); \
(cd $(prefix)/lib; ln -f -s libpng.sl.$(PNGVER) libpng.sl.$(PNGMAJ); \
ln -f -s libpng.sl.$(PNGMAJ) libpng.sl)
clean:

View File

@@ -34,7 +34,7 @@ RANLIB=ranlib
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
INCPATH=$(prefix)/include

View File

@@ -25,7 +25,7 @@ RANLIB=echo
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
INCPATH=$(prefix)/include

View File

@@ -19,8 +19,8 @@ CFLAGS=-I$(ZLIBINC) -O2 $(WARNMORE) -fPIC -mabi=n32 # -g -DPNG_DEBUG=5
LDFLAGS=-L. -L$(ZLIBLIB) -lpng -lz -lm
LDSHARED=gcc -shared
VER=1.0.8
LIBS=libpng.so.1.0.8
VER=1.0.9beta1
LIBS=libpng.so.1.0.9beta1
SHAREDLIB=libpng.so
libdir=$(prefix)/lib32

View File

@@ -31,7 +31,7 @@ RANLIB=echo
# read libpng.txt or png.h to see why PNGMAJ is 2. You should not
# have to change it.
PNGMAJ = 2
PNGMIN = 1.0.8
PNGMIN = 1.0.9beta1
PNGVER = $(PNGMAJ).$(PNGMIN)
INCPATH=$(prefix)/include

View File

@@ -3,6 +3,19 @@ $!
$!
$! Check for MMK/MMS
$!
$! This procedure accepts one parameter (contrib), which causes it to build
$! the programs from the contrib directory instead of libpng.
$!
$ p1 = f$edit(p1,"UPCASE")
$ if p1 .eqs. "CONTRIB"
$ then
$ set def [.contrib.gregbook]
$ @makevms
$ set def [-.pngminus]
$ @makevms
$ set def [--]
$ exit
$ endif
$ Make = ""
$ If F$Search ("Sys$System:MMS.EXE") .nes. "" Then Make = "MMS"
$ If F$Type (MMK) .eqs. "STRING" Then Make = "MMK"
@@ -83,6 +96,7 @@ $ call make pngtest.exe -
$ write sys$output "Testing Libpng..."
$ run pngtest
$ else
$ if f$search("DESCRIP.MMS") .eqs. "" then copy/nolog [.SCRIPTS]DESCRIP.MMS []
$ 'make'/macro=('comp',zlibsrc='zlibsrc')
$ endif
$ write sys$output "Libpng build completed"
@@ -128,4 +142,3 @@ $ VV='F$Verify(VV)
$Exit:
$ If V Then Set Verify
$ENDSUBROUTINE

View File

@@ -5,8 +5,8 @@ unit pngdef;
interface
const
PNG_LIBPNG_VER_STRING = '1.0.8';
PNG_LIBPNG_VER = 10008;
PNG_LIBPNG_VER_STRING = '1.0.9beta1';
PNG_LIBPNG_VER = 10009;
type
png_uint_32 = Cardinal;