Sophie

Sophie

distrib > Mageia > 8 > i586 > by-pkgid > 6988d81f8593f0602d2be8a066e0654a > files > 3

dhcp-forwarder-0.11-3.mga8.src.rpm

# OE: conditional switches
#
#(ie. use with rpm --rebuild):
#
#      --with diet     Compile dhcp-forwarder against dietlibc

%define build_diet 0

# commandline overrides:
# rpm -ba|--rebuild --with 'xxx'
%{?_with_diet: %{expand: %%define build_diet 1}}


Summary:	An DHCP relay agent
Name:		dhcp-forwarder
Version:	0.11
Release:	%mkrel 3
License:	GPL
Group:		System/Servers
URL:		http://www.nongnu.org/dhcp-fwd/
Source0:	http://savannah.nongnu.org/download/dhcp-fwd/%{name}-%{version}.tar.xz
Source1:	dhcp-fwd.init
Source2:	dhcp-forwarder.service
Conflicts:	dhcpd-relay
Requires(post):  rpm-helper >= 0.24.8-1
Requires(preun): rpm-helper >= 0.24.8-1

%if %{build_diet}
BuildRequires:	dietlibc-devel >= 0.20-1
%endif

%description
dhcp-fwd forwards DHCP messages between subnets with different sublayer
broadcast domains. It is similar to the DHCP relay agent dhcrelay of
ISC's DHCP, but has the following features which are important for me:

* Runs as non-root in a chroot-jail
* Uses "normal" AF_INET sockets which allows to uses packagefilters to
  filter incoming messages.
* The DHCP agent IDs can be defined freely
* Has a small memory footprint when using dietlibc

%prep
%setup -q

%build
%if %{build_diet}
%configure --enable-release enable-dietlibc
make CC="diet gcc" CFLAGS="-Os -s -static -nostdinc"
%else
%configure --enable-release --disable-dietlibc
%make
%endif

%install
%make_install

install -D -m 755 %{SOURCE1} %{buildroot}%{_initrddir}/dhcp-fwd
install -D -m 644 %{SOURCE2} %{buildroot}%{_unitdir}/dhcp-forwarder.service
install -D -m 644 contrib/dhcp-fwd.conf %{buildroot}%{_sysconfdir}/dhcp-fwd.conf
install -D -m 644 contrib/dhcp-fwd.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/dhcp-fwd

# (cg) Make sure we mask the sysvinit script name
ln -s dhcp-forwarder.service %{buildroot}%{_unitdir}/dhcp-fwd.service

install -m 755 -d %{buildroot}/var/lib/dhcpfwd

%pre
%_pre_useradd dhcp-fwd /var/lib/dhcpfwd /bin/false

%post
%_post_service dhcp-fwd

%preun
%_preun_service dhcp-fwd

%postun
%_postun_userdel dhcp-fwd

%files
%doc AUTHORS ChangeLog NEWS README
%{_initrddir}/dhcp-fwd
%{_unitdir}/dhcp-forwarder.service
%{_unitdir}/dhcp-fwd.service
%config(noreplace) %{_sysconfdir}/sysconfig/dhcp-fwd
%config(noreplace) %{_sysconfdir}/dhcp-fwd.conf
%{_sbindir}/*
%dir /var/lib/dhcpfwd
%{_mandir}/man1/*



%changelog
* Thu Feb 13 2020 umeabot <umeabot> 0.11-3.mga8
+ Revision: 1511830
- Mageia 8 Mass Rebuild
+ wally <wally>
- replace deprecated %%configure2_5x
- replace deprecated %%makeinstall_std

* Sun Sep 23 2018 umeabot <umeabot> 0.11-2.mga7
+ Revision: 1297436
- Mageia 7 Mass Rebuild

* Sat Mar 24 2018 kekepower <kekepower> 0.11-1.mga7
+ Revision: 1211991
- Update to version 0.11

* Fri Feb 05 2016 umeabot <umeabot> 0.8-15.mga6
+ Revision: 937443
- Mageia 6 Mass Rebuild

* Fri Feb 05 2016 umeabot <umeabot> 0.8-14.mga6
+ Revision: 936999
- Mageia 6 Mass Rebuild

* Wed Oct 15 2014 umeabot <umeabot> 0.8-13.mga5
+ Revision: 739404
- Second Mageia 5 Mass Rebuild

* Tue Sep 16 2014 umeabot <umeabot> 0.8-12.mga5
+ Revision: 678731
- Mageia 5 Mass Rebuild

* Fri Oct 18 2013 umeabot <umeabot> 0.8-11.mga4
+ Revision: 503830
- Mageia 4 Mass Rebuild

* Fri Jan 11 2013 umeabot <umeabot> 0.8-10.mga3
+ Revision: 348758
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sat Apr 28 2012 tmb <tmb> 0.8-9.mga2
+ Revision: 233667
- Require rpm-helper >= 0.24.8-1 for systemd support
- rebuild for versioned rpm-helper requires

* Sat Apr 21 2012 colin <colin> 0.8-7.mga2
+ Revision: 232341
- Neater masking of sysvinit script under systemd.

* Sat Apr 21 2012 colin <colin> 0.8-6.mga2
+ Revision: 232329
- Fix masked systemd unit link.

* Sat Apr 21 2012 colin <colin> 0.8-5.mga2
+ Revision: 232306
- Mask the sysvinit script with the systemd service.

* Fri Apr 20 2012 guillomovitch <guillomovitch> 0.8-4.mga2
+ Revision: 232007
- init script is not a configuration file
- spec cleanup
- systemd support

* Sun May 08 2011 nanardon <nanardon> 0.8-3.mga1
+ Revision: 96374
- imported package dhcp-forwarder


* Thu Dec 09 2010 Oden Eriksson <oeriksson@mandriva.com> 0.8-3mdv2011.0
+ Revision: 617577
- the mass rebuild of 2010.0 packages

* Sun Oct 04 2009 Oden Eriksson <oeriksson@mandriva.com> 0.8-2mdv2010.0
+ Revision: 453453
- rebuild

* Sun Jan 04 2009 Olivier Thauvin <nanardon@mandriva.org> 0.8-1mdv2009.1
+ Revision: 324864
- 0.8

* Wed Jul 23 2008 Thierry Vignaud <tv@mandriva.org> 0.7-5mdv2009.0
+ Revision: 244084
- rebuild

* Fri Dec 21 2007 Olivier Blin <oblin@mandriva.com> 0.7-3mdv2008.1
+ Revision: 136362
- restore BuildRoot

  + Thierry Vignaud <tv@mandriva.org>
    - kill re-definition of %%buildroot on Pixel's request


* Sun Aug 06 2006 Olivier Thauvin <nanardon@mandriva.org> 0.7-3mdv2007.0
+ Revision: 53234
- fix prereq
- %%mkrel
- Import dhcp-forwarder

* Sat Sep 10 2005 Oden Eriksson <oeriksson@mandriva.com> 0.7-2mdk
- rebuild

* Sat Aug 21 2004 Lenny Cartier <lenny@mandrakesoft.com> 0.7-1mdk
- 0.7

* Thu Jan 01 2004 Michael Scherer <misc@mandrake.org> 0.5-1mdk
- 0.5
- rework initfile a little, and extract it instead of patching it.
- various fix