commit: 6115c6de829c98087f3556886bba6bf7d3b3499f Author: Ivan S. Titov <iohann.s.titov <AT> gmail <DOT> com> AuthorDate: Tue Jan 6 11:43:20 2026 +0000 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org> CommitDate: Wed Jan 7 13:04:48 2026 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6115c6de
sys-fs/cryfs: add 1.0.3 Closes: https://bugs.gentoo.org/968454 Signed-off-by: Ivan S. Titov <iohann.s.titov <AT> gmail.com> Part-of: https://github.com/gentoo/gentoo/pull/45273 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org> sys-fs/cryfs/Manifest | 1 + sys-fs/cryfs/cryfs-1.0.3.ebuild | 173 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 174 insertions(+) diff --git a/sys-fs/cryfs/Manifest b/sys-fs/cryfs/Manifest index 334079ee7c36..f2ae61c718f2 100644 --- a/sys-fs/cryfs/Manifest +++ b/sys-fs/cryfs/Manifest @@ -1 +1,2 @@ DIST cryfs-1.0.1.tar.xz 7508060 BLAKE2B 21c2feba56181e51ec7799ccb90d604d6e183443ddf7ddaaa5e8952405d4b16382805c6c10affbd1e5ff251853bad53dcade9a1d004fa28220e0aa10c433f7c3 SHA512 e6bba11b0229cad75ae4383b04f73c436f5badf4b727a992cbef7071807049fa628768e375f057c54043af99bb9624ef0e69bcfa680dcc82ed6ed281887da11c +DIST cryfs-1.0.3.tar.xz 7540772 BLAKE2B 8e67b6606419045ad8698bffbcc518be765ad702ad6a3ad5715c70d32b9310caa53e5df987a6a91d84c9c04a059b17e680799edbe08f9337022d3e348846bc92 SHA512 40bf01e0f60de1b71b1caf0b0a2c7fd9b4a13748aad0f6a3a38156385451aa1e7d27d050565d145f1d498f85742edce765121dad6ef39994f81d7c666d7c50bb diff --git a/sys-fs/cryfs/cryfs-1.0.3.ebuild b/sys-fs/cryfs/cryfs-1.0.3.ebuild new file mode 100644 index 000000000000..c4d40e312251 --- /dev/null +++ b/sys-fs/cryfs/cryfs-1.0.3.ebuild @@ -0,0 +1,173 @@ +# Copyright 1999-2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..14} ) +inherit cmake eapi9-ver flag-o-matic linux-info python-any-r1 + +if [[ ${PV} == 9999 ]] ; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/cryfs/cryfs" +else + SRC_URI="https://github.com/cryfs/cryfs/releases/download/${PV}/${P}.tar.xz" + S=${WORKDIR} + KEYWORDS="~amd64 ~arm64 ~loong ~ppc64 ~riscv ~x86" +fi + +DESCRIPTION="Encrypted FUSE filesystem that conceals metadata" +HOMEPAGE="https://www.cryfs.org/" + +LICENSE="LGPL-3 MIT" +SLOT="0" +IUSE="test" +RESTRICT="!test? ( test )" + +RDEPEND=" + >=dev-libs/boost-1.84.0:= + dev-libs/crypto++:= + dev-libs/libfmt:= + dev-libs/spdlog:= + >=sys-fs/fuse-2.8.6:0 +" +DEPEND=" + ${RDEPEND} + dev-cpp/range-v3 + net-misc/curl + test? ( + dev-cpp/gtest + ) +" +BDEPEND=" + ${PYTHON_DEPS} + virtual/pkgconfig + $(python_gen_any_dep ' + dev-python/versioneer[${PYTHON_USEDEP}] + ') +" + +PATCHES=( + # TODO: upstream: + "${FILESDIR}"/cryfs-1.0.1-unbundle-vendored-libs.patch +) + +python_check_deps() { + python_has_version "dev-python/versioneer[${PYTHON_USEDEP}]" +} + +pkg_setup() { + local CONFIG_CHECK="~FUSE_FS" + local WARNING_FUSE_FS="CONFIG_FUSE_FS is required for cryfs support." + + check_extra_config + python-any-r1_pkg_setup +} + +src_prepare() { + cmake_src_prepare + + # don't install compressed manpage + cmake_comment_add_subdirectory doc + + # We use the package instead for >=py3.12 compat, bug #908997 + rm src/gitversion/versioneer.py || die + + # Hook up ctest properly for better maintainer quality of life + sed -i -e '/option(BUILD_TESTING/aenable_testing()' CMakeLists.txt || die + sed -i -e '/BUILD_TESTING/a include(GoogleTest)' test/CMakeLists.txt || die + sed -i -e 's/add_test/gtest_discover_tests/' test/*/CMakeLists.txt || die +} + +src_configure() { + # ODR violations (bug #880563) + # ./CMakeLists.txt + # """ + # We don't use LTO because crypto++ has problems with it, + # see https://github.com/weidai11/cryptopp/issues/1031 and + # https://www.cryptopp.com/wiki/Link_Time_Optimization + # """ + filter-lto + + local mycmakeargs=( + # Upstream inconsistently specifies their libraries as STATIC + # Leading to issues when static libraries without PIC are linked + # with PIC shared libraries. + -DBUILD_SHARED_LIBS=OFF + -DBUILD_TESTING=$(usex test) + -DCRYFS_UPDATE_CHECKS=OFF + -DUSE_SYSTEM_LIBS=ON + ) + + append-cppflags -DNDEBUG + + # bug 907096 + use elibc_musl && append-flags -D_LARGEFILE64_SOURCE + + cmake_src_configure +} + +src_test() { + local TMPDIR="${T}" + + local CMAKE_SKIP_TESTS=( + # Cannot test mounting filesystems in sandbox + # Filesystem did not call onMounted callback, probably wasn't successfully mounted. + # bug #808849 + CliTest.WorksWithCommasInBasedir + CliTest_IntegrityCheck.givenIncorrectFilesystemId_thenFails + CliTest_IntegrityCheck.givenIncorrectFilesystemKey_thenFails + CliTest_Setup.AutocreateBasedir + CliTest_Setup.AutocreateMountpoint + CliTest_Setup.ConfigfileGiven + CliTest_Setup.ExistingLogfileGiven + CliTest_Setup.NoSpecialOptions + CliTest_Setup.NotexistingLogfileGiven + CliTest_Unmount.givenMountedFilesystem_whenUnmounting_thenSucceeds + RunningInForeground/CliTest_WrongEnvironment.BaseDir_AllPermissions + RunningInForeground/CliTest_WrongEnvironment.BaseDir_DoesntExist_Create + RunningInForeground/CliTest_WrongEnvironment.MountDir_AllPermissions + RunningInForeground/CliTest_WrongEnvironment.MountDir_DoesntExist_Create + RunningInForeground/CliTest_WrongEnvironment.NoErrorCondition + RunningInForeground_ExternalConfigfile/CliTest_WrongEnvironment.BaseDir_AllPermissions + RunningInForeground_ExternalConfigfile/CliTest_WrongEnvironment.BaseDir_DoesntExist_Create + RunningInForeground_ExternalConfigfile/CliTest_WrongEnvironment.MountDir_AllPermissions + RunningInForeground_ExternalConfigfile/CliTest_WrongEnvironment.MountDir_DoesntExist_Create + RunningInForeground_ExternalConfigfile/CliTest_WrongEnvironment.NoErrorCondition + RunningInForeground_ExternalConfigfile_LogIsNotStderr/CliTest_WrongEnvironment.BaseDir_AllPermissions + RunningInForeground_ExternalConfigfile_LogIsNotStderr/CliTest_WrongEnvironment.BaseDir_DoesntExist_Create + RunningInForeground_ExternalConfigfile_LogIsNotStderr/CliTest_WrongEnvironment.MountDir_AllPermissions + RunningInForeground_ExternalConfigfile_LogIsNotStderr/CliTest_WrongEnvironment.MountDir_DoesntExist_Create + RunningInForeground_ExternalConfigfile_LogIsNotStderr/CliTest_WrongEnvironment.NoErrorCondition + RunningInForeground_LogIsNotStderr/CliTest_WrongEnvironment.BaseDir_AllPermissions + RunningInForeground_LogIsNotStderr/CliTest_WrongEnvironment.BaseDir_DoesntExist_Create + RunningInForeground_LogIsNotStderr/CliTest_WrongEnvironment.MountDir_AllPermissions + RunningInForeground_LogIsNotStderr/CliTest_WrongEnvironment.MountDir_DoesntExist_Create + RunningInForeground_LogIsNotStderr/CliTest_WrongEnvironment.NoErrorCondition + # Filesystem did not call onMounted callback, probably wasn't successfully mounted. + # fuse: failed to open /dev/fuse: Permission denied + CliTest_IntegrityCheck.givenFilesystemWithRolledBackBasedir_whenMounting_thenFails + CliTest_IntegrityCheck.whenRollingBackBasedirWhileMounted_thenUnmounts + # Tests that hang due to being unable to open fuse + # bug #699044 + # fuse: failed to open /dev/fuse: Permission denied + Fuse* + ) + + cmake_src_test +} + +src_install() { + cmake_src_install + doman doc/man/cryfs.1 + doman doc/man/cryfs-unmount.1 +} + +pkg_postinst() { + if ver_replacing -lt 1.0.0; then + elog "Filesystems created with CryFS 0.11.x and CryFS 1.0.0 are fully compatible with each other." + elog "This means filesystems created with 0.10.x or 0.11.x can be mounted without requiring a migration." + elog "Filesystems created with 1.0.0 or 0.11.x can be mounted by CryFS 0.10.x," + elog "but only if you configure it to use a cipher supported by CryFS 0.10.x, e.g. AES-256-GCM." + elog "The new default, XChaCha20-Poly1305, is not supported by CryFS 0.10.x." + fi +}
