Skip to content

Commit 8b8b95f

Browse files
authored
unicornscan: fix source and build errors (#4787)
* unicornscan: fix source and build errors * Update to-release * Update PKGBUILD * Update PKGBUILD
1 parent c9f4f34 commit 8b8b95f

File tree

2 files changed

+33
-25
lines changed

2 files changed

+33
-25
lines changed

lists/to-release

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
unicornscan

packages/unicornscan/PKGBUILD

Lines changed: 32 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -2,43 +2,50 @@
22
# See COPYING for license details.
33

44
pkgname=unicornscan
5-
pkgver=0.4.7
6-
pkgrel=9
7-
groups=('blackarch' 'blackarch-scanner')
5+
pkgver=v0.4.10.r5.gf110f0d
6+
pkgrel=1
87
pkgdesc='A new information gathering and correlation engine.'
9-
url='http://www.unicornscan.org/'
10-
depends=('libpcap' 'postgresql-libs' 'geoip' 'libdnet' 'libltdl')
11-
makedepends=('flex' 'bison')
12-
license=('GPL')
138
arch=('x86_64' 'aarch64')
14-
source=("http://downloads.sourceforge.net/project/osace/unicornscan/unicornscan%20-%200.4.7%20source/unicornscan-$pkgver-2.tar.bz2")
15-
sha512sums=('e952bad280b0f926cca2eb0dd960114f45da497f56c4a20a939b42eefb0c515c0613ca7271709778f83a8de5819a64c42616e38a73ef67fe08c44157c812d230')
16-
17-
build() {
18-
cd "$pkgname-$pkgver"
9+
groups=('blackarch' 'blackarch-scanner')
10+
url='https://github.com/robertelee78/unicornscan'
11+
license=('GPL-2.0-or-later')
12+
depends=('libpcap' 'postgresql-libs' 'libdnet' 'libltdl' 'libmaxminddb')
13+
makedepends=('git' 'flex' 'bison')
14+
source=("git+https://github.com/robertelee78/$pkgname.git")
15+
sha512sums=('SKIP')
16+
17+
pkgver() {
18+
cd $pkgname
19+
20+
( set -o pipefail
21+
git describe --long --tags --abbrev=7 2>/dev/null |
22+
sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
23+
printf "%s.%s" "$(git rev-list --count HEAD)" \
24+
"$(git rev-parse --short=7 HEAD)"
25+
)
26+
}
1927

20-
# prevent crashing geoip dependency
21-
export LDFLAGS="${LDFLAGS/--as-needed,/}"
28+
prepare() {
29+
cd "$pkgname"
2230

23-
if [[ "$CARCH" == "i686" || "$CARCH" == "x86_64" ]];
24-
then
25-
./configure CFLAGS="$CFLAGS -D_GNU_SOURCE" --prefix=/usr --sysconfdir=/etc \
26-
--localstatedir=/var --with-pgsql --with-geoip
31+
if [[ "$CARCH" == "i686" || "$CARCH" == "x86_64" ]]; then
32+
./configure CFLAGS="$CFLAGS -D_GNU_SOURCE" --prefix=/usr \
33+
--sysconfdir=/etc --localstatedir=/var --with-pgsql
2734
else
28-
./configure CFLAGS="$CFLAGS -D_GNU_SOURCE" --prefix=/usr --sysconfdir=/etc \
29-
--localstatedir=/var --with-pgsql --with-geoip --build=arm
35+
./configure CFLAGS="$CFLAGS -D_GNU_SOURCE" --prefix=/usr \
36+
--sysconfdir=/etc --localstatedir=/var --with-pgsql --build=arm
3037
fi
38+
}
39+
40+
build() {
41+
cd "$pkgname"
3142

3243
make
3344
}
3445

3546
package() {
36-
cd "$pkgname-$pkgver"
47+
cd "$pkgname"
3748

3849
make DESTDIR="$pkgdir" install
39-
40-
cd "$pkgdir/etc/$pkgname"
41-
42-
ln -s /usr/share/GeoIP/GeoIP.dat GeoIP.dat
4350
}
4451

0 commit comments

Comments
 (0)