pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/net/megacmd



Module Name:    pkgsrc
Committed By:   bsiegert
Date:           Tue Jun 18 18:23:15 UTC 2024

Modified Files:
        pkgsrc/net/megacmd: DESCR Makefile PLIST distinfo
        pkgsrc/net/megacmd/patches: patch-Makefile.am patch-sdk_Makefile.am
            patch-sdk_configure.ac patch-sdk_src_http.cpp
            patch-sdk_src_posix_fs.cpp patch-src_include.am
Added Files:
        pkgsrc/net/megacmd/files: README
        pkgsrc/net/megacmd/patches: patch-configure.ac
            patch-sdk_include_mega_http.h patch-sdk_include_mega_posix_megafs.h
            patch-sdk_include_mega_posix_megasys.h patch-sdk_src_include.am
            patch-src_megacmdshell_megacmdshellcommunications.cpp
Removed Files:
        pkgsrc/net/megacmd: MESSAGE

Log Message:
net/megacmd: Update megacmd to 1.7.0

SDK version update to 4.31.0b.
The patchset has been updated to be build-able on
DragonFly, Free-, Net- and OpenBSD. Pull request
is sent to upstream, but hasn't been merged yet.

Changelog not available.

>From Robert Bagdan via pkgsrc-users.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/net/megacmd/DESCR pkgsrc/net/megacmd/PLIST \
    pkgsrc/net/megacmd/distinfo
cvs rdiff -u -r1.1 -r0 pkgsrc/net/megacmd/MESSAGE
cvs rdiff -u -r1.3 -r1.4 pkgsrc/net/megacmd/Makefile
cvs rdiff -u -r0 -r1.1 pkgsrc/net/megacmd/files/README
cvs rdiff -u -r1.1 -r1.2 pkgsrc/net/megacmd/patches/patch-Makefile.am \
    pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am \
    pkgsrc/net/megacmd/patches/patch-sdk_configure.ac \
    pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp \
    pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp \
    pkgsrc/net/megacmd/patches/patch-src_include.am
cvs rdiff -u -r0 -r1.1 pkgsrc/net/megacmd/patches/patch-configure.ac \
    pkgsrc/net/megacmd/patches/patch-sdk_include_mega_http.h \
    pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megafs.h \
    pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megasys.h \
    pkgsrc/net/megacmd/patches/patch-sdk_src_include.am \
    pkgsrc/net/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/net/megacmd/DESCR
diff -u pkgsrc/net/megacmd/DESCR:1.1 pkgsrc/net/megacmd/DESCR:1.2
--- pkgsrc/net/megacmd/DESCR:1.1        Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/DESCR    Tue Jun 18 18:23:15 2024
@@ -1,5 +1,8 @@
-MEGAcmd provides non UI access to MEGA services.
-It intends to offer all the functionality with your
-MEGA account via commands. It features synchronization,
-backup of local folders into your MEGA account and
-a webdav/streaming server.
+MEGA is a cloud storage, file and folder sharing
+provider.
+MEGAcmd is a free, open source tool that provides
+non UI access to MEGA services. It intends to offer
+all the functionality with your MEGA account via
+commands. It features synchronization, backup of
+local folders into your MEGA account and a webdav
+or streaming server.
Index: pkgsrc/net/megacmd/PLIST
diff -u pkgsrc/net/megacmd/PLIST:1.1 pkgsrc/net/megacmd/PLIST:1.2
--- pkgsrc/net/megacmd/PLIST:1.1        Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/PLIST    Tue Jun 18 18:23:15 2024
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.1 2024/03/11 07:49:12 wiz Exp $
+@comment $NetBSD: PLIST,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 bin/mega-attr
 bin/mega-backup
 bin/mega-cancel
@@ -103,6 +103,7 @@ include/mega/posix/megafs.h
 include/mega/posix/meganet.h
 include/mega/posix/megasys.h
 include/mega/posix/megawaiter.h
+include/mega/process.h
 include/mega/proxy.h
 include/mega/pubkeyaction.h
 include/mega/raid.h
@@ -128,3 +129,4 @@ include/megaapi_impl.h
 lib/libmega.la
 lib/pkgconfig/libmega.pc
 share/bash-completion/completions/megacmd
