Opened 5 years ago

Closed 5 years ago

#58970 closed defect (fixed)

kdelibs4 @4.14.3_14: build failure against openssl 1.1.1

Reported by: photor Owned by: NicosPavlov
Priority: Normal Milestone:
Component: ports Version: 2.5.4
Keywords: Cc: RJVB (René Bertin), tehcog (tehcog), StanSanderson, mopihopi, NateAsir
Port: kdelibs4

Description (last modified by kencu (Ken))

Failed to build kdelibs4 when doing "sudo port upgrade outdated" on mac os x 10.10. Tried "sudo port clean --all installed" and then upgraded again, but no help.

:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_kde_kdelibs4/kdelibs4/work/kdelibs-4.14.3/kio/kssl/ksslcertificate.cpp:404:27: error: too many arguments to function call, expected 1, have 3; did you mean '::CRYPTO_free'?
:info:build                 d->kossl->OPENSSL_free(x);
:info:build                           ^~~~~~~~~~~~~~~
:info:build /opt/local/include/openssl/crypto.h:128:9: note: expanded from macro 'OPENSSL_free'
:info:build         CRYPTO_free(addr, OPENSSL_FILE, OPENSSL_LINE)
:info:build         ^~~~~~~~~~~
:info:build /opt/local/include/openssl/crypto.h:271:6: note: '::CRYPTO_free' declared here
:info:build void CRYPTO_free(void *ptr, const char *file, int line);
:info:build      ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_kde_kdelibs4/kdelibs4/work/kdelibs-4.14.3/kio/kssl/ksslcertificate.cpp:406:45: error: member access into incomplete type 'EVP_PKEY' (aka 'evp_pkey_st')
:info:build                 x = d->kossl->BN_bn2hex(pkey->pkey.dsa->g);
:info:build                                             ^
:info:build /opt/local/include/openssl/ossl_typ.h:93:16: note: forward declaration of 'evp_pkey_st'
:info:build typedef struct evp_pkey_st EVP_PKEY;
:info:build                ^
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_kde_kdelibs4/kdelibs4/work/kdelibs-4.14.3/kio/kssl/ksslcertificate.cpp:418:27: error: too many arguments to function call, expected 1, have 3; did you mean '::CRYPTO_free'?
:info:build                 d->kossl->OPENSSL_free(x);
:info:build                           ^~~~~~~~~~~~~~~
:info:build /opt/local/include/openssl/crypto.h:128:9: note: expanded from macro 'OPENSSL_free'
:info:build         CRYPTO_free(addr, OPENSSL_FILE, OPENSSL_LINE)
:info:build         ^~~~~~~~~~~
:info:build /opt/local/include/openssl/crypto.h:271:6: note: '::CRYPTO_free' declared here
:info:build void CRYPTO_free(void *ptr, const char *file, int line);
:info:build      ^

Attachments (1)

main.log.zip (691.4 KB) - added by photor 5 years ago.
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_kde_kdelibs4/kdelibs4/main.log

Download all attachments as: .zip

Change History (14)

Changed 5 years ago by photor

Attachment: main.log.zip added

/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_kde_kdelibs4/kdelibs4/main.log

comment:1 Changed 5 years ago by kencu (Ken)

Yep, it is blowing up when trying to build against openssl 1.1.1.

This one could be harder to fix, I'm afraid.

comment:2 Changed 5 years ago by kencu (Ken)

Owner: set to NicosPavlov
Port: kdelibs4 added
Status: newassigned

comment:3 Changed 5 years ago by kencu (Ken)

Description: modified (diff)
Summary: Failed to build kdelibs4 on mac os x 10.10kdelibs4 @4.14.3_14: build failure against openssl 1.1.1

comment:4 Changed 5 years ago by kencu (Ken)

Cc: RJVB added

Rene -- any ideas here?

comment:5 Changed 5 years ago by NicosPavlov

I had a rapid look in KDE's git repositories, and I could not find any patch for openssl 1.1, but I found a patch at https://aur.archlinux.org/cgit/aur.git/tree/kdelibs-openssl-1.1.patch?h=kdelibs that seems to do the trick. I did not try it extensively, but kdelibs4 builds in that case.

If there is not objection, I'll update the Portfile to include that patch later. For what I remember of KDE4, this should also hopefully let most of KDE work, as kdelibs4 provides the interface for openssl that most dependents then use.

comment:6 Changed 5 years ago by RJVB (René Bertin)

Strange that this wasn't caught earlier!

I hope to be able to migrate my own MacStrop tree to OSSL 1.1x over the coming week (hopefully it won't take me the entire week...).

It would stand to reason that a patch for KDE4 would have to come from a distro that also patched Qt4 and not from KDE themselves as they dropped support for the KDE4 libraries years ago.

Or did they? Part of the KDE4 Libraries lives on in the KDELibs4Support framework which contains a number of the old APIs that did not (yet) move to one of the other frameworks (think of them as the "grown up" ones?). And indeed there is this: https://cgit.kde.org/kdelibs4support.git/commit/?id=9a990c69c606126bcd60cd7718462aec2a92460d which presumably can be used as a reference to compare the Arch patch against.

Version 0, edited 5 years ago by RJVB (René Bertin) (next)

comment:7 Changed 5 years ago by tehcog (tehcog)

Cc: tehcog added

comment:8 Changed 5 years ago by StanSanderson

Cc: StanSanderson added

comment:9 Changed 5 years ago by mopihopi

Cc: mopihopi added

comment:10 Changed 5 years ago by NateAsir

Cc: NateAsir added

comment:11 Changed 5 years ago by RJVB (René Bertin)

@Nicos, any news? Did the patch apply cleanly for you? In my case I'll need to touch another patch and/or reinplace that changes paths (sic) in kopenssl.cpp . Should be trivial but I need to get around to figuring it out.

comment:12 Changed 5 years ago by NicosPavlov

Sorry, I indeed left that out. I am afraid the patch you sent does not apply cleanly at all. For what I could see, it is due to the fact that it is based on a git version that is different from the one we have currently.

On the other hand, the patch I found cleanly applies, so I would tend to use this one.

comment:13 Changed 5 years ago by Nicolas Pavillon <pavillon.nicolas@…>

Resolution: fixed
Status: assignedclosed

In c2af23c23a35af470c81f90538efdaffac799c2c/macports-ports (master):

kdelibs4: fix build with openssl 1.1 (fixes #58970)

Note: See TracTickets for help on using tickets.