Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --- PKGBUILD 2015-08-31 22:18:47.000000000 +0200
- +++ PKGBUILD.patched 2015-11-16 01:24:01.540558846 +0100
- @@ -5,6 +5,7 @@
- # Contributor: Mathias Buren <mathias.buren at gmail dot com>
- # Contributor: Benjamin Mtz (Cruznick) <cruznick at archlinux dot us>
- # Contributor: t3kk3n <corp at hush dot ai>
- +# Contributor: Marc Straube <email@marcstraube.de>
- #TODO: Investigate empty dir - /usr/lib/modules/3.12.9-2-ARCH/
- #TODO: Document and finish automation for patching and config
- @@ -12,6 +13,7 @@
- _runkernver=$(uname -r)
- _shortkernver=${_runkernver%.*}
- +_kernelname=$(uname -r | cut -d'-' -f3)
- pkgname=backports-patched
- pkgver=4.2_rc1_1
- @@ -22,7 +24,7 @@
- arch=('i686' 'x86_64')
- license=('GPL')
- depends=('linux')
- -makedepends=('linux-api-headers' "linux-headers>=$_shortkernver")
- +makedepends=('linux-api-headers' "linux-${_kernelname}-headers>=$_shortkernver")
- optdepends=('backports-frag+ack: wl-frag+ack patch')
- install=backports.install
- # Stable and rc? TODO: Check with rc :D | Double %% cuts to the first, single % cuts to the last
- @@ -39,7 +41,7 @@
- warning "Skipping checksum check for snapshots"
- fi
- -_extramodules=extramodules-${_shortkernver}-ARCH
- +_extramodules=extramodules-${_shortkernver}-${_kernelname}
- _kernver=$(cat /usr/lib/modules/${_extramodules}/version) # TODO make this a lower boundary and utilize in reality pacman to get freshest paths. Or make it for specific kernels. Or multiply it over specific kernels ? :3
- _cfgdir="/etc/makepkg.d/${pkgname}/"
- @@ -101,6 +103,28 @@
- .PHONY: modules_install
- EOF
- +# https://dev.openwrt.org/browser/trunk/package/kernel/mac80211/patches/020-backports-do-not-add-debugfs_create_devm_seqfile-on-.patch?rev=46492
- +echo "Patching debugfs.h"
- +patch -p0 <<'EOF'
- +--- backport-include/linux/debugfs.h 2015-07-12 01:29:39.000000000 +0200
- ++++ debugfs.h 2015-11-16 00:45:43.997159897 +0100
- +@@ -5,6 +5,8 @@
- + #include <linux/device.h>
- + #include <generated/utsrelease.h>
- +
- ++#if LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0)
- ++#define debugfs_create_devm_seqfile LINUX_BACKPORT(debugfs_create_devm_seqfile)
- + #if defined(CONFIG_DEBUG_FS)
- + struct dentry *debugfs_create_devm_seqfile(struct device *dev, const char *name,
- + struct dentry *parent,
- +@@ -20,5 +22,6 @@
- + return ERR_PTR(-ENODEV);
- + }
- + #endif /* CONFIG_DEBUG_FS */
- ++#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0) */
- +
- + #endif /* __BACKPORT_DEBUGFS_H_ */
- +EOF
- }
- build() {
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement