[yaws] Added xmlrpc as dependency and fixed docs building on EL-6

Peter Lemenkov peter at fedoraproject.org
Thu Nov 18 10:43:07 UTC 2010


commit 98d7aef0b7a2b0fe2390fe3785bbbc7b6cde697e
Author: Peter Lemenkov <lemenkov at gmail.com>
Date:   Thu Nov 18 13:42:59 2010 +0300

    Added xmlrpc as dependency and fixed docs building on EL-6
    
    Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>

 ...ime.erl-to-the-list-of-modules-to-compile.patch |   30 ++++++++++++++++++++
 yaws.spec                                          |   29 ++++++++++++++----
 2 files changed, 52 insertions(+), 7 deletions(-)
---
diff --git a/yaws-0003-Add-yaws_dime.erl-to-the-list-of-modules-to-compile.patch b/yaws-0003-Add-yaws_dime.erl-to-the-list-of-modules-to-compile.patch
new file mode 100644
index 0000000..f939075
--- /dev/null
+++ b/yaws-0003-Add-yaws_dime.erl-to-the-list-of-modules-to-compile.patch
@@ -0,0 +1,30 @@
+From 28b2a40b5aedeea9c04d1dac2a2f663ea750de3c Mon Sep 17 00:00:00 2001
+From: Peter Lemenkov <lemenkov at gmail.com>
+Date: Wed, 17 Nov 2010 18:20:23 +0300
+Subject: [PATCH 3/3] Add yaws_dime.erl to the list of modules to compile
+
+This module is used in yaws_rpc, yaws_soap_lib and
+yaws_soap_srv modules but it wasn't compiled. So it's
+quite likely that application will fails with 'undef'
+error.
+
+Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
+---
+ src/Makefile |    1 +
+ 1 files changed, 1 insertions(+), 0 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index bd06406..11c412a 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -55,6 +55,7 @@ MODULES=yaws \
+ 	yaws_sup_restarts \
+ 	yaws_stats \
+ 	yaws_multipart \
++	yaws_dime \
+ 	$(BITSMODS)
+ 
+ 
+-- 
+1.7.3.2
+
diff --git a/yaws.spec b/yaws.spec
index 3084206..f19f383 100644
--- a/yaws.spec
+++ b/yaws.spec
@@ -1,9 +1,11 @@
 # We're in fact noarch
 %global xdebug_package %{nil}
 
+%bcond_without docs
+
 Name:           yaws
 Version:        1.89
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        Web server for dynamic content written in Erlang
 Group:          System Environment/Daemons
 # BSD: see LICENSE
@@ -18,6 +20,8 @@ Source0:        http://yaws.hyber.org/download/%{name}-%{version}.tar.gz
 Source1:        yaws.logrotate
 Patch0:         yaws-1.85-sysvinit.patch
 Patch1:         yaws-1.88-fhs.patch
+# backported from upstream
+Patch3:		yaws-0003-Add-yaws_dime.erl-to-the-list-of-modules-to-compile.patch
 BuildRoot:      %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 
 BuildRequires:  erlang-erts
@@ -28,13 +32,16 @@ BuildRequires:  erlang-sasl
 BuildRequires:  erlang-ssl
 BuildRequires:  erlang-stdlib
 BuildRequires:  pam-devel
-BuildRequires:  tex(latex)  
+%if %{with docs}
+BuildRequires:  tex(latex)
 BuildRequires:  tex(dvips)
 BuildRequires:  latex2html
+%endif
 
 Requires:       erlang >= R13B
 Requires:       erlang-erlsom
 Requires:       erlang-ibrowse
+Requires:       erlang-xmlrpc
 Requires:       logrotate
 Requires(post): chkconfig
 Requires(preun): chkconfig
@@ -64,6 +71,7 @@ This package contains a pkg-config configuration for %{name}.
 %setup -q
 %patch0 -p1 -b .sysvinit
 %patch1 -p1 -b .fhs
+%patch3 -p1 -b .missing_module
 
 # This requires egssapi which is not yet available
 rm -f src/authmod_gssapi.erl
@@ -79,7 +87,11 @@ find . -name '*.dia' -delete
 
 %build
 %configure --libdir=%{_libdir}/erlang/lib
-make %{?_smp_mflags} all docs
+make %{?_smp_mflags} all
+%if %{with docs}
+# fails to build with smp_mflags sometimes
+make docs
+%endif
 
 
 %install
@@ -99,9 +111,6 @@ install -p -m0644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/yaws
 mkdir -p $RPM_BUILD_ROOT%{_libdir}
 mv $RPM_BUILD_ROOT%{_libdir}/erlang/lib/pkgconfig $RPM_BUILD_ROOT%{_libdir}
 
-# Source for debugging
-cp -a src/. $RPM_BUILD_ROOT%{_libdir}/erlang/lib/%{name}/src
-
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -139,13 +148,14 @@ fi
 %{_bindir}/yaws
 %{_libdir}/erlang/lib/yaws
 %exclude %{_libdir}/erlang/lib/yaws/ebin/.empty
+%if %{with docs}
 %doc doc/yaws.pdf
+%endif
 %doc %{_datadir}/man/man1/yaws.1*
 %doc %{_datadir}/man/man5/yaws.conf.5*
 %doc %{_datadir}/man/man5/yaws_api.5*
 %doc README LICENSE ChangeLog
 %exclude %{_libdir}/erlang/lib/yaws/examples
-%exclude %{_libdir}/erlang/lib/yaws/src
 
 %files devel
 %defattr(-,root,root,-)
@@ -153,6 +163,11 @@ fi
 
 
 %changelog
+* Thu Nov 18 2010 Peter Lemenkov <lemenkov at gmail.com> - 1.89-3
+- Make building docs conditional
+- Added one more module to package
+- Added missing runtime dependency - erlang-xmlrpc
+
 * Thu Oct 21 2010 Lubomir Rintel (GoodData) <lkundrak at v3.sk> - 1.89-2
 - Require newer Erlang (Peter Lemenkov)
 - Exclude examples/ and src/


More information about the scm-commits mailing list