From nobody Wed Oct 20 06:52:24 2021 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 11EF81810DB5; Wed, 20 Oct 2021 06:52:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4HZ1WX7296z4v4g; Wed, 20 Oct 2021 06:52:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id D2545231B6; Wed, 20 Oct 2021 06:52:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 19K6qOcZ036470; Wed, 20 Oct 2021 06:52:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 19K6qO4c036469; Wed, 20 Oct 2021 06:52:24 GMT (envelope-from git) Date: Wed, 20 Oct 2021 06:52:24 GMT Message-Id: <202110200652.19K6qO4c036469@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Li-Wen Hsu Subject: git: 4a010b3d9ad9 - main - graphics/cfdg: Update to 3.3 and unbreak List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: lwhsu X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4a010b3d9ad9bcc9e662339f8be1c9c15c2bdafb Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by lwhsu: URL: https://cgit.FreeBSD.org/ports/commit/?id=4a010b3d9ad9bcc9e662339f8be1c9c15c2bdafb commit 4a010b3d9ad9bcc9e662339f8be1c9c15c2bdafb Author: Robert Clausecker AuthorDate: 2021-10-04 14:17:33 +0000 Commit: Li-Wen Hsu CommitDate: 2021-10-20 06:42:56 +0000 graphics/cfdg: Update to 3.3 and unbreak Also transfer maintainership. PR: 258927, 259278 --- graphics/cfdg/Makefile | 36 +++++++------ graphics/cfdg/distinfo | 5 +- graphics/cfdg/files/patch-Makefile | 78 +++++++++++++++++++++++---- graphics/cfdg/files/patch-src-common_cfdg.ypp | 11 ++++ 4 files changed, 101 insertions(+), 29 deletions(-) diff --git a/graphics/cfdg/Makefile b/graphics/cfdg/Makefile index 61cb5bbff022..e438d4769070 100644 --- a/graphics/cfdg/Makefile +++ b/graphics/cfdg/Makefile @@ -1,38 +1,42 @@ # Created by: Anatoly Borodin PORTNAME= cfdg -PORTVERSION= 2.2.2 -PORTREVISION= 2 +PORTVERSION= 3.3 CATEGORIES= graphics math MASTER_SITES= http://www.contextfreeart.org/download/ \ http://glyphic.s3.amazonaws.com/cfa/download/ DISTNAME= ContextFreeSource${PORTVERSION} -MAINTAINER= anatoly.borodin@gmail.com +MAINTAINER= fuz@fuz.su COMMENT= Context Free Design Grammar compiler LICENSE= GPLv2+ LICENSE_FILE= ${WRKSRC}/LICENSE.txt -BROKEN_FreeBSD_13= does not build: error: conflicting types for 'yyget_leng' -BROKEN_FreeBSD_14= does not build: error: conflicting types for 'yyget_leng' +LIB_DEPENDS= libicuuc.so:devel/icu \ + libpng.so:graphics/png -LIB_DEPENDS= libpng.so:graphics/png +USES= bison gmake tar:xz +MAKE_ARGS= prefix=${PREFIX} \ + DESTDIR=${STAGEDIR} +TEST_TARGET= check +NO_WRKSUBDIR= yes +PLIST_FILES= bin/cfdg \ + share/man/man1/cfdg.1.gz -WRKSRC= ${WRKDIR}/${DISTNAME}${EXTRACT_SUFX} +PORTEXAMPLES= *.cfdg -USES= gmake tar:tgz -PLIST_FILES= bin/cfdg +OPTIONS_DEFINE= EXAMPLES FFMPEG +OPTIONS_DEFAULT= FFMPEG +FFMPEG_LIB_DEPENDS= libavformat.so:multimedia/ffmpeg \ + libx264.so:multimedia/libx264 +FFMPEG_MAKE_ARGS= WANT_FFMPEG=yes -PORTEXAMPLES= * - -OPTIONS_DEFINE= EXAMPLES - -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/cfdg ${STAGEDIR}${PREFIX}/bin +post-patch: + ${REINPLACE_CMD} -e 's,/usr/local,${LOCALBASE},' ${WRKSRC}/Makefile do-install-EXAMPLES-on: @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} - ${INSTALL_DATA} ${WRKSRC}/input/* ${STAGEDIR}${EXAMPLESDIR} + ${INSTALL_DATA} ${WRKSRC}/input/*.cfdg ${STAGEDIR}${EXAMPLESDIR} .include diff --git a/graphics/cfdg/distinfo b/graphics/cfdg/distinfo index 426dc506e36f..1b64578873fd 100644 --- a/graphics/cfdg/distinfo +++ b/graphics/cfdg/distinfo @@ -1,2 +1,3 @@ -SHA256 (ContextFreeSource2.2.2.tgz) = 2524726ee9a5df7c7dd4ce31364fad8fe2fcad930e0d88af5cf2c6148017705e -SIZE (ContextFreeSource2.2.2.tgz) = 1635320 +TIMESTAMP = 1633352475 +SHA256 (ContextFreeSource3.3.tar.xz) = f0b9b3622d7e729d867a5e5a9f8d1e9a134f019215fdde553c11b523416291c8 +SIZE (ContextFreeSource3.3.tar.xz) = 2684008 diff --git a/graphics/cfdg/files/patch-Makefile b/graphics/cfdg/files/patch-Makefile index c99dea41750e..15e6c8f49045 100644 --- a/graphics/cfdg/files/patch-Makefile +++ b/graphics/cfdg/files/patch-Makefile @@ -1,20 +1,76 @@ ---- ./Makefile.orig 2010-09-13 06:15:25.000000000 +0200 -+++ ./Makefile 2011-06-18 21:42:16.000000000 +0200 -@@ -54,7 +54,7 @@ +--- Makefile.orig 2020-04-10 19:38:18 UTC ++++ Makefile +@@ -34,7 +34,7 @@ MAN_DIR = $(DESTDIR)$(prefix)/share/man + # Library directories for FFmpeg and libpng + # + +-LIB_DIRS = /usr/local/lib ++LIB_DIRS = /usr/local/lib $(shell libpng-config --libdir) + + # + # Sources and Objects +@@ -69,30 +69,20 @@ INPUT_SRCS = ciliasun_v2.cfdg demo1_v2.cfdg demo2_v2.c + welcome.cfdg ziggy.cfdg + + +-LIBS = png m ++LIBS = m + +-# Use the first one for clang and the second one for gcc +-ifeq ($(shell uname -s), Darwin) +- LIBS += c++ icucore +-else +- LIBS += stdc++ atomic icui18n icuuc icudata +-endif ++LIBS += stdc++ icui18n icuuc icudata + + # + # FFmpeg support + # +-# Uncomment these lines to enable FFmpeg support +-# ++ifeq ($(WANT_FFMPEG), yes) ++ COMMON_SRCS += ffCanvas.cpp ++ LIBS += avformat avcodec swscale swresample avutil z m x264 pthread dl ++else ++ COMMON_SRCS += ffCanvasDummy.cpp ++endif + +-# COMMON_SRCS += ffCanvas.cpp +-# LIBS += avformat avcodec swscale swresample avutil z m x264 pthread dl +- +-# +-# Comment out this line to enable FFmpeg support +-# +- +-COMMON_SRCS += ffCanvasDummy.cpp +- + SRCS = $(DERIVED_SRCS) $(COMMON_SRCS) $(UNIX_SRCS) + + # +@@ -113,6 +103,7 @@ DEPS = $(patsubst %.o,%.d,$(OBJS)) + + LINKFLAGS += $(patsubst %,-L%,$(LIB_DIRS)) + LINKFLAGS += $(patsubst %,-l%,$(LIBS)) ++LINKFLAGS += $(shell libpng-config --libs) + LINKFLAGS += -fexceptions + + deps: $(OBJ_DIR) $(DEPS) +@@ -133,7 +124,7 @@ $(OBJS): $(OBJ_DIR)/Sentry # Under Cygwin replace strip $@ with strip $@.exe cfdg: $(OBJS) -- $(LINK.o) $^ -L/usr/local/lib -lstdc++ -lpng -lz -fexceptions -o $@ -+ $(CXX) $^ $(shell libpng-config --ldflags) -lm -fexceptions -o $@ +- $(LINK.o) $^ $(LINKFLAGS) -o $@ ++ $(CXX) $^ $(LINKFLAGS) -o $@ strip $@ -@@ -105,7 +105,7 @@ +@@ -196,7 +187,7 @@ check: cfdg # - CPPFLAGS += $(patsubst %,-I%,$(INC_DIRS)) --CPPFLAGS += -O3 -Wall -+CPPFLAGS += -O3 -Wall $(shell libpng-config --cflags) - #CPPFLAGS += -ggdb + CXXFLAGS += $(patsubst %,-I%,$(INC_DIRS)) +-CXXFLAGS += -O2 -Wall -Wextra -march=native -Wno-parentheses -std=c++14 ++CXXFLAGS += -Wall -Wextra -Wno-parentheses -std=c++14 + CXXFLAGS += -g -D_GLIBCXX_USE_C99_MATH=1 + CPPFLAGS += -DNDEBUG - $(OBJ_DIR)/%.o : %.cpp diff --git a/graphics/cfdg/files/patch-src-common_cfdg.ypp b/graphics/cfdg/files/patch-src-common_cfdg.ypp new file mode 100644 index 000000000000..f94bb67debde --- /dev/null +++ b/graphics/cfdg/files/patch-src-common_cfdg.ypp @@ -0,0 +1,11 @@ +--- src-common/cfdg.ypp.orig 2021-10-04 13:54:54 UTC ++++ src-common/cfdg.ypp +@@ -31,7 +31,7 @@ + %skeleton "lalr1.cc" /* -*- C++ -*- */ + %require "3.0" + %defines +-%define parser_class_name {CfdgParser} ++%define api.parser.class {CfdgParser} + %locations + %expect 3 + //%debug