+share/doc/megacmd/README
Index: pkgsrc/net/megacmd/distinfo
diff -u pkgsrc/net/megacmd/distinfo:1.1 pkgsrc/net/megacmd/distinfo:1.2
--- pkgsrc/net/megacmd/distinfo:1.1     Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/distinfo Tue Jun 18 18:23:15 2024
@@ -1,17 +1,20 @@
-$NetBSD: distinfo,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: distinfo,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-BLAKE2s (megacmd-1.6.3.tar.gz) = c3df7a71184d4bc373e41273361e1a9818881d1b4b00ca4703fa1c199cd7093c
-SHA512 (megacmd-1.6.3.tar.gz) = 425584a1350e5965aea8a09076bb447b4d6a00fc0305e9a19ad91ed8292eae5b758e4c1a41ea7c0887c2f8e0644cf1d1154e3b33503ddcf4713e4a13dd80a6f6
-Size (megacmd-1.6.3.tar.gz) = 2085751 bytes
-BLAKE2s (meganz-sdk-v4.17.1d.tar.gz) = e3490a45338f2d1b62cbc607e80aa806906cc693ca8428b77973340bfba9ac39
-SHA512 (meganz-sdk-v4.17.1d.tar.gz) = bc67910b0a5fbbe9bb5d9d6ef9a746f1762dbb9968d9c825fd0ede256ab674670d804c2d99c9c472f72b2f06fd2bac4765bd7fa7dbebb3746cd1e1cfd780d71c
-Size (meganz-sdk-v4.17.1d.tar.gz) = 3695020 bytes
-SHA1 (patch-Makefile.am) = e6e092d8da00df3d2d73e542de61bea37336e9df
-SHA1 (patch-sdk_Makefile.am) = 8fedc590e7423e8a32d3cbe47b9503e8b197cf04
-SHA1 (patch-sdk_configure.ac) = 264edd914b05e24221a2fdd1c9890920f3f00521
-SHA1 (patch-sdk_include_mega_http_h) = 6d2acb2bdfe444d94c27ee523c9499f73f2fb5fe
-SHA1 (patch-sdk_include_mega_posix_megafs_h) = 69b099d0e8b5ac54c70808ec825d834d9edac2a9
-SHA1 (patch-sdk_src_http.cpp) = 23ebb74d092c27ed26c34c41c5a812a1ba835933
-SHA1 (patch-sdk_src_posix_fs.cpp) = a6e2b45e8e4740ae4eb362a11e165b7740daf7c2
-SHA1 (patch-src_include.am) = bd7f0899704b10e5c043ecd075adb750683f2272
-SHA1 (patch-src_megacmdshell_megacmdshellcommunications_cpp) = 99610633144ae5bcfcfbc52da43797c70ab9dd53
+BLAKE2s (megacmd-1.7.0.tar.gz) = 3b0008daa28b220ae909c491aebce7fd32a595607744acf7f7b0a6cef3a956c0
+SHA512 (megacmd-1.7.0.tar.gz) = 9e29a318d062a7d01d2a7e7e7655ef3adf079f2ff64c2eee3c035816821f9c981411f3676c8749a6fc51c44fad06a1428b1db0d6b61f32be5e222553bd9bb0dd
+Size (megacmd-1.7.0.tar.gz) = 2124305 bytes
+BLAKE2s (meganz-sdk-v4.31.0b.tar.gz) = ca471a7fc6fbcb3a5cea04aff2bfedcd77d33ca6cfd741f3954381f9bfc1af94
+SHA512 (meganz-sdk-v4.31.0b.tar.gz) = 525fbdb7bb4bb6e02cc0268a788f744258e41bb39e78c33c3ac1d21c54ad78a630775aa4440529cc3faa4c0679db0a72161f856c49e15d721487a748a0a08969
+Size (meganz-sdk-v4.31.0b.tar.gz) = 3592431 bytes
+SHA1 (patch-Makefile.am) = 68b2a67c0b3ddac4b247fc6e0f6dd7ab068d90bd
+SHA1 (patch-configure.ac) = e05d9a14c7190f450bbb7264fa3641a8b50b3c7f
+SHA1 (patch-sdk_Makefile.am) = 3b83578498bf2917116bc18b31adf09f0c46d9b8
+SHA1 (patch-sdk_configure.ac) = ed55c46f0614a5acc5ea3edc69934fb72f5afd46
+SHA1 (patch-sdk_include_mega_http.h) = a3845e17a6bb5ea9985f1a7de152f1c43a1767ec
+SHA1 (patch-sdk_include_mega_posix_megafs.h) = cee06d1b594588a9fb2c07828d436c74188022e5
+SHA1 (patch-sdk_include_mega_posix_megasys.h) = 02b6259c8932163dee52baeec5e1e07003288279
+SHA1 (patch-sdk_src_http.cpp) = 85b1ef20d4f512e38e336cb4ca2cfbe74372e040
+SHA1 (patch-sdk_src_include.am) = 93eae44fc1fa3ec6f621c7aba8266d63ec835ad7
+SHA1 (patch-sdk_src_posix_fs.cpp) = fdf5129f54a65d3bc52e9a6c6b2e76fdc40026e2
+SHA1 (patch-src_include.am) = 6a7d0dc05a23463066fa74434af1af18f18e0885
+SHA1 (patch-src_megacmdshell_megacmdshellcommunications.cpp) = 7ce41cfcfbc7c8df8f6176bc2abd6a08825fef80

Index: pkgsrc/net/megacmd/Makefile
diff -u pkgsrc/net/megacmd/Makefile:1.3 pkgsrc/net/megacmd/Makefile:1.4
--- pkgsrc/net/megacmd/Makefile:1.3     Wed May 29 16:33:58 2024
+++ pkgsrc/net/megacmd/Makefile Tue Jun 18 18:23:15 2024
@@ -1,12 +1,11 @@
-# $NetBSD: Makefile,v 1.3 2024/05/29 16:33:58 adam Exp $
+# $NetBSD: Makefile,v 1.4 2024/06/18 18:23:15 bsiegert Exp $
 
