Kaydet (Commit) 0620573c authored tarafından Suleyman Poyraz's avatar Suleyman Poyraz

Linux kernel 5.2.14 added package tree.

üst 25d32dd6
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt
from inary.actionsapi import shelltools
from inary.actionsapi import autotools
from inary.actionsapi import inarytools
from inary.actionsapi import get
def setup():
# Remove source files
shelltools.unlink("usbdux/*dux")
shelltools.unlink("*/*.asm")
# These + a lot of other firmware are shipped within alsa-firmware
for fw in ("ess", "korg", "sb16", "yamaha"):
shelltools.unlinkDir(fw)
def build():
autotools.make()
def install():
autotools.rawInstall("DESTDIR=%s" % get.installDIR())
<?xml version="1.0"?>
<!DOCTYPE INARY SYSTEM "http://www.sulin.org/projeler/inary/inary-spec.dtd">
<INARY>
<Source>
<Name>linux-firmware</Name>
<Homepage>http://git.kernel.org/cgit/linux/kernel/git/firmware/linux-firmware.git/</Homepage>
<Packager>
<Name>Suleyman Poyraz</Name>
<Email>zaryob.dev@gmail.com</Email>
</Packager>
<License>ipw2100-fw</License>
<License>ipw2200-fw</License>
<License>freedist</License>
<License>GPLv2+</License>
<License>GPLv2</License>
<License>MIT</License>
<IsA>data</IsA>
<Summary>Firmware files used by the Linux kernel</Summary>
<Description>linux-firmware contains different firmware files required for some devices to operate correctly.</Description>
<Archive sha1sum="59004c56ac522ac14b61353ea456bd7adbaec15e" type="targz">https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/snapshot/linux-firmware-20190815.tar.gz</Archive>
</Source>
<Package>
<Name>linux-firmware</Name>
<Files>
<Path fileType="data">/lib/firmware</Path>
<Path fileType="doc">/usr/share/doc</Path>
</Files>
<BuildFlags>
<Flag>noDelta</Flag>
</BuildFlags>
</Package>
<History>
<Update release="1">
<Date>2019-09-11</Date>
<Version>20190815</Version>
<Comment>First release</Comment>
<Name>Suleyman Poyraz</Name>
<Email>zaryob.dev@gmail.com</Email>
</Update>
</History>
</INARY>
<INARY>
<Source>
<Name>alsa-lib</Name>
<Summary xml:lang="tr">Gelişmiş Linux Ses Mimarisi kütüphanesi</Summary>
<Description xml:lang="tr">alsa-lib, ses aygıtlarına erişim sağlayarak kolayca uygulama yazılmasını sağlayan bir kütüphanedir.</Description>
</Source>
<Package>
<Name>alsa-lib-devel</Name>
<Summary xml:lang="tr">alsa-lib için geliştirme dosyaları</Summary>
</Package>
<Package>
<Name>alsa-lib-32bit</Name>
<Summary xml:lang="tr">alsa-lib için 32-bit paylaşımlı kitaplıklar</Summary>
</Package>
</INARY>
<INARY>
<Name>kernel</Name>
</INARY>
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt
from inary.actionsapi import kerneltools
from inary.actionsapi import shelltools
from inary.actionsapi import autotools
from inary.actionsapi import inarytools
from inary.actionsapi import get
NoStrip = ["/lib", "/boot"]
shelltools.export("KBUILD_BUILD_USER", "sulin")
shelltools.export("KBUILD_BUILD_HOST", "uludag")
shelltools.export("PYTHONDONTWRITEBYTECODE", "1")
def setup():
kerneltools.configure()
def build():
kerneltools.build(debugSymbols=False)
def install():
kerneltools.install()
# add objtool for external module building and enabled VALIDATION_STACK option
inarytools.insinto("/usr/src/linux-headers-%s/tools/objtool" % get.srcVERSION(), "%s/tools/objtool/objtool" % get.curDIR())
# Install kernel headers needed for out-of-tree module compilation
kerneltools.installHeaders()
kerneltools.installLibcHeaders()
# Generate some module lists to use within mkinitramfs
shelltools.system("./generate-module-list %s/lib/modules/%s" % (get.installDIR(), kerneltools.__getSuffix()))
#mkinitcpio default config
inarytools.dodir("/etc/mkinitcpio.d")
shelltools.touch("linux.preset")
shelltools.echo("linux.preset", "# mkinitcpio preset file for the 'linux' package\n" +
'ALL_config="/etc/mkinitcpio.conf"\n'+
'ALL_kver="/boot/kernel-%s"\n\n'% get.srcVERSION() +
"PRESETS=('default' 'fallback') \n\n" +
'#default_config="/etc/mkinitcpio.conf"\n' +
'default_image="/boot/initramfs-%s.img"\n'% get.srcVERSION() +
'#default_options=""\n\n' +
'#fallback_config="/etc/mkinitcpio.conf"\n'+
'fallback_image="/boot/initramfs-%s-fallback.img"\n'% get.srcVERSION() +
'fallback_options="-S autodetect"\n')
inarytools.insinto("/etc/mkinitcpio.d", "linux.preset")
#!/bin/bash
# Generate modules.{networking, block, drm, modesetting}
# lists for further usage
# Adapted from Fedora
#
# Ozan Caglayan (C) 2010
collect_modules_list()
{
sed -r -n -e "s/^([^ ]+) \\.?($2)\$/\\1/p" $TMP_MODUNDEF |
LC_ALL=C sort -u > modules.$1
}
MOD_DIR=$1
TMP_MODNAMES=`mktemp`
TMP_MODUNDEF=`mktemp`
find $MOD_DIR -name "*.ko" -type f > $TMP_MODNAMES
cat $TMP_MODNAMES | xargs nm -upA |
sed -n 's,^.*/\([^/]*\.ko\): *U \(.*\)$,\1 \2,p' > $TMP_MODUNDEF
# Start collecting module lists
# based on undefined symbols
cd $MOD_DIR
collect_modules_list networking \
'register_netdev|ieee80211_register_hw|usbnet_probe|phy_driver_register'
collect_modules_list block \
'ata_scsi_ioctl|scsi_add_host|scsi_add_host_with_dma|blk_init_queue|register_mtd_blktrans|scsi_esp_register|scsi_register_device_handler'
collect_modules_list drm \
'drm_open|drm_init'
collect_modules_list modesetting \
'drm_crtc_init'
# Clean temporary files
rm -f $TMP_MODNAMES $TMP_MODUNDEF
<?xml version="1.0" ?>
<!DOCTYPE INARY SYSTEM "https://gitlab.com/sulinos/sulinproject/inary/raw/master/inary-spec.dtd">
<INARY>
<Source>
<Name>linux</Name>
<Homepage>http://www.kernel.org</Homepage>
<Packager>
<Name>Süleyman POYRAZ</Name>
<Email>zaryob.dev@gmail.com</Email>
</Packager>
<License>GPLv2</License>
<IsA>kernel</IsA>
<PartOf>kernel.linux</PartOf>
<Summary>The Linux kernel (the core of the Linux operating system) for Sulin</Summary>
<Description>kernel contains the Linux kernel, the core of any Linux operating system. The kernel handles the basic functions of the operating system: memory allocation, process allocation, device input and output, etc.</Description>
<Archive sha1sum="5922cd5f5d3decf6e39beadc5efce073aae474a2" type="tarxz">https://www.kernel.org/pub/linux/kernel/v5.x/linux-5.2.14.tar.xz</Archive>
<AdditionalFiles>
<AdditionalFile permission="0755" target="generate-module-list">scripts/generate-module-list</AdditionalFile>
<AdditionalFile permission="0755" target=".config">configs/kernel-x86_64-config-5.2.14</AdditionalFile>
</AdditionalFiles>
<BuildDependencies>
<Dependency>bc</Dependency>
<Dependency>cpio</Dependency>
<Dependency>docbook-xsl</Dependency>
<Dependency>diffutils</Dependency>
<Dependency>xmlto</Dependency>
<Dependency>zlib-devel</Dependency>
<Dependency>xz-devel</Dependency>
</BuildDependencies>
<Patches>
<!--Patch compressionType="xz">patches/linux/patch-5.2.14.xz</Patch-->
</Patches>
</Source>
<Package>
<Name>linux</Name>
<RuntimeDependencies>
<Dependency>linux-firmware</Dependency>
<Dependency>grub2</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="executable" permanent="true">/boot</Path>
<Path fileType="library" permanent="true">/lib/modules</Path>
<Path fileType="data">/etc/kernel</Path>
<Path fileType="config" permanent="true">/etc/mkinitcpio.d</Path>
</Files>
<Provides>
<SCOM script="package.py">System.Package</SCOM>
</Provides>
<BuildFlags>
<Flag>noDelta</Flag>
</BuildFlags>
</Package>
<Package>
<Name>linux-module-headers</Name>
<Summary>Kernel header files for external module building</Summary>
<Description>kernel-module-headers includes the C header files and the necessary Kbuild files for being able to build external kernel modules.</Description>
<Files>
<Path fileType="header">/usr/src/linux-headers*</Path>
<Path fileType="header">/tmp-headers*</Path>
</Files>
</Package>
<Package>
<Name>linux-headers</Name>
<PartOf>system.devel</PartOf>
<Summary>Header files for the Linux kernel for use by glibc</Summary>
<Description>kernel-headers includes the C header files that specify the interface between the Linux kernel and userspace libraries and programs. The header files define structures and constants that are needed for building most standard programs and are also needed for rebuilding the glibc package.</Description>
<Files>
<Path fileType="header">/usr/include</Path>
</Files>
</Package>
<Package>
<Name>linux-docs</Name>
<Summary>Documentation and scripts for the Linux kernel</Summary>
<Description>kernel-docs includes several documentation files and scripts for managing several debugging and other tasks.</Description>
<Files>
<Path fileType="header">/usr/src/linux-headers*/Documentation</Path>
</Files>
</Package>
<History>
<Update release="1">
<Date>2019-09-12</Date>
<Version>5.2.14</Version>
<Comment>First release</Comment>
<Type package="kernel">security</Type>
<Name>Süleyman POYRAZ</Name>
<Email>zaryob.dev@gmail.com</Email>
</Update>
</History>
</INARY>
#!/usr/bin/python
import os
def read_file(path):
with open(path) as f:
return f.read().strip()
def postInstall(fromVersion, fromRelease, toVersion, toRelease):
gcf = "/boot/grub2/grub.cfg"
if not os.path.isfile(gcf): return
os.environ["PATH"] = "/usr/sbin:/usr/bin:/sbin:/bin"
os.system("grub2-mkconfig -o %s" % gcf)
# Update GRUB entry
#if os.path.exists("/boot/grub/grub.conf"):
# call("grub", "Boot.Loader", "updateKernelEntry", (KVER, ""))
def preRemove():
pass
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment