~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/scripts/package/PKGBUILD

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /scripts/package/PKGBUILD (Version linux-6.11.5) and /scripts/package/PKGBUILD (Version linux-5.2.21)


  1 # SPDX-License-Identifier: GPL-2.0-only           
  2 # Maintainer: Thomas Weißschuh <linux@weisssch    
  3 # Contributor: Jan Alexander Steffens (heftig)<    
  4                                                   
  5 pkgbase=${PACMAN_PKGBASE:-linux-upstream}         
  6 pkgname=("${pkgbase}" "${pkgbase}-api-headers"    
  7 if grep -q CONFIG_MODULES=y include/config/aut    
  8         pkgname+=("${pkgbase}-headers")           
  9 fi                                                
 10 pkgver="${KERNELRELEASE//-/_}"                    
 11 # The PKGBUILD is evaluated multiple times.       
 12 # Running scripts/build-version from here woul    
 13 pkgrel="${KBUILD_REVISION}"                       
 14 pkgdesc='Upstream Linux'                          
 15 url='https://www.kernel.org/'                     
 16 # Enable flexible cross-compilation               
 17 arch=(${CARCH})                                   
 18 license=(GPL-2.0-only)                            
 19 makedepends=(                                     
 20         bc                                        
 21         bison                                     
 22         cpio                                      
 23         flex                                      
 24         gettext                                   
 25         kmod                                      
 26         libelf                                    
 27         openssl                                   
 28         pahole                                    
 29         perl                                      
 30         python                                    
 31         rsync                                     
 32         tar                                       
 33 )                                                 
 34 options=(!debug !strip !buildflags !makeflags)    
 35                                                   
 36 build() {                                         
 37         # MAKEFLAGS from makepkg.conf override    
 38         # Bypass this override with a custom v    
 39         export MAKEFLAGS="${KBUILD_MAKEFLAGS}"    
 40         cd "${objtree}"                           
 41                                                   
 42         ${MAKE} KERNELRELEASE="${KERNELRELEASE    
 43 }                                                 
 44                                                   
 45 _package() {                                      
 46         pkgdesc="The ${pkgdesc} kernel and mod    
 47                                                   
 48         export MAKEFLAGS="${KBUILD_MAKEFLAGS}"    
 49         cd "${objtree}"                           
 50         local modulesdir="${pkgdir}/usr/${MODL    
 51                                                   
 52         echo "Installing boot image..."           
 53         # systemd expects to find the kernel h    
 54         # https://github.com/systemd/systemd/c    
 55         install -Dm644 "$(${MAKE} -s image_nam    
 56                                                   
 57         # Used by mkinitcpio to name the kerne    
 58         echo "${pkgbase}" > "${modulesdir}/pkg    
 59                                                   
 60         echo "Installing modules..."              
 61         ${MAKE} INSTALL_MOD_PATH="${pkgdir}/us    
 62                 DEPMOD=true modules_install       
 63                                                   
 64         if [ -d "${srctree}/arch/${SRCARCH}/bo    
 65                 echo "Installing dtbs..."         
 66                 ${MAKE} INSTALL_DTBS_PATH="${m    
 67         fi                                        
 68                                                   
 69         # remove build link, will be part of -    
 70         rm -f "${modulesdir}/build"               
 71 }                                                 
 72                                                   
 73 _package-headers() {                              
 74         pkgdesc="Headers and scripts for build    
 75                                                   
 76         export MAKEFLAGS="${KBUILD_MAKEFLAGS}"    
 77         cd "${objtree}"                           
 78         local builddir="${pkgdir}/usr/${MODLIB    
 79                                                   
 80         echo "Installing build files..."          
 81         "${srctree}/scripts/package/install-ex    
 82                                                   
 83         echo "Installing System.map and config    
 84         cp System.map "${builddir}/System.map"    
 85         cp .config "${builddir}/.config"          
 86                                                   
 87         echo "Adding symlink..."                  
 88         mkdir -p "${pkgdir}/usr/src"              
 89         ln -sr "${builddir}" "${pkgdir}/usr/sr    
 90 }                                                 
 91                                                   
 92 _package-api-headers() {                          
 93         pkgdesc="Kernel headers sanitized for     
 94         provides=(linux-api-headers)              
 95         conflicts=(linux-api-headers)             
 96                                                   
 97         export MAKEFLAGS="${KBUILD_MAKEFLAGS}"    
 98         cd "${objtree}"                           
 99                                                   
100         ${MAKE} headers_install INSTALL_HDR_PA    
101 }                                                 
102                                                   
103 for _p in "${pkgname[@]}"; do                     
104         eval "package_$_p() {                     
105                 $(declare -f "_package${_p#$pk    
106                 _package${_p#$pkgbase}            
107         }"                                        
108 done                                              
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php