Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

krb5: add library version 1.18.2 #14226

Closed
wants to merge 9 commits into from
Closed

Conversation

Jihadist
Copy link
Contributor

Specify library name and version: krb5/1.18.2

This is also a good place to share with all of us why you are submitting this PR (specially if it is a new addition to ConanCenter): is it a dependency of other libraries you want to package? Are you the author of the library? Thanks!


  • I've read the guidelines for contributing.
  • I've followed the PEP8 style guides for Python code in the recipes.
  • I've used the latest Conan client version.
  • I've tried at least one configuration locally with the conan-center hook activated.

Closes #4102

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@Jihadist
Copy link
Contributor Author

@madebr I try to port your recipe to conan v2. Looks like everything is ok, but I don't understand what's wrong with ksu install. I reproduced problem locally but it didn't help. I can change ownership with chmod but not with install. Do you have any ideas how to fix it?
P.S. Windows doesn't have this problem.

@madebr
Copy link
Contributor

madebr commented Nov 18, 2022

I can't reproduce the error on CI. It looks like a rights issue.
The static install tree contains symbols links. Weird if this would not be allowed.

But the static library has issues:

  • the conan hooks complain it cannot find kadm5clnt_mit and kadm5srv_mit, even though these libraries are present in $PREFIX/lib.
    ├── lib
    │   ├── krb5
    │   │   └── plugins
    │   │       ├── authdata
    │   │       ├── kdb
    │   │       ├── libkrb5
    │   │       ├── preauth
    │   │       └── tls
    │   ├── libcom_err.a
    │   ├── libgssapi_krb5.a
    │   ├── libgssrpc.a
    │   ├── libk5crypto.a
    │   ├── libkadm5clnt.a -> libkadm5clnt_mit.a
    │   ├── libkadm5clnt_mit.a
    │   ├── libkadm5srv.a -> libkadm5srv_mit.a
    │   ├── libkadm5srv_mit.a
    │   ├── libkdb5.a
    │   ├── libkrad.a
    │   ├── libkrb5.a
    │   ├── libkrb5_db2.a
    │   ├── libkrb5_k5tls.a
    │   ├── libkrb5_otp.a
    │   ├── libkrb5_pkinit.a
    │   ├── libkrb5_spake.a
    │   ├── libkrb5support.a
    │   └── libkrb5_test.a
    
  • The static test package fails because of missing symbols, this might be because the dependencies are not correctly modeled in package_info.

Building the recipe, I noticed a few outdated packages, so I applied the patch below.
The version of krb5 you're adding here is also outdated: 1.20.1 is the newest.

diff --git a/recipes/krb5/all/conanfile.py b/recipes/krb5/all/conanfile.py
index 50e4b1be4..239d872af 100644
--- a/recipes/krb5/all/conanfile.py
+++ b/recipes/krb5/all/conanfile.py
@@ -113,7 +113,7 @@ class Krb5Conan(ConanFile):
         if not is_msvc(self):
             self.requires("libverto/0.3.2")
         if self.options.get_safe("with_tls") == "openssl":
-            self.requires("openssl/1.1.1q")
+            self.requires("openssl/1.1.1s")
         if self.options.get_safe("with_tcl"):
             self.requires("tcl/8.6.10")
 
@@ -169,7 +169,7 @@ class Krb5Conan(ConanFile):
                 replace_in_file(self, "kdb5_util.c",
                                 "krb5_keyblock master_keyblock;",
                                 "extern krb5_keyblock master_keyblock;")
-            with chdir(self, os.path.join(self.source_folder,"src", "tests", "create")):                    
+            with chdir(self, os.path.join(self.source_folder,"src", "tests", "create")):
                 replace_in_file(self, "kdb5_mkdums.c",
                                 "krb5_keyblock master_keyblock;",
                                 "extern krb5_keyblock master_keyblock;")
@@ -178,14 +178,14 @@ class Krb5Conan(ConanFile):
                                 "static krb5_principal master_princ;")
                 replace_in_file(self, "kdb5_mkdums.c",
                                 "krb5_pointer master_random;",
-                                "static krb5_pointer master_random;")                                                
+                                "static krb5_pointer master_random;")
             with chdir(self, os.path.join(self.source_folder,"src", "tests", "verify")):
                 replace_in_file(self, "kdb5_verify.c",
                                 "krb5_keyblock master_keyblock;",
                                 "extern krb5_keyblock master_keyblock;")
                 replace_in_file(self, "kdb5_verify.c",
                                 "krb5_principal master_princ;",
-                                "static krb5_principal master_princ;")                                                    
+                                "static krb5_principal master_princ;")
         apply_conandata_patches(self)
         if is_msvc(self):
             self._build_msvc()
@@ -229,7 +229,7 @@ class Krb5Conan(ConanFile):
         self.cpp_info.components["mit-krb5"].libs = [krb5_lib] + crypto_libs + [krb5support]
         if not is_msvc(self):
             self.cpp_info.components["mit-krb5"].libs.append("com_err")  # is a common library, that can potentially be packaged (but I don't know who "owns" it)
-            
+
         if self.options.get_safe('with_tls') == "openssl":
             self.cpp_info.components["mit-krb5"].requires.append("openssl::ssl")
         self.cpp_info.components["mit-krb5"].names["pkg_config"] = "mit-krb5"
diff --git a/recipes/krb5/all/test_package/conanfile.py b/recipes/krb5/all/test_package/conanfile.py
index a6564ead1..261d65b1a 100644
--- a/recipes/krb5/all/test_package/conanfile.py
+++ b/recipes/krb5/all/test_package/conanfile.py
@@ -7,7 +7,7 @@ class TestPackageConan(ConanFile):
     generators = "cmake", "pkg_config"
 
     def build_requirements(self):
