File dtb-armv7l.spec of Package dtb-source
#
# spec file for package dtb-armv7l
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: dtb-armv7l
BuildRequires: kernel-source
%define kernel_version %(rpm -q --qf "%{VERSION}" kernel-source | grep -v "is not")
Version: %kernel_version
Release: 0
Summary: Device Tree files for $MACHINES
License: GPL-2.0
Group: System/Boot
Url: http://www.kernel.org/
%if "dtb-armv7l" == "dtb-source"
Source99: pre_checkin.pl
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Requires: kernel = %kernel_version
BuildRequires: cpp
BuildRequires: dtc >= 1.4.0
BuildRequires: xz
ExclusiveArch: armv7l armv7hl
%description
Device Tree files for $MACHINES.
%package -n dtb-omap3
Summary: TI OMAP3 based systems
Group: System/Boot
%description -n dtb-omap3
Device Tree Files for TI OMAP3 based systems.
%package -n dtb-omap4
Summary: TI OMAP4 based systems
Group: System/Boot
%description -n dtb-omap4
Device Tree Files for TI OMAP4 based systems.
%package -n dtb-omap5
Summary: TI OMAP5 based systems
Group: System/Boot
%description -n dtb-omap5
Device Tree Files for TI OMAP5 based systems.
%package -n dtb-am335x
Summary: TI AM335x based systems
Group: System/Boot
%description -n dtb-am335x
Device Tree Files for TI AM335x based systems.
%package -n dtb-keystone
Summary: TI Keystone based systems
Group: System/Boot
%description -n dtb-keystone
Device Tree Files for TI Keystone based systems.
%package -n dtb-exynos4
Summary: Samsung Exynos4 based systems
Group: System/Boot
%description -n dtb-exynos4
Device Tree Files for Samsung Exynos4 based systems.
%package -n dtb-exynos5
Summary: Samsung Exynos5 based systems
Group: System/Boot
%description -n dtb-exynos5
Device Tree Files for Samsung Exynos5 based systems.
%package -n dtb-imx5
Summary: Freescale i.MX51 and i.MX53 based systems
Group: System/Boot
%description -n dtb-imx5
Device Tree Files for Freescale i.MX51 and i.MX53 based systems.
%package -n dtb-imx6
Summary: Freescale i.MX6 based systems
Group: System/Boot
%description -n dtb-imx6
Device Tree Files for Freescale i.MX6 based systems.
%package -n dtb-vf6
Summary: Freescale Vybrid VF6xx based systems
Group: System/Boot
%description -n dtb-vf6
Device Tree Files for Freescale Vybrid VF6xx based systems.
%package -n dtb-tegra2
Summary: NVidia Tegra2 based systems
Group: System/Boot
%description -n dtb-tegra2
Device Tree Files for NVidia Tegra2 based systems.
%package -n dtb-tegra3
Summary: NVidia Tegra3 based systems
Group: System/Boot
%description -n dtb-tegra3
Device Tree Files for NVidia Tegra3 based systems.
%package -n dtb-tegra114
Summary: NVidia Tegra4 based systems
Group: System/Boot
%description -n dtb-tegra114
Device Tree Files for NVidia Tegra4 based systems.
%package -n dtb-tegra124
Summary: NVidia Tegra K1 based systems
Group: System/Boot
%description -n dtb-tegra124
Device Tree Files for NVidia Tegra K1 based systems.
%package -n dtb-sun4i
Summary: Allwinner sun4i based systems
Group: System/Boot
%description -n dtb-sun4i
Device Tree Files for Allwinner sun4i based systems.
%package -n dtb-sun5i
Summary: Allwinner sun5i based systems
Group: System/Boot
%description -n dtb-sun5i
Device Tree Files for Allwinner sun5i based systems.
%package -n dtb-sun6i
Summary: Allwinner sun6i based systems
Group: System/Boot
%description -n dtb-sun6i
Device Tree Files for Allwinner sun6i based systems.
%package -n dtb-sun7i
Summary: Allwinner sun7i based systems
Group: System/Boot
%description -n dtb-sun7i
Device Tree Files for Allwinner sun7i based systems.
%package -n dtb-sun8i
Summary: Allwinner sun8i based systems
Group: System/Boot
%description -n dtb-sun8i
Device Tree Files for Allwinner sun8i based systems.
%package -n dtb-sun9i
Summary: Allwinner sun9i based systems
Group: System/Boot
%description -n dtb-sun9i
Device Tree Files for Allwinner sun9i based systems.
%package -n dtb-xenvm
Summary: Xen virtual machines
Group: System/Boot
%description -n dtb-xenvm
Device Tree Files for Xen virtual machines.
%package -n dtb-vexpress
Summary: ARM versatile express machines
Group: System/Boot
%description -n dtb-vexpress
Device Tree Files for ARM versatile express machines.
%package -n dtb-ste
Summary: ST Ericsson based systems
Group: System/Boot
%description -n dtb-ste
Device Tree Files for ST Ericsson based systems.
%package -n dtb-dove
Summary: Marvell dove based systems
Group: System/Boot
%description -n dtb-dove
Device Tree Files for Marvell dove based systems.
%package -n dtb-armada-370
Summary: Armada 370 based systems
Group: System/Boot
%description -n dtb-armada-370
Device Tree Files for Armada 370 based systems.
%package -n dtb-armada-xp
Summary: Armada XP based systems
Group: System/Boot
%description -n dtb-armada-xp
Device Tree Files for Armada XP based systems.
%package -n dtb-rk3
Summary: Rockchip RK3xxx based systems
Group: System/Boot
%description -n dtb-rk3
Device Tree Files for Rockchip RK3xxx based systems.
%package -n dtb-qcom
Summary: Qualcomm Snapdragon based systems
Group: System/Boot
%description -n dtb-qcom
Device Tree Files for Qualcomm Snapdragon based systems.
%package -n dtb-zynq
Summary: Xilinx Zynq based systems
Group: System/Boot
%description -n dtb-zynq
Device Tree Files for Xilinx Zynq based systems.
%prep
%build
cp /usr/src/linux/COPYING .
cp -r /usr/src/linux/ .
chmod -R ug+rw linux
%install
%if "dtb-armv7l" != "dtb-source"
export DTC_FLAGS="-R 4 -p 0x1000"
mkdir -p %{buildroot}/boot/dtb
cd linux/arch/arm/boot/dts
for dts in *omap3*.dts *omap4*.dts *omap5*.dts *am335x*.dts k2hk-evm.dts *exynos4*.dts *exynos5*.dts *imx5*.dts *imx6*.dts *vf6*.dts *tegra2*.dts *tegra3*.dts tegra114-*.dts tegra124-*.dts *sun4i*.dts *sun5i*.dts *sun6i*.dts *sun7i*.dts *sun8i*.dts *sun9i*.dts *xenvm*.dts vexpress*.dts ste*.dts dove*.dts armada-370*.dts armada-xp*.dts rk3*.dts qcom-*.dts zynq-*.dts ; do
target=${dts%*.dts}
cpp -x assembler-with-cpp -undef -D__DTS__ -nostdinc -I. -I./include/ -P $target.dts -o $target.dts.tmp
install -m 700 -d %{buildroot}/boot/dtb/$(dirname $target)
dtc $DTC_FLAGS -I dts -O dtb -o %{buildroot}/boot/dtb/$target.dtb $target.dts.tmp
done
cd -
%files -n dtb-omap3
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*omap3*.dtb
%files -n dtb-omap4
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*omap4*.dtb
%files -n dtb-omap5
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*omap5*.dtb
%files -n dtb-am335x
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*am335x*.dtb
%files -n dtb-keystone
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/k2hk-evm.dtb
%files -n dtb-exynos4
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*exynos4*.dtb
%files -n dtb-exynos5
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*exynos5*.dtb
%files -n dtb-imx5
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*imx5*.dtb
%files -n dtb-imx6
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*imx6*.dtb
%files -n dtb-vf6
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*vf6*.dtb
%files -n dtb-tegra2
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*tegra2*.dtb
%files -n dtb-tegra3
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*tegra3*.dtb
%files -n dtb-tegra114
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/tegra114-*.dtb
%files -n dtb-tegra124
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/tegra124-*.dtb
%files -n dtb-sun4i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun4i*.dtb
%files -n dtb-sun5i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun5i*.dtb
%files -n dtb-sun6i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun6i*.dtb
%files -n dtb-sun7i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun7i*.dtb
%files -n dtb-sun8i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun8i*.dtb
%files -n dtb-sun9i
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*sun9i*.dtb
%files -n dtb-xenvm
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/*xenvm*.dtb
%files -n dtb-vexpress
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/vexpress*.dtb
%files -n dtb-ste
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/ste*.dtb
%files -n dtb-dove
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/dove*.dtb
%files -n dtb-armada-370
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/armada-370*.dtb
%files -n dtb-armada-xp
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/armada-xp*.dtb
%files -n dtb-rk3
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/rk3*.dtb
%files -n dtb-qcom
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/qcom-*.dtb
%files -n dtb-zynq
%defattr(-,root,root)
%doc COPYING
%dir /boot/dtb/
/boot/dtb/zynq-*.dtb
%endif
%changelog