summaryrefslogtreecommitdiff
path: root/packaging
diff options
context:
space:
mode:
authorJoonyoung Shim <jy0922.shim@samsung.com>2017-01-24 13:19:59 +0900
committerJoonyoung Shim <jy0922.shim@samsung.com>2017-07-26 11:40:36 +0900
commitc9b5865fd504a7c81f3beb4a33e6c0bb5bda229a (patch)
tree5c0f9346a4256393d56c460745448fa9449e9e77 /packaging
parente7a78a70ffb5f7b7de3d53941a3a4d97ab263c3a (diff)
downloadlinux-rpi3-c9b5865fd504a7c81f3beb4a33e6c0bb5bda229a.tar.gz
linux-rpi3-c9b5865fd504a7c81f3beb4a33e6c0bb5bda229a.tar.bz2
linux-rpi3-c9b5865fd504a7c81f3beb4a33e6c0bb5bda229a.zip
packaging: Add spec file for ARM64
This adds linux-rpi3-arm64.spec file for ARM64 rpm packaging. v2: Remove creating fit style image Change-Id: I428fd32b69d082d935159476ace30c59c14b570d Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Diffstat (limited to 'packaging')
-rw-r--r--packaging/linux-rpi3-arm64.spec96
1 files changed, 96 insertions, 0 deletions
diff --git a/packaging/linux-rpi3-arm64.spec b/packaging/linux-rpi3-arm64.spec
new file mode 100644
index 000000000000..44c1e0cdb600
--- /dev/null
+++ b/packaging/linux-rpi3-arm64.spec
@@ -0,0 +1,96 @@
+%define config_name tizen_bcmrpi3_defconfig
+%define buildarch arm64
+%define target_board rpi3
+%define variant %{buildarch}-%{target_board}
+
+Name: %{target_board}-linux-kernel
+Summary: The Linux Kernel for Raspberry Pi3
+Version: 4.9.8
+Release: 0
+License: GPL-2.0
+ExclusiveArch: aarch64
+Group: System/Kernel
+Vendor: The Linux Community
+URL: https://www.kernel.org
+Source0: linux-kernel-%{version}.tar.xz
+BuildRoot: %{_tmppath}/%{name}-%{PACKAGE_VERSION}-root
+
+%define fullVersion %{version}-%{variant}
+
+BuildRequires: bc
+BuildRequires: module-init-tools
+BuildRequires: u-boot-tools >= 2016.03
+
+%description
+The Linux Kernel, the operating system core itself
+
+%package -n %{variant}-linux-kernel
+License: GPL-2.0
+Summary: Tizen kernel for %{target_board}
+Group: System/Kernel
+Provides: %{variant}-kernel-uname-r = %{fullVersion}
+Provides: linux-kernel = %{version}-%{release}
+
+%description -n %{variant}-linux-kernel
+This package contains the Linux kernel for Tizen (arch %{buildarch}, target board %{target_board})
+
+%package -n %{variant}-linux-kernel-modules
+Summary: Kernel modules for %{target_board}
+Group: System/Kernel
+Provides: %{variant}-kernel-modules = %{fullVersion}
+Provides: %{variant}-kernel-modules-uname-r = %{fullVersion}
+
+%description -n %{variant}-linux-kernel-modules
+Kernel-modules includes the loadable kernel modules(.ko files) for %{target_board}
+
+%prep
+%setup -q -n linux-kernel-%{version}
+
+%build
+# Make sure EXTRAVERSION says what we want it to say
+sed -i "s/^EXTRAVERSION.*/EXTRAVERSION = -%{variant}/" Makefile
+
+# 1-1. Set config file
+make %{config_name}
+
+# 1-2. Build Image/Image.gz
+make %{?_smp_mflags}
+
+# 1-3. Build dtbs
+make dtbs %{?_smp_mflags}
+
+# 1-4. Build modules
+make modules %{?_smp_mflags}
+
+%install
+QA_SKIP_BUILD_ROOT="DO_NOT_WANT"; export QA_SKIP_BUILD_ROOT
+
+# 2-1. Destination directories
+mkdir -p %{buildroot}/boot
+mkdir -p %{buildroot}/lib/modules
+
+# 2-2. Install kernel binary and DTB
+install -m 644 arch/%{buildarch}/boot/Image %{buildroot}/boot/
+install -m 644 arch/%{buildarch}/boot/dts/broadcom/bcm*.dtb %{buildroot}/boot/
+
+# 2-3. Install modules
+make INSTALL_MOD_STRIP=1 INSTALL_MOD_PATH=%{buildroot} modules_install
+
+# 2-4. Install boot binary files
+install -m 644 rpi3/boot/* %{buildroot}/boot/
+
+%clean
+rm -rf %{buildroot}
+
+%files -n %{variant}-linux-kernel-modules
+/lib/modules/*
+
+%files -n %{variant}-linux-kernel
+%license COPYING
+/boot/Image
+/boot/bcm*.dtb
+/boot/bootcode.bin
+/boot/config.txt
+/boot/fixup.dat
+/boot/LICENCE.broadcom
+/boot/start.elf