pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
net/megacmd: import from pkgsrc
Module Name: pkgsrc-wip
Committed By: kikadf <kikadf.01%gmail.com@localhost>
Pushed By: kikadf
Date: Fri May 24 17:04:32 2024 +0200
Changeset: ee02f65a57b420742b423734f4a390de984627c5
Modified Files:
Makefile
Added Files:
megacmd/DESCR
megacmd/MESSAGE
megacmd/Makefile
megacmd/PLIST
megacmd/distinfo
megacmd/patches/patch-Makefile.am
megacmd/patches/patch-sdk_Makefile.am
megacmd/patches/patch-sdk_configure.ac
megacmd/patches/patch-sdk_include_mega_http_h
megacmd/patches/patch-sdk_include_mega_posix_megafs_h
megacmd/patches/patch-sdk_src_http.cpp
megacmd/patches/patch-sdk_src_posix_fs.cpp
megacmd/patches/patch-src_include.am
megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications_cpp
Log Message:
net/megacmd: import from pkgsrc
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=ee02f65a57b420742b423734f4a390de984627c5
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
Makefile | 1 +
megacmd/DESCR | 5 +
megacmd/MESSAGE | 9 ++
megacmd/Makefile | 57 +++++++++
megacmd/PLIST | 130 +++++++++++++++++++++
megacmd/distinfo | 17 +++
megacmd/patches/patch-Makefile.am | 16 +++
megacmd/patches/patch-sdk_Makefile.am | 16 +++
megacmd/patches/patch-sdk_configure.ac | 26 +++++
megacmd/patches/patch-sdk_include_mega_http_h | 16 +++
.../patches/patch-sdk_include_mega_posix_megafs_h | 16 +++
megacmd/patches/patch-sdk_src_http.cpp | 15 +++
megacmd/patches/patch-sdk_src_posix_fs.cpp | 16 +++
megacmd/patches/patch-src_include.am | 15 +++
...src_megacmdshell_megacmdshellcommunications_cpp | 16 +++
15 files changed, 371 insertions(+)
diffs:
diff --git a/Makefile b/Makefile
index 7df11616a4..b5bb49fac1 100644
--- a/Makefile
+++ b/Makefile
@@ -2219,6 +2219,7 @@ SUBDIR+= mdadm
SUBDIR+= mdbtools
SUBDIR+= mdpress
SUBDIR+= mediawiki-mode
+SUBDIR+= megacmd
SUBDIR+= meka-git
SUBDIR+= melonds
SUBDIR+= memdump
diff --git a/megacmd/DESCR b/megacmd/DESCR
new file mode 100644
index 0000000000..31497df882
--- /dev/null
+++ b/megacmd/DESCR
@@ -0,0 +1,5 @@
+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.
diff --git a/megacmd/MESSAGE b/megacmd/MESSAGE
new file mode 100644
index 0000000000..86f06ec142
--- /dev/null
+++ b/megacmd/MESSAGE
@@ -0,0 +1,9 @@
+===========================================================================
+$NetBSD: MESSAGE,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+To use megacmd features you need to generate a machine-id.
+For that, run the following command as root:
+
+ dbus-uuidgen --ensure
+
+===========================================================================
diff --git a/megacmd/Makefile b/megacmd/Makefile
new file mode 100644
index 0000000000..f859ece03b
--- /dev/null
+++ b/megacmd/Makefile
@@ -0,0 +1,57 @@
+# $NetBSD: Makefile,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+DISTNAME= megacmd-1.6.3
+CATEGORIES= net
+MASTER_SITES= ${MASTER_SITE_GITHUB:=meganz/}
+GITHUB_PROJECT= MEGAcmd
+GITHUB_TAG= ${PKGVERSION_NOREV}_Linux
+SDK_VERSION= v4.17.1d
+
+GITHUB_SUBMODULES= meganz sdk ${SDK_VERSION} sdk
+
+MAINTAINER= kikadf.01%gmail.com@localhost
+HOMEPAGE= https://mega.io/
+COMMENT= CLI and scriptable application to access MEGA
+# MEGAcmd: GPLv3, SDK: BSD 2-clause
+LICENSE= gnu-gpl-v3 AND 2-clause-bsd
+
+USE_LANGUAGES+= c c++
+USE_CXX_FEATURES+= filesystem
+USE_LIBTOOL= yes
+USE_TOOLS+= autoreconf autoconf automake
+GNU_CONFIGURE= yes
+REPLACE_SH= src/client/mega-*
+CXXFLAGS+= -DCRYPTOPP_DISABLE_ASM -std=c++17
+BUILDLINK_TRANSFORM+= rm:-std=c++11
+
+CONFIGURE_ARGS+= --disable-examples
+CONFIGURE_ARGS+= --disable-java
+CONFIGURE_ARGS+= --disable-php
+CONFIGURE_ARGS+= --disable-python
+CONFIGURE_ARGS+= --disable-chat
+CONFIGURE_ARGS+= --without-freeimage
+CONFIGURE_ARGS+= --without-termcap
+CONFIGURE_ARGS+= --without-ffmpeg
+CONFIGURE_ARGS+= --without-libraw
+CONFIGURE_ARGS+= --without-libzen
+CONFIGURE_ARGS+= --without-libmediainfo
+CONFIGURE_ARGS+= --enable-gcc-hardening
+
+CHECK_PORTABILITY_SKIP+= sdk/bindings/ios/3rdparty/*.sh
+
+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
+
+.include "../../databases/sqlite3/buildlink3.mk"
+.include "../../devel/pcre/buildlink3.mk"
+.include "../../devel/libuv/buildlink3.mk"
+.include "../../devel/readline/buildlink3.mk"
+.include "../../net/libcares/buildlink3.mk"
+.include "../../security/crypto++/buildlink3.mk"
+.include "../../security/libsodium/buildlink3.mk"
+.include "../../www/curl/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/megacmd/PLIST b/megacmd/PLIST
new file mode 100644
index 0000000000..77e4709cc1
--- /dev/null
+++ b/megacmd/PLIST
@@ -0,0 +1,130 @@
+@comment $NetBSD: PLIST,v 1.1 2024/03/11 07:49:12 wiz Exp $
+bin/mega-attr
+bin/mega-backup
+bin/mega-cancel
+bin/mega-cat
+bin/mega-cd
+bin/mega-cmd
+bin/mega-cmd-server
+bin/mega-confirm
+bin/mega-confirmcancel
+bin/mega-cp
+bin/mega-debug
+bin/mega-deleteversions
+bin/mega-df
+bin/mega-du
+bin/mega-errorcode
+bin/mega-exclude
+bin/mega-exec
+bin/mega-export
+bin/mega-find
+bin/mega-ftp
+bin/mega-get
+bin/mega-graphics
+bin/mega-help
+bin/mega-https
+bin/mega-import
+bin/mega-invite
+bin/mega-ipc
+bin/mega-killsession
+bin/mega-lcd
+bin/mega-log
+bin/mega-login
+bin/mega-logout
+bin/mega-lpwd
+bin/mega-ls
+bin/mega-mediainfo
+bin/mega-mkdir
+bin/mega-mount
+bin/mega-mv
+bin/mega-passwd
+bin/mega-permissions
+bin/mega-preview
+bin/mega-proxy
+bin/mega-put
+bin/mega-pwd
+bin/mega-quit
+bin/mega-reload
+bin/mega-rm
+bin/mega-session
+bin/mega-share
+bin/mega-showpcr
+bin/mega-signup
+bin/mega-speedlimit
+bin/mega-sync
+bin/mega-thumbnail
+bin/mega-transfers
+bin/mega-tree
+bin/mega-userattr
+bin/mega-users
+bin/mega-version
+bin/mega-webdav
+bin/mega-whoami
+include/mega.h
+include/mega/account.h
+include/mega/attrmap.h
+include/mega/backofftimer.h
+include/mega/base64.h
+include/mega/command.h
+include/mega/config.h
+include/mega/console.h
+include/mega/crypto/cryptopp.h
+include/mega/crypto/sodium.h
+include/mega/db.h
+include/mega/db/sqlite.h
+include/mega/drivenotify.h
+include/mega/file.h
+include/mega/fileattributefetch.h
+include/mega/filefingerprint.h
+include/mega/filesystem.h
+include/mega/gfx.h
+include/mega/gfx/GfxProcCG.h
+include/mega/gfx/external.h
+include/mega/gfx/freeimage.h
+include/mega/gfx/gfx_pdfium.h
+include/mega/http.h
+include/mega/json.h
+include/mega/logging.h
+include/mega/mediafileattribute.h
+include/mega/mega_ccronexpr.h
+include/mega/mega_dict-src.h
+include/mega/mega_evt_queue.h
+include/mega/mega_evt_tls.h
+include/mega/mega_http_parser.h
+include/mega/mega_utf8proc.h
+include/mega/mega_zxcvbn.h
+include/mega/megaapp.h
+include/mega/megaclient.h
+include/mega/node.h
+include/mega/pendingcontactrequest.h
+include/mega/posix/megaconsole.h
+include/mega/posix/megaconsolewaiter.h
+include/mega/posix/megafs.h
+include/mega/posix/meganet.h
+include/mega/posix/megasys.h
+include/mega/posix/megawaiter.h
+include/mega/proxy.h
+include/mega/pubkeyaction.h
+include/mega/raid.h
+include/mega/request.h
+include/mega/serialize64.h
+include/mega/share.h
+include/mega/sharenodekeys.h
+include/mega/sync.h
+include/mega/thread.h
+include/mega/thread/cppthread.h
+include/mega/thread/posixthread.h
+include/mega/transfer.h
+include/mega/transferslot.h
+include/mega/treeproc.h
+include/mega/types.h
+include/mega/user.h
+include/mega/useralerts.h
+include/mega/utils.h
+include/mega/version.h
+include/mega/waiter.h
+include/megaapi.h
+include/megaapi_impl.h
+lib/libmega.la
+lib/pkgconfig/libmega.pc
+share/bash-completion/completions/megacmd
diff --git a/megacmd/distinfo b/megacmd/distinfo
new file mode 100644
index 0000000000..98acb16405
--- /dev/null
+++ b/megacmd/distinfo
@@ -0,0 +1,17 @@
+$NetBSD: distinfo,v 1.1 2024/03/11 07:49:12 wiz 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
diff --git a/megacmd/patches/patch-Makefile.am b/megacmd/patches/patch-Makefile.am
new file mode 100644
index 0000000000..6e9b37d42f
--- /dev/null
+++ b/megacmd/patches/patch-Makefile.am
@@ -0,0 +1,16 @@
+$NetBSD: patch-Makefile.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+--- Makefile.am.orig 2023-05-05 10:48:34.000000000 +0000
++++ Makefile.am
+@@ -35,9 +35,7 @@ if ANDROID
+ AM_LIBTOOLFLAGS="--tag=CXX"
+ endif
+
+-if LINUX
+ AM_LIBTOOLFLAGS="--tag=CXX"
+-endif
+
+ VERSION_INFO=$(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
+
diff --git a/megacmd/patches/patch-sdk_Makefile.am b/megacmd/patches/patch-sdk_Makefile.am
new file mode 100644
index 0000000000..376b054472
--- /dev/null
+++ b/megacmd/patches/patch-sdk_Makefile.am
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_Makefile.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+--- sdk/Makefile.am.orig 2023-05-02 16:07:05.000000000 +0000
++++ sdk/Makefile.am
+@@ -42,9 +42,7 @@ if ANDROID
+ AM_LIBTOOLFLAGS="--tag=CXX"
+ endif
+
+-if LINUX
+ AM_LIBTOOLFLAGS="--tag=CXX"
+-endif
+
+ VERSION_INFO=$(LT_CURRENT):$(LT_REVISION):$(LT_AGE)
+
diff --git a/megacmd/patches/patch-sdk_configure.ac b/megacmd/patches/patch-sdk_configure.ac
new file mode 100644
index 0000000000..3b5097a9db
--- /dev/null
+++ b/megacmd/patches/patch-sdk_configure.ac
@@ -0,0 +1,26 @@
+$NetBSD: patch-sdk_configure.ac,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* mega-cmd-server not syncing with aio_write function,
+* workaround disable librt. #TODO
+
+--- sdk/configure.ac.orig 2024-02-27 08:17:47.102044837 +0000
++++ sdk/configure.ac
+@@ -1382,12 +1382,12 @@ if test "x$WIN32" = "xno" ; then
+ fi
+
+ # 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])
++ #],
++ #)
+
+ # OpenSSL
+ AC_MSG_CHECKING(for OpenSSL)
diff --git a/megacmd/patches/patch-sdk_include_mega_http_h b/megacmd/patches/patch-sdk_include_mega_http_h
new file mode 100644
index 0000000000..316818e3a7
--- /dev/null
+++ b/megacmd/patches/patch-sdk_include_mega_http_h
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_include_mega_http_h,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+Index: sdk/include/mega/http.h
+--- sdk/include/mega/http.h.orig 2023-05-02 16:07:05.000000000 +0000
++++ sdk/include/mega/http.h
+@@ -42,7 +42,7 @@
+ #pragma warning(pop)
+ #endif
+
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || defined(__NetBSD__)
+ #include <netinet/in.h>
+ #endif
+
diff --git a/megacmd/patches/patch-sdk_include_mega_posix_megafs_h b/megacmd/patches/patch-sdk_include_mega_posix_megafs_h
new file mode 100644
index 0000000000..9c333a4203
--- /dev/null
+++ b/megacmd/patches/patch-sdk_include_mega_posix_megafs_h
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_include_mega_posix_megafs_h,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+Index: sdk/include/mega/posix/megafs.h
+--- sdk/include/mega/posix/megafs.h.orig
++++ sdk/include/mega/posix/megafs.h
+@@ -28,7 +28,7 @@
+ #define O_DIRECT 0
+ #include <sys/param.h>
+ #include <sys/mount.h>
+-#elif defined(__FreeBSD__)
++#elif defined(__FreeBSD__) || defined(__NetBSD__)
+ #include <sys/mount.h>
+ #else
+ #include <sys/vfs.h>
diff --git a/megacmd/patches/patch-sdk_src_http.cpp b/megacmd/patches/patch-sdk_src_http.cpp
new file mode 100644
index 0000000000..a7bb7e9274
--- /dev/null
+++ b/megacmd/patches/patch-sdk_src_http.cpp
@@ -0,0 +1,15 @@
+$NetBSD: patch-sdk_src_http.cpp,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Fix build on NetBSD, missing AI_V4MAPPED
+
+--- sdk/src/http.cpp.orig 2023-06-20 16:04:22.829147987 +0000
++++ sdk/src/http.cpp
+@@ -270,7 +270,7 @@ void HttpIO::getMEGADNSservers(string *d
+ hints.ai_family = AF_UNSPEC;
+
+ #ifndef __MINGW32__
+- hints.ai_flags = AI_V4MAPPED | AI_ADDRCONFIG;
++ hints.ai_flags = AI_ADDRCONFIG;
+ #endif
+
+ if (!getaddrinfo("ns.mega.co.nz", NULL, &hints, &aiList))
diff --git a/megacmd/patches/patch-sdk_src_posix_fs.cpp b/megacmd/patches/patch-sdk_src_posix_fs.cpp
new file mode 100644
index 0000000000..0493f026ff
--- /dev/null
+++ b/megacmd/patches/patch-sdk_src_posix_fs.cpp
@@ -0,0 +1,16 @@
+$NetBSD: patch-sdk_src_posix_fs.cpp,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+--- sdk/src/posix/fs.cpp.orig 2023-05-02 16:07:05.000000000 +0000
++++ sdk/src/posix/fs.cpp
+@@ -27,6 +27,9 @@
+ #include <sys/utsname.h>
+ #include <sys/ioctl.h>
+ #include <sys/statvfs.h>
++#if defined(__NetBSD__)
++#define statfs statvfs
++#endif
+ #include <sys/resource.h>
+ #ifdef TARGET_OS_MAC
+ #include "mega/osx/osxutils.h"
diff --git a/megacmd/patches/patch-src_include.am b/megacmd/patches/patch-src_include.am
new file mode 100644
index 0000000000..0c945160b5
--- /dev/null
+++ b/megacmd/patches/patch-src_include.am
@@ -0,0 +1,15 @@
+$NetBSD: patch-src_include.am,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+--- src/include.am.orig 2023-05-05 10:48:34.000000000 +0000
++++ src/include.am
+@@ -9,7 +9,7 @@ MEGACMD = mega-cmd mega-exec mega-cmd-se
+ bin_PROGRAMS += $(MEGACMD)
+ $(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
+-megacmdcompletiondir = $(sysconfdir)/bash_completion.d/
++megacmdcompletiondir = $(datadir)/bash-completion/completions/
+ megacmdcompletion_DATA = src/client/megacmd_completion.sh
+ megacmdscripts_bindir = $(bindir)
+
diff --git a/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications_cpp b/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications_cpp
new file mode 100644
index 0000000000..0f285c8045
--- /dev/null
+++ b/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications_cpp
@@ -0,0 +1,16 @@
+$NetBSD: patch-src_megacmdshell_megacmdshellcommunications_cpp,v 1.1 2024/03/11 07:49:12 wiz Exp $
+
+* Add NetBSD support
+
+Index: src/megacmdshell/megacmdshellcommunications.cpp
+--- src/megacmdshell/megacmdshellcommunications.cpp.orig
++++ src/megacmdshell/megacmdshellcommunications.cpp
+@@ -54,7 +54,7 @@
+ #include <limits.h>
+ #endif
+
+-#ifdef __FreeBSD__
++#if defined(__FreeBSD__) || defined(__NetBSD__)
+ #include <netinet/in.h>
+ #endif
+
Home |
Main Index |
Thread Index |
Old Index