Group :: Sistema/Configurações/Rede
RPM: guarddog
Main Changelog Spec Patches Sources Download Gear Bugs e FR Repocop
%undefine __libtoolize
%define scriptname /etc/rc.d/rc.firewall
Name: guarddog
Version: 2.4.0
Release: alt1
Group: System/Configuration/Networking
Summary: Firewall Utility
Url: http://www.simonzone.com/software/guarddog/
License: GPL
Requires: iptables gawk coreutils sed
Source: %name-%version.tar.bz2
Patch1: guarddog-2.3.2-script_place.patch
# Automatically added by buildreq on Thu Dec 16 2004 (-bi)
#BuildRequires: fontconfig freetype2 gcc-c++ gcc-g77 kde-settings kdelibs-devel libarts-devel libjpeg-devel libpng-devel libqt3-devel libqt3-settings libstdc++-devel menu-devel qt3-designer xml-utils xorg-x11-devel xorg-x11-libs zlib-devel
BuildRequires: fontconfig freetype2 gcc-c++ kdelibs-devel libarts-devel
BuildRequires: libjpeg-devel libpng-devel libqt3-devel libstdc++-devel
BuildRequires: menu-devel qt3-designer xml-utils XFree86-devel XFree86-libs zlib-devel
BuildRequires: kdelibs-devel-cxx = %__gcc_version_base
%description
Guarddog is user friendly firewall generation and management utility for KDE
on Linux. It allows you to simply specify which protocols should be allowed
between which groups of computers and requires no knowledge of port numbers
or packets. Built on top of ipchains and/or iptables.
%prep
%setup -q
%patch1 -p1
subst "s/\(Wl,--no-undefined\)/-Wl,--warn-unresolved-symbols \1/g" ./configure
subst "s/\-lkdeui/-lkdeui -lpthread/g" ./configure
subst "s/\.la/.so/g" ./configure
#make -f admin/Makefile.common cvs
%build
export CFLAGS="%optflags" CXXFLAGS="%optflags"
%configure \
--enable-final \
--disable-static \
--enable-shared \
--disable-rpath
# --with-kde-version=3
%make_build
%install
%make install DESTDIR=%buildroot
rm -f %buildroot/%_menudir/*
%Kd2m %name Configuration/Networking %Kbapplnk/System/guarddog.desktop %Kb_menudir/%name
%find_lang --with-kde %name
%post
%update_menus
if [ ! -e %scriptname ]; then
echo "#!/bin/sh" > %scriptname
echo "# This is just a place holder rc.firewall file so that when the links" >> %scriptname
echo "# /sbin/ifup-local and /sbin/ifdown-local have something valid to point to." >> %scriptname
echo "# It will be over written once the Guarddog configuration utility is used." >> %scriptname
echo "# --Guarddog, http://www.simonzone.com/software/guarddog/" >> %scriptname
chmod u+x %scriptname
fi
if [ ! -x /sbin/ifup-local ]; then
ln -s %scriptname /sbin/ifup-local
else
if [ ! -L /sbin/ifup-local ]; then
echo "*** Warning: Could not make a link from /sbin/ifup-local to %scriptname ***"
fi
fi
if [ ! -x /sbin/ifdown-local ]; then
ln -s %scriptname /sbin/ifdown-local
else
if [ ! -L /sbin/ifdown-local ]; then
echo "*** Warning: Could not make a link from /sbin/ifdown-local to %scriptname ***"
fi
fi
if [ ! -e /etc/ppp/ip-up.local ]; then
echo "#!/bin/sh" > /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "# This short script just runs any firewall script located at %scriptname ." >> /etc/ppp/ip-up.local
echo "# It will be called whenever a ppp interface comes up. Normally we would hook" >> /etc/ppp/ip-up.local
echo "# our firewall script in via /sbin/ifup-local, but a bug in the" >> /etc/ppp/ip-up.local
echo "# /etc/ppp/ip-up script prevents that from working. This script provides a" >> /etc/ppp/ip-up.local
echo "# workaround." >> /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "# cheers, Guardddog http://www.simonzone.com/software/guarddog/" >> /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "[ -x %scriptname ] && %scriptname" >> /etc/ppp/ip-up.local
chmod u+x /etc/ppp/ip-up.local
fi
if [ ! -e /etc/ppp/ip-down.local ]; then
echo "#!/bin/sh" > /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "# This short script just runs any firewall script located at %scriptname ." >> /etc/ppp/ip-down.local
echo "# It will be called whenever a ppp interface goes down. Normally we would hook" >> /etc/ppp/ip-down.local
echo "# our firewall script in via /sbin/ifdown-local, but a bug in the" >> /etc/ppp/ip-down.local
echo "# /etc/ppp/ip-down script prevents that from working. This script provides a" >> /etc/ppp/ip-down.local
echo "# workaround." >> /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "# cheers, Guardddog http://www.simonzone.com/software/guarddog/" >> /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "[ -x %scriptname ] && %scriptname" >> /etc/ppp/ip-down.local
chmod u+x /etc/ppp/ip-down.local
fi
%postun
%clean_menus
%files -f %name.lang
%doc README TODO AUTHORS COPYING ChangeLog
%_bindir/%name
%_datadir/apps/%name
%_datadir/sgml/protocoldb
#%doc %_docdir/HTML/en/%name
%_iconsdir/*/*/apps/guarddog.png
%_datadir/applnk/System/guarddog.desktop
%_menudir/%name
%changelog
…
Todas as alterações você pod ver aqui
%define scriptname /etc/rc.d/rc.firewall
Name: guarddog
Version: 2.4.0
Release: alt1
Group: System/Configuration/Networking
Summary: Firewall Utility
Url: http://www.simonzone.com/software/guarddog/
License: GPL
Requires: iptables gawk coreutils sed
Source: %name-%version.tar.bz2
Patch1: guarddog-2.3.2-script_place.patch
# Automatically added by buildreq on Thu Dec 16 2004 (-bi)
#BuildRequires: fontconfig freetype2 gcc-c++ gcc-g77 kde-settings kdelibs-devel libarts-devel libjpeg-devel libpng-devel libqt3-devel libqt3-settings libstdc++-devel menu-devel qt3-designer xml-utils xorg-x11-devel xorg-x11-libs zlib-devel
BuildRequires: fontconfig freetype2 gcc-c++ kdelibs-devel libarts-devel
BuildRequires: libjpeg-devel libpng-devel libqt3-devel libstdc++-devel
BuildRequires: menu-devel qt3-designer xml-utils XFree86-devel XFree86-libs zlib-devel
BuildRequires: kdelibs-devel-cxx = %__gcc_version_base
%description
Guarddog is user friendly firewall generation and management utility for KDE
on Linux. It allows you to simply specify which protocols should be allowed
between which groups of computers and requires no knowledge of port numbers
or packets. Built on top of ipchains and/or iptables.
%prep
%setup -q
%patch1 -p1
subst "s/\(Wl,--no-undefined\)/-Wl,--warn-unresolved-symbols \1/g" ./configure
subst "s/\-lkdeui/-lkdeui -lpthread/g" ./configure
subst "s/\.la/.so/g" ./configure
#make -f admin/Makefile.common cvs
%build
export CFLAGS="%optflags" CXXFLAGS="%optflags"
%configure \
--enable-final \
--disable-static \
--enable-shared \
--disable-rpath
# --with-kde-version=3
%make_build
%install
%make install DESTDIR=%buildroot
rm -f %buildroot/%_menudir/*
%Kd2m %name Configuration/Networking %Kbapplnk/System/guarddog.desktop %Kb_menudir/%name
%find_lang --with-kde %name
%post
%update_menus
if [ ! -e %scriptname ]; then
echo "#!/bin/sh" > %scriptname
echo "# This is just a place holder rc.firewall file so that when the links" >> %scriptname
echo "# /sbin/ifup-local and /sbin/ifdown-local have something valid to point to." >> %scriptname
echo "# It will be over written once the Guarddog configuration utility is used." >> %scriptname
echo "# --Guarddog, http://www.simonzone.com/software/guarddog/" >> %scriptname
chmod u+x %scriptname
fi
if [ ! -x /sbin/ifup-local ]; then
ln -s %scriptname /sbin/ifup-local
else
if [ ! -L /sbin/ifup-local ]; then
echo "*** Warning: Could not make a link from /sbin/ifup-local to %scriptname ***"
fi
fi
if [ ! -x /sbin/ifdown-local ]; then
ln -s %scriptname /sbin/ifdown-local
else
if [ ! -L /sbin/ifdown-local ]; then
echo "*** Warning: Could not make a link from /sbin/ifdown-local to %scriptname ***"
fi
fi
if [ ! -e /etc/ppp/ip-up.local ]; then
echo "#!/bin/sh" > /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "# This short script just runs any firewall script located at %scriptname ." >> /etc/ppp/ip-up.local
echo "# It will be called whenever a ppp interface comes up. Normally we would hook" >> /etc/ppp/ip-up.local
echo "# our firewall script in via /sbin/ifup-local, but a bug in the" >> /etc/ppp/ip-up.local
echo "# /etc/ppp/ip-up script prevents that from working. This script provides a" >> /etc/ppp/ip-up.local
echo "# workaround." >> /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "# cheers, Guardddog http://www.simonzone.com/software/guarddog/" >> /etc/ppp/ip-up.local
echo "#" >> /etc/ppp/ip-up.local
echo "[ -x %scriptname ] && %scriptname" >> /etc/ppp/ip-up.local
chmod u+x /etc/ppp/ip-up.local
fi
if [ ! -e /etc/ppp/ip-down.local ]; then
echo "#!/bin/sh" > /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "# This short script just runs any firewall script located at %scriptname ." >> /etc/ppp/ip-down.local
echo "# It will be called whenever a ppp interface goes down. Normally we would hook" >> /etc/ppp/ip-down.local
echo "# our firewall script in via /sbin/ifdown-local, but a bug in the" >> /etc/ppp/ip-down.local
echo "# /etc/ppp/ip-down script prevents that from working. This script provides a" >> /etc/ppp/ip-down.local
echo "# workaround." >> /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "# cheers, Guardddog http://www.simonzone.com/software/guarddog/" >> /etc/ppp/ip-down.local
echo "#" >> /etc/ppp/ip-down.local
echo "[ -x %scriptname ] && %scriptname" >> /etc/ppp/ip-down.local
chmod u+x /etc/ppp/ip-down.local
fi
%postun
%clean_menus
%files -f %name.lang
%doc README TODO AUTHORS COPYING ChangeLog
%_bindir/%name
%_datadir/apps/%name
%_datadir/sgml/protocoldb
#%doc %_docdir/HTML/en/%name
%_iconsdir/*/*/apps/guarddog.png
%_datadir/applnk/System/guarddog.desktop
%_menudir/%name
%changelog
…
Todas as alterações você pod ver aqui