Bug 241761 - security/libssh: Update to 0.9.2
Summary: security/libssh: Update to 0.9.2
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Tobias C. Berner
URL: https://www.libssh.org/2019/10/25/lib...
Keywords: buildisok
Depends on:
Reported: 2019-11-06 17:34 UTC by Lorenzo Salvadore
Modified: 2019-12-07 21:31 UTC (History)
3 users (show)

See Also:

libssh.diff - update to 0.9.1 (2.27 KB, patch)
2019-11-06 17:34 UTC, Lorenzo Salvadore
salvadore: maintainer-approval+
Details | Diff
patch for 0.9.2 (3.01 KB, patch)
2019-11-12 14:06 UTC, Steve Wills
salvadore: maintainer-approval-
Details | Diff
libssh - swills with CMAKE_BUILD_TYPE=release (2.99 KB, patch)
2019-11-13 12:08 UTC, Lorenzo Salvadore
salvadore: maintainer-approval-
Details | Diff
libssh - no conditional (2.93 KB, patch)
2019-11-13 12:09 UTC, Lorenzo Salvadore
salvadore: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lorenzo Salvadore freebsd_committer 2019-11-06 17:34:12 UTC
Created attachment 208917 [details]
libssh.diff - update to 0.9.1

Update to 0.9.1.
Changelog: https://www.libssh.org/2019/10/25/libssh-0-9-1/

- Remove unnecessary CMAKE_ARGS= -DWITH_TESTING:BOOL=OFF, as WITH_TESTING option does not exist.
- Replace CMAKE_ARGS= -DWITH_ZLIB:BOOL=ON with an option enabled by default.

The port itself has been tested successfully with poudriere on {11.3,12.1}-RELEASE {i386,amd64}.
I am also testing the ports that depends on it, but this will take some time since my machine is a bit old. If someone wants to help, here is the complete list of dependent ports that need to be tested (and that would need a PORTREVISION bump when the update is commited):

- devel/kio-extras
- net/frr5
- net/bird2
- net/frr6
- net/remmina-plugin-nx
- net/wireshark
- net/x2goclient
- net/remmina
- net/frr7
- net/sshping
- multimedia/kodi
- multimedia/ffmpeg
- net-mgmt/rtrlib
- net-mgmt/netxms
- editors/codelite
- sysutils/tmate
- sysutils/tmate-slave
- ftp/yafc
- security/openvas8-libraries
- security/hydra
Comment 1 Automation User 2019-11-06 18:20:58 UTC
Build info is available at https://gitlab.com/swills/freebsd-ports/pipelines/94150746
Comment 2 Tobias C. Berner freebsd_committer 2019-11-09 11:21:14 UTC
Moin moin

The following is most likely a wronlgy applied substitution by makeplist:
that should most likely be 

mfg Tobias
Comment 3 Tobias C. Berner freebsd_committer 2019-11-09 12:15:54 UTC
devel/kio-extras fails to build with this.
Comment 4 commit-hook freebsd_committer 2019-11-09 12:40:06 UTC
A commit references this bug:

Author: tcberner
Date: Sat Nov  9 12:39:34 UTC 2019
New revision: 517124
URL: https://svnweb.freebsd.org/changeset/ports/517124

  devel/kio-extras: prepare for libssh-0.9.2

  PR:		241761
  Obtained from:	https://phabricator.kde.org/D25170

Comment 5 Tobias C. Berner freebsd_committer 2019-11-09 12:40:36 UTC
There is a 0.9.2 release [1] and a patch to make kio-extras [2] work against that. 
Could you upgrade your diff to 0.9.2?

[1] https://www.libssh.org/2019/11/07/libssh-0-9-2/
[2] https://svnweb.freebsd.org/ports?view=revision&revision=517124
Comment 6 Steve Wills freebsd_committer 2019-11-12 14:06:03 UTC
Created attachment 209101 [details]
patch for 0.9.2

Here's a patch that updates to 0.9.2 and cleans up the REINPLACE_CMD stuff a bit.
Comment 7 Lorenzo Salvadore freebsd_committer 2019-11-13 11:20:02 UTC
(In reply to Steve Wills from comment #6)

Thanks for helping: I am very busy in these days :)

I am looking into your patch. In particular I notice that you add a special post-install target when the STATIC option is enabled: indeed I saw that libssh.a was not installed automatically and your solution should work.

In pkg-plist we probably have to replace %%CMAKE_BUILD_TYPE%% with "release" as suggested in comment #2.

I am unsure about the .if block you introduced in the Makefile: is there a reason you choose to run it only if ${LOCALBASE} is different from "/usr/local"? My impression is that we can run the conditional replacement even in the case ${LOCALBASE}="/usr/local", which would make the Makefile simpler and permit us to include "bsd.port.mk" only again.
Comment 8 Lorenzo Salvadore freebsd_committer 2019-11-13 12:08:54 UTC
Created attachment 209130 [details]
libssh - swills with CMAKE_BUILD_TYPE=release

This is swills patch with the substitution CMAKE_BUILD_TYPE=release.

Tested successfully with poudriere on {11.3,12.1}-RELEASE {i386,amd64}.
Comment 9 Lorenzo Salvadore freebsd_committer 2019-11-13 12:09:58 UTC
Created attachment 209131 [details]
libssh - no conditional

This is the same patch as above, but without the conditional ${LOCALBASE} != "/usr/local".

Tested successfully with poudriere on {11.3,12.1}-RELEASE {i386,amd64}.
Comment 10 Lorenzo Salvadore freebsd_committer 2019-11-13 12:12:24 UTC
Comment on attachment 209101 [details]
patch for 0.9.2

I deny approval for this patch because it has been improved by replacing %%CMAKE_BUILD_TYPE%% with "release" (and maybe also by removing an unneeded condition test).

See the other attachments.
Comment 11 Steve Wills freebsd_committer 2019-11-13 12:20:57 UTC
(In reply to Lorenzo Salvadore from comment #7)
The reason for the conditional is that there's no need to run sed if it's doing nothing, so skip it.
Comment 12 Lorenzo Salvadore freebsd_committer 2019-11-13 19:07:46 UTC
Comment on attachment 209130 [details]
libssh - swills with CMAKE_BUILD_TYPE=release

Thanks for clarifying swills.

Since the conditional block is so simple (only a ${REINPLACE_CMD}), I think it is better to just run it in any case: I think it will not make any difference with respect to performances. On the other hand it makes a simpler Makefile (no .if/.endif block, only 1 .include instead of 2).
Comment 13 Lorenzo Salvadore freebsd_committer 2019-11-26 17:43:06 UTC
All dependent ports have been tested successfully with poudriere on 12.0-RELEASE except for:

- net-mgmt/netxms: the port is broken on 12 and 13; it has been tested successfully on 11.3-RELEASE;

- sysutils/tmate-slave: the port is marked as broken, indipendently from libssh.
Comment 14 Tobias C. Berner freebsd_committer 2019-12-07 21:30:58 UTC
Thanks, committed.

I changed one little thing before committing:
instead of using CMAKE_ARGS.

mfg Tobias
Comment 15 commit-hook freebsd_committer 2019-12-07 21:31:19 UTC
A commit references this bug:

Author: tcberner
Date: Sat Dec  7 21:30:19 UTC 2019
New revision: 519242
URL: https://svnweb.freebsd.org/changeset/ports/519242

  security/libssh: Update to 0.9.2

  PR:		241761
  Submitted by:	Lorenzo Salvadore <phascolarctos@protonmail.ch>  (maintainer)