diff --git a/graphics/zphoto/Makefile b/graphics/zphoto/Makefile index 3415c5d9ce95..54e804ec8b06 100644 --- a/graphics/zphoto/Makefile +++ b/graphics/zphoto/Makefile @@ -1,34 +1,38 @@ PORTNAME= zphoto PORTVERSION= 1.2 -PORTREVISION= 14 +PORTREVISION= 15 CATEGORIES= graphics www MASTER_SITES= http://namazu.org/~satoru/zphoto/ MAINTAINER= ports@FreeBSD.org COMMENT= Zooming photo album generator WWW= http://namazu.org/~satoru/zphoto/ -LIB_DEPENDS= libming.so:graphics/ming \ - libpopt.so:devel/popt \ - libImlib2.so:graphics/imlib2 +LICENSE= LGPL21 +LICENSE_FILE= ${WRKSRC}/COPYING -USES= alias gmake localbase perl5 +LIB_DEPENDS= libImlib2.so:graphics/imlib2 \ + libming.so:graphics/ming \ + libpopt.so:devel/popt + +USES= alias gmake localbase perl5 pkgconfig USE_PERL5= build GNU_CONFIGURE= yes CONFIGURE_ARGS= --disable-avifile -OPTIONS_DEFINE= ZIP NLS +OPTIONS_DEFINE= NLS ZIP OPTIONS_DEFAULT= ZIP OPTIONS_SUB= yes -ZIP_DESC= Enable zip support -ZIP_RUN_DEPENDS= zip:archivers/zip -ZIP_CONFIGURE_OFF= --disable-zip +ZIP_DESC= Enable zip support -NLS_USES= gettext +NLS_USES= gettext-tools NLS_CONFIGURE_ENABLE= nls +ZIP_RUN_DEPENDS= zip:archivers/zip +ZIP_CONFIGURE_OFF= --disable-zip + post-patch: @${REINPLACE_CMD} -e 's|||g' ${WRKSRC}/*.c ${WRKSRC}/configure .include diff --git a/graphics/zphoto/files/patch-configure b/graphics/zphoto/files/patch-configure index 81857a226640..59d2b3606c5f 100644 --- a/graphics/zphoto/files/patch-configure +++ b/graphics/zphoto/files/patch-configure @@ -1,11 +1,27 @@ ---- configure.orig Wed May 5 16:27:51 2004 -+++ configure Wed May 5 16:44:18 2004 -@@ -4131,7 +4131,7 @@ +Add minimal support to `pkg-config imlib2`; imlib2-config has been +dropped since imlib2-1.7.5. + +--- configure.orig 2004-07-20 16:49:27 UTC ++++ configure +@@ -4494,7 +4494,7 @@ EOF SWFMovie_save(movie, "foo"); /* 0.2a API */ } EOF -if $CC -c tmp.c > /dev/null 2>&1; then +if $CC -c $CFLAGS $CPPFLAGS tmp.c > /dev/null 2>&1; then cat >>confdefs.h <<_ACEOF #define MING_0_2a 1 +@@ -4867,6 +4867,12 @@ IMLIB2CONFIG=$ac_cv_path_IMLIB2CONFIG + esac + fi + IMLIB2CONFIG=$ac_cv_path_IMLIB2CONFIG ++ ++if test -z "$IMLIB2CONFIG"; then ++ if pkg-config imlib2; then ++ IMLIB2CONFIG="pkg-config imlib2" ++ fi ++fi + + if test -n "$IMLIB2CONFIG"; then + echo "$as_me:$LINENO: result: $IMLIB2CONFIG" >&5 diff --git a/graphics/zphoto/files/patch-exif.c b/graphics/zphoto/files/patch-exif.c index 6963c63ed522..6042b6be5303 100644 --- a/graphics/zphoto/files/patch-exif.c +++ b/graphics/zphoto/files/patch-exif.c @@ -1,144 +1,144 @@ ---- exif.c.orig 2004-06-07 18:58:04.000000000 +0900 -+++ exif.c 2010-12-03 21:25:38.562390923 +0900 -@@ -33,11 +33,11 @@ +--- exif.c.orig 2004-06-07 09:58:04 UTC ++++ exif.c +@@ -33,11 +33,11 @@ enum { HEADER_OFFSET2 = 8 }; -#define SWAP_ENDIAN_LONG(val) ((unsigned long) ( \ - (((unsigned long) (val) & (unsigned long) 0x000000ffU) << 24) | \ - (((unsigned long) (val) & (unsigned long) 0x0000ff00U) << 8) | \ - (((unsigned long) (val) & (unsigned long) 0x00ff0000U) >> 8) | \ - (((unsigned long) (val) & (unsigned long) 0xff000000U) >> 24))) +#define SWAP_ENDIAN_LONG(val) ((unsigned int) ( \ + (((unsigned int) (val) & (unsigned int) 0x000000ffU) << 24) | \ + (((unsigned int) (val) & (unsigned int) 0x0000ff00U) << 8) | \ + (((unsigned int) (val) & (unsigned int) 0x00ff0000U) >> 8) | \ + (((unsigned int) (val) & (unsigned int) 0xff000000U) >> 24))) #define SWAP_ENDIAN_SHORT(val) ((unsigned short) ( \ (((unsigned short) (val) & (unsigned short) 0x00ff) << 8) | \ -@@ -46,14 +46,14 @@ +@@ -46,14 +46,14 @@ is_little_endian () static int is_little_endian () { - static long retval = -1; + static int retval = -1; if (retval == -1) { - long n = 1; + int n = 1; char *p = (char *)&n; char x[] = {1, 0, 0, 0}; - assert(sizeof(long) == 4); + assert(sizeof(int) == 4); if (memcmp(p, x, 4) == 0) { retval = 1; } else { -@@ -63,8 +63,8 @@ +@@ -63,8 +63,8 @@ is_little_endian () return retval; } -static unsigned long -ulong_from_le (unsigned long x) +static unsigned int +uint_from_le (unsigned int x) { if (is_little_endian()) { return x; -@@ -83,8 +83,8 @@ +@@ -83,8 +83,8 @@ ushort_from_be (unsigned short x) } } -static unsigned long -ulong_from_be (unsigned long x) +static unsigned int +uint_from_be (unsigned int x) { if (is_little_endian()) { return SWAP_ENDIAN_LONG(x); -@@ -115,7 +115,7 @@ +@@ -115,7 +115,7 @@ static int static int -efseek (FILE *stream, long offset, int whence) +efseek (FILE *stream, int offset, int whence) { int x = fseek(stream, offset, whence); if (x != 0) -@@ -142,16 +142,16 @@ +@@ -142,16 +142,16 @@ typedef void (*TraverseFunc) (FILE *fp, typedef void (*TraverseFunc) (FILE *fp, unsigned short tag, unsigned short type, - unsigned long size, - unsigned long value, + unsigned int size, + unsigned int value, void *data); static void get_special_offset (FILE *fp, unsigned short tag, unsigned short type, - unsigned long size, - unsigned long value, + unsigned int size, + unsigned int value, void *data) { if (tag == 0x8769) { -@@ -163,12 +163,12 @@ +@@ -163,12 +163,12 @@ get_time (FILE *fp, get_time (FILE *fp, unsigned short tag, unsigned short type, - unsigned long size, - unsigned long value, + unsigned int size, + unsigned int value, void *data) { if (tag == 0x9003) { - long curpos; + int curpos; char buf[BUFSIZ]; struct tm t; -@@ -204,16 +204,16 @@ +@@ -204,16 +204,16 @@ read_ushort (FILE *fp, int le_exif_p) return ushort_from_be(x); } -static unsigned long -read_ulong (FILE *fp, int le_exif_p) +static unsigned int +read_uint (FILE *fp, int le_exif_p) { - unsigned long x; + unsigned int x; - efread(&x, sizeof(unsigned long), 1, fp); + efread(&x, sizeof(unsigned int), 1, fp); if (le_exif_p) - return ulong_from_le(x); + return uint_from_le(x); else - return ulong_from_be(x); + return uint_from_be(x); } static int -@@ -225,12 +225,12 @@ +@@ -225,12 +225,12 @@ read_directory (FILE *fp, TraverseFunc func, void *dat n = read_ushort(fp, le_exif_p); for (i = 0; i < n; i++) { unsigned short tag, type; - unsigned long size, value; + unsigned int size, value; tag = read_ushort(fp, le_exif_p); type = read_ushort(fp, le_exif_p); - size = read_ulong(fp, le_exif_p); - value = read_ulong(fp, le_exif_p); + size = read_uint(fp, le_exif_p); + value = read_uint(fp, le_exif_p); func(fp, tag, type, size, value, data); } diff --git a/graphics/zphoto/files/patch-Makefile.in b/graphics/zphoto/files/patch-templates_default_all_Makefile.in similarity index 63% rename from graphics/zphoto/files/patch-Makefile.in rename to graphics/zphoto/files/patch-templates_default_all_Makefile.in index 2b920bc11c4f..0edc504cbfa3 100644 --- a/graphics/zphoto/files/patch-Makefile.in +++ b/graphics/zphoto/files/patch-templates_default_all_Makefile.in @@ -1,15 +1,15 @@ ---- templates/default/all/Makefile.in.org 2014-06-21 19:51:31.487457236 +0900 -+++ templates/default/all/Makefile.in 2014-06-21 19:51:46.935435015 +0900 -@@ -369,9 +369,9 @@ +--- templates/default/all/Makefile.in.orig 2004-07-20 16:49:24 UTC ++++ templates/default/all/Makefile.in +@@ -369,9 +369,9 @@ install-data-local: | sh install-data-local: - mkdir -p $(templatesdir) - cp -p *.html.* $(templatesdir) - cp -p *.js.* $(templatesdir) + mkdir -p $(DESTDIR)$(templatesdir) + cp -p *.html.* $(DESTDIR)$(templatesdir) + cp -p *.js.* $(DESTDIR)$(templatesdir) clean: rm -f zphoto.css .photo.html *.html.* *.js.* *.txt diff --git a/graphics/zphoto/files/patch-util.c b/graphics/zphoto/files/patch-util.c index 9a3ea02f4a9d..f35f88a9c757 100644 --- a/graphics/zphoto/files/patch-util.c +++ b/graphics/zphoto/files/patch-util.c @@ -1,11 +1,11 @@ ---- util.c.orig 2010-12-04 00:36:16.000000000 +0900 -+++ util.c 2010-12-04 00:36:52.000000000 +0900 -@@ -389,7 +389,7 @@ +--- util.c.orig 2004-07-20 16:48:11 UTC ++++ util.c +@@ -389,7 +389,7 @@ zphoto_get_image_suffixes (void) zphoto_get_image_suffixes (void) { static char *empty[] = { NULL }; - static char *suffixes[] = { "jpg", "png", "gif", "bmp", NULL }; + static char *suffixes[] = { "jpeg", "jpg", "png", "gif", "bmp", NULL }; if (zphoto_support_image_p()) { return suffixes;