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
|
--- ppm/Makefile.orig Tue May 16 10:30:30 2000
+++ ppm/Makefile Sat May 20 00:00:00 2000
@@ -3,8 +3,7 @@
LIBROOT = ppm
LIBPPM = lib$(LIBROOT).$(NETPBMLIBSUFFIX)
-MAJ = 9
-MIN = 1
+SOVER = 1
PGMDIR = $(SRCDIR)/pgm
LIBPGM = libpgm.$(NETPBMLIBSUFFIX)
@@ -24,7 +23,7 @@
PORTBINARIES = bmptoppm eyuvtoppm gouldtoppm hpcdtoppm ilbmtoppm imgtoppm \
mtvtoppm pcxtoppm pgmtoppm pi1toppm picttoppm \
pjtoppm \
- ppm3d ppmbrighten ppmchange ppmcolormask \
+ ppm3d ppmbrighten ppmchange \
ppmdim ppmdist ppmdither \
ppmflash ppmhist ppmmake ppmmix ppmnorm \
ppmquant ppmrelief ppmshift ppmspread ppmtoacad \
@@ -34,12 +33,13 @@
ppmtotga ppmtouil ppmtoxpm ppmtoyuv \
ppmtoyuvsplit ppmtv \
qrttoppm rawtoppm rgb3toppm sldtoppm spctoppm \
- sputoppm tgatoppm ximtoppm xpmtoppm xvminitoppm \
+ sputoppm xpmtoppm xvminitoppm \
yuvtoppm yuvsplittoppm
# We don't build vidtoppm by default, because it requires special libraries
# and there is no known requirement for vidtoppm.
+NOMERGEBINARIES = ppmcolormask ppmntsc tgatoppm ximtoppm
ifneq ($(JPEGLIB_DIR), NONE)
ifneq ($(JPEGHDR_DIR), NONE)
NOMERGEBINARIES += ppmtojpeg
@@ -48,7 +48,7 @@
MERGEBINARIES = $(PORTBINARIES) $(MATHBINARIES)
-MATHBINARIES = ppmcie ppmforge ppmlabel ppmntsc ppmpat ppmqvga ppmtomap
+MATHBINARIES = ppmcie ppmforge ppmlabel ppmpat ppmqvga ppmtomap
BINARIES = $(MERGEBINARIES) $(NOMERGEBINARIES)
SCRIPTS = ppmquantall ppmshadow ppmfade
@@ -57,6 +57,8 @@
MERGE_OBJECTS = $(patsubst %,%.o2, $(MERGEBINARIES))
LIBOBJECTS = libppm1.o libppm2.o libppm3.o libppm4.o libppm5.o bitio.o
+LIBSOBJECTS = libppm1.so libppm2.so libppm3.so libppm4.so libppm5.so bitio.so
+LIBSHHOPT = $(SRCDIR)/shhopt/libshhopt.a
MANUALS1 = $(BINARIES) $(SCRIPTS)
MANUALS3 = libppm
@@ -64,18 +66,24 @@
MERGENAME= ppmmerge
-INTERFACE_HEADERS = ppm.h ppmcmap.h
+INTERFACE_HEADERS = ppm.h ppmcmap.h ppmdraw.h
.PHONY: all
all: $(BINARIES)
- $(MAKE) -C ppmtompeg all
.PHONY: merge
merge: $(MERGENAME) $(NOMERGEBINARIES)
- $(MAKE) -C ppmtompeg all
-ppmtojpeg: %: %.o $(NETPBMLIBS) $(LIBOPT)
+ppmcolormask tgatoppm ximtoppm: %: %.o $(NETPBMLIBS) $(LIBOPT) $(LIBSHHOPT)
$(LD) $(LDFLAGS) -o $@ $@.o `$(LIBOPT) $(NETPBMLIBS)` \
- -L$(JPEGLIB_DIR) -ljpeg $(CDEBUG)
+ $(LIBSHHOPT) $(CDEBUG)
+
+ppmntsc: %: %.o $(NETPBMLIBS) $(LIBOPT) $(LIBSHHOPT)
+ $(LD) $(LDFLAGS) -o $@ $@.o `$(LIBOPT) $(NETPBMLIBS)` \
+ -lm $(LIBSHHOPT) $(CDEBUG)
+
+ppmtojpeg: %: %.o $(NETPBMLIBS) $(LIBOPT) $(LIBSHHOPT)
+ $(LD) $(LDFLAGS) -o $@ $@.o `$(LIBOPT) $(NETPBMLIBS)` \
+ -L$(JPEGLIB_DIR) -ljpeg $(LIBSHHOPT) $(CDEBUG)
# And libraries.
$(PBMDIR)/$(LIBPBM): FORCE
@@ -88,19 +96,19 @@
.PHONY: install.merge
install.merge: install.merge.common
- $(MAKE) -C ppmtompeg install.bin
.PHONY: install.lib
install.lib: install.lib.common
.PHONY: install.man
install.man: install.man.common
- $(MAKE) -C ppmtompeg install.man
include $(SRCDIR)/Makefile.common
+$(SRCDIR)/shhopt/libshhopt.a:
+ cd ../shhopt; $(MAKE) libshhopt.a
+
.PHONY: clean
clean: clean.common
- $(MAKE) -C ppmtompeg clean
FORCE:
|