commit d52b4c0cacf8a4bb3037ce011e6251db700802c4 Author: BigfootACA Date: Sat Mar 9 02:48:30 2024 +0800 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..350749a --- /dev/null +++ b/.gitignore @@ -0,0 +1,53 @@ +*.rej +*.orig +*.swp +*.save* +*.o +*.a +*.out +*.lib +*.obj +*.dll +*.so +*.exe +*.gch +*.plist +*.mo +*.gmo +*.fd +*.iso +*.img +*.img.* +*.qcow2 +*.vhd +*.vdi +*.vmdk +*.cpio +*.cpio.* +*.ttf +*.ttc +*.pcf +*.pcf.* +*.efi +*.pkg.tar.* +vgcore.* +/build* +initramfs*.* +initrd*.* +System.map* +/cmake-build-* +/.idea +/.vscode +/.cache +CMakeCache.txt +CMakeFiles +Makefile +cmake_install.cmake +node_modules +package.json +package-lock.json +fonts.scale +fonts.dir +/src +/pkg +/qca-swiss-army-knife diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..a2105e7 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,44 @@ +pipeline { + agent { + label 'aarch64 && archlinux' + } + stages { + stage('Download Config') { + steps { + dir('jenkins-utils') { + git 'https://gitlab.classfun.cn:4443/renegade-project/jenkins-utils' + } + } + } + stage('Cleanup packages') { + steps { + sh 'rm -f *.pkg.tar.*' + } + } + stage('Build') { + steps { + sh 'makepkg --config jenkins-utils/makepkg-aarch64.conf --syncdeps --force' + } + } + stage('Signature packages') { + steps { + withCredentials([ + file(credentialsId: 'gpg-file', variable: 'GPG_FILE'), + string(credentialsId: 'gpg-secret', variable: 'GPG_SECRET') + ]) { + sh 'python3 jenkins-utils/sign-pkg.py -d . -k "$GPG_FILE" -p "$GPG_SECRET"' + } + } + } + stage('Upload packages') { + steps { + sh 'python3 jenkins-utils/upload-pkg.py -d . -a aarch64' + } + } + stage('Archive') { + steps { + archiveArtifacts artifacts: '*.pkg.tar.*', fingerprint: true + } + } + } +} diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..58efe13 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,44 @@ +# Maintainer: Jami Kettunen +# Maintainer: BigfootACA + +pkgname="qca-swiss-army-knife" +pkgdesc="Qualcomm Atheros swiss army knife" +pkgver=r274.e9a0327 +pkgrel=1 +arch=("aarch64" "armv7" "x86_64") +url="https://github.com/qca/qca-swiss-army-knife" +license=("custom") +groups=("qcom-icnss-wlan") +depends=("libpciaccess") +optdepends=("python" "perl") +makedepends=("git" "make" "gcc") +source=("git+$url") +md5sums=('SKIP') + +pkgver() { + cd "$srcdir/$pkgname" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +build() { + pushd "$srcdir/$pkgname/tools/edump" + ./autogen.sh + ./configure --prefix=/usr + make + popd + pushd "$srcdir/$pkgname/tools/halregdump" + make + popd + pushd "$srcdir/$pkgname/tools/initvals" + make + popd +} + +package() { + mkdir -pv "$pkgdir/usr/bin" + make -C "$srcdir/$pkgname/tools/edump" DESTDIR="$pkgdir/" install + cp -av "$srcdir/$pkgname/tools/halregdump/hal-reg-dump" "$pkgdir/usr/bin/" + cp -av "$srcdir/$pkgname/tools/initvals/initvals" "$pkgdir/usr/bin/" + cp -av "$srcdir/$pkgname/tools/scripts"/ath*/* "$pkgdir/usr/bin/" + install -Dm644 "$srcdir/$pkgname/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +}