linux-qemu-guest (6362B)
1 #!/usr/bin/env pthbs-build 2 #+busybox.379b7b2d8316b3678245563c8e592d71e6c380bc22a735c30c1c0e6f8f60caf3 3 #+busybox-bzip2.4788e6edf9eeb73c7c665238a23aeed4703f8e25ab101509aee01440865ccdb1 4 #+busybox-gzip.4fc908cacf4533192819578a079617c0cbe879b8ebd3e2140d896b067d3a574c 5 #+busybox-lzop.e6e42a1a8451a4b845355899c9cd49efea2e395a0ef0c6ae7099103213a7bf4f 6 #+busybox-unzip.93b5e83122059c87a2ddf489cdc7381bb80288630c508c218c2cfbadff524784 7 #+busybox-xz.34137cc6ac8d23bf1bf5979b7fd047d4f50b34be07cd6ab636368952a199368d 8 #+busybox-cpio.de88944ccff44a1f3abe06c42f83492a7e080de89fba27aadf5fe1a40e830cae 9 #+busybox-dpkg.17e445a8089bc61db749a44c665597ecac3f21c4088daaa024f574412eb4d704 10 #+busybox-rpm.669ed61ee218bc72206e069c896f392a025c88772ceb92ecb37b01ab0765baf8 11 #+busybox-tar.15f67670238651149114006ae79359f24e1fa3c62be2e229a48f1334747ba413 12 #+busybox-ed.78c51627a372c5b2ad3d046d0e77f341ae7c79917c4a16ca8abba284e7472cb7 13 #+busybox-sed.8782396ae5c7b6e7d6bc8a93a7cff9912e6427e3d919dd5e5b00d1813ae88caf 14 #+busybox-vi.e661d8eb052fbeebdd3be36ff6bd27651a7e59c857dad05c8633589790caa38c 15 #+busybox-xxd.d2dc96e92cfdafae2c91d6fe897f42fdccae2dbc8b2d79f31eccc49d4e3a2d68 16 #+busybox-process-extra.993cfd65eae2892ecb3fdfbece44b11e7ff6caa78f73e9f22bc2c97e7cd8a267 17 #+busybox-procps.51ea8cb23d5eb1498f9167cc80b97c1a873758a8c1a7293079f50a2365466a71 18 #+busybox-psmisc.ff1f9cf00f4c448946acb65d52b3b598e0495822af70b1504720cadf559e2090 19 #+busybox-ash.7d10753f118afb2568e9f950c9cffa559b053a9b3ea516d6b46c3c73ebb6f8d8 20 #+busybox-bc.c595636f103108c81f0ae55d2bf10d7cbc06ef1455a8353fcf04e42e765780a8 21 #+busybox-coreutils.6b8071260ab4297f0e71013e42ac2a1a83fa99d92378d181ba49003fd349134a 22 #+busybox-coreutils-extra.fc1b0766c881ee461d36c386833909553fcb0c31a547bfb563a7c6a50206bdcd 23 #+busybox-daemontools.97aad28bbe5f38cff29db16c0f0d21e2fdc931825f683137df9bb57ef3a9b628 24 #+busybox-grep.261a809c35cb58acc896143c2a81406a097f5870e02ce9906953181ef6b4c72b 25 #+busybox-misc.5c2c025f1b74b9243a0128cd3f10dd1577b5ae123f53244d8e6895d4bdbd161d 26 #+busybox-sh.25a9438d8449ade9c98af61b14af5711990dd002462a046b13b61969634c4d94 27 #+busybox-util-linux-unpriv.4ea1c8c8746d7e80d36dea8924c576bc9666905b461dd543ceb5595394406c97 28 #+busybox-modutils.e3648cc66d2a6452f817e0fbd6aab21991df354010962bf69fa4d1dd1a38e123 29 #+gnu-make.31d90a55d6506852f9784f6f6febf0d843f8051f63bc18795fd5275baa369f50 30 #+musl-cross-make.74cd95cd7bd1db21d28d9a8579d924d588b9cbfd0f9744c0fb890188d71646aa 31 #+findutils.fd366384c1f4cac901fab56c88fa7cb2fb8d971fe1ee1ebaa4c41466f37a2c67 32 #+diffutils.ab73a7cef21b2bb9fb17c0c9117d643f832adcebdd63fe4f63f7351856be90ee 33 #+patch.9f797bc59fd95c01d8139ed7ae4e98ac46c7e94fb8d66509f86f5620714d03c0 34 #+flex.1108ea92b5d0a289d5884ebb2df2398eed87d0f2898feedc18af4d85dcb5255d 35 #+bison.8878bfa3e199ad13de1c2932195a8654f3793729b04c6dc0f70bb57cb3697b40 36 #+rsync.3d0a477167789eb4a71f9b027e9f02614fc0f4f4e4d1f13690ecb4811deb6907 37 #+zstd.47e57cb2d8c327bf55c48e3e1a8dabdd79b82431c34ac1d86997c12802f93b8d 38 #+libelf.7c8f7195b1e499d6afc6bf4af2080a16814f25f4d2e10b1bfa39168ded98192f 39 #+pkgconf-pkg-config.e61a83028581fdc1c99b8e2215a1c3a93637aedf315899811044cfa21d2522f7 40 #+nawk.d6c1a6fd67ebccb4cb1b8062bed80778ee976f5a62370e60fcbc443257a78cd9 41 #@untar:-J:sha256:7586962547803be7ecc4056efc927fb25214548722bd28171172f3599abb9764:. 42 #@sha256:cc2633ee136db0283d4faf7c27c890641e90cd835fc3adb19eaf0569e4078867:linux.config 43 #@sha256:ff3ddd131d73fee6838b11a6c4773bdb85c5f60fdd4b9ac4120ced021c341417:noobjtool.patch 44 45 46 # - build script start - 47 48 49 prefix=/home/ccx/versions/$pthbs_package 50 dest=${pthbs_destdir%/}${prefix} 51 cd 'linux-6.15' 52 53 patch -p1 -N <../noobjtool.patch 54 55 56 export CPATH="$pthbs_build_environment/include" 57 58 cp -v ../linux.config .config 59 make olddefconfig 60 diff -u ../linux.config .config || true 61 62 63 64 make -j${JOBS:-1} -l$((1+${JOBS:-1})) \ 65 V=1 \ 66 HOSTLDFLAGS="-static -L$pthbs_build_environment/library" \ 67 HOSTCFLAGS="-L$pthbs_build_environment/library" 68 69 70 mkdir -p "${dest}/doc/linux" "${dest}/boot" 71 cp -v .config "${dest}/config" 72 mv Documentation/* "${dest}/doc/linux" 73 make modules_install install \ 74 INSTALL_MOD_PATH="${dest}/kernel" \ 75 INSTALL_MOD_STRIP=1 \ 76 INSTALL_PATH="${dest}/boot" \ 77 INSTALL_DTBS_PATH="${dest}/boot/dtbs" 78 79 # remove dangling symlinks 80 module_dir="${dest}/kernel/lib/modules/6.15.0" 81 rm -f "$module_dir/build" "$module_dir/source" 82 ls -lhA "$module_dir" 83 84 85 86 87 88 cd "$pthbs_destdir/home/ccx/versions/$pthbs_package" 89 find -type d -o -print | awk -F/ ' 90 BEGIN { 91 kernel_name="6.15.0" 92 x["./boot/vmlinuz"]=1 93 x["./boot/System.map"]=1 94 x["./kernel/lib/modules/" kernel_name "/modules.alias"]=1 95 x["./kernel/lib/modules/" kernel_name "/modules.builtin"]=1 96 x["./kernel/lib/modules/" kernel_name "/modules.dep"]=1 97 x["./kernel/lib/modules/" kernel_name "/modules.order"]=1 98 x["./kernel/lib/modules/" kernel_name "/modules.symbols"]=1 99 } 100 101 function r1(s) { 102 sub("^[.]/[^/]*", ".", s) 103 return s 104 } 105 function s1(repl, s) { 106 sub("^[.]/[^/]*", "./"repl, s) 107 return s 108 } 109 function link(src) { 110 x[$0]=0 111 printf "%s\t%s\n", $0, src 112 printf "genlinks >>%s\t%s<<\n", $0, src >>"/dev/stderr" 113 } 114 $1!="."{exit 1} 115 116 117 $2 == "boot" { link($0); next } 118 $2 == "lib" && $3 == "modules" { exit 3 } # make sure kernel modules do not mix with userspace libraries 119 function mod_path(s) { 120 sub("^[.]/kernel/lib/", "./kernel/", s) 121 return s 122 } 123 $2 == "kernel" && $3 == "lib" && $4 == "modules" { link(mod_path($0)); next } 124 125 $2 == "config" { link($0); next } 126 $2 == "keys" { link($0); next } 127 $2 == "zsh" { link($0); next } 128 $2 == "env" { link($0); next } 129 $2 == "command" { link($0); next } 130 $2 == "bin" { link(s1("command", $0)); next } 131 132 $2 == "library.so" { link($0); next } 133 $2 == "library" { link($0); next } 134 $2 == "lib" && $NF ~ /\.l?a$/ { link(s1("library", $0)); next } 135 $2 == "lib" && $NF ~ /\.so(\..*)?$/ { link(s1("library.so", $0)); next } 136 137 $2 == "share" && $3 ~ /^(info|man|doc|icons|terminfo)$/ { link(r1($0)); next } 138 139 $2 == "man" { link($0); next } 140 $2 == "info" { link($0); next } 141 $2 == "doc" { link($0); next } 142 $2 == "icons" { link($0); next } 143 $2 == "terminfo" { link($0); next } 144 $2 == "data" { link($0); next } 145 $2 == "include" { link($0); next } 146 147 { printf "genlinks ##%s## skipped\n", $0 >>"/dev/stderr" } 148 149 END { 150 for(fname in x) { printf "DEBUG: x[\"%s\"]=\"%s\"\n", fname, x[fname] >"/dev/stderr" } 151 for(fname in x) { 152 if(x[fname]) { 153 printf "ERROR: missing expected file \"%s\"\n", fname >"/dev/stderr" 154 exit 3 155 } 156 } 157 }' >.install-links.new 158 mv .install-links.new .install-links 159