[Midnightbsd-cvs] mports [18066] trunk/graphics/jbigkit: jbigkit 2.1

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Sat Mar 7 16:22:34 EST 2015


Revision: 18066
          http://svnweb.midnightbsd.org/mports/?rev=18066
Author:   laffer1
Date:     2015-03-07 16:22:33 -0500 (Sat, 07 Mar 2015)
Log Message:
-----------
jbigkit 2.1

Modified Paths:
--------------
    trunk/graphics/jbigkit/Makefile
    trunk/graphics/jbigkit/distinfo
    trunk/graphics/jbigkit/pkg-plist

Added Paths:
-----------
    trunk/graphics/jbigkit/files/patch-Makefile
    trunk/graphics/jbigkit/files/patch-libjbig_Makefile
    trunk/graphics/jbigkit/files/patch-pbmtools_Makefile
    trunk/graphics/jbigkit/files/patch-warnings

Removed Paths:
-------------
    trunk/graphics/jbigkit/files/patch-aa
    trunk/graphics/jbigkit/files/patch-ab
    trunk/graphics/jbigkit/files/patch-ac

Modified: trunk/graphics/jbigkit/Makefile
===================================================================
--- trunk/graphics/jbigkit/Makefile	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/Makefile	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,8 +1,7 @@
 # $MidnightBSD$
 
 PORTNAME=	jbigkit
-PORTVERSION=	1.6
-PORTREVISION=	1
+PORTVERSION=	2.1
 CATEGORIES=	graphics
 MASTER_SITES=	http://www.cl.cam.ac.uk/~mgk25/download/
 
@@ -11,19 +10,35 @@
 
 LICENSE=	gpl2
 
-WRKSRC=	${WRKDIR}/${PORTNAME}
-
 USE_LDCONFIG=	yes
+MANS=		jbgtopbm.1 pbmtojbg.1
+BINS=		jbgtopbm pbmtojbg jbgtopbm85 pbmtojbg85
+LIBA=		libjbig.a libjbig85.a
+LIBS=		libjbig.so.2 libjbig85.so.1
+DOCSDIR?=	${PREFIX}/share/doc/jbig
 
-MAN1=	jbgtopbm.1 pbmtojbg.1
+OPTIONS_DEFINE=	DOCS
 
-post-install:
-.if !defined(NOPORTDOCS)
-	${MKDIR} ${PREFIX}/share/doc/jbig
-	${INSTALL_DATA} ${WRKSRC}/libjbig/jbig.doc ${PREFIX}/share/doc/jbig
-.endif
+do-install:
+	${INSTALL_PROGRAM}	\
+		${BINS:S|^|${WRKSRC}/pbmtools/|} ${STAGEDIR}${PREFIX}/bin
 
-post-build test:
-	cd ${WRKSRC} && ${SETENV} LD_LIBRARY_PATH=${WRKSRC}/libjbig ${MAKE} test
+	${INSTALL_MAN}	\
+		${MANS:S|^|${WRKSRC}/pbmtools/|} ${STAGEDIR}${MANPREFIX}/man/man1
 
