Here is an update to megatools 1.11.1, released on February 12,
2023. Upstream has switched to meson.
changelog for 1.11.1 and 1.11.0:
https://megatools.megous.com/builds/NEWS
This port update does the following:
- copes with the suffix date by removing it for PKGNAME
- regens WANTLIB. ssl is pulled in by curl and intl and pthread are
pulled in by glib-2.0 according to `env LD_DEBUG= megatools'
- adds textproc/docbook2x since meson.build checks for asciidoc and
docbook2x in order to build man pages
- moves to meson and adds devel/ninja
- sets NO_TEST because the tests just use the tools and require network
access
- There is now one binary megatools. Install all associated man pages
and docs. I chose not to install symlinks (e.g., megadl --> megatools
dl).
I tested `megatools dl', which worked, but `megatools reg' failed, as
with the current version.
Feedback and tests are welcome. OK?
Index: Makefile
===================================================================
RCS file: /cvs/ports/net/megatools/Makefile,v
retrieving revision 1.22
diff -u -p -u -p -r1.22 Makefile
--- Makefile 11 Mar 2022 19:46:20 -0000 1.22
+++ Makefile 2 May 2023 23:08:35 -0000
@@ -2,8 +2,10 @@ PORTROACH = limit:[0-9]\.tar\.gz
COMMENT = command line client application for Mega
-DISTNAME = megatools-1.10.3
-REVISION = 0
+V = 1.11.1
+DATE = 20230212
+DISTNAME = megatools-${V}.${DATE}
+PKGNAME = ${DISTNAME:S/.${DATE}//}
CATEGORIES = net
@@ -14,23 +16,39 @@ MAINTAINER = Anthony J. Bentley <anthon
# GPLv2+
PERMIT_PACKAGE = Yes
-WANTLIB = c crypto curl gio-2.0 glib-2.0 gobject-2.0 intl pthread
-WANTLIB += ssl
+WANTLIB += c crypto curl gio-2.0 glib-2.0 gobject-2.0
MASTER_SITES = https://megatools.megous.com/builds/
COMPILER = base-clang ports-gcc
BUILD_DEPENDS = devel/gobject-introspection \
- textproc/asciidoc
+ devel/ninja \
+ textproc/asciidoc \
+ textproc/docbook2x
LIB_DEPENDS = devel/glib2 \
net/curl
-USE_GMAKE = Yes
-CONFIGURE_STYLE = gnu
-MAKE_FLAGS = VERBOSE=1
+MODULE = devel/meson
-CONFIGURE_ARGS = --disable-introspection
+do-configure:
+ cd ${WRKSRC} && ${SETENV} ${CONFIGURE_ENV} meson setup ${WRKBUILD}
+
+do-build:
+ cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ninja -C ${WRKBUILD}
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKBUILD}/${PKGSTEM} ${PREFIX}/bin
+.for M in 1 5
+ ${INSTALL_DATA} ${WRKBUILD}/*.${M} ${PREFIX}/man/man${M}
+.endfor
+ ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/${PKGSTEM}
+.for F in README NEWS TODO LICENSE
+ ${INSTALL_DATA} ${WRKSRC}/${F} ${PREFIX}/share/doc/${PKGSTEM}
+.endfor
SEPARATE_BUILD = Yes
+
+# tests require network access
+NO_TEST = Yes
.include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/net/megatools/distinfo,v
retrieving revision 1.7
diff -u -p -u -p -r1.7 distinfo
--- distinfo 19 May 2020 06:22:48 -0000 1.7
+++ distinfo 2 May 2023 23:08:35 -0000
@@ -1,2 +1,2 @@
-SHA256 (megatools-1.10.3.tar.gz) = jcHKNIYz/UnefrgysyPo3ClfHFWu+0hNMOZHUhhVi9s=
-SIZE (megatools-1.10.3.tar.gz) = 196361
+SHA256 (megatools-1.11.1.20230212.tar.gz) = 7Pou5LJ3xgHrrmSChzEQMKpMpz6mHucwvGa+8k7xmjQ=
+SIZE (megatools-1.11.1.20230212.tar.gz) = 105339
Index: patches/patch-lib_mega_c
===================================================================
RCS file: /cvs/ports/net/megatools/patches/patch-lib_mega_c,v
retrieving revision 1.4
diff -u -p -u -p -r1.4 patch-lib_mega_c
--- patches/patch-lib_mega_c 11 Mar 2022 19:46:20 -0000 1.4
+++ patches/patch-lib_mega_c 2 May 2023 23:08:35 -0000
@@ -3,7 +3,7 @@ Fix build with opaque RSA in LibreSSL 3.
Index: lib/mega.c
--- lib/mega.c.orig
+++ lib/mega.c
-@@ -785,7 +785,7 @@ static gboolean rsa_key_gen(struct rsa_key *k)
+@@ -787,7 +787,7 @@ static gboolean rsa_key_gen(struct rsa_key *k)
return FALSE;
}
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/net/megatools/pkg/PLIST,v
retrieving revision 1.5
diff -u -p -u -p -r1.5 PLIST
--- pkg/PLIST 11 Mar 2022 19:46:20 -0000 1.5
+++ pkg/PLIST 2 May 2023 23:08:35 -0000
@@ -1,26 +1,18 @@
-@bin bin/megacopy
-@bin bin/megadf
-@bin bin/megadl
-@bin bin/megaget
-@bin bin/megals
-@bin bin/megamkdir
-@bin bin/megaput
-@bin bin/megareg
-@bin bin/megarm
-@man man/man1/megacopy.1
-@man man/man1/megadf.1
-@man man/man1/megadl.1
-@man man/man1/megaget.1
-@man man/man1/megals.1
-@man man/man1/megamkdir.1
-@man man/man1/megaput.1
-@man man/man1/megareg.1
-@man man/man1/megarm.1
+@bin bin/megatools
+@man man/man1/megatools-copy.1
+@man man/man1/megatools-df.1
+@man man/man1/megatools-dl.1
+@man man/man1/megatools-export.1
+@man man/man1/megatools-get.1
+@man man/man1/megatools-ls.1
+@man man/man1/megatools-mkdir.1
+@man man/man1/megatools-put.1
+@man man/man1/megatools-reg.1
+@man man/man1/megatools-rm.1
+@man man/man1/megatools-test.1
+@man man/man1/megatools.1
@man man/man5/megarc.5
-@man man/man7/megatools.7
share/doc/megatools/
-share/doc/megatools/HACKING
-share/doc/megatools/INSTALL
share/doc/megatools/LICENSE
share/doc/megatools/NEWS
share/doc/megatools/README
No comments:
Post a Comment