From 2eda4a09d5e44cb3b09e7333f2939b2c7694948acd6919f07acccaa4fdd838ed Mon Sep 17 00:00:00 2001
From: OBS User buildservice-autocommit <null@suse.de>
Date: Wed, 1 Dec 2010 01:06:13 +0000
Subject: [PATCH 1/2] Updating link to change in openSUSE:Factory/dhcp revision
 41.0

OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=e2a50348a544589fd613a9e79b6b352b
---
 dhcp.spec | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dhcp.spec b/dhcp.spec
index 27929eb..1fbdde5 100644
--- a/dhcp.spec
+++ b/dhcp.spec
@@ -33,7 +33,7 @@ License:        BSD3c(or similar)
 Group:          Productivity/Networking/Boot/Servers
 AutoReqProv:    on
 Version:        4.2.0.P1
-Release:        0
+Release:        1
 Summary:        Common Files Used by ISC DHCP Software
 Url:            http://www.isc.org/software/dhcp
 Source0:        dhcp-%{isc_version}.tar.bz2

From 2ee797eb70f12132739ae99a42ac424c4300a478649355f1e1369de39577f855 Mon Sep 17 00:00:00 2001
From: Marius Tomaschewski <mt@suse.com>
Date: Tue, 7 Dec 2010 14:52:41 +0000
Subject: [PATCH 2/2] - Enable ldap CASA support on SLE only.

OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=49
---
 dhcp.changes |  5 +++++
 dhcp.spec    | 17 +++++++++++------
 2 files changed, 16 insertions(+), 6 deletions(-)

diff --git a/dhcp.changes b/dhcp.changes
index f81f908..1d33b09 100644
--- a/dhcp.changes
+++ b/dhcp.changes
@@ -1,3 +1,8 @@
+-------------------------------------------------------------------
+Tue Dec  7 14:50:23 UTC 2010 - mt@suse.de
+
+- Enable ldap CASA support on SLE only.
+
 -------------------------------------------------------------------
 Tue Nov 30 21:56:04 UTC 2010 - mt@suse.de
 
diff --git a/dhcp.spec b/dhcp.spec
index 1fbdde5..69de6f3 100644
--- a/dhcp.spec
+++ b/dhcp.spec
@@ -22,10 +22,13 @@
 %define omc_prefix    /usr/share/omc
 %define omc_svcdir    %{omc_prefix}/svcinfo.d
 %define with_ldap     1
+%define with_ldapcasa 0%{?sles_version} > 0
 
 Name:           dhcp
-%if 0%{?with_ldap:1}
+%if 0%{?with_ldap}
+%if 0%{?with_ldapcasa}
 BuildRequires:  CASA-devel
+%endif
 BuildRequires:  openldap2-devel
 %endif
 BuildRequires:  dos2unix
@@ -198,7 +201,7 @@ Authors:
 %patch15 -p0
 %patch20 -p1
 %patch21 -p1
-%if 0%{?with_ldap:1}
+%if 0%{?with_ldap}
 %patch30 -p1
 %endif
 %patch39 -p1
@@ -235,10 +238,12 @@ autoreconf
 	--enable-failover \
 	--enable-paranoia \
 	--enable-early-chroot \
-%if 0%{?with_ldap:%with_ldap}
+%if 0%{?with_ldap}
 	--with-ldap \
 	--with-ldapcrypto \
+%if 0%{with_ldapcasa}
 	--with-ldapcasa \
+%endif
 %endif
 	--with-cli-pid-file=%{_localstatedir}/run/dhclient.pid \
 	--with-cli-lease-file=%{_localstatedir}/lib/dhcp/dhclient.leases \
@@ -272,7 +277,7 @@ install -d -m0755 $RPM_BUILD_ROOT/sbin
 install -d -m0755 $RPM_BUILD_ROOT%{_sysconfdir}/init.d
 install -d -m0755 $RPM_BUILD_ROOT/%{susefw2dir}
 install -d -m0755 $RPM_BUILD_ROOT/%{omc_svcdir}
-%if 0%{?with_ldap:%with_ldap}
+%if 0%{?with_ldap}
 install -d -m0755 $RPM_BUILD_ROOT%{_sysconfdir}/openldap/schema
 %endif
 install -d -m0755 $RPM_BUILD_ROOT%{_localstatedir}/run
@@ -320,7 +325,7 @@ install    -m0644 $RPM_SOURCE_DIR/sysconfig.syslog-dhcpd    \
 install    -m0644 $RPM_SOURCE_DIR/sysconfig.dhcrelay        \
                   $RPM_BUILD_ROOT%{_localstatedir}/adm/fillup-templates/
 # another config files and scripts
-%if 0%{?with_ldap:%with_ldap}
+%if 0%{?with_ldap}
 install    -m0644 contrib/ldap/dhcp.schema                       \
                   $RPM_BUILD_ROOT%{_sysconfdir}/openldap/schema
 %endif
@@ -445,7 +450,7 @@ if ! test -f /.buildenv; then rm -rf $RPM_BUILD_ROOT; fi
 %doc %{_mandir}/man8/dhcpd.8.gz
 %doc %{_mandir}/man5/dhcpd.conf.5.gz
 %doc %{_mandir}/man5/dhcpd.leases.5.gz
-%if 0%{?with_ldap:%with_ldap}
+%if 0%{?with_ldap}
 %dir %{_sysconfdir}/openldap
 %dir %{_sysconfdir}/openldap/schema
 %attr(0644, root, root) %config %{_sysconfdir}/openldap/schema/dhcp.schema