summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormio <miyopan@e.email>2024-09-07 03:42:26 +0000
committeromni <omni+alpine@hack.org>2024-09-07 11:45:10 +0000
commitdf80a9ed7657632df9fe8283b3e1fea5983dcc5c (patch)
tree5e53df8cb0ba02155b9dcbe98c1923acc2eae144
parent7d885ba7dd3a0358dd0b9d6967444637e7eaa6e0 (diff)
downloadaports-df80a9ed7657632df9fe8283b3e1fea5983dcc5c.zip
community/scanssh: fix build with gcc 14
-rw-r--r--community/scanssh/APKBUILD7
-rw-r--r--community/scanssh/gcc14.patch20
2 files changed, 25 insertions, 2 deletions
diff --git a/community/scanssh/APKBUILD b/community/scanssh/APKBUILD
index d6938778503..40b2cd68e46 100644
--- a/community/scanssh/APKBUILD
+++ b/community/scanssh/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: fossdd <fossdd@pwned.life>
pkgname=scanssh
pkgver=2.1.3.1
-pkgrel=2
+pkgrel=3
pkgdesc="Fast SSH server and open proxy scanner"
url="https://github.com/ofalk/scanssh"
arch="all"
@@ -10,7 +10,9 @@ license="BSD-3-Clause"
options="!check" # no testsuite
makedepends="autoconf automake libpcap-dev libevent-dev libdnet-dev"
subpackages="$pkgname-doc"
-source="$pkgname-$pkgver.tar.gz::https://github.com/ofalk/scanssh/archive/$pkgver.tar.gz"
+source="$pkgname-$pkgver.tar.gz::https://github.com/ofalk/scanssh/archive/$pkgver.tar.gz
+ gcc14.patch
+ "
prepare() {
default_prepare
@@ -33,4 +35,5 @@ package() {
sha512sums="
970cbb03aa44fcef62aa03132335e6ecedb083cee98a360b3d781efc8c2d3c169f70c17837b1faaf9ceaa2691a7c619174a9bb185146af50188eaceda5d14adb scanssh-2.1.3.1.tar.gz
+72b136f29ce041a7111be2896a5471469eab90c8c8fdfd4eb05fd294796afd9804adc3dc07c894a559cbf16679184ce00b713b0394e9a9a399b587d7f6daa231 gcc14.patch
"
diff --git a/community/scanssh/gcc14.patch b/community/scanssh/gcc14.patch
new file mode 100644
index 00000000000..543786e786d
--- /dev/null
+++ b/community/scanssh/gcc14.patch
@@ -0,0 +1,20 @@
+Fix -Wimplicit-function-declaration error with gcc 14.
+
+Error:
+
+```
+arc4random.c:19:25: error: implicit declaration of function 'time'
+[-Wimplicit-function-declaration]
+ 19 | srandom(time(NULL));
+ | ^~~~
+```
+
+--- scanssh-2.1.3.1-origin/arc4random.c
++++ scanssh-2.1.3.1/arc4random.c
+@@ -1,5 +1,6 @@
+ #include <sys/types.h>
+ #include <stdlib.h>
++#include <time.h>
+
+ #include "config.h"
+