2007-04-02 04:28:12 +02:00
|
|
|
#
|
2011-07-04 13:55:11 +02:00
|
|
|
# spec file for package dtc
|
2007-04-02 04:28:12 +02:00
|
|
|
#
|
2021-04-21 14:31:57 +02:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
2007-04-02 04:28:12 +02:00
|
|
|
#
|
2009-06-18 17:17:02 +02:00
|
|
|
# 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.
|
|
|
|
|
2019-10-08 14:11:37 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2007-04-02 04:28:12 +02:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%define sover 1
|
2007-04-02 04:28:12 +02:00
|
|
|
Name: dtc
|
2020-03-14 17:19:10 +01:00
|
|
|
Version: 1.6.0
|
2013-05-24 15:32:51 +02:00
|
|
|
Release: 0
|
2011-07-04 13:54:28 +02:00
|
|
|
Summary: Device-tree compiler
|
2019-10-08 14:11:37 +02:00
|
|
|
License: GPL-2.0-or-later
|
2019-10-30 14:31:20 +01:00
|
|
|
URL: https://github.com/dgibson/dtc
|
2019-03-18 17:50:13 +01:00
|
|
|
Source0: https://mirrors.edge.kernel.org/pub/software/utils/dtc/dtc-%{version}.tar.gz
|
2019-10-30 16:22:15 +01:00
|
|
|
Source1: https://mirrors.edge.kernel.org/pub/software/utils/dtc/dtc-%{version}.tar.sign
|
|
|
|
Source2: baselibs.conf
|
2015-12-07 08:40:45 +01:00
|
|
|
BuildRequires: bison
|
|
|
|
BuildRequires: flex
|
2019-10-28 11:24:13 +01:00
|
|
|
BuildRequires: libyaml-devel
|
2019-10-30 16:22:15 +01:00
|
|
|
BuildRequires: python3-devel
|
2019-10-30 16:38:49 +01:00
|
|
|
BuildRequires: python3-setuptools
|
2019-10-30 16:22:15 +01:00
|
|
|
BuildRequires: swig
|
2007-04-02 04:28:12 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
PowerPC kernels are moving towards requiring a small Open
|
|
|
|
Firmware-style device tree as the only means of passing information
|
|
|
|
from bootloaders/firmware to the kernel. This does not require a full
|
|
|
|
Open Firmware implementation. DTC (Device Tree Compiler) is a tool to
|
|
|
|
create a static device tree, which is adequate for most embedded
|
|
|
|
systems (since their topology will not vary across reboots). DTC is
|
|
|
|
available via a git tree: git://ozlabs.org/srv/projects/dtc/dtc.git
|
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%package -n libfdt%{sover}
|
2011-07-04 13:55:11 +02:00
|
|
|
Summary: Device tree library
|
2007-04-02 04:28:12 +02:00
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%description -n libfdt%{sover}
|
2011-07-04 13:54:28 +02:00
|
|
|
libfdt is a library to process Open Firmware style device trees on various
|
|
|
|
architectures.
|
2007-04-02 04:28:12 +02:00
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%package -n libfdt-devel
|
2011-07-04 13:55:11 +02:00
|
|
|
Summary: Development headers for device tree library
|
2015-12-07 08:40:45 +01:00
|
|
|
Requires: libfdt%{sover} = %{version}-%{release}
|
2015-12-15 19:38:57 +01:00
|
|
|
# Provide previously used incorrectly named devel package
|
|
|
|
Provides: libfdt1-devel = %{version}-%{release}
|
|
|
|
Obsoletes: libfdt1-devel < %{version}-%{release}
|
2011-07-04 13:54:28 +02:00
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%description -n libfdt-devel
|
2011-07-04 13:54:28 +02:00
|
|
|
This package provides development files for libfdt
|
2007-04-02 04:28:12 +02:00
|
|
|
|
2019-10-30 16:22:15 +01:00
|
|
|
|
|
|
|
%package -n python3-libfdt
|
|
|
|
Summary: Python binding for Device Tree
|
|
|
|
|
|
|
|
%description -n python3-libfdt
|
|
|
|
libfdt is a library to process Open Firmware style device trees on various
|
|
|
|
architectures.
|
|
|
|
|
|
|
|
Python binding part.
|
|
|
|
|
2007-04-02 04:28:12 +02:00
|
|
|
%prep
|
2013-07-09 11:30:00 +02:00
|
|
|
%setup -q
|
2007-04-02 04:28:12 +02:00
|
|
|
|
|
|
|
%build
|
2021-04-21 14:31:57 +02:00
|
|
|
export EXTRA_CFLAGS="%{optflags} -pie"
|
2019-12-20 09:28:12 +01:00
|
|
|
%make_build NO_PYTHON=1
|
2019-10-30 17:48:23 +01:00
|
|
|
cd pylibfdt
|
2019-10-30 17:59:43 +01:00
|
|
|
python3 setup.py build_ext
|
|
|
|
%py3_build
|
2007-04-02 04:28:12 +02:00
|
|
|
|
|
|
|
%install
|
2019-10-30 17:47:29 +01:00
|
|
|
%make_install PREFIX=%{_prefix} LIBDIR=%{_libdir} NO_PYTHON=1
|
2017-03-16 09:38:03 +01:00
|
|
|
install -p -m 644 libfdt/libfdt_env.h %{buildroot}/%{_includedir}
|
2011-07-04 13:54:28 +02:00
|
|
|
rm -f %{buildroot}/%{_libdir}/*.a
|
2019-10-30 17:48:23 +01:00
|
|
|
cd pylibfdt
|
2019-10-30 17:59:43 +01:00
|
|
|
%python3_install
|
2007-04-02 04:28:12 +02:00
|
|
|
|
2017-03-16 09:38:03 +01:00
|
|
|
%check
|
2019-12-20 09:28:12 +01:00
|
|
|
export EXTRA_CFLAGS="%{optflags}"
|
|
|
|
%make_build check
|
2017-03-16 09:38:03 +01:00
|
|
|
|
2007-04-02 04:28:12 +02:00
|
|
|
%files
|
2019-10-30 14:31:20 +01:00
|
|
|
%license README.license
|
|
|
|
%doc Documentation/manual.txt
|
2013-06-19 08:58:39 +02:00
|
|
|
%{_bindir}/convert-dtsv0
|
|
|
|
%{_bindir}/dtc
|
|
|
|
%{_bindir}/dtdiff
|
2013-07-09 11:30:00 +02:00
|
|
|
%{_bindir}/fdtdump
|
|
|
|
%{_bindir}/fdtget
|
|
|
|
%{_bindir}/fdtput
|
2018-12-19 14:11:21 +01:00
|
|
|
%{_bindir}/fdtoverlay
|
2011-07-04 13:54:28 +02:00
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%post -n libfdt%{sover} -p /sbin/ldconfig
|
|
|
|
%postun -n libfdt%{sover} -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%files -n libfdt%{sover}
|
2020-03-14 17:19:10 +01:00
|
|
|
%{_libdir}/libfdt-1.6.0.so
|
2011-07-04 13:54:28 +02:00
|
|
|
%{_libdir}/libfdt.so.*
|
|
|
|
|
2015-12-07 08:40:45 +01:00
|
|
|
%files -n libfdt-devel
|
2011-07-04 13:54:28 +02:00
|
|
|
%{_libdir}/libfdt.so
|
|
|
|
%{_includedir}/*
|
2007-04-02 04:28:12 +02:00
|
|
|
|
2019-10-30 16:22:15 +01:00
|
|
|
%files -n python3-libfdt
|
|
|
|
%{python3_sitearch}/*.so
|
|
|
|
%{python3_sitearch}/*.egg-info
|
|
|
|
%{python3_sitearch}/__pycache__/*.pyc
|
|
|
|
%{python3_sitearch}/libfdt.py
|
|
|
|
|
2007-04-02 04:28:12 +02:00
|
|
|
%changelog
|