From 4b4fc26f0ed99a92035dfe22a027a3fbd4480284 Mon Sep 17 00:00:00 2001 From: Hans Ulrich Niedermann Date: Jul 27 2010 10:59:18 +0000 Subject: - Spec file cleanups: - Avoid accidental %rel increments by rpmdev-bumpspec. - Use %global for our spec file macros. - Use macro for redundant directory names. - Whitespace cleanups (tabs vs. spaces). - Fix accidental macro usage in %changelog. --- diff --git a/erlang.spec b/erlang.spec index 47240e8..50718cb 100644 --- a/erlang.spec +++ b/erlang.spec @@ -1,17 +1,18 @@ -%define ver R14A -# Please, dont increment %%{rel} during rebuilds - it's a mainstream's -# version which should be increased only during major upgrades -%define rel 0 +%global upstream_ver R14A +# Do NOT change %%{upstream_rel} unless UPSTREAM has actually changed it! +%global upstream_rel 0 + +%global n_uvr %{name}-%{upstream_ver}-%{upstream_rel} Name: erlang -Version: %{ver} -Release: %{rel}.3%{?dist} +Version: %{upstream_ver} +Release: %{upstream_rel}.4%{?dist} Summary: General-purpose programming language and runtime environment Group: Development/Languages License: ERPL URL: http://www.erlang.org -Source0: http://www.erlang.org/download/otp_src_%{ver}.tar.gz +Source0: http://www.erlang.org/download/otp_src_%{upstream_ver}.tar.gz Source3: erlang-find-provides.escript Source4: erlang-find-provides.sh Source5: erlang-find-requires.escript @@ -415,7 +416,7 @@ Requires: %{name}-kernel = %{version}-%{release} Requires: %{name}-stdlib = %{version}-%{release} BuildRequires: tcl-devel BuildRequires: tk-devel -Requires: tk +Requires: tk Obsoletes: %{name} < R13B-04.5 %description gs @@ -542,7 +543,7 @@ Requires: %{name}-erts = %{version}-%{release} Requires: %{name}-kernel = %{version}-%{release} Requires: %{name}-stdlib = %{version}-%{release} Obsoletes: %{name} < R13B-04.5 -BuildRequires: unixODBC-devel +BuildRequires: unixODBC-devel %description odbc An interface to relational SQL-databases built on ODBC (Open Database @@ -847,7 +848,7 @@ Requires: %{name}-stdlib = %{version}-%{release} Requires: mesa-libGL Requires: mesa-libGLU Obsoletes: %{name} < R13B-04.5 -BuildRequires: wxGTK-devel +BuildRequires: wxGTK-devel %description wx A Graphics System used to write platform independent user interfaces. @@ -864,7 +865,7 @@ Obsoletes: %{name} < R13B-04.5 Provides support for XML 1.0. %prep -%setup -q -n otp_src_%{ver} +%setup -q -n otp_src_%{upstream_ver} %patch1 -p1 -b .do_not_format_manpages %patch2 -p1 -b .rpath %patch4 -p1 -b .dlopen_opengl_libs @@ -910,18 +911,18 @@ find $RPM_BUILD_ROOT%{_libdir}/erlang/lib/kernel-*/examples/uds_dist -type d -pe chmod 0755 $RPM_BUILD_ROOT%{_libdir}/erlang/bin # Relocate doc-files into the proper directory -mkdir -p $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel}/lib +mkdir -p $RPM_BUILD_ROOT%{_docdir}/%{n_uvr}/lib pushd . cd $RPM_BUILD_ROOT%{_libdir}/erlang -mv -v doc $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel} -for i in erts-* ; do mv -v $i/doc $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel}/$i ; done +mv -v doc $RPM_BUILD_ROOT%{_docdir}/%{n_uvr} +for i in erts-* ; do mv -v $i/doc $RPM_BUILD_ROOT%{_docdir}/%{n_uvr}/$i ; done cd $RPM_BUILD_ROOT%{_libdir}/erlang/lib -for i in * ; do mv -v $i/doc $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel}/lib/$i || true ; done +for i in * ; do mv -v $i/doc $RPM_BUILD_ROOT%{_docdir}/%{n_uvr}/lib/$i || true ; done popd -cp -av AUTHORS EPLICENCE README.md $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel} -mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/PR.template $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel} -mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/README $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel} -mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/COPYRIGHT $RPM_BUILD_ROOT%{_docdir}/%{name}-%{ver}-%{rel} +cp -av AUTHORS EPLICENCE README.md $RPM_BUILD_ROOT%{_docdir}/%{n_uvr} +mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/PR.template $RPM_BUILD_ROOT%{_docdir}/%{n_uvr} +mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/README $RPM_BUILD_ROOT%{_docdir}/%{n_uvr} +mv -v $RPM_BUILD_ROOT%{_libdir}/erlang/COPYRIGHT $RPM_BUILD_ROOT%{_docdir}/%{n_uvr} # Win32-specific man-pages rm -f $RPM_BUILD_ROOT%{_libdir}/erlang/man/man1/erlsrv.* @@ -947,13 +948,13 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) -%dir %{_docdir}/%{name}-%{ver}-%{rel}/ -%doc %{_docdir}/%{name}-%{ver}-%{rel}/AUTHORS -%doc %{_docdir}/%{name}-%{ver}-%{rel}/COPYRIGHT -%doc %{_docdir}/%{name}-%{ver}-%{rel}/EPLICENCE -%doc %{_docdir}/%{name}-%{ver}-%{rel}/PR.template -%doc %{_docdir}/%{name}-%{ver}-%{rel}/README -%doc %{_docdir}/%{name}-%{ver}-%{rel}/README.md +%dir %{_docdir}/%{n_uvr}/ +%doc %{_docdir}/%{n_uvr}/AUTHORS +%doc %{_docdir}/%{n_uvr}/COPYRIGHT +%doc %{_docdir}/%{n_uvr}/EPLICENCE +%doc %{_docdir}/%{n_uvr}/PR.template +%doc %{_docdir}/%{n_uvr}/README +%doc %{_docdir}/%{n_uvr}/README.md %files appmon %defattr(-,root,root) @@ -1109,9 +1110,9 @@ rm -rf $RPM_BUILD_ROOT %files doc %defattr(-,root,root) -%doc %{_docdir}/%{name}-%{ver}-%{rel}/doc -%doc %{_docdir}/%{name}-%{ver}-%{rel}/erts-*/ -%doc %{_docdir}/%{name}-%{ver}-%{rel}/lib/ +%doc %{_docdir}/%{n_uvr}/doc +%doc %{_docdir}/%{n_uvr}/erts-*/ +%doc %{_docdir}/%{n_uvr}/lib/ %files docbuilder @@ -1948,6 +1949,14 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Mon Jul 26 2010 Hans Ulrich Niedermann - R14A-0.4 +- Spec file cleanups: + - Avoid accidental %%rel increments by rpmdev-bumpspec. + - Use %%global for our spec file macros. + - Use macro for redundant directory names. + - Whitespace cleanups (tabs vs. spaces). + - Fix accidental macro usage in %%changelog. + * Wed Jul 14 2010 Dan HorĂ¡k - R14A-0.3 - rebuilt against wxGTK-2.8.11-2 @@ -2036,7 +2045,7 @@ rm -rf $RPM_BUILD_ROOT * Sun Mar 1 2009 Gerard Milmeister - R12B-5.6 - new release R12B-5 -- link escript and dialyzer to %{_bindir} +- link escript and dialyzer to %%{_bindir} * Tue Feb 24 2009 Fedora Release Engineering - R12B-5.5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild