Hi John,

                  Thanks a lot for making a release. I was trying to run the 
latest release on SLES 11 and RHEL 6 servers in my environment. I wanted to 
make RPMs from the source to install it on the target m/c. I used to build rpms 
based on svn trunks before and were working fine. I wrote my own openslp.spec 
file to  suit my environment. However when i try to use the same on the latest 
release i get the following error. Iam not an expert in these autoconf tools so 
any help will be great.

- I Make one  modification, ie add 1 patch on top the latest source, the patch 
is pasted below.
diff -Nur openslp-2.1.1636.orig/etc/Makefile.am 
openslp-2.1.1636.mark/etc/Makefile.am
--- openslp-2.1.1636.orig/etc/Makefile.am       2008-10-28 15:03:04.000000000 
-0500
+++ openslp-2.1.1636.mark/etc/Makefile.am       2010-09-14 13:47:03.000000000 
-0500
@@ -4,7 +4,7 @@

 #make sure the slpd log directory is there
 install-data-hook:
-       mkdir -p $(localstatedir)/log
+       mkdir -p $(DESTDIR)$(localstatedir)/log

 ##install-data-local:
 ##     mkdir -p $(DESTDIR)$(sysconfdir)
~                                               

- I then have to simply run rpmbuild command with my openslp.spec file attached 
in this mail. When the rebuild the src rpm i get the following errors.
varun@sles-virt:~/openslp-2.0.beta2> ./configure --prefix=/usr 
--libdir=/usr/lib --sysconfdir=/etc --enable-async-api --enable-slpv2-security 
--localstatedir=/var
checking grp.h usability... yes
checking grp.h presence... yes
checking for grp.h... yes
checking return type of signal handlers... void
./configure: line 13749: syntax error near unexpected token `socklen_t,'
./configure: line 13749: `OPENSLP_CHECK_TYPE(socklen_t, int,'
varun@sles-virt:~/openslp-2.0.beta2> 

This happens because the openslp.spec runs the following during the rebuild of 
the RPM
#libtoolize --force
#aclocal
#autoconf
#automake --add-missing

As soon as autoconf is run and the ./configure is called we run into this 
problem. This is seen in SLES 11. I did not face the same problem when dealing 
with svn releases. The main difference in svn release was that i would run
./autogen.sh before i build the rpm, here its NOT needed.

SLES 11 specs:

      host-triplet:     i686-pc-linux-gnu
      shell:            /bin/sh
      compiler:         gcc
      compiler flags:           -march=i586 -mtune=i686 -fmessage-length=0 -O2 
-Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables 
-fasynchronous-unwind-tables -g
      linker:           /usr/i586-suse-linux/bin/ld (gnu? yes)
      libtool:          (GNU libtool) 2.2.6
      automake:         automake (GNU automake) 1.10.1
      autoconf:         autoconf (GNU Autoconf) 2.63

Regards,
Varun
#
# spec file for package OpenSLP (Version 2.1-1658)
#
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Please submit bugfixes or comments via openslp-devel@lists.sourceforge.net
#

# norootforbuild

Name:           openslp
BuildRequires:  bison flex openssl-devel doxygen
BuildRequires:  automake libtool
Summary:        An Implementation of Service Location Protocol V2
Version:        2.0.beta2
Release:        1 
License:        BSD 3-Clause
Group:          System/Daemons
URL:            http://www.openslp.org/
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Source0:        %name-%version.tar.gz
#Patch0:         openslp-kvm.patch
#Patch1:         openslp-mtu.patch
Patch2:		openslp-log-directory.patch

%description
Service Location Protocol is an IETF standards track protocol that
provides a framework that allows networking applications to discover
the existence, location, and configuration of networked services in
enterprise networks.

OpenSLP is an open source implementation of the SLPv2 protocol as
defined by RFC 2608 and RFC 2614.  This package includes the slptool
and runtime libraries.



Authors:
--------
    Matthew Peterson <mpeter...@calderasystems.com>
    John Calcote <john.calc...@gmail.com>
    Ganesan Rajagopal <rgane...@myrealbox.com>
    David McCormack <david.mccorm...@ottawa.com>
    Evan Hughes <hug...@lab43.org>
    Matthieu Desmons <m...@ocegr.fr>
    Praveen Kumar Amritaluru <prav...@india.hp.com>

%package server
Group:          System/Daemons
Summary:        The OpenSLP Implementation of the  Service Location Protocol V2
Requires: %{name} = %{version}-%{release}
Requires(preun): /sbin/chkconfig, /sbin/service
Requires(post): /sbin/chkconfig
Requires(postun): /sbin/service

%description server
Service Location Protocol is an IETF standards track protocol that
provides a framework that allows networking applications to discover
the existence, location, and configuration of networked services in
enterprise networks.

This package contains the SLP server. Every system, which provides any
services that should be used via an SLP client must run this server and
register the service.



Authors:
--------
    Matthew Peterson <mpeter...@calderasystems.com>
    John Calcote <john.calc...@gmail.com>
    Ganesan Rajagopal <rgane...@myrealbox.com>
    David McCormack <david.mccorm...@ottawa.com>
    Evan Hughes <hug...@lab43.org>
    Matthieu Desmons <m...@ocegr.fr>
    Praveen Kumar Amritaluru <prav...@india.hp.com>

%package devel
Requires:       openssl-devel openslp = %version
Group:          System/Daemons
Summary:        OpenSLP Development SDK
Requires: %{name} = %{version}-%{release}

%description devel
Service Location Protocol is an IETF standards track protocol that
provides a framework that allows networking applications to discover
the existence, location, and configuration of networked services in
enterprise networks.

This package contains header and library files to compile applications
with SLP support. It also contains developer documentation to develop
such applications.



Authors:
--------
    Matthew Peterson <mpeter...@calderasystems.com>
    John Calcote <john.calc...@gmail.com>
    Ganesan Rajagopal <rgane...@myrealbox.com>
    David McCormack <david.mccorm...@ottawa.com>
    Evan Hughes <hug...@lab43.org>
    Matthieu Desmons <m...@ocegr.fr>
    Praveen Kumar Amritaluru <prav...@india.hp.com>

%prep
%setup -q

#%patch0 -p1
#%patch1 -p1
%patch2 -p1

#re-automake avoids conflicts

libtoolize --force
aclocal
autoconf
automake --add-missing

%build
export CFLAGS="$RPM_OPT_FLAGS"
./configure \
  --prefix=%_prefix \
  --libdir=%_libdir \
  --sysconfdir=%_sysconfdir \
  --enable-async-api \
  --enable-slpv2-security \
  --localstatedir=/var
make %{?_smp_mflags}

%install
rm -rf ${RPM_BUILD_ROOT}
make DESTDIR=${RPM_BUILD_ROOT} install
mkdir -p ${RPM_BUILD_ROOT}/etc/slp.reg.d
mkdir -p ${RPM_BUILD_ROOT}/etc/init.d/
install -m 0755 etc/slpd.all_init ${RPM_BUILD_ROOT}/etc/init.d/slpd
ln -sf ../../etc/init.d/slpd ${RPM_BUILD_ROOT}/usr/sbin/rcslpd

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%post server
/sbin/chkconfig --add slpd

%postun server
if [ $1 -gt 0 ]; then
  /sbin/service slpd condrestart >/dev/null 2>&1 ||:
fi

%preun server
if [ $1 -eq 0 ]; then
  /sbin/service slpd stop >/dev/null 2>&1 ||:
  /sbin/chkconfig --del slpd
fi

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog NEWS README
%doc doc/doc/*
%_libdir/libslp.so.*
/usr/bin/slptool
%config(noreplace) /etc/slp.conf
%config(noreplace) /etc/slp.spi

%files server
%defattr(-,root,root)
%dir /etc/slp.reg.d/
%dir /var/log/
/usr/sbin/rcslpd
/usr/sbin/slpd
/etc/init.d/slpd
%config(noreplace) /etc/slp.reg

%files devel
%defattr(-,root,root)
/usr/include/slp.h
%_libdir/libslp.a
%_libdir/libslp.la
%_libdir/libslp.so

%changelog
* Tue Sep 7 2010 - ha...@us.ibm.com
- created from version 2.1-1636
------------------------------------------------------------------------------
WhatsUp Gold - Download Free Network Management Software
The most intuitive, comprehensive, and cost-effective network 
management toolset available today.  Delivers lowest initial 
acquisition cost and overall TCO of any competing solution.
http://p.sf.net/sfu/whatsupgold-sd
_______________________________________________
Openslp-devel mailing list
Openslp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openslp-devel

Reply via email to