pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
megacmd: remove, imported changes to pkgsrc
Module Name: pkgsrc-wip
Committed By: kikadf <kikadf.01%gmail.com@localhost>
Pushed By: kikadf
Date: Thu Jan 8 18:53:48 2026 +0100
Changeset: c63c624531af1889a9655e8951a7cdbb5df9857e
Modified Files:
Makefile
Removed Files:
megacmd/DESCR
megacmd/Makefile
megacmd/PLIST
megacmd/distinfo
megacmd/files/README
megacmd/patches/patch-CMakeLists.txt
megacmd/patches/patch-build_cmake_modules_megacmd__libraries.cmake
megacmd/patches/patch-sdk_cmake_config.h.in
megacmd/patches/patch-sdk_cmake_modules_sdklib__libraries.cmake
megacmd/patches/patch-sdk_cmake_modules_sdklib__target.cmake
megacmd/patches/patch-sdk_include_mega_filesystem.h
megacmd/patches/patch-sdk_include_mega_posix_megafs.h
megacmd/patches/patch-sdk_include_mega_sync.h
megacmd/patches/patch-sdk_include_megaapi__impl.h
megacmd/patches/patch-sdk_src_filesystem.cpp
megacmd/patches/patch-sdk_src_node.cpp
megacmd/patches/patch-sdk_src_posix_fs.cpp
megacmd/patches/patch-sdk_src_syncfilter.cpp
megacmd/patches/patch-sdk_src_utils.cpp
megacmd/patches/patch-src_megacmdcommonutils.cpp
megacmd/patches/patch-src_megacmdcommonutils.h
megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp
megacmd/patches/patch-src_megacmdutils.cpp
megacmd/patches/patch-src_updater_UpdateTask.cpp
Log Message:
megacmd: remove, imported changes to pkgsrc
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=c63c624531af1889a9655e8951a7cdbb5df9857e
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
Makefile | 1 -
megacmd/DESCR | 8 -
megacmd/Makefile | 59 ------
megacmd/PLIST | 73 --------
megacmd/distinfo | 27 ---
megacmd/files/README | 12 --
megacmd/patches/patch-CMakeLists.txt | 73 --------
...ch-build_cmake_modules_megacmd__libraries.cmake | 15 --
megacmd/patches/patch-sdk_cmake_config.h.in | 29 ---
...patch-sdk_cmake_modules_sdklib__libraries.cmake | 15 --
.../patch-sdk_cmake_modules_sdklib__target.cmake | 15 --
.../patches/patch-sdk_include_mega_filesystem.h | 31 ----
.../patches/patch-sdk_include_mega_posix_megafs.h | 36 ----
megacmd/patches/patch-sdk_include_mega_sync.h | 22 ---
megacmd/patches/patch-sdk_include_megaapi__impl.h | 15 --
megacmd/patches/patch-sdk_src_filesystem.cpp | 42 -----
megacmd/patches/patch-sdk_src_node.cpp | 15 --
megacmd/patches/patch-sdk_src_posix_fs.cpp | 198 ---------------------
megacmd/patches/patch-sdk_src_syncfilter.cpp | 15 --
megacmd/patches/patch-sdk_src_utils.cpp | 15 --
megacmd/patches/patch-src_megacmdcommonutils.cpp | 26 ---
megacmd/patches/patch-src_megacmdcommonutils.h | 16 --
...src_megacmdshell_megacmdshellcommunications.cpp | 15 --
megacmd/patches/patch-src_megacmdutils.cpp | 15 --
megacmd/patches/patch-src_updater_UpdateTask.cpp | 26 ---
25 files changed, 814 deletions(-)
diffs:
diff --git a/Makefile b/Makefile
index 89f270e79a..8407bf5293 100644
--- a/Makefile
+++ b/Makefile
@@ -2374,7 +2374,6 @@ SUBDIR+= mdbtools
SUBDIR+= mdpress
SUBDIR+= med
SUBDIR+= mediawiki-mode
-SUBDIR+= megacmd
SUBDIR+= meka-git
SUBDIR+= melonds
SUBDIR+= memdump
diff --git a/megacmd/DESCR b/megacmd/DESCR
deleted file mode 100644
index e9403124a5..0000000000
--- a/megacmd/DESCR
+++ /dev/null
@@ -1,8 +0,0 @@
-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.
diff --git a/megacmd/Makefile b/megacmd/Makefile
deleted file mode 100644
index 7b9fca0c73..0000000000
--- a/megacmd/Makefile
+++ /dev/null
@@ -1,59 +0,0 @@
-# $NetBSD: Makefile,v 1.14 2025/10/05 19:26:11 js Exp $
-
-DISTNAME= megacmd-2.1.1
-PKGREVISION= 1
-CATEGORIES= net
-MASTER_SITES= ${MASTER_SITE_GITHUB:=meganz/}
-GITHUB_PROJECT= MEGAcmd
-GITHUB_TAG= ${PKGVERSION_NOREV}_Linux
-SDK_VERSION= v9.1.1
-
-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
-
-TOOL_DEPENDS+= git-base-[0-9]*:../../devel/git-base
-
-USE_LANGUAGES+= c c++
-USE_CXX_FEATURES+= filesystem
-FORCE_CXX_STD= c++17
-USE_LIBTOOL= yes
-USE_TOOLS+= pkg-config
-REPLACE_SH= src/client/mega-*
-CXXFLAGS+= -DCRYPTOPP_DISABLE_ASM
-
-CMAKE_CONFIGURE_ARGS+= -DCMAKE_BUILD_TYPE=Release
-CMAKE_CONFIGURE_ARGS+= -DFULL_REQS=OFF
-CMAKE_CONFIGURE_ARGS+= -DUSE_MEDIAINFO=OFF
-CMAKE_CONFIGURE_ARGS+= -DUSE_FREEIMAGE=OFF
-CMAKE_CONFIGURE_ARGS+= -DUSE_FFMPEG=OFF
-CMAKE_CONFIGURE_ARGS+= -DUSE_PDFIUM=OFF
-CMAKE_CONFIGURE_ARGS+= -DWITH_FUSE=OFF
-CMAKE_CONFIGURE_ARGS+= -DVCPKG_ROOT=""
-
-CHECK_PORTABILITY_SKIP+= sdk/bindings/ios/3rdparty/*.sh
-
-INSTALLATION_DIRS+= share/doc/megacmd
-
-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/cmake/build.mk"
-.include "../../devel/pcre/buildlink3.mk"
-.include "../../devel/libuv/buildlink3.mk"
-.include "../../devel/readline/buildlink3.mk"
-.include "../../net/libcares/buildlink3.mk"
-BUILDLINK_API_DEPENDS.cryptopp+= cryptopp>=8.7.0nb1
-.include "../../security/crypto++/buildlink3.mk"
-.include "../../security/libsodium/buildlink3.mk"
-.include "../../textproc/icu/buildlink3.mk"
-.include "../../www/curl/buildlink3.mk"
-.include "../../mk/atomic64.mk"
-.include "../../mk/bsd.pkg.mk"
diff --git a/megacmd/PLIST b/megacmd/PLIST
deleted file mode 100644
index 38afe55d16..0000000000
--- a/megacmd/PLIST
+++ /dev/null
@@ -1,73 +0,0 @@
-@comment $NetBSD: PLIST,v 1.4 2025/05/16 19:43:58 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-fuse-add
-bin/mega-fuse-config
-bin/mega-fuse-disable
-bin/mega-fuse-enable
-bin/mega-fuse-remove
-bin/mega-fuse-show
-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-sync-config
-bin/mega-sync-ignore
-bin/mega-sync-issues
-bin/mega-thumbnail
-bin/mega-transfers
-bin/mega-tree
-bin/mega-userattr
-bin/mega-users
-bin/mega-version
-bin/mega-webdav
-bin/mega-whoami
-share/bash-completion/completions/megacmd
-share/doc/megacmd/README
diff --git a/megacmd/distinfo b/megacmd/distinfo
deleted file mode 100644
index d696946167..0000000000
--- a/megacmd/distinfo
+++ /dev/null
@@ -1,27 +0,0 @@
-$NetBSD: distinfo,v 1.4 2025/05/16 19:43:58 wiz Exp $
-
-BLAKE2s (megacmd-2.1.1.tar.gz) = 493c50974e425b54d952dea2f066b10d8d4dec13721b52808c7cba36074eac5d
-SHA512 (megacmd-2.1.1.tar.gz) = 5b510cca8a1cc8480aa759856ca6f4af5a81967f34b05a03af66334a0004ebe295f7825b3d560d86371f71a57ab60952b3dc8b020480a47b35fee2ec781962bc
-Size (megacmd-2.1.1.tar.gz) = 2087992 bytes
-BLAKE2s (meganz-sdk-v9.1.1.tar.gz) = 3923b242bae105806d10959978ff58a0c0db9e494a1ce04bc59a5bb6cf5946cf
-SHA512 (meganz-sdk-v9.1.1.tar.gz) = bb39b0c5d35caeeed70f373fc9b94dd19b995931d4ba843f1d45a28525a4d4ab681c7d5f992f4e0eb4506a44303fcc771c4e31b216edc0b97b5692bd466b0021
-Size (meganz-sdk-v9.1.1.tar.gz) = 4151889 bytes
-SHA1 (patch-CMakeLists.txt) = 66d843860251fc55eba4e08858b0418dbc9e7fb1
-SHA1 (patch-build_cmake_modules_megacmd__libraries.cmake) = afabd22177c0437fbe1d13fdf6601832bc60cd96
-SHA1 (patch-sdk_cmake_config.h.in) = 4cc3eab8be8c11571f4aab834690749335c764ec
-SHA1 (patch-sdk_cmake_modules_sdklib__libraries.cmake) = 65125e82d0921571a9ba44cfbbb816776a8fc987
-SHA1 (patch-sdk_cmake_modules_sdklib__target.cmake) = 33f5b16dc561e37f076c60fa537a4c5b8d8c992e
-SHA1 (patch-sdk_include_mega_filesystem.h) = 827dd8098b72ddc397790c60b1a21163a5df45a5
-SHA1 (patch-sdk_include_mega_posix_megafs.h) = a87e49a8a9d387f5325bf41df3fbd27ecd453b02
-SHA1 (patch-sdk_include_mega_sync.h) = 7b73c2619a5fbf33a4df012164876cc4dccfdb84
-SHA1 (patch-sdk_include_megaapi__impl.h) = cd5cd30d989d11d58d0030ebb7a34b3b0963d6fb
-SHA1 (patch-sdk_src_filesystem.cpp) = 3890ea10a66cd2a99925af57b0a3558c617cd6e3
-SHA1 (patch-sdk_src_node.cpp) = c9fe20a7825edd0345dd28b4947097b3d141493b
-SHA1 (patch-sdk_src_posix_fs.cpp) = 7b3923a465dfd98d86dc2ceabf914450b62dc066
-SHA1 (patch-sdk_src_syncfilter.cpp) = 15d5209c9df3925ad45214c6a327938297f9d69b
-SHA1 (patch-sdk_src_utils.cpp) = a96bb75ab6de83bb5dc838726f3c183d06aafbb2
-SHA1 (patch-src_megacmdcommonutils.cpp) = 92bb24ee05c541f6040577e3ddad0fa7414f0868
-SHA1 (patch-src_megacmdcommonutils.h) = 194d991a02e8e48c9c31c60384549c276e4ee735
-SHA1 (patch-src_megacmdshell_megacmdshellcommunications.cpp) = ff794d128ffa6e0626296a504b22f391e0fc923b
-SHA1 (patch-src_megacmdutils.cpp) = 5130d6d5c7a86a341764674a4203ce64a8d99fd0
-SHA1 (patch-src_updater_UpdateTask.cpp) = 3b284b57109c94279c91ca96c78f89ff16bad05d
diff --git a/megacmd/files/README b/megacmd/files/README
deleted file mode 100644
index c98d131988..0000000000
--- a/megacmd/files/README
+++ /dev/null
@@ -1,12 +0,0 @@
-$NetBSD: README,v 1.2 2025/01/23 20:10:07 wiz 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:
-
-- if dbus installed:
- dbus-uuidgen --ensure
-
-- without dbus:
- sh -c 'date|md5 > /etc/machine-id'
diff --git a/megacmd/patches/patch-CMakeLists.txt b/megacmd/patches/patch-CMakeLists.txt
deleted file mode 100644
index 440e4d73e0..0000000000
--- a/megacmd/patches/patch-CMakeLists.txt
+++ /dev/null
@@ -1,73 +0,0 @@
-$NetBSD: patch-CMakeLists.txt,v 1.2 2025/05/16 19:43:58 wiz Exp $
-
-* Use system dependencies instead of vcpkg
-* Fix install directories
-* Install inotify conf file only on Linux
-
---- CMakeLists.txt.orig 2025-01-30 14:04:12.000000000 +0100
-+++ CMakeLists.txt
-@@ -39,7 +39,7 @@ execute_process(
- )
- endif()
-
--if((NOT WIN32 OR BASH_VERSION_RESULT EQUAL 0) AND NOT EXISTS ${VCPKG_ROOT})
-+if(VCPKG_ROOT AND (NOT WIN32 OR BASH_VERSION_RESULT EQUAL 0) AND NOT EXISTS ${VCPKG_ROOT})
- message(STATUS "vcpkg will be cloned into ${VCPKG_ROOT}")
- execute_process(
- #TODO: have the same for windows ... or at least check if bash is available
-@@ -134,8 +134,8 @@ if(UNIX AND NOT APPLE)
- # If CMAKE_INSTALL_PREFIX is not set, it will set rpath to /opt/....
- # Note: using cmake --install --prefix /some/prefix will not set rpath relative to that prefix
- # The above can be used for building packages: in which install dir is a path construction folder that will not be there in packages
-- set(CMAKE_INSTALL_LIBDIR "opt/megacmd/lib")
-- set(CMAKE_INSTALL_BINDIR "usr/bin") #override default "bin"
-+ set(CMAKE_INSTALL_LIBDIR "lib")
-+ set(CMAKE_INSTALL_BINDIR "bin") #override default "bin"
-
- if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
- message(STATUS "Overriding default CMAKE_INSTALL_PREFIX to /")
-@@ -457,27 +457,31 @@ elseif(NOT WIN32)
- PATTERN "win" EXCLUDE)
-
- install(FILES "${CMAKE_CURRENT_LIST_DIR}/src/client/megacmd_completion.sh"
-- DESTINATION "etc/bash_completion.d"
-+ DESTINATION "share/bash-completion/completions"
- )
-
-- # generate 100-megacmd-inotify-limit.conf file and have it installed
-- execute_process(COMMAND echo "fs.inotify.max_user_watches = 524288"
-+ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
-+ # generate 100-megacmd-inotify-limit.conf file and have it installed
-+ execute_process(COMMAND echo "fs.inotify.max_user_watches = 524288"
- OUTPUT_FILE ${CMAKE_CURRENT_BINARY_DIR}/99-megacmd-inotify-limit.conf)
-- install(FILES ${CMAKE_CURRENT_BINARY_DIR}/99-megacmd-inotify-limit.conf
-- DESTINATION "etc/sysctl.d"
-- )
--
-- #Install vcpkg dynamic libraries in locations defined by GNUInstallDirs.
-- if(CMAKE_BUILD_TYPE STREQUAL "Debug")
-- SET(vcpkg_lib_folder "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug/lib/")
-- else()
-- SET(vcpkg_lib_folder "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/lib/")
-+ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/99-megacmd-inotify-limit.conf
-+ DESTINATION "etc/sysctl.d"
-+ )
- endif()
-- install(DIRECTORY "${vcpkg_lib_folder}"
-+
-+ if(VCPKG_ROOT)
-+ #Install vcpkg dynamic libraries in locations defined by GNUInstallDirs.
-+ if(CMAKE_BUILD_TYPE STREQUAL "Debug")
-+ SET(vcpkg_lib_folder "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug/lib/")
-+ else()
-+ SET(vcpkg_lib_folder "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/lib/")
-+ endif()
-+ install(DIRECTORY "${vcpkg_lib_folder}"
- DESTINATION ${CMAKE_INSTALL_LIBDIR}
- FILES_MATCHING
- PATTERN "lib*.so*"
- PATTERN "*dylib*" #macOS
- PATTERN "manual-link" EXCLUDE
- PATTERN "pkgconfig" EXCLUDE)
-+ endif()
- endif() #not WIN32
diff --git a/megacmd/patches/patch-build_cmake_modules_megacmd__libraries.cmake b/megacmd/patches/patch-build_cmake_modules_megacmd__libraries.cmake
deleted file mode 100644
index 12cfa6b5bf..0000000000
--- a/megacmd/patches/patch-build_cmake_modules_megacmd__libraries.cmake
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-build_cmake_modules_megacmd__libraries.cmake,v 1.1 2025/02/15 07:40:13 wiz Exp $
-
-* Fix used pcre library name
-
---- build/cmake/modules/megacmd_libraries.cmake.orig 2025-01-30 14:04:12.000000000 +0100
-+++ build/cmake/modules/megacmd_libraries.cmake
-@@ -16,7 +16,7 @@ macro(load_megacmdserver_libraries)
- find_package(PkgConfig REQUIRED) # For libraries loaded using pkg-config
-
- if(USE_PCRE) #TODO: UNTESTED!
-- pkg_check_modules(pcre REQUIRED IMPORTED_TARGET libpcre)
-+ pkg_check_modules(pcre REQUIRED IMPORTED_TARGET libpcrecpp)
- target_link_libraries(LMegacmdServer PRIVATE PkgConfig::pcre)
- set(USE_PCRE 1)
- endif()
diff --git a/megacmd/patches/patch-sdk_cmake_config.h.in b/megacmd/patches/patch-sdk_cmake_config.h.in
deleted file mode 100644
index 7f746503c2..0000000000
--- a/megacmd/patches/patch-sdk_cmake_config.h.in
+++ /dev/null
@@ -1,29 +0,0 @@
-$NetBSD: patch-sdk_cmake_config.h.in,v 1.1 2025/05/16 19:43:58 wiz Exp $
-
-* Use periodic scan instead of filesystem notification on BSDs
-
---- sdk/cmake/config.h.in.orig 2025-05-12 14:43:30.633759167 +0200
-+++ sdk/cmake/config.h.in
-@@ -10,6 +10,12 @@
- #cmakedefine ENABLE_SYNC 1
- #endif
-
-+/* Define to use periodic scan instead of filesystem notification */
-+#if (defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__)) && \
-+ defined(ENABLE_SYNC)
-+#define USE_PERIODIC
-+#endif
-+
- #ifndef ENABLE_LOG_PERFORMANCE
- #cmakedefine ENABLE_LOG_PERFORMANCE 1
- #endif
-@@ -226,7 +232,8 @@
- #define USE_DB 0
-
- /* Use inotify API */
--#if !defined(__APPLE__) && !defined(_WIN32)
-+#if !defined(__APPLE__) && !defined(_WIN32) && !defined(__FreeBSD__) && !defined(__OpenBSD__) && \
-+ !defined(__NetBSD__) && !defined(__DragonFly__)
- #define USE_INOTIFY 1
- #endif
-
diff --git a/megacmd/patches/patch-sdk_cmake_modules_sdklib__libraries.cmake b/megacmd/patches/patch-sdk_cmake_modules_sdklib__libraries.cmake
deleted file mode 100644
index 3772bbbdbd..0000000000
--- a/megacmd/patches/patch-sdk_cmake_modules_sdklib__libraries.cmake
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-sdk_cmake_modules_sdklib__libraries.cmake,v 1.2 2025/05/16 19:43:58 wiz Exp $
-
-* Fix to find libcrypto++
-
---- sdk/cmake/modules/sdklib_libraries.cmake.orig 2025-04-02 09:16:59.000000000 +0200
-+++ sdk/cmake/modules/sdklib_libraries.cmake
-@@ -91,7 +91,7 @@ macro(load_sdklib_libraries)
-
- find_package(PkgConfig REQUIRED) # For libraries loaded using pkg-config
-
-- pkg_check_modules(cryptopp REQUIRED IMPORTED_TARGET libcrypto++)
-+ pkg_check_modules(cryptopp REQUIRED IMPORTED_TARGET libcryptopp)
- target_link_libraries(SDKlib PUBLIC PkgConfig::cryptopp) # TODO: Private for SDK core
-
- pkg_check_modules(sodium REQUIRED IMPORTED_TARGET libsodium)
diff --git a/megacmd/patches/patch-sdk_cmake_modules_sdklib__target.cmake b/megacmd/patches/patch-sdk_cmake_modules_sdklib__target.cmake
deleted file mode 100644
index eee8232a82..0000000000
--- a/megacmd/patches/patch-sdk_cmake_modules_sdklib__target.cmake
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-sdk_cmake_modules_sdklib__target.cmake,v 1.1 2025/02/15 07:40:13 wiz Exp $
-
-* On gcc-10 std::filesystem is in stdc++
-
---- sdk/cmake/modules/sdklib_target.cmake.orig 2025-02-07 10:00:44.872621812 +0100
-+++ sdk/cmake/modules/sdklib_target.cmake
-@@ -358,7 +358,7 @@ endif()
- load_sdklib_libraries()
-
- # System libraries
--if((NOT (WIN32 OR APPLE OR ANDROID)) AND CMAKE_CXX_STANDARD LESS_EQUAL 17)
-+if((NOT (WIN32 OR APPLE OR ANDROID OR UNIX)) AND CMAKE_CXX_STANDARD LESS_EQUAL 17)
- # Needed for std::experimental::filesystem
- # Needed for c++17 and std::filesystem for some compilers. Not needed starting in gcc9, but harmless.
- target_link_libraries(SDKlib PRIVATE stdc++fs)
diff --git a/megacmd/patches/patch-sdk_include_mega_filesystem.h b/megacmd/patches/patch-sdk_include_mega_filesystem.h
deleted file mode 100644
index 241d45f204..0000000000
--- a/megacmd/patches/patch-sdk_include_mega_filesystem.h
+++ /dev/null
@@ -1,31 +0,0 @@
-$NetBSD: patch-sdk_include_mega_filesystem.h,v 1.1 2025/05/16 19:43:58 wiz Exp $
-
-* Add BSD supported filesystems
-
---- sdk/include/mega/filesystem.h.orig 2025-04-02 09:16:59.000000000 +0200
-+++ sdk/include/mega/filesystem.h
-@@ -51,6 +51,10 @@ enum FileSystemType
- FS_SMB = 12,
- FS_SMB2 = 13,
- FS_LIFS = 14,
-+ FS_FFS = 15,
-+ FS_HAMMER = 16,
-+ FS_UFS = 17,
-+ FS_ZFS = 18,
- };
-
- typedef void (*asyncfscallback)(void *);
-@@ -233,11 +237,13 @@ class MEGA_API LocalPath
- friend class ScopedSyncPathRestore;
- friend class WinFileSystemAccess;
- friend class PosixFileSystemAccess;
-+ friend class FallbackFileSystemAccess;
- friend struct WinDirAccess;
- friend struct WinDirNotify;
- friend class LinuxDirNotify;
- friend class MacDirNotify;
- friend class PosixDirNotify;
-+ friend class FallbackDirNotify;
- friend class WinFileAccess;
- friend class PosixFileAccess;
- friend void RemoveHiddenFileAttribute(LocalPath& path);
diff --git a/megacmd/patches/patch-sdk_include_mega_posix_megafs.h b/megacmd/patches/patch-sdk_include_mega_posix_megafs.h
deleted file mode 100644
index e42f3487f6..0000000000
--- a/megacmd/patches/patch-sdk_include_mega_posix_megafs.h
+++ /dev/null
@@ -1,36 +0,0 @@
-$NetBSD: patch-sdk_include_mega_posix_megafs.h,v 1.3 2025/05/16 19:43:58 wiz Exp $
-
-* Add Fallback classes to avoid inotify
-
---- sdk/include/mega/posix/megafs.h.orig 2025-04-02 09:16:59.000000000 +0200
-+++ sdk/include/mega/posix/megafs.h
-@@ -260,6 +260,29 @@ private:
-
- #endif // ENABLE_SYNC
-
-+#elif defined(USE_PERIODIC)
-+
-+#define FSACCESS_CLASS FallbackFileSystemAccess
-+
-+class FallbackFileSystemAccess : public PosixFileSystemAccess
-+{
-+public:
-+ DirNotify* newdirnotify(LocalNode& root,
-+ const LocalPath& rootPath,
-+ Waiter* waiter) override;
-+
-+ void addevents(Waiter*, int) override;
-+
-+ int checkevents(Waiter*) override;
-+
-+}; // class FallbackFileSystemAccess
-+
-+class FallbackDirNotify : public DirNotify
-+{
-+public:
-+ FallbackDirNotify(const LocalPath& rootPath);
-+};
-+
- #endif // __linux__
-
- } // namespace
diff --git a/megacmd/patches/patch-sdk_include_mega_sync.h b/megacmd/patches/patch-sdk_include_mega_sync.h
deleted file mode 100644
index c87f9955ac..0000000000
--- a/megacmd/patches/patch-sdk_include_mega_sync.h
+++ /dev/null
@@ -1,22 +0,0 @@
-$NetBSD: patch-sdk_include_mega_sync.h,v 1.1 2025/05/16 19:43:58 wiz Exp $
-
-* Set ChangeDetectionMethod to USE_PERIODIC
-
---- sdk/include/mega/sync.h.orig 2025-05-12 14:52:24.963962961 +0200
-+++ sdk/include/mega/sync.h
-@@ -224,10 +224,14 @@ public:
- const MegaClient& client) const;
-
- // How should the engine detect filesystem changes?
-+#ifdef USE_PERIODIC
-+ ChangeDetectionMethod mChangeDetectionMethod = CDM_PERIODIC_SCANNING;
-+#else
- ChangeDetectionMethod mChangeDetectionMethod = CDM_NOTIFICATIONS;
-+#endif
-
- // Only meaningful when a sync is in CDM_PERIODIC_SCANNING mode.
-- unsigned mScanIntervalSec = 0;
-+ unsigned mScanIntervalSec = 60;
-
- // enum to string conversion
- static const char* synctypename(const Type type);
diff --git a/megacmd/patches/patch-sdk_include_megaapi__impl.h b/megacmd/patches/patch-sdk_include_megaapi__impl.h
deleted file mode 100644
index 6b97ea9baf..0000000000
--- a/megacmd/patches/patch-sdk_include_megaapi__impl.h
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-sdk_include_megaapi__impl.h,v 1.1 2025/05/16 19:43:58 wiz Exp $
-
-* Use FallbackFileSystemAccess if USE_PERIODIC defined
-
---- sdk/include/megaapi_impl.h.orig 2025-05-12 14:53:36.536485792 +0200
-+++ sdk/include/megaapi_impl.h
-@@ -90,6 +90,8 @@ class MegaSemaphore : public CppSemaphor
- class MegaWaiter : public PosixWaiter {};
- #ifdef __APPLE__
- class MegaFileSystemAccess : public MacFileSystemAccess {};
-+ #elif defined(USE_PERIODIC)
-+ class MegaFileSystemAccess : public FallbackFileSystemAccess {};
- #else
- class MegaFileSystemAccess : public LinuxFileSystemAccess {};
- #endif
diff --git a/megacmd/patches/patch-sdk_src_filesystem.cpp b/megacmd/patches/patch-sdk_src_filesystem.cpp
deleted file mode 100644
index fa0196d66b..0000000000
--- a/megacmd/patches/patch-sdk_src_filesystem.cpp
+++ /dev/null
@@ -1,42 +0,0 @@
-$NetBSD: patch-sdk_src_filesystem.cpp,v 1.1 2025/05/16 19:43:58 wiz Exp $
-
-* Add BSD supported filesystems
-
---- sdk/src/filesystem.cpp.orig 2025-04-17 16:07:37.374980956 +0200
-+++ sdk/src/filesystem.cpp
-@@ -785,8 +785,12 @@ const char *FileSystemAccess::fstypetost
- return "EXFAT";
- case FS_FAT32:
- return "FAT32";
-+ case FS_FFS:
-+ return "FFS";
- case FS_EXT:
- return "EXT";
-+ case FS_HAMMER :
-+ return "HAMMER";
- case FS_HFS:
- return "HFS";
- case FS_APFS:
-@@ -809,6 +813,10 @@ const char *FileSystemAccess::fstypetost
- return "SMB2";
- case FS_LIFS:
- return "LIFS";
-+ case FS_UFS:
-+ return "UFS";
-+ case FS_ZFS:
-+ return "ZFS";
- case FS_UNKNOWN: // fall through
- return "UNKNOWN FS";
- }
-@@ -884,7 +892,11 @@ bool FileSystemAccess::islocalfscompatib
- case FS_APFS:
- case FS_EXT:
- case FS_F2FS:
-+ case FS_FFS:
-+ case FS_HAMMER:
-+ case FS_UFS:
- case FS_XFS:
-+ case FS_ZFS:
- return character != '/';
- case FS_EXFAT:
- case FS_FAT32:
diff --git a/megacmd/patches/patch-sdk_src_node.cpp b/megacmd/patches/patch-sdk_src_node.cpp
deleted file mode 100644
index d7f176c214..0000000000
--- a/megacmd/patches/patch-sdk_src_node.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-* Fix ctype(3) tolower usage
-
---- sdk/src/node.cpp.orig 2026-01-03 22:32:23.317953423 +0000
-+++ sdk/src/node.cpp
-@@ -197,7 +197,7 @@ bool Node::getExtension(std::string& ext
- ext = nodeName.substr(dotPos + 1);
- for (auto& c : ext)
- {
-- c = static_cast<char>(tolower(c));
-+ c = static_cast<char>(tolower(static_cast<unsigned char>(c)));
- }
- return true;
- }
diff --git a/megacmd/patches/patch-sdk_src_posix_fs.cpp b/megacmd/patches/patch-sdk_src_posix_fs.cpp
deleted file mode 100644
index 7f6e47737a..0000000000
--- a/megacmd/patches/patch-sdk_src_posix_fs.cpp
+++ /dev/null
@@ -1,198 +0,0 @@
-$NetBSD: patch-sdk_src_posix_fs.cpp,v 1.4 2025/05/16 19:43:58 wiz Exp $
-
-* Fix build on NetBSD, use statvfs
-* Don't use mntent features on BSDs
-* O_NOATIME not available on BSDs
-* Fallback funcs
-* Fix ctype(3) tolower usage
-
---- sdk/src/posix/fs.cpp.orig 2025-04-02 09:16:59.000000000 +0200
-+++ sdk/src/posix/fs.cpp
-@@ -22,7 +22,8 @@
- * You should have received a copy of the license along with this
- * program.
- */
--#ifndef __APPLE__
-+#if !defined(__APPLE__) && !defined(__FreeBSD__) && !defined(__OpenBSD__) && \
-+ !defined(__NetBSD__) && !defined(__DragonFly__)
- #include <mntent.h>
- #endif // ! __APPLE__
-
-@@ -32,6 +33,9 @@
- #include <sys/ioctl.h>
- #include <sys/resource.h>
- #include <sys/statvfs.h>
-+#if defined(__NetBSD__)
-+#define statfs statvfs
-+#endif
- #include <sys/types.h>
- #include <sys/utsname.h>
- #ifdef TARGET_OS_MAC
-@@ -1018,6 +1022,18 @@ int LinuxFileSystemAccess::checkevents([
- return result;
- }
-
-+#elif defined(USE_PERIODIC)
-+
-+void FallbackFileSystemAccess::addevents([[maybe_unused]] Waiter* waiter, int /*flags*/)
-+{
-+ //Nothing
-+}
-+
-+int FallbackFileSystemAccess::checkevents([[maybe_unused]] Waiter* waiter)
-+{
-+ return 0;
-+}
-+
- #endif // __linux__
-
-
-@@ -1417,7 +1433,8 @@ string getDistro()
- {
- distro = distro.substr(0, 20);
- }
-- transform(distro.begin(), distro.end(), distro.begin(), ::tolower);
-+ transform(distro.begin(), distro.end(), distro.begin(),
-+ [](unsigned char c) { return static_cast<char>(std::tolower(c)); });
- return distro;
- }
-
-@@ -1433,7 +1450,8 @@ string getDistroVersion()
- {
- version = version.substr(0, 10);
- }
-- transform(version.begin(), version.end(), version.begin(), ::tolower);
-+ transform(version.begin(), version.end(), version.begin(),
-+ [](unsigned char c) { return static_cast<char>(std::tolower(c)); });
- return version;
- }
- #endif
-@@ -1749,6 +1767,16 @@ void LinuxDirNotify::removeWatch(WatchMa
- }
-
- #endif // USE_INOTIFY
-+
-+#elif defined(USE_PERIODIC)
-+
-+FallbackDirNotify::FallbackDirNotify(const LocalPath& rootPath):
-+ DirNotify(rootPath)
-+{
-+ // Let the engine know everything's ok.
-+ setFailed(0, "");
-+}
-+
- #endif // __linux__
-
- #endif //ENABLE_SYNC
-@@ -1805,8 +1833,8 @@ private:
- // open with O_NOATIME if possible
- int open(const char *path)
- {
--#ifdef TARGET_OS_IPHONE
-- // building for iOS, there is no O_NOATIME flag
-+#ifndef O_NOATIME
-+ // building for iOS and BSDs, there is no O_NOATIME flag
- int fd = ::open(path, O_RDONLY) ;
- #else
- // for sync in particular, try to open without setting access-time
-@@ -2065,6 +2093,7 @@ ScanResult PosixFileSystemAccess::direct
- }
-
- #ifndef __APPLE__
-+#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__)
-
- // Determine which device contains the specified path.
- static std::string deviceOf(const std::string& database,
-@@ -2233,6 +2262,7 @@ static std::string deviceOf(const std::s
- // No database has a mapping for this path.
- return std::string();
- }
-+#endif
-
- // Compute legacy filesystem fingerprint.
- static std::uint64_t fingerprintOf(const std::string& path)
-@@ -2261,6 +2291,7 @@ static std::uint64_t fingerprintOf(const
- return ++value;
- }
-
-+#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__)
- // Determine the UUID of the specified device.
- static std::string uuidOf(const std::string& device)
- {
-@@ -2337,6 +2368,7 @@ static std::string uuidOf(const std::str
- // Couldn't determine device's UUID.
- return std::string();
- }
-+#endif
-
- fsfp_t FileSystemAccess::fsFingerprint(const LocalPath& path) const
- {
-@@ -2347,6 +2379,7 @@ fsfp_t FileSystemAccess::fsFingerprint(c
- if (!fingerprint)
- return fsfp_t();
-
-+#if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__)
- // What device contains the specified path?
- auto device = deviceOf(path.localpath);
-
-@@ -2360,6 +2393,7 @@ fsfp_t FileSystemAccess::fsFingerprint(c
- if (!uuid.empty())
- return fsfp_t(fingerprint, std::move(uuid));
- }
-+#endif
-
- // Couldn't determine filesystem UUID.
- return fsfp_t(fingerprint, std::string());
-@@ -2452,6 +2486,15 @@ DirNotify* LinuxFileSystemAccess::newdir
- return new LinuxDirNotify(*this, root, rootPath);
- }
- #endif
-+
-+#elif defined(USE_PERIODIC)
-+DirNotify* FallbackFileSystemAccess::newdirnotify(LocalNode& root,
-+ const LocalPath& rootPath,
-+ Waiter*)
-+{
-+ return new FallbackDirNotify(rootPath);
-+}
-+
- #endif
-
- bool PosixFileSystemAccess::issyncsupported(const LocalPath& localpathArg, bool& isnetwork, SyncError& syncError, SyncWarning& syncWarning)
-@@ -2526,18 +2569,26 @@ bool PosixFileSystemAccess::getlocalfsty
- }
- #endif /* __linux__ || __ANDROID__ */
-
--#if defined(__APPLE__) || defined(USE_IOS)
-+#if defined(__APPLE__) || defined(USE_IOS) || defined(__FreeBSD__) || defined(__OpenBSD__) || \
-+ defined(__NetBSD__) || defined(__DragonFly__)
- static const map<string, FileSystemType> filesystemTypes = {
- {"apfs", FS_APFS},
- {"exfat", FS_EXFAT},
-+ {"ext2fs", FS_EXT},
-+ {"ffs", FS_FFS},
-+ {"hammer", FS_HAMMER},
-+ {"hammer2", FS_HAMMER},
- {"hfs", FS_HFS},
- {"msdos", FS_FAT32},
-+ {"msdosfs", FS_FAT32},
- {"nfs", FS_NFS},
- {"ntfs", FS_NTFS}, // Apple NTFS
- {"smbfs", FS_SMB},
- {"tuxera_ntfs", FS_NTFS}, // Tuxera NTFS for Mac
-+ {"ufs", FS_UFS},
- {"ufsd_NTFS", FS_NTFS}, // Paragon NTFS for Mac
- {"lifs", FS_LIFS}, // on macos (in Ventura at least), external USB with exFAT are reported as "lifs"
-+ {"zfs", FS_ZFS},
- }; /* filesystemTypes */
-
- struct statfs statbuf;
-@@ -2555,7 +2606,7 @@ bool PosixFileSystemAccess::getlocalfsty
- type = FS_UNKNOWN;
- return true;
- }
--#endif /* __APPLE__ || USE_IOS */
-+#endif /* __APPLE__ || USE_IOS || BSDs */
-
- type = FS_UNKNOWN;
- return false;
diff --git a/megacmd/patches/patch-sdk_src_syncfilter.cpp b/megacmd/patches/patch-sdk_src_syncfilter.cpp
deleted file mode 100644
index ded064b93d..0000000000
--- a/megacmd/patches/patch-sdk_src_syncfilter.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-* Fix ctype(3) tolower usage
-
---- sdk/src/syncfilter.cpp.orig 2026-01-03 22:42:24.434490944 +0000
-+++ sdk/src/syncfilter.cpp
-@@ -980,7 +980,7 @@ bool add(const string& text, SizeFilterP
- {
- std::uint64_t shift = 0;
-
-- switch (std::tolower(istream.get()))
-+ switch (std::tolower(static_cast<unsigned char>(istream.get())))
- {
- case 'k':
- // Kilobytes.
diff --git a/megacmd/patches/patch-sdk_src_utils.cpp b/megacmd/patches/patch-sdk_src_utils.cpp
deleted file mode 100644
index 7e74bbeba6..0000000000
--- a/megacmd/patches/patch-sdk_src_utils.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-* Fix ctype(3) tolower usage
-
---- sdk/src/utils.cpp.orig 2026-01-03 22:27:50.415280578 +0000
-+++ sdk/src/utils.cpp
-@@ -2190,7 +2190,7 @@ string webdavnameescape(const string &va
-
- void tolower_string(std::string& str)
- {
-- std::transform(str.begin(), str.end(), str.begin(), [](char c) {return static_cast<char>(::tolower(c)); });
-+ std::transform(str.begin(), str.end(), str.begin(), [](unsigned char c) {return static_cast<char>(::tolower(c)); });
- }
-
- #ifdef __APPLE__
diff --git a/megacmd/patches/patch-src_megacmdcommonutils.cpp b/megacmd/patches/patch-src_megacmdcommonutils.cpp
deleted file mode 100644
index fd57442ed7..0000000000
--- a/megacmd/patches/patch-src_megacmdcommonutils.cpp
+++ /dev/null
@@ -1,26 +0,0 @@
-$NetBSD: patch-src_megacmdcommonutils.cpp,v 1.1 2025/02/15 07:40:14 wiz Exp $
-
-* BSDs use the functions of linux
-* Fix ctype(3) tolower usage
-
---- src/megacmdcommonutils.cpp.orig 2025-04-04 10:39:49.000000000 +0000
-+++ src/megacmdcommonutils.cpp
-@@ -660,7 +660,7 @@ string toLower(const std::string& str)
- std::string lower = str;
- for (char& c : lower)
- {
-- c = std::tolower(c);
-+ c = static_cast<char>(std::tolower(static_cast<unsigned char>(c)));
- }
- return lower;
- }
-@@ -1153,7 +1153,8 @@ bool isValidEmail(string email)
- || (email.find("@") > email.find_last_of(".")));
- }
-
--#ifdef __linux__
-+#if defined(__linux__) || defined(__FreeBSD__) || defined(__OpenBSD__) || \
-+ defined(__NetBSD__) || defined(__DragonFly__)
- std::string getCurrentExecPath()
- {
- std::string path = ".";
diff --git a/megacmd/patches/patch-src_megacmdcommonutils.h b/megacmd/patches/patch-src_megacmdcommonutils.h
deleted file mode 100644
index 1d19bbd721..0000000000
--- a/megacmd/patches/patch-src_megacmdcommonutils.h
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-src_megacmdcommonutils.h,v 1.1 2025/02/15 07:40:14 wiz Exp $
-
-* BSDs use the functions of linux
-
---- src/megacmdcommonutils.h.orig 2025-02-07 09:44:39.977015171 +0100
-+++ src/megacmdcommonutils.h
-@@ -269,7 +269,8 @@ void sleepMilliSeconds(long microseconds
-
- bool isValidEmail(std::string email);
-
--#ifdef __linux__
-+#if defined(__linux__) || defined(__FreeBSD__) || defined(__OpenBSD__) || \
-+ defined(__NetBSD__) || defined(__DragonFly__)
- std::string getCurrentExecPath();
- #endif
-
diff --git a/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp b/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp
deleted file mode 100644
index 8d6d3a848a..0000000000
--- a/megacmd/patches/patch-src_megacmdshell_megacmdshellcommunications.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-src_megacmdshell_megacmdshellcommunications.cpp,v 1.2 2025/02/15 07:40:14 wiz Exp $
-
-* Fix include on BSDs
-
---- 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
-
diff --git a/megacmd/patches/patch-src_megacmdutils.cpp b/megacmd/patches/patch-src_megacmdutils.cpp
deleted file mode 100644
index cb494c88e0..0000000000
--- a/megacmd/patches/patch-src_megacmdutils.cpp
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD$
-
-* Fix ctype(3) tolower usage
-
---- src/megacmdutils.cpp.orig 2026-01-03 22:04:27.842177008 +0000
-+++ src/megacmdutils.cpp
-@@ -546,7 +546,7 @@ string secondsToText(m_time_t seconds, b
- const char *getTimeFormatFromSTR(string formatName)
- {
- string lformatName = formatName;
-- transform(lformatName.begin(), lformatName.end(), lformatName.begin(), [](char c) { return (char)::tolower(c); });
-+ transform(lformatName.begin(), lformatName.end(), lformatName.begin(), [](unsigned char c) { return static_cast<char>(std::tolower(c)); });
-
- if (lformatName == "rfc2822")
- {
diff --git a/megacmd/patches/patch-src_updater_UpdateTask.cpp b/megacmd/patches/patch-src_updater_UpdateTask.cpp
deleted file mode 100644
index 9531381692..0000000000
--- a/megacmd/patches/patch-src_updater_UpdateTask.cpp
+++ /dev/null
@@ -1,26 +0,0 @@
-$NetBSD$
-
-* Fix ctype(3) tolower usage
-
---- src/updater/UpdateTask.cpp.orig 2026-01-04 16:27:16.088641735 +0100
-+++ src/updater/UpdateTask.cpp
-@@ -589,7 +589,8 @@ string getDistro()
- {
- distro = distro.substr(0, 20);
- }
-- transform(distro.begin(), distro.end(), distro.begin(), ::tolower);
-+ transform(distro.begin(), distro.end(), distro.begin(),
-+ [](unsigned char c) { return static_cast<char>(std::tolower(c)); });
- return distro;
- }
-
-@@ -605,7 +606,8 @@ string getDistroVersion()
- {
- version = version.substr(0, 10);
- }
-- transform(version.begin(), version.end(), version.begin(), ::tolower);
-+ transform(version.begin(), version.end(), version.begin(),
-+ [](unsigned char c) { return static_cast<char>(std::tolower(c)); });
- return version;
- }
- #endif
Home |
Main Index |
Thread Index |
Old Index