+	${INSTALL_DATA} ${WRKSRC}/libjbig/*.h ${STAGEDIR}${PREFIX}/include
+
+	${INSTALL_DATA}	\
+		${LIBA:S|^|${WRKSRC}/libjbig/|} ${STAGEDIR}${PREFIX}/lib
+	${INSTALL_LIB}	\
+		${LIBS:S|^|${WRKSRC}/libjbig/|} ${STAGEDIR}${PREFIX}/lib
+	${LN} -sf libjbig.so.2 ${STAGEDIR}${PREFIX}/lib/libjbig.so
+	${LN} -sf libjbig85.so.1 ${STAGEDIR}${PREFIX}/lib/libjbig85.so
+
+	@${MKDIR} ${STAGEDIR}${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/libjbig/jbig.txt ${STAGEDIR}${DOCSDIR}
+
+regression-test test:
+	cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} LD_LIBRARY_PATH=${WRKSRC}/libjbig ${MAKE} test
+
 .include <bsd.port.mk>

Modified: trunk/graphics/jbigkit/distinfo
===================================================================
--- trunk/graphics/jbigkit/distinfo	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/distinfo	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,2 +1,2 @@
-SHA256 (jbigkit-1.6.tar.gz) = d841b6d0723c1082450967f3ea500be01810a34ec4a97ad10985ae7071a6150b
-SIZE (jbigkit-1.6.tar.gz) = 405712
+SHA256 (jbigkit-2.1.tar.gz) = de7106b6bfaf495d6865c7dd7ac6ca1381bd12e0d81405ea81e7f2167263d932
+SIZE (jbigkit-2.1.tar.gz) = 438710

Added: trunk/graphics/jbigkit/files/patch-Makefile
===================================================================
--- trunk/graphics/jbigkit/files/patch-Makefile	                        (rev 0)
+++ trunk/graphics/jbigkit/files/patch-Makefile	2015-03-07 21:22:33 UTC (rev 18066)
@@ -0,0 +1,31 @@
+--- ./Makefile.orig	2014-03-27 18:47:15.000000000 +0000
++++ ./Makefile	2014-06-21 22:53:57.000000000 +0000
+@@ -1,24 +1,22 @@
+ # Unix makefile for JBIG-KIT
+ 
+ # Select an ANSI/ISO C compiler here, GNU gcc is recommended
+-CC = gcc
++#CC = gcc
+ 
+ # Options for the compiler: A high optimization level is suggested
+-CFLAGS = -O2 -W -Wno-unused-result
++CFLAGS += -W # -Wno-unused-result -- older compilers don't have this
+ # CFLAGS = -O -g -W -Wall -Wno-unused-result -ansi -pedantic # -DDEBUG
+ 
+-export CC CFLAGS
+-
+ VERSION=2.1
+ 
+ all: lib pbm
+ 	@echo "Enter 'make test' in order to start some automatic tests."
+ 
+ lib:
+-	cd libjbig && $(MAKE) -e
++	cd libjbig && $(MAKE)
+ 
+ pbm: lib
+-	cd pbmtools && $(MAKE) -e
++	cd pbmtools && $(MAKE)
+ 
+ test: lib pbm
+ 	cd libjbig  && $(MAKE) test


Property changes on: trunk/graphics/jbigkit/files/patch-Makefile
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Deleted: trunk/graphics/jbigkit/files/patch-aa
===================================================================
--- trunk/graphics/jbigkit/files/patch-aa	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/files/patch-aa	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,61 +0,0 @@
---- Makefile.orig	Tue Apr  9 19:37:13 2002
-+++ Makefile	Tue Apr  9 22:45:53 2002
-@@ -2,13 +2,13 @@
- # $Id: patch-aa,v 1.2 2012-03-01 02:56:42 laffer1 Exp $
- 
- # Select an ANSI/ISO C compiler here, GNU gcc is recommended
--CC = gcc
-+#CC = gcc
- 
- # Options for the compiler: A high optimization level is suggested
--CCFLAGS = -O2 -W
-+#CCFLAGS = -O2 -W
- #CCFLAGS = -O -g -W -Wall -ansi -pedantic #-DDEBUG  # developer only
- 
--CFLAGS = $(CCFLAGS) -I../libjbig
-+CFLAGS += -I../libjbig
- 
- VERSION=1.4
- 
-@@ -16,14 +16,14 @@
- 	@echo "Enter 'make test' in order to start some automatic tests."
- 
- lib:
--	(cd libjbig;  make "CC=$(CC)" "CFLAGS=$(CFLAGS)")
-+	(cd libjbig;  $(MAKE) "CC=$(CC)" "CFLAGS=$(CFLAGS)")
- 
- pbm: lib
--	(cd pbmtools; make "CC=$(CC)" "CFLAGS=$(CFLAGS)")
-+	(cd pbmtools; $(MAKE) "CC=$(CC)" "CFLAGS=$(CFLAGS)")
- 
- test: lib pbm
--	(cd libjbig;  make "CC=$(CC)" "CFLAGS=$(CFLAGS)" test)
--	(cd pbmtools; make "CC=$(CC)" "CFLAGS=$(CFLAGS)" test)
-+	(cd libjbig;  $(MAKE) "CC=$(CC)" "CFLAGS=$(CFLAGS)" test)
-+	(cd pbmtools; $(MAKE) "CC=$(CC)" "CFLAGS=$(CFLAGS)" test)
- 
- clean:
- 	rm -f *~ core
-@@ -36,3 +36,22 @@
- 	  gzip -9f jbigkit-$(VERSION).tar )
- 	mv ../jbigkit-$(VERSION).tar.gz $(HOME)/public_html/download/
- 	cp CHANGES $(HOME)/public_html/jbigkit/
-+
-+install:
-+	mkdir -p ${PREFIX}/bin
-+	${BSD_INSTALL_PROGRAM} pbmtools/jbgtopbm pbmtools/pbmtojbg \
-+		${PREFIX}/bin
-+	mkdir -p ${PREFIX}/man/man1
-+	${BSD_INSTALL_MAN} pbmtools/pbmtojbg.1 pbmtools/jbgtopbm.1 \
-+		${PREFIX}/man/man1
-+	# mkdir -p ${PREFIX}/man/man5
-+	# Not installing the pbm(5) man page, because BSD has its own
-+	# install -c -m 644 -o bin -g bin pbmtools/pbm.5 ${PREFIX}/man/man5
-+	# Not installing the pgm(5) man page for it comes with netpbm port
-+	# install -c -m 644 -o bin -g bin pbmtools/pgm.5 ${PREFIX}/man/man5
-+	mkdir -p ${PREFIX}/include
-+	${BSD_INSTALL_DATA} libjbig/jbig.h ${PREFIX}/include
-+	mkdir -p ${PREFIX}/lib
-+	${BSD_INSTALL_DATA} libjbig/libjbig.a ${PREFIX}/lib
-+	${BSD_INSTALL_DATA} libjbig/libjbig.so.1 ${PREFIX}/lib
-+	ln -sf libjbig.so.1 ${PREFIX}/lib/libjbig.so

Deleted: trunk/graphics/jbigkit/files/patch-ab
===================================================================
--- trunk/graphics/jbigkit/files/patch-ab	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/files/patch-ab	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,40 +0,0 @@
---- libjbig/Makefile	Fri Apr 10 20:33:27 1998
-+++ libjbig/Makefile	Wed Sep 16 11:57:16 1998
-@@ -5,9 +5,11 @@
--CC = gcc
- 
- # Options for the compiler: A high optimization level is suggested
--CFLAGS = -O -Wall -ansi -pedantic
-+CFLAGS += -Wall -ansi -pedantic
- 
--all: libjbig.a tstcodec
-+JBIGLIB=libjbig.a
-+SOJBIGLIB=libjbig.so.1
-+
-+all: libjbig.a $(SOJBIGLIB)
- 
- tstcodec: tstcodec.c jbig.c jbig.h jbig_tab.o
- 	$(CC) $(CFLAGS) -o tstcodec -DTEST_CODEC tstcodec.c jbig.c \
-@@ -18,10 +25,21 @@
- 	ar rc libjbig.a jbig.o jbig_tab.o
- 	ranlib libjbig.a
- 
-+$(SOJBIGLIB): jbig.so jbig_tab.so
-+	rm -f ${.TARGET}
-+	$(CC) -o ${.TARGET} ${LDFLAGS} -shared -Wl,-soname,${.TARGET} ${.ALLSRC}         
-+	ln -sf ${.TARGET} `echo ${.TARGET} | sed 's/\.so.*$$/.so/'`
-+	
- jbig.o: jbig.c jbig.h
- 
-+.SUFFIXES: .c .so
-+.c.so:
-+	${CC} -c -fpic -DPIC ${CFLAGS} ${.IMPSRC} -o ${.TARGET}
-+jbig.so: jbig.c jbig.h
-+jbig_tab.so: jbig_tab.c
-+
- test: tstcodec
- 	./tstcodec
- 
- clean:
--	rm -f *.o *~ core gmon.out dbg_d\=??.pbm tstcodec
-+	rm -f *.o *~ core gmon.out dbg_d\=??.pbm tstcodec *.so libjbig.so.1 libjbig.so.1.1 libjbig.a

Deleted: trunk/graphics/jbigkit/files/patch-ac
===================================================================
--- trunk/graphics/jbigkit/files/patch-ac	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/files/patch-ac	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,16 +0,0 @@
---- pbmtools/Makefile.orig	Thu Jun 25 13:30:38 1998
-+++ pbmtools/Makefile	Thu Jun 25 13:31:00 1998
-@@ -5,11 +5,10 @@
--CC = gcc
- 
- # Options for the compiler
--CFLAGS = -g -Wall -ansi -pedantic -I../libjbig
-+CFLAGS += -Wall -ansi -pedantic -I../libjbig
- 
- .SUFFIXES: .1 .5 .txt $(SUFFIXES)
- 
--all: pbmtojbg jbgtopbm pbmtojbg.txt jbgtopbm.txt pbm.txt pgm.txt
-+all: pbmtojbg jbgtopbm
- 
- pbmtojbg: pbmtojbg.o ../libjbig/libjbig.a
- 	$(CC) $(CFLAGS) -o pbmtojbg pbmtojbg.o -L../libjbig -ljbig

Added: trunk/graphics/jbigkit/files/patch-libjbig_Makefile
===================================================================
--- trunk/graphics/jbigkit/files/patch-libjbig_Makefile	                        (rev 0)
+++ trunk/graphics/jbigkit/files/patch-libjbig_Makefile	2015-03-07 21:22:33 UTC (rev 18066)
@@ -0,0 +1,38 @@
+--- libjbig/Makefile	2014-03-27 14:47:15.000000000 -0400
++++ libjbig/Makefile	2014-04-08 08:43:57.000000000 -0400
+@@ -2,10 +2,14 @@
+ 
+ # Select an ANSI/ISO C compiler here, GNU gcc is recommended
+-CC = gcc
++#CC = gcc
+ 
+ # Options for the compiler: A high optimization level is suggested
+-CFLAGS = -g -O -W -Wall -ansi -pedantic # --coverage
++CFLAGS += -W -Wall -ansi -pedantic # --coverage
+ 
+-all: libjbig.a libjbig85.a tstcodec tstcodec85
++all: libjbig.a libjbig85.a tstcodec tstcodec85 libjbig.so.2 libjbig85.so.1
++
++.SUFFIXES: .c .So
++.c.So:
++	$(CC) -c -fpic -DPIC ${CFLAGS} ${.IMPSRC} -o ${.TARGET}
+ 
+ tstcodec: tstcodec.o jbig.o jbig_ar.o
+@@ -20,4 +24,8 @@
+ 	-ranlib libjbig.a
+ 
++libjbig.so.2: jbig.So jbig_ar.So
++	rm -f ${.TARGET}
++	$(CC) -o ${.TARGET} ${LDFLAGS} -shared -Wl,-soname,${.TARGET} ${.ALLSRC}
++
+ libjbig85.a: jbig85.o jbig_ar.o
+ 	rm -f libjbig85.a
+@@ -25,4 +33,8 @@
+ 	-ranlib libjbig85.a
+ 
++libjbig85.so.1: jbig85.So jbig_ar.So
++	rm -f ${.TARGET}
++	$(CC) -o ${.TARGET} ${LDFLAGS} -shared -Wl,-soname,${.TARGET} ${.ALLSRC}
++
+ jbig.o: jbig.c jbig.h jbig_ar.h
+ jbig85.o: jbig85.c jbig85.h jbig_ar.h


Property changes on: trunk/graphics/jbigkit/files/patch-libjbig_Makefile
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: trunk/graphics/jbigkit/files/patch-pbmtools_Makefile
===================================================================
--- trunk/graphics/jbigkit/files/patch-pbmtools_Makefile	                        (rev 0)
+++ trunk/graphics/jbigkit/files/patch-pbmtools_Makefile	2015-03-07 21:22:33 UTC (rev 18066)
@@ -0,0 +1,32 @@
+--- pbmtools/Makefile	2014-03-27 14:47:15.000000000 -0400
++++ pbmtools/Makefile	2014-04-08 09:18:42.000000000 -0400
+@@ -2,14 +2,14 @@
+ 
+ # Select an ANSI/ISO C compiler here, e.g. GNU gcc is recommended
+-CC = gcc
++#CC = gcc
+ 
+ # Options for the compiler
+-CFLAGS = -g -O -W -Wall -Wno-unused-result -ansi -pedantic # --coverage
+-CPPFLAGS = -I../libjbig 
++CFLAGS += -W -Wall -ansi -pedantic # --coverage -Wno-unused-result
++CFLAGS += -I../libjbig 
+ 
+ .SUFFIXES: .1 .5 .txt $(SUFFIXES)
+ .PHONY: txt test test82 test85 clean
+ 
+-all: pbmtojbg jbgtopbm pbmtojbg85 jbgtopbm85 txt
++all: pbmtojbg jbgtopbm pbmtojbg85 jbgtopbm85
+ 
+ txt: pbmtojbg.txt jbgtopbm.txt pbm.txt pgm.txt
+@@ -144,6 +144,8 @@
+ 	cmp test-$(IMG).pbm test-$(IMG).pbm85
+ 
+-test-%.pbm: ../examples/%.jbg
+-	./jbgtopbm $< $@
++.for i in 1 2 3
++test-ccitt$i.pbm: ../examples/ccitt$i.jbg
++	./jbgtopbm ${.ALLSRC} ${.TARGET}
++.endfor
+ 
+ test-t82.pbm:


Property changes on: trunk/graphics/jbigkit/files/patch-pbmtools_Makefile
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Added: trunk/graphics/jbigkit/files/patch-warnings
===================================================================
--- trunk/graphics/jbigkit/files/patch-warnings	                        (rev 0)
+++ trunk/graphics/jbigkit/files/patch-warnings	2015-03-07 21:22:33 UTC (rev 18066)
@@ -0,0 +1,36 @@
+--- pbmtools/pbmtojbg85.c	2014-03-27 14:47:15.000000000 -0400
++++ pbmtools/pbmtojbg85.c	2014-04-08 09:00:16.000000000 -0400
+@@ -71,8 +71,12 @@
+   if (c != EOF) {
+     ungetc(c, f);
+-    fscanf(f, "%lu", &i);
+-  }
++    if (fscanf(f, "%lu", &i) == 1)
++       return i;
++    else
++       fprintf(stderr, "%s: corrupt input", progname);
++  } else
++       fprintf(stderr, "%s: unexpected end of input", progname);
+ 
+-  return i;
++  return -1;
+ }
+
+--- pbmtools/pbmtojbg.c	2014-03-27 14:47:15.000000000 -0400
++++ pbmtools/pbmtojbg.c	2014-04-08 09:00:16.000000000 -0400
+@@ -87,8 +87,12 @@
+   if (c != EOF) {
+     ungetc(c, f);
+-    fscanf(f, "%lu", &i);
+-  }
++    if (fscanf(f, "%lu", &i) == 1)
++       return i;
++    else
++       fprintf(stderr, "%s: corrupt input", progname);
++  } else
++       fprintf(stderr, "%s: unexpected end of input", progname);
+ 
+-  return i;
++  return -1;
+ }
+ 


Property changes on: trunk/graphics/jbigkit/files/patch-warnings
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:mime-type
## -0,0 +1 ##
+text/plain
\ No newline at end of property
Modified: trunk/graphics/jbigkit/pkg-plist
===================================================================
--- trunk/graphics/jbigkit/pkg-plist	2015-03-07 21:18:29 UTC (rev 18065)
+++ trunk/graphics/jbigkit/pkg-plist	2015-03-07 21:22:33 UTC (rev 18066)
@@ -1,8 +1,16 @@
 bin/jbgtopbm
+bin/jbgtopbm85
 bin/pbmtojbg
+bin/pbmtojbg85
 include/jbig.h
+include/jbig85.h
+include/jbig_ar.h
 lib/libjbig.a
 lib/libjbig.so
-lib/libjbig.so.1
-%%PORTDOCS%%share/doc/jbig/jbig.doc
-%%PORTDOCS%%@dirrm share/doc/jbig
+lib/libjbig.so.2
+lib/libjbig85.a
+lib/libjbig85.so
+lib/libjbig85.so.1
+man/man1/jbgtopbm.1.gz
+man/man1/pbmtojbg.1.gz
+%%PORTDOCS%%%%DOCSDIR%%/jbig.txt



More information about the Midnightbsd-cvs mailing list