push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,58 @@
--- a/configure
+++ b/configure
@@ -6143,53 +6143,8 @@ rm -f confcache
#AC_CHECK_HEADERS(openssl/ssl.h openssl/crypto.h)
#AC_CHECK_HEADERS(zlib.h)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for path to OpenSSL" >&5
-$as_echo_n "checking for path to OpenSSL... " >&6; }
-
-
-# Check whether --with-openssl was given.
-if test "${with_openssl+set}" = set; then :
- withval=$with_openssl; with_openssl_path=$withval
-else
- with_openssl_path=auto
-fi
-
-
-
-cf_openssl_basedir=""
-if test "$with_openssl_path" != "auto"; then
- cf_openssl_basedir="`echo ${with_openssl_path} | sed 's/\/$//'`"
-else
- for dirs in /usr/local/ssl /usr/pkg /usr/local /usr/local/openssl; do
- if test -f "${dirs}/include/openssl/opensslv.h" && test -f "${dirs}/lib/libssl.so"; then
- cf_openssl_basedir="${dirs}"
- break
- fi
- done
- unset dirs
-fi
-if test ! -z "$cf_openssl_basedir"; then
- if test -f "${cf_openssl_basedir}/include/openssl/opensslv.h" && test -f "${cf_openssl_basedir}/lib/libssl.so"; then
- SSL_INCLUDES="-I${cf_openssl_basedir}/include"
- SSL_LIBS="-L${cf_openssl_basedir}/lib"
- else
- cf_openssl_basedir=""
- fi
-else
- if test -f "/usr/include/openssl/opensslv.h" ; then
- cf_openssl_basedir="/usr"
- fi
-fi
-
-if test ! -z "$cf_openssl_basedir"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cf_openssl_basedir" >&5
-$as_echo "$cf_openssl_basedir" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
-$as_echo "not found" >&6; }
- as_fn_error 1 "OpenSSL is required." "$LINENO" 5
-fi
-unset cf_openssl_basedir
+SSL_INCLUDES="-I@openssl.dev@/include"
+SSL_LIBS="-L@openssl-lib@/lib"
save_CXX="$CXX"
CXX="$CXX $SSL_INCLUDES"

View File

@@ -0,0 +1,48 @@
diff --git a/src/libcrypto.cc b/src/libcrypto.cc
index 5139f66..517103f 100644
--- a/src/libcrypto.cc
+++ b/src/libcrypto.cc
@@ -100,17 +100,9 @@ int load_libcrypto() {
}
sdprintf("Loading libcrypto");
+ dlerror(); // Clear Errors
+ libcrypto_handle = dlopen("@openssl@/lib/libcrypto.so", RTLD_LAZY|RTLD_GLOBAL);
- bd::Array<bd::String> libs_list(bd::String("libcrypto.so." SHLIB_VERSION_NUMBER " libcrypto.so libcrypto.so.1.1 libcrypto.so.1.0.0 libcrypto.so.0.9.8 libcrypto.so.10 libcrypto.so.9 libcrypto.so.8 libcrypto.so.7 libcrypto.so.6").split(' '));
-
- for (size_t i = 0; i < libs_list.length(); ++i) {
- dlerror(); // Clear Errors
- libcrypto_handle = dlopen(bd::String(libs_list[i]).c_str(), RTLD_LAZY|RTLD_GLOBAL);
- if (libcrypto_handle) {
- sdprintf("Found libcrypto: %s", bd::String(libs_list[i]).c_str());
- break;
- }
- }
if (!libcrypto_handle) {
fprintf(stderr, STR("Unable to find libcrypto\n"));
return(1);
diff --git a/src/libssl.cc b/src/libssl.cc
index 6010abc..86e29fc 100644
--- a/src/libssl.cc
+++ b/src/libssl.cc
@@ -78,17 +78,9 @@ int load_libssl() {
}
sdprintf("Loading libssl");
+ dlerror(); // Clear Errors
+ libssl_handle = dlopen("@openssl@/lib/libssl.so", RTLD_LAZY);
- bd::Array<bd::String> libs_list(bd::String("libssl.so." SHLIB_VERSION_NUMBER " libssl.so libssl.so.1.1 libssl.so.1.0.0 libssl.so.0.9.8 libssl.so.10 libssl.so.9 libssl.so.8 libssl.so.7 libssl.so.6").split(' '));
-
- for (size_t i = 0; i < libs_list.length(); ++i) {
- dlerror(); // Clear Errors
- libssl_handle = dlopen(bd::String(libs_list[i]).c_str(), RTLD_LAZY);
- if (libssl_handle) {
- sdprintf("Found libssl: %s", bd::String(libs_list[i]).c_str());
- break;
- }
- }
if (!libssl_handle) {
fprintf(stderr, STR("Unable to find libssl\n"));
return(1);

View File

@@ -0,0 +1,54 @@
{
lib,
stdenv,
fetchurl,
openssl_1_1,
}:
stdenv.mkDerivation rec {
pname = "wraith";
version = "1.4.10";
src = fetchurl {
url = "mirror://sourceforge/wraithbotpack/wraith-v${version}.tar.gz";
sha256 = "1h8159g6wh1hi69cnhqkgwwwa95fa6z1zrzjl219mynbf6vjjzkw";
};
hardeningDisable = [ "format" ];
buildInputs = [ openssl_1_1 ];
patches = [
./configure.patch
./dlopen.patch
];
postPatch = ''
substituteInPlace configure --subst-var-by openssl.dev ${openssl_1_1.dev} \
--subst-var-by openssl-lib ${lib.getLib openssl_1_1}
substituteInPlace src/libssl.cc --subst-var-by openssl ${lib.getLib openssl_1_1}
substituteInPlace src/libcrypto.cc --subst-var-by openssl ${lib.getLib openssl_1_1}
'';
installPhase = ''
mkdir -p $out/bin
cp -a wraith $out/bin/wraith
ln -s wraith $out/bin/hub
'';
meta = with lib; {
broken = (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64);
description = "IRC channel management bot written purely in C/C++";
longDescription = ''
Wraith is an IRC channel management bot written purely in C/C++. It has
been in development since late 2003. It is based on Eggdrop 1.6.12 but has
since evolved into something much different at its core. TCL and loadable
modules are currently not supported.
Maintainer's Notes:
Copy the binary out of the store before running it with the -C option to
configure it. See https://github.com/wraith/wraith/wiki/GettingStarted .
The binary will not run when moved onto non-NixOS systems; use patchelf
to fix its runtime dependenices.
'';
homepage = "https://wraith.botpack.net/";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ elitak ];
platforms = platforms.linux;
};
}