From owner-svn-ports-head@freebsd.org Sun Oct 4 18:01:54 2015 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9114DA0F890; Sun, 4 Oct 2015 18:01:54 +0000 (UTC) (envelope-from sunpoet@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 80D171108; Sun, 4 Oct 2015 18:01:54 +0000 (UTC) (envelope-from sunpoet@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.70]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id t94I1sAI047589; Sun, 4 Oct 2015 18:01:54 GMT (envelope-from sunpoet@FreeBSD.org) Received: (from sunpoet@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id t94I1sHt047587; Sun, 4 Oct 2015 18:01:54 GMT (envelope-from sunpoet@FreeBSD.org) Message-Id: <201510041801.t94I1sHt047587@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sunpoet set sender to sunpoet@FreeBSD.org using -f From: Sunpoet Po-Chuan Hsieh Date: Sun, 4 Oct 2015 18:01:54 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r398615 - in head/graphics/mupdf: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Oct 2015 18:01:54 -0000 Author: sunpoet Date: Sun Oct 4 18:01:53 2015 New Revision: 398615 URL: https://svnweb.freebsd.org/changeset/ports/398615 Log: - Fix build with openjpeg 2.1.1 - Bump PORTREVISION - While I'm here: - Update MASTER_SITES: make 1.7 fetchable - Use DISTVERSIONSUFFIX instead of EXTRACT_SUFX - Convert to new options helper PR: 203327 Submitted by: Walter Schwarzenfeld Approved by: Zsolt Udvari (maintainer) Modified: head/graphics/mupdf/Makefile head/graphics/mupdf/files/patch-source__fitz__load-jpx.c Modified: head/graphics/mupdf/Makefile ============================================================================== --- head/graphics/mupdf/Makefile Sun Oct 4 18:01:48 2015 (r398614) +++ head/graphics/mupdf/Makefile Sun Oct 4 18:01:53 2015 (r398615) @@ -3,18 +3,17 @@ PORTNAME= mupdf PORTVERSION= 1.7 +DISTVERSIONSUFFIX= -source PORTEPOCH= 1 CATEGORIES= graphics -MASTER_SITES= http://www.mupdf.com/download/ -EXTRACT_SUFX= -source.tar.gz +MASTER_SITES= http://www.mupdf.com/download/ \ + http://www.mupdf.com/download/archive/ MAINTAINER= udvzsolt@gmail.com COMMENT= Lightweight PDF viewer and toolkit LICENSE= AGPLv3 -BROKEN= fails to link with openjpeg 2.1.1 - LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl \ libfreetype.so:${PORTSDIR}/print/freetype2 \ libjbig2dec.so:${PORTSDIR}/graphics/jbig2dec \ @@ -35,16 +34,9 @@ OPTIONS_DEFAULT=SCROLL SCROLL_DESC= Build with scroll hacks JS_DESC= JavaScript support (V8 engine) -.include - -.if ${PORT_OPTIONS:MSCROLL} -EXTRA_PATCHES+= ${FILESDIR}/scroll_hack-platform__x11__pdfapp.c -.endif - -.if ${PORT_OPTIONS:MJS} -LIB_DEPENDS+= libv8.so:${PORTSDIR}/lang/v8 -MAKE_ARGS+= V8_PRESENT=1 V8LIBS=-lv8 -.endif +SCROLL_EXTRA_PATCHES= ${FILESDIR}/scroll_hack-platform__x11__pdfapp.c +JS_LIB_DEPENDS= libv8.so:${PORTSDIR}/lang/v8 +JS_MAKE_ARGS= V8_PRESENT=1 V8LIBS=-lv8 post-patch: @${REINPLACE_CMD} -e 's/-pipe -O2 //' \ Modified: head/graphics/mupdf/files/patch-source__fitz__load-jpx.c ============================================================================== --- head/graphics/mupdf/files/patch-source__fitz__load-jpx.c Sun Oct 4 18:01:48 2015 (r398614) +++ head/graphics/mupdf/files/patch-source__fitz__load-jpx.c Sun Oct 4 18:01:53 2015 (r398615) @@ -1,15 +1,25 @@ ---- ./source/fitz/load-jpx.c.orig 2014-06-10 17:09:28.000000000 +0200 -+++ ./source/fitz/load-jpx.c 2014-08-04 18:51:45.000000000 +0200 -@@ -8,7 +8,7 @@ +--- source/fitz/load-jpx.c.orig 2015-04-16 08:57:45 UTC ++++ source/fitz/load-jpx.c +@@ -3,12 +3,17 @@ + /* Without the definition of OPJ_STATIC, compilation fails on windows + * due to the use of __stdcall. We believe it is required on some + * linux toolchains too. */ ++ ++#ifdef __cplusplus ++extern "C" ++{ + #define OPJ_STATIC + #ifndef _MSC_VER #define OPJ_HAVE_STDINT_H #endif ++#endif -#include +#include static void fz_opj_error_callback(const char *msg, void *client_data) { -@@ -116,7 +116,7 @@ +@@ -117,7 +122,7 @@ fz_load_jpx(fz_context *ctx, unsigned ch opj_stream_set_read_function(stream, fz_opj_stream_read); opj_stream_set_skip_function(stream, fz_opj_stream_skip); opj_stream_set_seek_function(stream, fz_opj_stream_seek); @@ -18,3 +28,10 @@ /* Set the length to avoid an assert */ opj_stream_set_user_data_length(stream, size); +@@ -247,3 +252,6 @@ fz_load_jpx(fz_context *ctx, unsigned ch + + return img; + } ++#ifdef __cplusplus ++} ++#endif