-DISTNAME=      megacmd-1.6.3
-PKGREVISION=   2
+DISTNAME=      megacmd-1.7.0
 CATEGORIES=    net
 MASTER_SITES=  ${MASTER_SITE_GITHUB:=meganz/}
 GITHUB_PROJECT=        MEGAcmd
 GITHUB_TAG=    ${PKGVERSION_NOREV}_Linux
-SDK_VERSION=   v4.17.1d
+SDK_VERSION=   v4.31.0b
 
 GITHUB_SUBMODULES=     meganz sdk ${SDK_VERSION} sdk
 
@@ -18,12 +17,12 @@ LICENSE=    gnu-gpl-v3 AND 2-clause-bsd
 
 USE_LANGUAGES+=                c c++
 USE_CXX_FEATURES+=     filesystem
+FORCE_CXX_STD=         c++17
 USE_LIBTOOL=           yes
-USE_TOOLS+=            autoreconf autoconf automake
+USE_TOOLS+=            autoreconf autoconf automake gmake
 GNU_CONFIGURE=         yes
 REPLACE_SH=            src/client/mega-*
-CXXFLAGS+=             -DCRYPTOPP_DISABLE_ASM -std=c++17
-BUILDLINK_TRANSFORM+=  rm:-std=c++11
+CXXFLAGS+=             -DCRYPTOPP_DISABLE_ASM
 
 CONFIGURE_ARGS+=       --disable-examples
 CONFIGURE_ARGS+=       --disable-java
@@ -36,16 +35,20 @@ CONFIGURE_ARGS+=    --without-ffmpeg
 CONFIGURE_ARGS+=       --without-libraw
 CONFIGURE_ARGS+=       --without-libzen
 CONFIGURE_ARGS+=       --without-libmediainfo
