[Debian-med-packaging] Bug#1010554: orthanc: FTBFS with dcmtk >= 3.6.7

Johannes Schauer Marin Rodrigues josch at debian.org
Wed May 4 09:48:30 BST 2022


Source: orthanc
Version: 1.10.1+dfsg-1
Severity: serious
Tags: ftbfs
Justification: fails to build from source (but built successfully in the past)
X-Debbugs-Cc: josch at debian.org, malat at debian.org

Hi,

orthanc FTBFS with dcmtk 3.6.7 from unstable:

/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp:110:118: error: ‘TCS_ok’ was
not declared in this scope
  110 |       if (tls->addTrustedCertificateFile(trustedCertificatesPath.c_str(), DCF_Filetype_PEM /*opt_keyFi
leFormat*/) != TCS_ok)
      |
               ^~~~~~
/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp:116:104: error: ‘TCS_ok’ was
not declared in this scope
  116 |       if (tls->setPrivateKeyFile(ownPrivateKeyPath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/) !=
 TCS_ok)
      |
 ^~~~~~
/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp:122:106: error: ‘TCS_ok’ was
not declared in this scope
  122 |       if (tls->setCertificateFile(ownCertificatePath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/)
!= TCS_ok)
      |
   ^~~~~~
/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp:135:72: error: ‘TCS_ok’ was n
ot declared in this scope
  135 |       if (tls->setTLSProfile(TSP_Profile_BCP195 /*opt_tlsProfile*/) != TCS_ok)
      |                                                                        ^~~~~~
/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp:140:36: error: could not convert ‘DcmTLSTransportLayer::activateCipherSuites()()’ from ‘OFCondition’ to ‘bool’
  140 |       if (tls->activateCipherSuites())
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~^~
      |                                    |
      |                                    OFCondition
make[4]: *** [CMakeFiles/OrthancFramework.dir/build.make:1941: CMakeFiles/OrthancFramework.dir/<<PKGBUILDDIR>>/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp.o] Error 1


The attached debdiff fixes above problem but the testsuite still fails with:

[100%] Linking CXX executable UnitTests
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/11/../../../x86_64-linux-gnu/libdcmdata.so: undefined reference to symbol 'inflateEnd'
/usr/bin/ld: /lib/x86_64-linux-gnu/libz.so.1: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status

Maybe this has to be fixed in dcmtk but I'm not sure. Because my patch
is not complete I'm not tagging this bug with patch.

Thanks!

cheers, josch
-------------- next part --------------
diff -Nru orthanc-1.10.1+dfsg/debian/changelog orthanc-1.10.1+dfsg/debian/changelog
--- orthanc-1.10.1+dfsg/debian/changelog	2022-03-23 21:05:58.000000000 +0100
+++ orthanc-1.10.1+dfsg/debian/changelog	2022-05-04 10:13:08.000000000 +0200
@@ -1,3 +1,10 @@
+orthanc (1.10.1+dfsg-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * add patch to build with dcmtk >= 3.6.7 (closes: #XXXXXXX)
+
+ -- Johannes Schauer Marin Rodrigues <josch at debian.org>  Wed, 04 May 2022 10:13:08 +0200
+
 orthanc (1.10.1+dfsg-1) unstable; urgency=medium
 
   * New upstream version
diff -Nru orthanc-1.10.1+dfsg/debian/patches/dcmtk-3.6.7 orthanc-1.10.1+dfsg/debian/patches/dcmtk-3.6.7
--- orthanc-1.10.1+dfsg/debian/patches/dcmtk-3.6.7	1970-01-01 01:00:00.000000000 +0100
+++ orthanc-1.10.1+dfsg/debian/patches/dcmtk-3.6.7	2022-05-04 10:13:08.000000000 +0200
@@ -0,0 +1,40 @@
+--- a/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp
++++ b/OrthancFramework/Sources/DicomNetworking/Internals/DicomTls.cpp
+@@ -107,19 +107,19 @@ namespace Orthanc
+         new DcmTLSTransportLayer(tmpRole /*opt_networkRole*/, NULL /*opt_readSeedFile*/,
+                                  OFFalse /*initializeOpenSSL, done by Orthanc::Toolbox::InitializeOpenSsl()*/));
+ 
+-      if (tls->addTrustedCertificateFile(trustedCertificatesPath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/) != TCS_ok)
++      if (tls->addTrustedCertificateFile(trustedCertificatesPath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/).bad())
+       {
+         throw OrthancException(ErrorCode_BadFileFormat, "Cannot parse PEM file with trusted certificates for DICOM TLS: " +
+                                trustedCertificatesPath);
+       }
+ 
+-      if (tls->setPrivateKeyFile(ownPrivateKeyPath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/) != TCS_ok)
++      if (tls->setPrivateKeyFile(ownPrivateKeyPath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/).bad())
+       {
+         throw OrthancException(ErrorCode_BadFileFormat, "Cannot parse PEM file with private key for DICOM TLS: " +
+                                ownPrivateKeyPath);
+       }
+ 
+-      if (tls->setCertificateFile(ownCertificatePath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/) != TCS_ok)
++      if (tls->setCertificateFile(ownCertificatePath.c_str(), DCF_Filetype_PEM /*opt_keyFileFormat*/).bad())
+       {
+         throw OrthancException(ErrorCode_BadFileFormat, "Cannot parse PEM file with own certificate for DICOM TLS: " +
+                                ownCertificatePath);
+@@ -132,12 +132,12 @@ namespace Orthanc
+       }
+ 
+ #if DCMTK_VERSION_NUMBER >= 364
+-      if (tls->setTLSProfile(TSP_Profile_BCP195 /*opt_tlsProfile*/) != TCS_ok)
++      if (tls->setTLSProfile(TSP_Profile_BCP195 /*opt_tlsProfile*/).bad())
+       {
+         throw OrthancException(ErrorCode_InternalError, "Cannot set the DICOM TLS profile");
+       }
+     
+-      if (tls->activateCipherSuites())
++      if (tls->activateCipherSuites().good())
+       {
+         throw OrthancException(ErrorCode_InternalError, "Cannot activate the cipher suites for DICOM TLS");
+       }
diff -Nru orthanc-1.10.1+dfsg/debian/patches/series orthanc-1.10.1+dfsg/debian/patches/series
--- orthanc-1.10.1+dfsg/debian/patches/series	1970-01-01 01:00:00.000000000 +0100
+++ orthanc-1.10.1+dfsg/debian/patches/series	2022-05-04 10:11:02.000000000 +0200
@@ -0,0 +1 @@
+dcmtk-3.6.7


More information about the Debian-med-packaging mailing list