2015-05-08 17:39:01 +00:00
|
|
|
# Conditional for release and snapshot builds.
|
|
|
|
# Uncomment for release-builds.
|
|
|
|
%global rel_build 1
|
|
|
|
|
|
|
|
# Conditional for bootstrapping new distributions.
|
|
|
|
# Uncomment for bootstrap-builds.
|
2015-05-08 17:49:49 +00:00
|
|
|
#global bootstrap_build 1
|
2015-05-08 17:39:01 +00:00
|
|
|
|
|
|
|
# Settings used for build from snapshots.
|
|
|
|
%{!?rel_build:%global commit a85b2c6a5bf53de97883299a87f61a0bcf6844b7}
|
|
|
|
%{!?rel_build:%global commit_date 20141215}
|
|
|
|
%{!?rel_build:%global shortcommit %(c=%{commit};echo ${c:0:7})}
|
|
|
|
%{!?rel_build:%global gitver git%{commit_date}-%{shortcommit}}
|
|
|
|
%{!?rel_build:%global gitrel .git%{commit_date}.%{shortcommit}}
|
|
|
|
|
|
|
|
# Proper naming for the tarball from github.
|
|
|
|
%global gittar %{name}-%{version}%{!?rel_build:-%{gitver}}.tar.gz
|
|
|
|
|
|
|
|
# Place rpm-macros into proper location.
|
|
|
|
%{!?_macrosdir:%global _macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)}
|
|
|
|
|
|
|
|
# Setup _pkgdocdir if not defined already.
|
|
|
|
%{!?_pkgdocdir:%global _pkgdocdir %{_docdir}/%{name}-%{version}}
|
|
|
|
|
|
|
|
# Are licenses packaged using %%license?
|
|
|
|
%if 0%{?fedora} >= 21 || 0%{?rhel} >= 8
|
|
|
|
%bcond_without license_dir
|
|
|
|
%else # 0%%{?fedora} >= 21 || 0%%{?rhel} >= 8
|
|
|
|
%bcond_with license_dir
|
|
|
|
%endif # 0%%{?fedora} >= 21 || 0%%{?rhel} >= 8
|
|
|
|
|
|
|
|
# This is a package from a whole suite.
|
|
|
|
%global suite_name yast
|
|
|
|
%global name_suffix devtools
|
|
|
|
%global repo_name %{suite_name}-%{name_suffix}
|
|
|
|
%global src_url https://github.com/%{suite_name}/%{repo_name}
|
|
|
|
|
|
|
|
Name: %{suite_name}2-%{name_suffix}
|
2015-05-11 12:26:15 +00:00
|
|
|
Version: 3.1.32
|
|
|
|
Release: 1%{?gitrel}%{?dist}
|
2015-05-08 17:39:01 +00:00
|
|
|
Summary: YaST Development Tools
|
|
|
|
|
|
|
|
License: GPLv2+
|
|
|
|
URL: https://en.opensuse.org/Portal:YaST
|
|
|
|
# Sources for release-builds.
|
|
|
|
%{?rel_build:Source0: %{src_url}/archive/%{repo_name}/master/%{version}.tar.gz#/%{gittar}}
|
|
|
|
# Sources for snapshot-builds.
|
|
|
|
%{!?rel_build:Source0: %{src_url}/archive/%{commit}.tar.gz#/%{gittar}}
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: docbook-style-xsl
|
|
|
|
BuildRequires: doxygen
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: gettext
|
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: libxslt
|
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: rubygem(redcarpet)
|
|
|
|
BuildRequires: rubygem(yard)
|
|
|
|
|
|
|
|
Requires: %{_bindir}/libtool
|
|
|
|
Requires: %{_bindir}/xsltproc
|
|
|
|
Requires: automake
|
|
|
|
Requires: cmake
|
|
|
|
Requires: docbook-style-xsl
|
|
|
|
Requires: doxygen
|
|
|
|
Requires: emacs-filesystem
|
|
|
|
Requires: filesystem
|
|
|
|
Requires: gettext
|
|
|
|
Requires: redhat-rpm-config
|
|
|
|
Requires: rubygem(redcarpet)
|
|
|
|
Requires: rubygem(yard)
|
|
|
|
|
|
|
|
# Additional requirements after bootstrap.
|
|
|
|
%if 0%{?bootstrap_build} == 0
|
|
|
|
BuildRequires: pkgconfig(%{name})
|
2015-05-08 21:11:36 +00:00
|
|
|
Requires: config(yast2-filesystem)
|
2015-05-08 17:39:01 +00:00
|
|
|
%endif # 0%%{?bootstrap_build} == 0
|
|
|
|
|
|
|
|
%description
|
|
|
|
Common scripts and templates for developing
|
|
|
|
and building YaST2 modules and components.
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -qn %{repo_name}-%{?rel_build:%{repo_name}-master-%{version}}%{!?rel_build:%{commit}}
|
|
|
|
|
|
|
|
# Bootstrap autosh*t.
|
|
|
|
./build-tools/scripts/y2autoconf --bootstrap ./build-tools/
|
|
|
|
./build-tools/scripts/y2automake --bootstrap ./build-tools/
|
|
|
|
%{__cat} ./build-tools/aclocal/*.m4 > acinclude.m4
|
2015-05-11 12:26:15 +00:00
|
|
|
%{_bindir}/autoreconf -fiv -Wobsolete
|
2015-05-08 17:39:01 +00:00
|
|
|
|
|
|
|
# Fix-up hashbangs.
|
|
|
|
for _file in $(%{__grep} -Rle '#![ \t]*/usr/bin/env' .)
|
|
|
|
do
|
|
|
|
%{__sed} -e '1s~^#![ \t]*%{_bindir}/env[ \t]\+~#!%{_bindir}/~' \
|
|
|
|
< ${_file} > ${_file}.new && \
|
|
|
|
/bin/touch -r ${_file} ${_file}.new && \
|
|
|
|
%{__mv} -f ${_file}.new ${_file}
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%configure
|
|
|
|
%make_build
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
%make_install
|
|
|
|
|
|
|
|
# Create additionally needed dirs.
|
|
|
|
%{__mkdir} -p %{buildroot}%{?_macrosdir} %{buildroot}%{?_pkgdocdir}
|
|
|
|
|
|
|
|
# Install ChangeLog.
|
|
|
|
%{__cp} -a ./package/yast2-devtools.changes \
|
|
|
|
%{buildroot}%{?_pkgdocdir}/ChangeLog
|
|
|
|
|
|
|
|
# Install additional tools.
|
|
|
|
%{__cp} -a ./mass-tools/y2m %{buildroot}%{_bindir}
|
|
|
|
|
|
|
|
# Move documentation to %%{?_pkgdocdir}.
|
|
|
|
%{__mv} -f %{buildroot}%{_docdir}/packages/yast2-devtools/* \
|
|
|
|
%{buildroot}%{?_pkgdocdir}
|
|
|
|
%{__install} -pm 0644 ./mass-tools/README \
|
|
|
|
%{buildroot}%{?_pkgdocdir}/README.y2m.txt
|
|
|
|
|
|
|
|
# Move rpm-macros to proper dir.
|
|
|
|
%if "0%{?_macrosdir}" != "0%{_sysconfdir}/rpm"
|
|
|
|
%{__mv} -f %{buildroot}%{_sysconfdir}/rpm/* %{buildroot}%{?_macrosdir}
|
|
|
|
%endif # "0%%{?_macrosdir}" != "0%%{_sysconfdir}/rpm"
|
|
|
|
|
|
|
|
# This script gets sourced by external commands, only.
|
|
|
|
%{__chmod} -c 0644 \
|
|
|
|
%{buildroot}%{_datadir}/YaST2/data/devtools/bin/gettextdomains
|
|
|
|
|
|
|
|
# Final clean-up.
|
|
|
|
%{__rm} -rf %{buildroot}%{_docdir}/packages/yast2-devtools \
|
|
|
|
%if %{with license_dir}
|
|
|
|
%{buildroot}%{?_pkgdocdir}/COPYING \
|
|
|
|
%endif # %%{with license_dir}
|
|
|
|
;
|
|
|
|
|
|
|
|
# Softlink duplicate files.
|
|
|
|
%fdupes -s %{buildroot}
|
|
|
|
|
|
|
|
|
|
|
|
%check
|
2015-05-11 12:26:15 +00:00
|
|
|
if [ ! -f "%{yast_ydatadir}/devtools/NO_MAKE_CHECK" ]; then
|
|
|
|
%{__make} check VERBOSE=1 Y2DIR="%{buildroot}/%{yast_dir}" \
|
|
|
|
DESTDIR="%{buildroot}"
|
|
|
|
fi
|
2015-05-08 17:39:01 +00:00
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
%if %{with license_dir}
|
|
|
|
%license COPYING
|
|
|
|
%endif # %%{with license_dir}
|
|
|
|
%doc %{?_pkgdocdir}
|
|
|
|
%{_bindir}/y2*
|
|
|
|
%{_datadir}/aclocal/*.m4
|
|
|
|
%{_datadir}/cmake/Modules/*.cmake
|
|
|
|
%{_datadir}/emacs/site-lisp/*
|
|
|
|
%{_datadir}/pkgconfig/%{name}.pc
|
|
|
|
%{_datadir}/vim
|
|
|
|
%{_datadir}/YaST2/*
|
|
|
|
%{?_macrosdir}/macros.%{suite_name}
|
|
|
|
%{_prefix}/lib/YaST2/*
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2015-05-11 12:26:15 +00:00
|
|
|
* Mon May 11 2015 Björn Esser <bjoern.esser@gmail.com> - 3.1.32-1
|
|
|
|
- new upstream release
|
|
|
|
- add `-Wobsolete`-flag to autoreconf
|
|
|
|
- remove Patch0 and Patch1, since they are merged into upstream
|
|
|
|
- use conditional and more elaborate test-invocation
|
|
|
|
|
2015-05-09 11:51:57 +00:00
|
|
|
* Sat May 09 2015 Björn Esser <bjoern.esser@gmail.com> - 3.1.31-2
|
|
|
|
- fix AutoTools: Obsoleted m4s found: AC_PROG_LIBTOOL (#1220036)
|
|
|
|
- add Patch0: use new `AC_INIT()`-syntax with args in square braces
|
|
|
|
- add Patch1: replace obsolete `A[CM]_PROG_LIBTOOL` with `LT_INIT()`
|
|
|
|
|
2015-05-08 21:11:36 +00:00
|
|
|
* Fri May 08 2015 Björn Esser <bjoern.esser@gmail.com> - 3.1.31-1
|
|
|
|
- new upstream release
|
|
|
|
|
2015-05-08 17:49:49 +00:00
|
|
|
* Fri May 08 2015 Björn Esser <bjoern.esser@gmail.com> - 3.1.30-1
|
|
|
|
- initial rpm release (#1218749)
|
|
|
|
|
2015-05-08 17:39:01 +00:00
|
|
|
* Mon May 04 2015 Björn Esser <bjoern.esser@gmail.com> - 3.1.30-0.1
|
|
|
|
- bootstrapping
|