-        self.build_requires("pkgconf/1.7.3")
+        self.build_requires("pkgconf/1.9.3")
 
     def build(self):
         cmake = CMake(self)
diff --git a/recipes/libevent/all/conanfile.py b/recipes/libevent/all/conanfile.py
index 0a8f1ba78..8ae1637de 100644
--- a/recipes/libevent/all/conanfile.py
+++ b/recipes/libevent/all/conanfile.py
@@ -56,7 +56,7 @@ class LibeventConan(ConanFile):
 
     def requirements(self):
         if self.options.with_openssl:
-            self.requires("openssl/1.1.1q")
+            self.requires("openssl/1.1.1s")
 
     def source(self):
         get(self, **self.conan_data["sources"][self.version],
diff --git a/recipes/libverto/all/conanfile.py b/recipes/libverto/all/conanfile.py
index 8e6ade5b4..30c814e06 100644
--- a/recipes/libverto/all/conanfile.py
+++ b/recipes/libverto/all/conanfile.py
@@ -96,7 +96,7 @@ class LibVertoConan(ConanFile):
 
     def requirements(self):
         if self.options.with_glib:
-            self.requires("glib/2.69.2")
+            self.requires("glib/2.74.21")
         if self.options.with_libevent:
             self.requires("libevent/2.1.12")
         if self.options.with_libev:
@@ -106,8 +106,8 @@ class LibVertoConan(ConanFile):
             raise ConanInvalidConfiguration("tevent is not (yet) available on conan-center")
 
     def build_requirements(self):
-        self.build_requires("pkgconf/1.7.4")
-        self.build_requires("libtool/2.4.6")
+        self.build_requires("pkgconf/1.9.3")
+        self.build_requires("libtool/2.4.7")
         if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"):
             self.build_requires("msys2/cci.latest")
 

@Jihadist
Copy link
Contributor Author

The version of krb5 you're adding here is also outdated: 1.20.1 is the newest.

I understand but I want to create fully working recipe for old version and then port to current newest. I think it can be easier than drop your patches and create my own

@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline

Failure in build 8 (0db630419592e3f0676c53b6be14b26ca3ba7957):

  • krb5/1.18.2@:
    CI failed to create some packages (All logs)

    Logs for packageID 3116fbb4c4e14bd1424668078676cd852f7dba08:
    [settings]
    arch=x86_64
    build_type=Debug
    compiler=gcc
    compiler.libcxx=libstdc++11
    compiler.version=7
    os=Linux
    [options]
    krb5:shared=True
    
    [...]
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_write_lock':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:78: undefined reference to `pthread_rwlock_wrlock'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_unlock':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:91: undefined reference to `pthread_rwlock_unlock'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_lock_free':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:107: undefined reference to `pthread_rwlock_destroy'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_run_once':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:118: undefined reference to `pthread_once'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_init_local':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:126: undefined reference to `pthread_key_create'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_get_local':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:134: undefined reference to `pthread_getspecific'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_set_local':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:139: undefined reference to `pthread_setspecific'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `CRYPTO_THREAD_cleanup_local':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:147: undefined reference to `pthread_key_delete'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `fork_once_func':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:188: undefined reference to `pthread_atfork'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(threads_pthread.o): In function `openssl_init_fork_handlers':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/threads_pthread.c:196: undefined reference to `pthread_once'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_load':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:116: undefined reference to `dlopen'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:119: undefined reference to `dlerror'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:138: undefined reference to `dlclose'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_unload':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:161: undefined reference to `dlclose'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_bind_func':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:186: undefined reference to `dlsym'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:189: undefined reference to `dlerror'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_pathbyaddr':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:422: undefined reference to `dladdr'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:440: undefined reference to `dlerror'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/package/db2ca884c9793e0b0fb54ec3f846326d1addacc8/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup':
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:447: undefined reference to `dlopen'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:450: undefined reference to `dlsym'
    /home/conan/w/prod/BuildSingleReference/.conan/data/openssl/1.1.1s/_/_/build/db2ca884c9793e0b0fb54ec3f846326d1addacc8/source_subfolder/crypto/dso/dso_dlfcn.c:451: undefined reference to `dlclose'
    collect2: error: ld returned 1 exit status
    make[2]: *** [softpkcs11.so] Error 1
    make[1]: *** [all-recurse] Error 1
    make: *** [all-recurse] Error 1
    WARN: libevent/2.1.12: requirement openssl/1.1.1q overridden by libverto/0.3.2 to openssl/1.1.1s 
    krb5/1.18.2: WARN: Using the new toolchains and generators without specifying a build profile (e.g: -pr:b=default) is discouraged and might cause failures and unexpected behavior
    krb5/1.18.2: WARN: Using the new toolchains and generators without specifying a build profile (e.g: -pr:b=default) is discouraged and might cause failures and unexpected behavior
    krb5/1.18.2: ERROR: Package '3116fbb4c4e14bd1424668078676cd852f7dba08' build failed
    krb5/1.18.2: WARN: Build folder /home/conan/w/prod/BuildSingleReference/.conan/data/krb5/1.18.2/_/_/build/3116fbb4c4e14bd1424668078676cd852f7dba08/build-debug
    ERROR: krb5/1.18.2: Error in build() method, line 193
    	self._build_autotools()
    while calling '_build_autotools', line 138
    	autotools.make()
    	ConanException: Error 2 while executing make -j3
    

Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.

@stale
Copy link

stale bot commented Dec 20, 2022

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 20, 2022
@stale
Copy link

stale bot commented Jan 20, 2023

This pull request has been automatically closed because it has not had recent activity. Thank you for your contributions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[request] krb5/1.18.3
3 participants