Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added: sentrypeer #3903

Merged
merged 11 commits into from
Jul 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions lists/to-release
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
sentrypeer
libosip2
opendht-c
36 changes: 36 additions & 0 deletions packages/libosip2/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

# Maintainer: Brian Bidulock <[email protected]>
# Contributor: Sergej Pupykin <[email protected]>
# Contributor: Michal Hybner <[email protected]>

pkgname=libosip2
epoch=1
pkgver=5.3.1
pkgrel=1
pkgdesc="an implementation of SIP"
arch=('x86_64' 'aarch64')
url="http://www.gnu.org/software/osip/"
license=('LGPL')
depends=(glibc)
options=(!emptydirs)
validpgpkeys=('34C3985D068879312FE23C8BB5902A3AD90A5421')
source=(https://ftp.gnu.org/gnu/osip/libosip2-${pkgver/_/-}.tar.gz)
sha512sums=('cd9db7a736cca90c6862b84c4941ef025f5affab8af9bbc02ce0dd3310a2c555e0922c1bfa72d8ac08791fa1441bbcc30b627d52ca8b51f3471573a10ac82a00')

build() {
cd "$srcdir"/libosip2-${pkgver/_/-}/

./configure --prefix=/usr --disable-semaphore --enable-sysv
# Fight unused direct deps
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0 /g' libtool
make
}

package() {
cd "$srcdir"/libosip2-${pkgver/_/-}/

make DESTDIR="$pkgdir" install
}

56 changes: 56 additions & 0 deletions packages/opendht-c/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=opendht-c
pkgver=v2.6.0rc5.r8.g3e888d8e
pkgrel=1
epoch=1
pkgdesc="C++17 Distributed Hash Table implementation."
arch=('x86_64' 'aarch64')
url='https://github.com/savoirfairelinux/opendht'
license=('GPL3')
depends=('argon2' 'asio' 'gnutls' 'jsoncpp' 'nettle' 'readline')
makedepends=('cmake' 'cython' 'fmt' 'git' 'http-parser' 'msgpack-cxx' 'python' 'python-setuptools' 'restinio' 'samurai')
checkdepends=('cppunit-dev')
provides=('opendht')
conflicts=('opendht')
source=("git+https://github.com/savoirfairelinux/${pkgname%-c}.git")
sha512sums=('SKIP')

pkgver() {
cd "${pkgname%-c}"

git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
cd "${srcdir}/${pkgname%-*}"

install -d build
}

build() {
cd "${srcdir}/${pkgname%-c}/build"

cmake .. \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DBUILD_SHARED_LIBS=True \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DOPENDHT_C=ON \
-DOPENDHT_TOOLS=ON \
-DOPENDHT_PYTHON=ON \
-DOPENDHT_HTTP=ON \
-DOPENDHT_PUSH_NOTIFICATIONS=ON \
-DBUILD_TESTING="$(want_check && echo ON || echo OFF)" \
$CMAKE_CROSSOPTS .
make
}

package() {
cd "${srcdir}/${pkgname%-c}/build"

make DESTDIR="${pkgdir}" install
install -D -m644 ../README.md "${pkgdir}/usr/share/doc/opendht/README.md"
}

44 changes: 44 additions & 0 deletions packages/sentrypeer/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=sentrypeer
pkgver=v3.0.0.r14.g02173c8
pkgrel=1
pkgdesc='Protect SIP Servers from bad actors.'
arch=('x86_64' 'aarch64')
groups=('blackarch' 'blackarch-defensive')
url='https://github.com/SentryPeer/SentryPeer'
license=('GPL')
depends=('curl' 'opendht-c' 'jansson' 'libmicrohttpd' 'libosip2' 'pcre2' 'sqlite' 'uuid')
makedepends=('autoconf-archive' 'cmocka' 'git')
source=("git+https://github.com/SentryPeer/$pkgname")
sha512sums=('SKIP')

pkgver() {
cd $pkgname

git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
cd "$pkgname"

./bootstrap.sh
./configure --prefix=/usr
}

build() {
cd "$pkgname"

make
make check
}

package() {
cd "$pkgname"

make DESTDIR="$pkgdir" install

install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" *.md
}