Abomnation
This commit is contained in:
parent
5723b948cd
commit
cb69821988
5
debian/changelog
vendored
5
debian/changelog
vendored
@ -1,5 +0,0 @@
|
||||
upstream-name (pkgver-pkgrel) distro_codename; urgency=medium
|
||||
|
||||
* Initial release. (Closes: #nnnn) <nnnn is the bug number of your ITP>
|
||||
|
||||
-- ferreo <harderthanfire@gmail.com> Wed, 18 Jan 2023 21:48:14 +0000
|
19
debian/control
vendored
19
debian/control
vendored
@ -1,19 +0,0 @@
|
||||
Source: upstream-name
|
||||
Section: admin
|
||||
Priority: optional
|
||||
Maintainer: name <email>
|
||||
Standards-Version: 4.6.1
|
||||
Build-Depends: debhelper-compat (= 13)
|
||||
Rules-Requires-Root: no
|
||||
|
||||
Package: pkgname1
|
||||
Architecture: linux-any
|
||||
# Delete any of these lines if un-used
|
||||
Depends: ${misc:Depends}, depends
|
||||
Recommends: high priority optdepends
|
||||
Conflicts: conflicts
|
||||
Suggests: low priority optdepends
|
||||
Breaks: also conflicts!?
|
||||
Provides: provides
|
||||
#
|
||||
Description: pkgdesc
|
80
debian/rules
vendored
80
debian/rules
vendored
@ -1,80 +0,0 @@
|
||||
#! /usr/bin/make -f
|
||||
|
||||
## See debhelper(7) (uncomment to enable).
|
||||
## Output every command that modifies files on the build system.
|
||||
export DH_VERBOSE = 1
|
||||
|
||||
## === Set paths env vars ===
|
||||
|
||||
## Source directory, called upon by $(srcdir)
|
||||
srcdir = $(shell debian/scripts/get_pwd.sh)
|
||||
## The Root of package number one, called upon by $(pkgdir1)
|
||||
pkgdir1 = $(srcdir)/debian/pkgdir1
|
||||
## The Root of package number two, you can add as many of these as you like
|
||||
pkgdir2 = $(srcdir)/debian/pkgdir2
|
||||
|
||||
## If building a singular package you can remove the number, and as you guessed you call upon it with $(pkgdir)
|
||||
# pkgdir = $(srcdir)/debian/pkgdir
|
||||
|
||||
## === End end of region ===
|
||||
|
||||
## === the chain of command ===
|
||||
## debuild runs a chain of dh functions in the following order:
|
||||
## dh_testdir
|
||||
## dh_clean
|
||||
## dh_auto_clean
|
||||
## dh_update_autotools_config
|
||||
## dh_autoreconf
|
||||
## dh_auto_configure
|
||||
## dh_prep
|
||||
## dh_build
|
||||
## dh_auto_build
|
||||
## dh_install
|
||||
## dh_auto_install
|
||||
## dh_installdocs
|
||||
## dh_installchangelogs
|
||||
## dh_perl
|
||||
## dh_link
|
||||
## dh_strip_nondeterminism
|
||||
## dh_compress
|
||||
## dh_fixperms
|
||||
## dh_missing
|
||||
## dh_dwz
|
||||
## dh_strip
|
||||
## dh_makeshlibs
|
||||
## dh_shlibdeps
|
||||
## dh_installdeb
|
||||
## dh_gencontrol
|
||||
## but you are most likely to only need to override the following:
|
||||
## dh_clean
|
||||
## dh_auto_configure
|
||||
## dh_build
|
||||
## dh_install
|
||||
|
||||
## === End end of region ===
|
||||
|
||||
## === overriding dh functions ===
|
||||
## by default all dh functions will run a specific command based on the build system selected by "dh $@"
|
||||
## if you have a makefile that does everything you need this is fine,
|
||||
## but most likely you have no MakeFile and you want to add your own commands
|
||||
## Note : overrides must be places above %:
|
||||
## So here's a few examples:
|
||||
|
||||
## overriding dh_clean to make it not delete rust vendor files:
|
||||
#override_dh_clean:
|
||||
# echo "disabled"
|
||||
|
||||
## overriding dh_auto_configure to add custom configs:
|
||||
#override_dh_auto_configure:
|
||||
# $(srcdir)/configure -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_DATADIR=/usr/share -DCMAKE_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu -DBUILD_PLUGIN=OFF
|
||||
|
||||
## overriding dh_install to install files to a package:
|
||||
#override_dh_auto_configure:
|
||||
# mkdir -p $(pkgdir1)/usr/bin
|
||||
# cp $(srcdir)/pikman $(pkgdir1)/usr/bin/
|
||||
|
||||
## === End end of region ===
|
||||
|
||||
## This here will start the build:
|
||||
%:
|
||||
dh $@
|
21
main.sh
21
main.sh
@ -1,14 +1,25 @@
|
||||
#! /bin/bash
|
||||
DRIVER=535
|
||||
|
||||
echo "$(apt-cache show nvidia-driver-$DRIVER | grep Version: | head -n1 | cut -f2 -d":" | cut -f1,2,3 -d"." | cut -f1 -d"-" | tr -d ' ')" > ./nvidia-pikaos-kernel-module/DRIVER
|
||||
echo "$(apt-cache show kernel-pika | grep Depends: | head -n1 | cut -f2 -d":" | cut -f1 -d"," | cut -f3,4 -d"-" | tr -d ' ')" > ./nvidia-pikaos-kernel-module/KERNEL
|
||||
echo "$(apt-cache show nvidia-dkms-535 | grep Version: | head -n1 | cut -f2 -d":" | tr -d ' ')" > ./nvidia-pikaos-kernel-module/DRIVER_VERSION
|
||||
|
||||
cd ./nvidia-pikaos-kernel-module
|
||||
|
||||
chmod +x ./nvidia-pikaos-kernel-module/get_pwd.sh
|
||||
|
||||
echo -e "nvidia-pikaos-kernel-module ($(cat ./DRIVER)-$(cat ./KERNEL)-99pika1.lunar) lunar; urgency=medium\n\n * New Release\n\n -- Ward Nakchbandi <hotrod.master@hotmail.com> Sat, 01 Oct 2022 14:50:00 +0200" > debian/changelog
|
||||
|
||||
echo -e "Source: nvidia-pikaos-kernel-module\nSection: graphics\nPriority: optional\nMaintainer: Ward Nakchbandi <hotrod.master@hotmail.com>\nStandards-Version: 4.6.1\nBuild-Depends: debhelper-compat (= 13), linux-image-$(cat ./KERNEL)-pikaos, linux-headers-$(cat ./KERNEL)-pikaos, dkms, fakeroot\nRules-Requires-Root: no\n\nPackage: nvidia-$(cat ./KERNEL)-module-$DRIVER\nArchitecture: linux-any\nDepends: linux-image-$(cat ./KERNEL)-pikaos, linux-headers-$(cat ./KERNEL)-pikaos, $(apt-cache show nvidia-dkms-$DRIVER | grep Depends: | head -n1 | cut -f2 -d":")\nConflicts: nvidia-dkms-$DRIVER (= $(cat DRIVER_VERSION))\nProvides: nvidia-dkms-$DRIVER (= $(cat DRIVER_VERSION))\nReplaces: nvidia-dkms-$DRIVER (= $(cat DRIVER_VERSION))\nDescription: Prebuilt Nvidia module for PikaOS kernel" > ./debian/control
|
||||
|
||||
|
||||
DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# Clone Upstream
|
||||
mkdir -p ./src-pkg-name
|
||||
cp -rvf ./debian ./src-pkg-name/
|
||||
cd ./src-pkg-name/
|
||||
|
||||
# Get build deps
|
||||
apt-get build-dep ./ -y
|
||||
apt download nvidia-dkms-$DRIVER -y
|
||||
dpkg-deb -x ./nvidia-dkms-$DRIVER*.deb /
|
||||
|
||||
# Build package
|
||||
dpkg-buildpackage --no-sign
|
||||
|
13
nvidia-pikaos-kernel-module/Makefile
Normal file
13
nvidia-pikaos-kernel-module/Makefile
Normal file
@ -0,0 +1,13 @@
|
||||
DRIVER=$(shell cat ${./DRIVER})
|
||||
KERNEL=$(shell cat ${./KERNEL})
|
||||
VERSION=$(shell cat ${./VERSION})
|
||||
CARCH=x86_64
|
||||
|
||||
.PHONY: install
|
||||
all:
|
||||
true
|
||||
|
||||
install:
|
||||
fakeroot dkms build --dkmstree "$(shell ./get_pwd.sh)" -m nvidia/"${DRIVER}" -k "${KERNEL}"
|
||||
install -Dt "$(DESTDIR)/usr/lib/modules/"${KERNEL}"/extramodules" -m644 nvidia/"${DRIVER}"/"${KERNEL}"/"${CARCH}"/module/*
|
||||
find "$(DESTDIR)" -name '*.ko' -exec xz -T1 {} +
|
9
nvidia-pikaos-kernel-module/debian/rules
Normal file
9
nvidia-pikaos-kernel-module/debian/rules
Normal file
@ -0,0 +1,9 @@
|
||||
#! /usr/bin/make -f
|
||||
|
||||
## See debhelper(7) (uncomment to enable).
|
||||
## Output every command that modifies files on the build system.
|
||||
export DH_VERBOSE = 1
|
||||
|
||||
## This here will start the build:
|
||||
%:
|
||||
dh $@
|
0
debian/scripts/get_pwd.sh → nvidia-pikaos-kernel-module/get_pwd.sh
Executable file → Normal file
0
debian/scripts/get_pwd.sh → nvidia-pikaos-kernel-module/get_pwd.sh
Executable file → Normal file
Loading…
Reference in New Issue
Block a user