Hi ports@, Here is a diff to update ledger to 3.1.3.
This fixes CVE-2017-2807, CVE-2017-2808, CVE-2017-12481, CVE-2017-12482. Bumping major as symbols were removed from the library. Emacs Lisp files have been moved out of ledger, and are now hosted in a separate repository [1], so those files are not part of the package anymore. Comments? OK? [1]: https://github.com/ledger/ledger-mode Index: Makefile =================================================================== RCS file: /cvs/ports/productivity/ledger/Makefile,v retrieving revision 1.27 diff -u -p -r1.27 Makefile --- Makefile 9 Aug 2019 16:05:17 -0000 1.27 +++ Makefile 20 Dec 2019 08:25:35 -0000 @@ -2,16 +2,15 @@ COMMENT = command line double-entry accounting ledger -GH_TAGNAME = v3.1.1 +GH_TAGNAME = v3.1.3 GH_ACCOUNT = ledger GH_PROJECT = ledger -REVISION = 4 -SHARED_LIBS += ledger 0.0 # 3.0 +SHARED_LIBS += ledger 1.0 # 3.0 CATEGORIES = productivity -HOMEPAGE = http://www.ledger-cli.org/ +HOMEPAGE = https://www.ledger-cli.org/ MAINTAINER = Sergey Bronnikov <este...@gmail.com> @@ -20,7 +19,7 @@ PERMIT_PACKAGE = Yes WANTLIB += boost_date_time-mt boost_filesystem-mt boost_iostreams-mt WANTLIB += boost_regex-mt boost_system-mt boost_unit_test_framework-mt -WANTLIB += c gmp m mpfr pthread ${COMPILER_LIBCXX} +WANTLIB += c gmp icuuc m mpfr pthread ${COMPILER_LIBCXX} MODULES = devel/cmake \ lang/python @@ -49,7 +48,7 @@ pre-configure: ${SUBST_CMD} ${WRKSRC}/src/CMakeLists.txt post-install: -.for i in ledger3 ledger-mode +.for i in ledger3 cd ${WRKBUILD}/doc/ && \ cp ${WRKSRC}/doc/$i.texi . && \ makeinfo --force --no-split -o ${PREFIX}/info/$i.info $i.texi Index: distinfo =================================================================== RCS file: /cvs/ports/productivity/ledger/distinfo,v retrieving revision 1.6 diff -u -p -r1.6 distinfo --- distinfo 13 Aug 2016 19:22:05 -0000 1.6 +++ distinfo 20 Dec 2019 08:25:35 -0000 @@ -1,2 +1,2 @@ -SHA256 (ledger-3.1.1.tar.gz) = kPBlYatpKxktRtZ7wQYVjanGxoE8w4SLUDJDqd/YVIo= -SIZE (ledger-3.1.1.tar.gz) = 842364 +SHA256 (ledger-3.1.3.tar.gz) = skjJHWXHoQG51iJgJfK0vz2r6UwMSattUc6Eoio5Yis= +SIZE (ledger-3.1.3.tar.gz) = 800880 Index: patches/patch-src_CMakeLists_txt =================================================================== RCS file: /cvs/ports/productivity/ledger/patches/patch-src_CMakeLists_txt,v retrieving revision 1.1 diff -u -p -r1.1 patch-src_CMakeLists_txt --- patches/patch-src_CMakeLists_txt 13 Aug 2016 19:22:05 -0000 1.1 +++ patches/patch-src_CMakeLists_txt 20 Dec 2019 08:25:35 -0000 @@ -2,9 +2,10 @@ $OpenBSD: patch-src_CMakeLists_txt,v 1.1 Enforce library versioning. ---- src/CMakeLists.txt.orig Mon Jan 11 16:59:38 2016 -+++ src/CMakeLists.txt Thu Aug 11 22:42:45 2016 -@@ -268,8 +268,8 @@ if (BUILD_LIBRARY) +Index: src/CMakeLists.txt +--- src/CMakeLists.txt.orig ++++ src/CMakeLists.txt +@@ -278,8 +278,8 @@ if (BUILD_LIBRARY) set_target_properties(libledger PROPERTIES PREFIX "" INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}" Index: patches/patch-src_item_h =================================================================== RCS file: patches/patch-src_item_h diff -N patches/patch-src_item_h --- patches/patch-src_item_h 9 Aug 2019 16:05:17 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,17 +0,0 @@ -$OpenBSD: patch-src_item_h,v 1.1 2019/08/09 16:05:17 cwen Exp $ - -Fix the build with ports-gcc, from upstream: -https://github.com/ledger/ledger/commit/258cab91ab702e82d477b41bb1c6a026c848bda5 - -Index: src/item.h ---- src/item.h.orig -+++ src/item.h -@@ -92,7 +92,7 @@ class item_t : public supports_flags<uint_least16_t>, - - typedef std::pair<optional<value_t>, bool> tag_data_t; - typedef std::map<string, tag_data_t, -- function<bool(string, string)> > string_map; -+ std::function<bool(string, string)> > string_map; - - state_t _state; - optional<date_t> _date; Index: pkg/PLIST =================================================================== RCS file: /cvs/ports/productivity/ledger/pkg/PLIST,v retrieving revision 1.4 diff -u -p -r1.4 PLIST --- pkg/PLIST 13 Aug 2016 19:22:05 -0000 1.4 +++ pkg/PLIST 20 Dec 2019 08:25:35 -0000 @@ -29,7 +29,6 @@ include/ledger/lookup.h include/ledger/mask.h include/ledger/op.h include/ledger/option.h -include/ledger/org.h include/ledger/output.h include/ledger/parser.h include/ledger/pool.h @@ -50,7 +49,6 @@ include/ledger/select.h include/ledger/session.h include/ledger/stats.h include/ledger/stream.h -include/ledger/strptime.h include/ledger/system.hh include/ledger/temps.h include/ledger/timelog.h @@ -61,7 +59,6 @@ include/ledger/utils.h include/ledger/value.h include/ledger/views.h include/ledger/xact.h -info/ledger-mode.info info/ledger3.info @lib lib/libledger.so.${LIBledger_VERSION} @man man/man1/ledger.1 @@ -103,8 +100,8 @@ share/examples/ledger/non-profit-audit-r share/examples/ledger/non-profit-audit-reports/tests/Financial/BankStuff/ share/examples/ledger/non-profit-audit-reports/tests/Financial/BankStuff/bank-statement.pdf share/examples/ledger/non-profit-audit-reports/tests/Financial/Invoices/ -share/examples/ledger/non-profit-audit-reports/tests/Financial/Invoices/Invoice2${LIBledger_MAJOR}11${LIBledger_MAJOR}51${LIBledger_MAJOR}.pdf -share/examples/ledger/non-profit-audit-reports/tests/Financial/Invoices/Invoice2${LIBledger_MAJOR}11${LIBledger_MAJOR}51${LIBledger_MAJOR}.txt +share/examples/ledger/non-profit-audit-reports/tests/Financial/Invoices/Invoice20110510.pdf +share/examples/ledger/non-profit-audit-reports/tests/Financial/Invoices/Invoice20110510.txt share/examples/ledger/non-profit-audit-reports/tests/Projects/ share/examples/ledger/non-profit-audit-reports/tests/Projects/Blah/ share/examples/ledger/non-profit-audit-reports/tests/Projects/Blah/Expenses/ @@ -117,7 +114,7 @@ share/examples/ledger/non-profit-audit-r share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/Expenses/hosting/AprilHostingReceipt.pdf share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/Expenses/hosting/AprilHostingReceipt.txt share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/Invoices/ -share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/Invoices/Invoice2${LIBledger_MAJOR}1${LIBledger_MAJOR}${LIBledger_MAJOR}1${LIBledger_MAJOR}1.pdf +share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/Invoices/Invoice20100101.pdf share/examples/ledger/non-profit-audit-reports/tests/Projects/Foo/earmark-record.txt share/examples/ledger/non-profit-audit-reports/tests/non-profit-test-data.ledger share/examples/ledger/non-profit-audit-reports/tests/non-profit-test-data_MANIFEST