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

add smbclient-ng + python-pefile #4466

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
28 changes: 28 additions & 0 deletions packages/python-pefile/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python-pefile
_pkgname=${pkgname#python-}
pkgver=2024.8.26
pkgrel=1
pkgdesc='Read and work with PE (Portable Executable) files.'
arch=('any')
url='https://github.com/erocarrera/pefile'
license=('MIT')
depends=('python')
makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-wheel')
options=(!emptydirs)
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('62781f2ab84040a13304ce550dd1e943991df152c5f2951281906e837b1659694051a074ff49cd08d5d508e9b70009b56418a4237511c4464c4eba9bda4bccf7')

build() {
cd "$_pkgname-$pkgver"

python -m build --wheel --no-isolation
}

package() {
cd "$_pkgname-$pkgver"

python -m installer --destdir="$pkgdir" dist/*.whl
}
59 changes: 59 additions & 0 deletions packages/smbclient-ng/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=smbclient-ng
_pkgname=smbclientng
pkgver=2.1.7.r5.g4f29b0f
pkgrel=1
pkgdesc='Interact with SMB shares.'
arch=('any')
groups=('blackarch' 'blackarch-networking' 'blackarch-windows')
url='https://github.com/p0dalirius/smbclient-ng'
license=('GPL-3.0-only')
depends=('python'
'impacket-ba'
'python-rich'
'python-charset-normalizer'
'python-pefile')
makedepends=('git' 'python-build' 'python-pip')
source=("git+https://github.com/p0dalirius/$pkgname.git")
sha512sums=('SKIP')

pkgver() {
cd $pkgname

( set -o pipefail
git describe --long --tags --abbrev=7 2>/dev/null |
sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
printf "%s.%s" "$(git rev-list --count HEAD)" \
"$(git rev-parse --short=7 HEAD)"
)
}

build() {
cd $pkgname

python -m build --wheel --outdir="$startdir/dist"
}

package() {
cd $pkgname

pip install \
--verbose \
--disable-pip-version-check \
--no-warn-script-location \
--ignore-installed \
--no-compile \
--no-deps \
--root="$pkgdir" \
--prefix=/usr \
--no-index \
--find-links="file://$startdir/dist" \
$_pkgname

# Alias
install -dm 755 "$pkgdir/usr/bin/"
ln -s "/usr/bin/$_pkgname" "$pkgdir/usr/bin/$pkgname"
}

Loading