+CONFIGURE_ARGS+=       --without-rt
 CONFIGURE_ARGS+=       --enable-gcc-hardening
 
 CHECK_PORTABILITY_SKIP+=       sdk/bindings/ios/3rdparty/*.sh
 
+INSTALLATION_DIRS+=    share/doc/megacmd
+
 pre-configure:
        cd ${WRKSRC} && ${SH} autogen.sh
 
 post-install:
        ${MV} ${DESTDIR}${PREFIX}/share/bash-completion/completions/megacmd_completion.sh \
                ${DESTDIR}${PREFIX}/share/bash-completion/completions/megacmd
+       ${INSTALL_DATA} ${FILESDIR}/README ${DESTDIR}${PREFIX}/share/doc/megacmd
 
 .include "../../databases/sqlite3/buildlink3.mk"
 .include "../../devel/pcre/buildlink3.mk"
@@ -54,5 +57,6 @@ post-install:
 .include "../../net/libcares/buildlink3.mk"
 .include "../../security/crypto++/buildlink3.mk"
 .include "../../security/libsodium/buildlink3.mk"
+.include "../../textproc/icu/buildlink3.mk"
 .include "../../www/curl/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"

Index: pkgsrc/net/megacmd/patches/patch-Makefile.am
diff -u pkgsrc/net/megacmd/patches/patch-Makefile.am:1.1 pkgsrc/net/megacmd/patches/patch-Makefile.am:1.2
--- pkgsrc/net/megacmd/patches/patch-Makefile.am:1.1    Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-Makefile.am        Tue Jun 18 18:23:15 2024
@@ -1,16 +1,22 @@
-$NetBSD: patch-Makefile.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-Makefile.am,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* Add NetBSD support
+Add --tag=CXX libtool flag on NetBSD and Dragonfly.
+Upstream pull req: https://github.com/meganz/MEGAcmd/pull/949
 
---- Makefile.am.orig   2023-05-05 10:48:34.000000000 +0000
+--- Makefile.am.orig   2024-05-20 12:29:43.000000000 +0000
 +++ Makefile.am
-@@ -35,9 +35,7 @@ if ANDROID
+@@ -39,6 +39,14 @@ if LINUX
  AM_LIBTOOLFLAGS="--tag=CXX"
  endif
  
--if LINUX
- AM_LIBTOOLFLAGS="--tag=CXX"
--endif
- 
++if DRAGONFLY
++AM_LIBTOOLFLAGS="--tag=CXX"
++endif
++
++if NETBSD
++AM_LIBTOOLFLAGS="--tag=CXX"
++endif
++
  VERSION_INFO=$(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
  
+ CLEANFILES=
Index: pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am
diff -u pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am:1.1 pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am:1.2
--- pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am:1.1        Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_Makefile.am    Tue Jun 18 18:23:15 2024
@@ -1,16 +1,22 @@
-$NetBSD: patch-sdk_Makefile.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-sdk_Makefile.am,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* Add NetBSD support
+Add --tag=CXX libtool flag on NetBSD and DragonFly
+Upstream pull req: https://github.com/meganz/sdk/pull/2663
 
---- sdk/Makefile.am.orig       2023-05-02 16:07:05.000000000 +0000
+--- sdk/Makefile.am.orig       2024-05-17 14:19:43.000000000 +0000
 +++ sdk/Makefile.am
-@@ -42,9 +42,7 @@ if ANDROID
+@@ -46,6 +46,14 @@ if LINUX
  AM_LIBTOOLFLAGS="--tag=CXX"
  endif
  
--if LINUX
- AM_LIBTOOLFLAGS="--tag=CXX"
--endif
- 
++if DRAGONFLY
++AM_LIBTOOLFLAGS="--tag=CXX"
++endif
++
++if NETBSD
++AM_LIBTOOLFLAGS="--tag=CXX"
++endif
++
  VERSION_INFO=$(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
  
+ CLEANFILES=
Index: pkgsrc/net/megacmd/patches/patch-sdk_configure.ac
diff -u pkgsrc/net/megacmd/patches/patch-sdk_configure.ac:1.1 pkgsrc/net/megacmd/patches/patch-sdk_configure.ac:1.2
--- pkgsrc/net/megacmd/patches/patch-sdk_configure.ac:1.1       Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_configure.ac   Tue Jun 18 18:23:15 2024
@@ -1,26 +1,149 @@
-$NetBSD: patch-sdk_configure.ac,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-sdk_configure.ac,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* mega-cmd-server not syncing with aio_write function,
-* workaround disable librt. #TODO
+Add NetBSD and DragonFly support.
+Upstream pull req: https://github.com/meganz/sdk/pull/2663
 
---- sdk/configure.ac.orig      2024-02-27 08:17:47.102044837 +0000
+Add --with-rt=... configure option, syncing  with aio_write
+doesn't work on NetBSD, workaround build without rt support.
+Upstream pull req: https://github.com/meganz/sdk/pull/2665
+
+--- sdk/configure.ac.orig      2024-05-17 14:19:43.000000000 +0000
 +++ sdk/configure.ac
-@@ -1382,12 +1382,12 @@ if test "x$WIN32" = "xno" ; then
+@@ -208,6 +208,8 @@ WIN32=no
+ DARWIN=no
+ ANDROID=no
+ LINUX=no
++DRAGONFLY=no
++NETBSD=no
+ AC_MSG_CHECKING([platform options])
+ case $host in
+   *-*-cygwin*)
+@@ -238,6 +240,12 @@ case $host in
+   *-linux*)
+     LINUX=yes
+     ;;
++  *-dragonfly*)
++    DRAGONFLY=yes
++    ;;
++  *-netbsd*)
++    NETBSD=yes
++    ;;
+   *)
+     LIBS_EXTRA=""
+     ;;
+@@ -247,6 +255,8 @@ AM_CONDITIONAL([WIN32], [test "${WIN32}"
+ AM_CONDITIONAL([DARWIN], [test "${DARWIN}" = "yes"])
+ AM_CONDITIONAL([ANDROID], [test "${ANDROID}" = "yes"])
+ AM_CONDITIONAL([LINUX], [test "${LINUX}" = "yes"])
++AM_CONDITIONAL([DRAGONFLY], [test "${DRAGONFLY}" = "yes"])
++AM_CONDITIONAL([NETBSD], [test "${NETBSD}" = "yes"])
+ 
+ AC_SUBST(LIBS_EXTRA)
+ 
+@@ -1369,6 +1379,7 @@ AM_CONDITIONAL([USE_LIBMEDIAINFO], [test
+ #
+ openssl=false
+ cares=false
++rt=undef
+ if test "x$WIN32" = "xno" ; then
+ 
+     AC_ARG_WITH([poll],
+@@ -1381,12 +1392,71 @@ if test "x$WIN32" = "xno" ; then
+         LDFLAGS="-pthread $LDFLAGS"
      fi
  
-     # librt #TODO: allow --with-rt=...
+-    # librt #TODO: allow --with-rt=...
 -    AC_CHECK_LIB([rt], [aio_write], [
 -    SAVE_LDFLAGS="-lrt $SAVE_LDFLAGS"
 -    LDFLAGS="-lrt $LDFLAGS"
 -    AC_DEFINE(HAVE_AIO_RT, [1], [Define to indicate AIO presence in librt])
 -    ],
--    )
-+    #AC_CHECK_LIB([rt], [aio_write], [
-+    #SAVE_LDFLAGS="-lrt $SAVE_LDFLAGS"
-+    #LDFLAGS="-lrt $LDFLAGS"
-+    #AC_DEFINE(HAVE_AIO_RT, [1], [Define to indicate AIO presence in librt])
-+    #],
-+    #)
++    # librt
++    AC_MSG_CHECKING(for rt)
++    AC_ARG_WITH([rt],
++      AS_HELP_STRING(--with-rt=PATH, base of Real-time Library installation),
++      [
++       case $with_rt in
++       no)
++            AC_MSG_RESULT([no])
++
++            rt=false
++         ;;
++       yes)
++            AC_CHECK_HEADERS([aio.h], [],
++                AC_MSG_ERROR([aio.h header not found or not usable])
++            )
++            AC_CHECK_LIB(rt, [aio_write], [LIBRT_LIBS="$LIBRT_LIBS -lrt"],
++                AC_MSG_ERROR([Could not find rt library!])
++            )
++
++            AC_SUBST(LIBRT_LIBS)
++            rt=true
++         ;;
++       *)
++        # determine if library is installed
++        if test -d "$with_rt/lib"; then
++            LDFLAGS="-L$with_rt/lib $LDFLAGS"
++            CXXFLAGS="-I$with_rt/include $CXXFLAGS"
++
++            AC_CHECK_HEADERS([aio.h], [
++                LIBRT_LDFLAGS="-L$with_rt/lib"
++                LIBRT_CXXFLAGS="-I$with_rt/include"],
++                AC_MSG_ERROR([aio.h header not found or not usable])
++            )
++        
++            AC_CHECK_LIB(rt, [aio_write], [LIBRT_LIBS="$LIBRT_LIBS -lrt"],
++                AC_MSG_ERROR([Could not find rt library!])
++            )
++        else
++            AC_MSG_ERROR([Could not find rt library in "$with_rt/lib"!])
++        fi
++
++        AC_SUBST(LIBRT_LDFLAGS)
++        AC_SUBST(LIBRT_CXXFLAGS)
++        AC_SUBST(LIBRT_LIBS)
++        rt=true
++
++        #restore
++        LDFLAGS=$SAVE_LDFLAGS
++        CXXFLAGS=$SAVE_CXXFLAGS
++        ;;
++       esac
++      ],
++      [
++        AC_MSG_RESULT([--with-rt not specified])
++
++        AC_CHECK_HEADERS([aio.h], [],
++            AC_MSG_ERROR([aio.h header not found or not usable])
++        )
++        AC_CHECK_LIB(rt, [aio_write], [LIBRT_LIBS="$LIBRT_LIBS -lrt"],
++            AC_MSG_NOTICE([Could not find librt])
++        )
++
++        AC_SUBST(LIBRT_LIBS)
++        rt=true
++      ]
+     )
  
      # OpenSSL
-     AC_MSG_CHECKING(for OpenSSL)
+@@ -1617,6 +1687,12 @@ if test "x$WIN32" = "xno" ; then
+ fi
+ 
+ # define on all platforms
++AM_CONDITIONAL(HAVE_RT, test x$rt = xtrue)
++if test "x$rt" = "xtrue" ; then
++    AC_DEFINE(HAVE_AIO_RT, [1], [Define to indicate AIO presence in librt])
++fi
++
++# define on all platforms
+ AM_CONDITIONAL(HAVE_OPENSSL, test x$openssl = xtrue)
+ if test "x$openssl" = "xtrue" ; then
+     AC_DEFINE(USE_OPENSSL, [1], [Define to use OpenSSL])
+@@ -2308,6 +2384,7 @@ AC_MSG_NOTICE([Configured to build Mega 
+   PCRE:             $PCRE_CXXFLAGS $PCRE_LDFLAGS $PCRE_LIBS
+   LIBUV:            $LIBUV_CXXFLAGS $LIBUV_LDFLAGS $LIBUV_LIBS
+   LIBRAW:           $LIBRAW_CXXFLAGS $LIBRAW_LDFLAGS $LIBRAW_LIBS
++  LIBRT:            $LIBRT_CXXFLAGS $LIBRT_LDFLAGS $LIBRT_LIBS
+   LIBMEDIAINFO:     $LIBMEDIAINFO_CXXFLAGS $LIBMEDIAINFO_LDFLAGS $LIBMEDIAINFO_LIBS
+   FFMPEG:           $FFMPEG_CXXFLAGS $FFMPEG_LDFLAGS $FFMPEG_LIBS
+ 
Index: pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp
diff -u pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp:1.1 pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp:1.2
--- pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp:1.1       Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_src_http.cpp   Tue Jun 18 18:23:15 2024
@@ -1,15 +1,20 @@
-$NetBSD: patch-sdk_src_http.cpp,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-sdk_src_http.cpp,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* Fix build on NetBSD, missing AI_V4MAPPED
+NetBSD and OpenBSD don't support AI_V4MAPPED.
+Upstream pull req: https://github.com/meganz/sdk/pull/2664
 
---- sdk/src/http.cpp.orig      2023-06-20 16:04:22.829147987 +0000
+--- sdk/src/http.cpp.orig      2024-05-17 14:19:43.000000000 +0000
 +++ sdk/src/http.cpp
-@@ -270,7 +270,7 @@ void HttpIO::getMEGADNSservers(string *d
+@@ -270,8 +270,12 @@ void HttpIO::getMEGADNSservers(string *d
          hints.ai_family = AF_UNSPEC;
  
  #ifndef __MINGW32__
--        hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG;
++#if defined(__NetBSD__) || defined(__OpenBSD__)
 +        hints.ai_flags = AI_ADDRCONFIG;
++#else
+         hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG;
  #endif
++#endif
  
          if (!getaddrinfo("ns.mega.co.nz", NULL, &hints, &aiList))
+         {
Index: pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp
diff -u pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp:1.1 pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp:1.2
--- pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp:1.1   Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_src_posix_fs.cpp       Tue Jun 18 18:23:15 2024
@@ -1,8 +1,8 @@
-$NetBSD: patch-sdk_src_posix_fs.cpp,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-sdk_src_posix_fs.cpp,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* Add NetBSD support
+Fix build on NetBSD, use statvfs
 
---- sdk/src/posix/fs.cpp.orig  2023-05-02 16:07:05.000000000 +0000
+--- sdk/src/posix/fs.cpp.orig  2024-05-17 14:19:43.000000000 +0000
 +++ sdk/src/posix/fs.cpp
 @@ -27,6 +27,9 @@
  #include <sys/utsname.h>
Index: pkgsrc/net/megacmd/patches/patch-src_include.am
diff -u pkgsrc/net/megacmd/patches/patch-src_include.am:1.1 pkgsrc/net/megacmd/patches/patch-src_include.am:1.2
--- pkgsrc/net/megacmd/patches/patch-src_include.am:1.1 Mon Mar 11 07:49:12 2024
+++ pkgsrc/net/megacmd/patches/patch-src_include.am     Tue Jun 18 18:23:15 2024
@@ -1,15 +1,15 @@
-$NetBSD: patch-src_include.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+$NetBSD: patch-src_include.am,v 1.2 2024/06/18 18:23:15 bsiegert Exp $
 
-* Add NetBSD support
+Fix bash-completion path
 
---- src/include.am.orig        2023-05-05 10:48:34.000000000 +0000
+--- src/include.am.orig        2024-05-20 12:29:43.000000000 +0000
 +++ src/include.am
-@@ -9,7 +9,7 @@ MEGACMD = mega-cmd mega-exec mega-cmd-se
- bin_PROGRAMS += $(MEGACMD)
+@@ -16,7 +16,7 @@ bin_PROGRAMS += $(MEGACMD) $(TESTS)
  $(MEGACMD): $(top_builddir)/sdk/src/libmega.la
- noinst_HEADERS += src/comunicationsmanager.h src/configurationmanager.h src/megacmd.h src/megacmdlogger.h src/megacmdsandbox.h src/megacmdutils.h src/megacmdcommonutils.h src/listeners.h 
src/megacmdexecuter.h src/megacmdtransfermanager.h src/megacmdversion.h src/megacmdplatform.h src/comunicationsmanagerportsockets.h
+ 
+ #scripst (to install and where)
 -megacmdcompletiondir = $(sysconfdir)/bash_completion.d/
 +megacmdcompletiondir = $(datadir)/bash-completion/completions/
  megacmdcompletion_DATA = src/client/megacmd_completion.sh
  megacmdscripts_bindir = $(bindir)
- 
+ megacmdscripts_bin_SCRIPTS = src/client/mega-attr src/client/mega-cd src/client/mega-confirm src/client/mega-cp src/client/mega-debug src/client/mega-du src/client/mega-df src/client/mega-proxy 
src/client/mega-export src/client/mega-find src/client/mega-get src/client/mega-help src/client/mega-https src/client/mega-webdav src/client/mega-permissions src/client/mega-deleteversions 
src/client/mega-transfers src/client/mega-import src/client/mega-invite src/client/mega-ipc src/client/mega-killsession src/client/mega-lcd src/client/mega-log src/client/mega-login 
src/client/mega-logout src/client/mega-lpwd src/client/mega-ls src/client/mega-backup src/client/mega-mkdir src/client/mega-mount src/client/mega-mv src/client/mega-passwd src/client/mega-preview 
src/client/mega-put src/client/mega-speedlimit src/client/mega-pwd src/client/mega-quit src/client/mega-reload src/client/mega-rm src/client/mega-session src/client/mega-share src/client/mega-showpcr 
src/client/mega-signup src/client/m
 ega-sync src/client/mega-exclude src/client/mega-thumbnail src/client/mega-userattr src/client/mega-users src/client/mega-version src/client/mega-whoami src/client/mega-cat src/client/mega-tree 
src/client/mega-mediainfo src/client/mega-graphics src/client/mega-ftp src/client/mega-cancel src/client/mega-confirmcancel src/client/mega-errorcode

Added files:

Index: pkgsrc/net/megacmd/files/README
diff -u /dev/null pkgsrc/net/megacmd/files/README:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/files/README     Tue Jun 18 18:23:15 2024
@@ -0,0 +1,8 @@
+$NetBSD: README,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+To use megacmd features you need machine-id.
+If /etc/machine-id or /var/lib/dbus/machine-id
+not exists, you should generate one. For that,
+run the following command as root:
+
+       dbus-uuidgen --ensure

Index: pkgsrc/net/megacmd/patches/patch-configure.ac
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-configure.ac:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-configure.ac       Tue Jun 18 18:23:15 2024
@@ -0,0 +1,38 @@
+$NetBSD: patch-configure.ac,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Add NetBSD and DragonFly support to configure script.
+Upstream pull req: https://github.com/meganz/MEGAcmd/pull/949
+
+--- configure.ac.orig  2024-05-20 12:29:43.000000000 +0000
++++ configure.ac
+@@ -209,6 +209,8 @@ WIN32=no
+ DARWIN=no
+ ANDROID=no
+ LINUX=no
++DRAGONFLY=no
++NETBSD=no
+ AC_MSG_CHECKING([if building for Win32 platform])
+ case $host in
+   *-*-cygwin*)
+@@ -231,6 +233,12 @@ case $host in
+   *-linux*)
+     LINUX=yes
+     ;;
++  *-dragonfly*)
++    DRAGONFLY=yes
++    ;;
++  *-netbsd*)
++    NETBSD=yes
++    ;;
+   *)
+     LIBS_EXTRA=""
+     ;;
+@@ -240,6 +248,8 @@ AM_CONDITIONAL([WIN32], [test "${WIN32}"
+ AM_CONDITIONAL([DARWIN], [test "${DARWIN}" = "yes"])
+ AM_CONDITIONAL([ANDROID], [test "${ANDROID}" = "yes"])
+ AM_CONDITIONAL([LINUX], [test "${LINUX}" = "yes"])
++AM_CONDITIONAL([DRAGONFLY], [test "${DRAGONFLY}" = "yes"])
++AM_CONDITIONAL([NETBSD], [test "${NETBSD}" = "yes"])
+ 
+ SAVE_LDFLAGS=$LDFLAGS
+ SAVE_CXXFLAGS=$CXXFLAGS
Index: pkgsrc/net/megacmd/patches/patch-sdk_include_mega_http.h
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-sdk_include_mega_http.h:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_include_mega_http.h    Tue Jun 18 18:23:15 2024
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_include_mega_http.h,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Add support to other BSDs.
+Upstream pull req: https://github.com/meganz/sdk/pull/2662
+
+--- sdk/include/mega/http.h.orig       2024-05-17 14:19:43.000000000 +0000
++++ sdk/include/mega/http.h
+@@ -42,7 +42,7 @@
+ #pragma warning(pop)
+ #endif
+ 
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
+ #include <netinet/in.h>
+ #endif
+ 
Index: pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megafs.h
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megafs.h:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megafs.h    Tue Jun 18 18:23:15 2024
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_include_mega_posix_megafs.h,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Add support to other BSDs.
+Upstream pull req: https://github.com/meganz/sdk/pull/2662
+
+--- sdk/include/mega/posix/megafs.h.orig       2024-05-17 14:19:43.000000000 +0000
++++ sdk/include/mega/posix/megafs.h
+@@ -32,7 +32,7 @@
+ #define O_DIRECT 0
+ #include <sys/param.h>
+ #include <sys/mount.h>
+-#elif defined(__FreeBSD__)
++#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
+ #include <sys/mount.h>
+ #else
+ #include <sys/vfs.h>
Index: pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megasys.h
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megasys.h:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_include_mega_posix_megasys.h   Tue Jun 18 18:23:15 2024
@@ -0,0 +1,17 @@
+$NetBSD: patch-sdk_include_mega_posix_megasys.h,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Add support to other BSDs.
+Upstream pull req: https://github.com/meganz/sdk/pull/2662
+
+--- sdk/include/mega/posix/megasys.h.orig      2024-05-17 14:19:43.000000000 +0000
++++ sdk/include/mega/posix/megasys.h
+@@ -99,7 +99,8 @@
+ #include <endian.h>
+ #endif
+ 
+-#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__minix)
++#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__minix) || \
++    defined(__OpenBSD__)
+ #include <sys/endian.h>
+ #endif
+ 
Index: pkgsrc/net/megacmd/patches/patch-sdk_src_include.am
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-sdk_src_include.am:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-sdk_src_include.am Tue Jun 18 18:23:15 2024
@@ -0,0 +1,24 @@
+$NetBSD: patch-sdk_src_include.am,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Handle LIBRT_* flags
+Upstream pull req: https://github.com/meganz/sdk/pull/2665
+
+--- sdk/src/include.am.orig    2024-05-17 14:19:43.000000000 +0000
++++ sdk/src/include.am
+@@ -5,14 +5,14 @@ lib_LTLIBRARIES = src/libmega.la
+ if WIN32
+ src_libmega_la_CXXFLAGS = -D_WIN32=1 -Iinclude/ -Iinclude/mega/win32 $(LIBS_EXTRA) $(ZLIB_CXXFLAGS) $(LIBUV_CXXFLAGS) $(LIBRAW_CXXFLAGS) $(LIBMEDIAINFO_CXXFLAGS) $(FFMPEG_CXXFLAGS) 
$(CRYPTO_CXXFLAGS) $(SODIUM_CXXFLAGS) $(DB_CXXFLAGS) $(CXXFLAGS) $(WINHTTP_CXXFLAGS) $(FI_CXXFLAGS) $(PDF_CXXFLAGS) $(ICU_CXXFLAGS) $(PCRE_CXXFLAGS)
+ else
+-src_libmega_la_CXXFLAGS = $(CARES_FLAGS) $(LIBCURL_FLAGS) $(ZLIB_CXXFLAGS) $(LIBUV_CXXFLAGS) $(LIBRAW_CXXFLAGS) $(LIBMEDIAINFO_CXXFLAGS) $(FFMPEG_CXXFLAGS) $(CRYPTO_CXXFLAGS) $(SODIUM_CXXFLAGS) 
$(DB_CXXFLAGS) $(FI_CXXFLAGS) $(PDF_CXXFLAGS) $(ICU_CXXFLAGS) $(LIBSSL_FLAGS) $(PCRE_CXXFLAGS)
++src_libmega_la_CXXFLAGS = $(CARES_FLAGS) $(LIBCURL_FLAGS) $(ZLIB_CXXFLAGS) $(LIBUV_CXXFLAGS) $(LIBRAW_CXXFLAGS) $(LIBRT_CXXFLAGS) $(LIBMEDIAINFO_CXXFLAGS) $(FFMPEG_CXXFLAGS) $(CRYPTO_CXXFLAGS) 
$(SODIUM_CXXFLAGS) $(DB_CXXFLAGS) $(FI_CXXFLAGS) $(PDF_CXXFLAGS) $(ICU_CXXFLAGS) $(LIBSSL_FLAGS) $(PCRE_CXXFLAGS)
+ endif
+ 
+ # Libs
+ if WIN32
+ src_libmega_la_LIBADD = $(LIBS_EXTRA)  $(FFMPEG_LDFLAGS) $(FFMPEG_LIBS) $(LIBUV_LDFLAGS) $(LIBUV_LIBS) $(LIBRAW_LDFLAGS) $(LIBRAW_LIBS) $(LIBMEDIAINFO_LDFLAGS) $(LIBMEDIAINFO_LIBS) $(ZLIB_LDFLAGS) 
$(ZLIB_LIBS) $(CRYPTO_LDFLAGS) $(CRYPTO_LIBS) $(SODIUM_LDFLAGS) $(SODIUM_LIBS) $(DB_LDFLAGS) $(DB_LIBS) $(WINHTTP_LDFLAGS) $(WINHTTP_LIBS) $(FI_LDFLAGS) $(FI_LIBS) $(PDF_LDFLAGS) $(PDF_LIBS) 
$(ICU_LDFLAGS) $(ICU_LIBS) $(PCRE_LDFLAGS) $(PCRE_LIBS)
+ else
+-src_libmega_la_LIBADD = $(CARES_LDFLAGS) $(CARES_LIBS) $(LIBCURL_LIBS) $(FFMPEG_LDFLAGS) $(FFMPEG_LIBS) $(LIBUV_LDFLAGS) $(LIBUV_LIBS) $(LIBRAW_LDFLAGS) $(LIBRAW_LIBS) $(LIBMEDIAINFO_LDFLAGS) 
$(LIBMEDIAINFO_LIBS) $(ZLIB_LDFLAGS) $(ZLIB_LIBS) $(CRYPTO_LDFLAGS) $(CRYPTO_LIBS) $(SODIUM_LDFLAGS) $(SODIUM_LIBS) $(DB_LDFLAGS) $(DB_LIBS) $(FI_LDFLAGS) $(FI_LIBS) $(PDF_LDFLAGS) $(PDF_LIBS) 
$(ICU_LDFLAGS) $(ICU_LIBS) $(LIBSSL_LDFLAGS) $(LIBSSL_LIBS) $(PCRE_LDFLAGS) $(PCRE_LIBS)
++src_libmega_la_LIBADD = $(CARES_LDFLAGS) $(CARES_LIBS) $(LIBCURL_LIBS) $(FFMPEG_LDFLAGS) $(FFMPEG_LIBS) $(LIBUV_LDFLAGS) $(LIBUV_LIBS) $(LIBRAW_LDFLAGS) $(LIBRAW_LIBS) $(LIBRT_LDFLAGS) 
$(LIBRT_LIBS) $(LIBMEDIAINFO_LDFLAGS) $(LIBMEDIAINFO_LIBS) $(ZLIB_LDFLAGS) $(ZLIB_LIBS) $(CRYPTO_LDFLAGS) $(CRYPTO_LIBS) $(SODIUM_LDFLAGS) $(SODIUM_LIBS) $(DB_LDFLAGS) $(DB_LIBS) $(FI_LDFLAGS) 
$(FI_LIBS) $(PDF_LDFLAGS) $(PDF_LIBS) $(ICU_LDFLAGS) $(ICU_LIBS) $(LIBSSL_LDFLAGS) $(LIBSSL_LIBS) $(PCRE_LDFLAGS) $(PCRE_LIBS)
+ endif
+ 
+ # add library version
Index: pkgsrc/net/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp
diff -u /dev/null pkgsrc/net/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp:1.1
--- /dev/null   Tue Jun 18 18:23:15 2024
+++ pkgsrc/net/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp    Tue Jun 18 18:23:15 2024
@@ -0,0 +1,16 @@
+$NetBSD: patch-src_megacmdshell_megacmdshellcommunications.cpp,v 1.1 2024/06/18 18:23:15 bsiegert Exp $
+
+Fix include on BSDs
+Upstream pull req: https://github.com/meganz/MEGAcmd/pull/949
+
+--- src/megacmdshell/megacmdshellcommunications.cpp.orig       2024-05-20 12:29:43.000000000 +0000
++++ src/megacmdshell/megacmdshellcommunications.cpp
+@@ -55,7 +55,7 @@
+ #include <limits.h>
+ #endif
+ 
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
+ #include <netinet/in.h>
+ #endif
+ 



Home | Main Index | Thread Index | Old Index