Репозиторий ALT Linux backports/2.4
Последнее обновление: 9 июля 2008 | Пакетов: 497 | Посещений: 1571896
 поиск   регистрация   авторизация 
 
Группа :: Графические оболочки/KDE
Пакет: kdeadmin

 Главная   Изменения   Спек   Патчи   Загрузить   Bugs and FR 

%undefine __libtoolize
%define qtdir /usr/lib/qt3

%define unstable 0
%define lilo 0
%define kuser 0
%define kcmlinuz 0
%define kwuftpd 0
%define kpackage 0
%define kxconfig 0

%add_findprov_lib_path %_libdir/kde3

Name: kdeadmin
Version: 3.3.2
Release: alt0.0.M24
Serial: 1

Group: Graphical desktop/KDE
Summary: K Desktop Environment - Administrative Tools
Url: http://www.kde.org/
License: GPL

Source: kdeadmin-%version.tar.bz2
#Source: kdeadmin-3.0.98.tar.bz2
Source10: kpackage.pam
Source11: kpackage.helper
Source12: kuser.pam
Source13: kuser.helper
Source14: kwuftpd.pam
Source15: kwuftpd.helper

# ALT patches

Patch5000: kdeadmin-3.1.1-ksysv-alt.patch
Patch5001: kdeadmin-3.1-kpakage_db.patch
Patch5002: kdeadmin-3.2.3-alt_tcb.patch
Patch5003: kpackage-3.2.0-dist-upgrade.patch
Patch5004: kpackage-3.2.0-remove-unused-pkgmanagers.patch
Patch5005: kpackage-3.2.0-rpm-uninstall.patch
Patch5006: 3.2.0-flags.patch
Patch5007: kpackage-3.2.0-fix-start-via-consolehelper.patch
Patch5008: kuser-3.2.3-first-id.patch

Requires: %name-kcron = %version-%release
Requires: %name-kdat = %version-%release
Requires: %name-kfile = %version-%release
Requires: %name-ksysv = %version-%release
Requires: %name-secpolicy = %version-%release
%if %lilo
Requires: %name-lilo = %version-%release
%endif
%if %kcmlinuz
Requires: %name-kcmlinuz = %version-%release
%endif
%if %kpackage
Requires: %name-kpackage = %version-%release
%endif
%if %kwuftpd
Requires: %name-kwuftpd = %version-%release
%endif
%if %kuser
Requires: %name-kuser = %version-%release
%endif
%if %kxconfig
Requires: %name-kxconfig = %version-%release
%endif


# Automatically added by buildreq on Mon Apr 08 2002

#BuildRequires: XFree86-devel XFree86-libs bzlib-devel freetype2 gcc-c++ kde-common kdebase kdelibs-devel kdemultimedia-aktion libarts-devel libbeecrypt-devel libdb1-devel libdb4-devel libjpeg-devel liblcms libmng libpam-devel libpng-devel libpopt-devel libqt3-devel librpm-devel libstdc++-devel lilo zlib-devel

BuildRequires: XFree86-devel XFree86-libs bzlib-devel
BuildRequires: freetype2 gcc-c++ kde-common kdelibs-devel
#BuildRequires: kdebase
BuildRequires: libarts-devel libbeecrypt-devel libart_lgpl-devel
BuildRequires: libjpeg-devel liblcms libmng libpam-devel
BuildRequires: libpng-devel libpopt-devel libqt3-devel libstdc++-devel zlib-devel
BuildRequires: kdelibs-devel-cxx = %__gcc_version_base
BuildRequires: kdelibs > 3.0 kdelibs-devel > 3.0
%if %lilo
BuildRequires: lilo
%endif
%if %kpackage
BuildRequires: librpm-devel
%endif

%description
Administrative tools for the K Desktop Environment.

%package common
Summary: Common empty package for %name
Group: Graphical desktop/KDE
Requires: kde-common >= 3.2
Conflicts: kdeadmin <= 3.0.1
#
%description common
Common empty package for %name

%package kcron
Group: System/Configuration/Other
Summary: Crontab editor for KDE
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kcron
KCron is a crontab editor for KDE - it helps you make your system run
commands periodically.

%package kdat
Group: Archiving/Backup
Summary: Tape backup tool for KDE
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kdat
KDat is a KDE application for controlling tape backups.

%package kfile
Summary: KDE File dialog plugins for deb and rpm files
Group: File tools
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
Provides: %name-kfile-plugins = %serial:%version-%release
Obsoletes: %name-kfile-plugins
#
%description kfile
File dialog plugins for deb and rpm package files.

%package kpackage
Group: System/Configuration/Packaging
Summary: KDE package manager
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
Requires: consolehelper
#
%description kpackage
KPackage is a graphical frontend for RPM and other package managers.

%package ksysv
Group: System/Configuration/Boot and Init
Summary: System V startup editor
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description ksysv
KSysV is a graphical frontend for configuring your runlevels (system
startup/shutdown sequence).

%package kuser
Group: System/Configuration/Other
Summary: Frontend for configuring users and user groups
Requires: consolehelper
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kuser
KUser is a graphical frontend for managing the users and user groups on
your system.

%package kwuftpd
Group: System/Configuration/Networking
Summary: Graphical interface for configuring wu-ftpd
Requires: consolehelper
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kwuftpd
KWuftpd is a graphical frontend for configuring the wu-ftpd ftp server.

%package kcmlinuz
Group: System/Configuration/Other
Summary: Linux kernel configurator for KDE
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kcmlinuz
kcmlinuz is a graphical frontend for creating configuration files for compiling
kernels.

%package lilo
Group: System/Configuration/Boot and Init
Summary: Graphical frontend for configuring the LILO bootloader
Requires: lilo
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description lilo
kdeadmin-lilo is a KDE frontend for configuring the LILO bootloader.

%package kxconfig
Summary: KDE display configuration tool
Group: System/Configuration/Hardware
Conflicts: %name < %version
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description kxconfig
This program allows you to configure your X display.

%package secpolicy
Summary: KDE PAM security policy configuration tool
Group: System/Configuration/Other
Requires: %{get_dep kdelibs}
Requires: %name-common = %version-%release
#
%description secpolicy
This tool allows you to manipulate the PAM configuration files for each
"service" you have created to use PAM.

%prep
%setup -q -n %name-%version
#%setup -q -n %name-3.0.98

%patch5000 -p1
#%patch5001 -p1
# kuser
###%patch5002 -p1
%patch5003 -p1
###%patch5004 -p1
%patch5005 -p1
%patch5006 -p1
%patch5007 -p1
###%patch5008 -p1

subst "s/\(Wl,--no-undefined\)/-Wl,--warn-unresolved-symbols \1/g" admin/acinclude.m4.in
subst "s/\-lkdeui/-lkdeui -lpthread/g" admin/acinclude.m4.in
subst "s/\.la/.so/g" admin/acinclude.m4.in
make -f admin/Makefile.common cvs ||:

%build
rm -rf %buildroot
export QTDIR=%qtdir
export KDEDIR=%prefix

export PATH=$QTDIR/bin:$KDEDIR/bin:$PATH

export LD_LIBRARY_PATH=$QTDIR/lib:$KDEDIR/lib:$LD_LIBRARY_PATH
export LDFLAGS="-L%buildroot/%_libdir -L%buildroot/%_libdir/kde3 -L%_libdir"

%if !%kuser
DO_NOT_COMPILE="$DO_NOT_COMPILE kuser"
%endif
%if !%kwuftpd
DO_NOT_COMPILE="$DO_NOT_COMPILE kwuftpd"
%endif
%if !%kcmlinuz
DO_NOT_COMPILE="$DO_NOT_COMPILE kcmlinuz"
%endif
%if !%kpackage
DO_NOT_COMPILE="$DO_NOT_COMPILE kpackage"
%endif
%if !%kxconfig
DO_NOT_COMPILE="$DO_NOT_COMPILE kxconfig"
%endif
%if !%lilo
DO_NOT_COMPILE="$DO_NOT_COMPILE lilo-config"
%endif

[ -n "$DO_NOT_COMPILE" ] && export DO_NOT_COMPILE

%configure \
%if %unstable
--enable-debug=full \
%else
--disable-debug \
%endif
                   --enable-final \
                   --enable-shared \
                   --disable-static \
                   --disable-objprelink \
                   --enable-xinerama \
                   --disable-rpath \
                   --with-rpm \
                   --with-shadow \
                   --without-quota \
   --without-nis \
                   --with-homeprefix=/home \
                   --with-private-groups \
   --with-first-uid=500 \
   --with-first-gid=500 \
   --with-mailbox-gid=8 \
%if !%kuser
   --without-kuser \
%endif
%if !%kwuftpd
   --without-kwuftpd \
%endif
%if !%kcmlinuz
   --without-kcmlinuz \
%endif
%if !%kpackage
   --without-kpackage \
%endif
%if !%kxconfig
   --without-kxconfig \
%endif
%if !%lilo
   --without-lilo-config \
%endif
   --program-transform-name="" \
                   --with-pam=yes \

%make_build

%install
%if %unstable
%set_strip_method none
%endif
export PATH=%_bindir:$PATH

%make_build \
   DESTDIR=%buildroot \
   prefix=%prefix \
   exec_prefix=%prefix \
install

# Create LMDK menu directory

install -d %buildroot/%_menudir/

export PATH=%_bindir:$PATH

# %%_datadir/applnk/Settings/System

%if %lilo
%Kd2m %name-lilo "Configuration/Boot and Init" %Kbmenudir/lilo.desktop %Kb_menudir/%name-lilo kde
%endif
# %%_datadir/applnk/System
%Kd2m %name-kcron Configuration/Other %Kbmenudir/kcron.desktop %Kb_menudir/%name-kcron
%Kd2m %name-ksysv "Configuration/Boot and Init" %Kbmenudir/ksysv.desktop %Kb_menudir/%name-ksysv
%Kd2m %name-kdat "Applications/Archiving/Backup" %Kbmenudir/kdat.desktop %Kb_menudir/%name-kdat
%if %kxconfig
%Kd2m %name-kxconfig Configuration/Hardware %Kbmenudir/kxconfig.desktop %Kb_menudir/%name-kxconfig
%endif
%if %kcmlinuz
%Kd2m %name-kcmlinuz Configuration/Other %Kbmenudir/linuz.desktop %Kb_menudir/%name-kcmlinuz kde
%endif
%if %kuser
%Kd2m %name-kuser Configuration/Other %Kbmenudir/kuser.desktop %Kb_menudir/%name-kuser
%endif
%if %kwuftpd
%Kd2m %name-kwuftpd Configuration/Networking %Kbmenudir/kwuftpd.desktop %Kb_menudir/%name-kwuftpd
%endif
%if %kpackage
%Kd2m %name-kpackage Configuration/Packaging %Kbmenudir/kpackage.desktop %Kb_menudir/%name-kpackage
%endif

mkdir -p %buildroot/%prefix/sbin \
        %buildroot/%_sysconfdir/pam.d \
        %buildroot/%_sysconfdir/security/console.apps

%if %kpackage
install -c -m 644 %SOURCE11 %buildroot/%_sysconfdir/security/console.apps/kpackage
install -c -m 644 %SOURCE10 %buildroot/%_sysconfdir/pam.d/kpackage
mv %buildroot/%_bindir/kpackage %buildroot/%_sbindir
(cd %buildroot/%_bindir && ln -fs consolehelper kpackage)
%endif

%if %kuser
install -c -m 644 %SOURCE13 %buildroot/%_sysconfdir/security/console.apps/kuser
install -c -m 644 %SOURCE12 %buildroot/%_sysconfdir/pam.d/kuser
mv %buildroot/%_bindir/kuser %buildroot/%_sbindir
(cd %buildroot/%_bindir && ln -fs consolehelper kuser)
%endif

%if %kwuftpd
install -c -m 644 %SOURCE15 %buildroot/%_sysconfdir/security/console.apps/kwuftpd
install -c -m 644 %SOURCE14 %buildroot/%_sysconfdir/pam.d/kwuftpd
mv %buildroot/%_bindir/kwuftpd %buildroot/%_sbindir
(cd %buildroot/%_bindir && ln -fs consolehelper kwuftpd)
%endif

%post kcron
%update_menus
%postun kcron
%clean_menus

%post kdat
%update_menus
%postun kdat
%clean_menus

%post kpackage
%update_menus
%postun kpackage
%clean_menus

%post ksysv
%update_menus
%postun ksysv
%clean_menus

%post kuser
%update_menus
%postun kuser
%clean_menus

%post kwuftpd
%update_menus
%postun kwuftpd
%clean_menus

%post kcmlinuz
%update_menus
%postun kcmlinuz
%clean_menus

%post lilo
%update_menus
%postun lilo
%clean_menus

%post kxconfig
%update_menus
%postun kxconfig
%clean_menus

%files
%files common
%files kcron
%_bindir/kcron
%Kmenudir/kcron.desktop
%_datadir/icons/*/*/apps/kcron*
%doc %_docdir/HTML/en/kcron
%_menudir/kdeadmin-kcron

%files kdat
%_bindir/kdat
%_datadir/apps/kdat
%Kmenudir/kdat.desktop
%_iconsdir/*/*/*/kdat.png
%doc %_docdir/HTML/en/kdat
%_menudir/kdeadmin-kdat

%files kfile
%_libdir/kde3/kfile_*.la
%_libdir/kde3/kfile_*.so
%_datadir/services/kfile_*.desktop

%if %kpackage
%files kpackage
%_bindir/kpackage
%_sbindir/kpackage
%_datadir/apps/kpackage
%_datadir/icons/*/*/apps/kpackage.png
%Kmenudir/kpackage.desktop
%_datadir/mimelnk/application/x-debian-package.desktop
%config(noreplace) %_sysconfdir/pam.d/kpackage
%config(noreplace) %_sysconfdir/security/console.apps/kpackage
%doc %_docdir/HTML/en/kpackage
%_menudir/kdeadmin-kpackage
%endif

%files ksysv
%_bindir/ksysv
%_datadir/apps/ksysv
%Kmenudir/ksysv.desktop
%_datadir/icons/*/*/apps/ksysv*
%_datadir/mimelnk/application/x-ksysv.desktop
%_datadir/mimelnk/text/x-ksysv-log.desktop
%_datadir/icons/*/*/actions/toggle_log.png
%doc %_docdir/HTML/en/ksysv
%_menudir/kdeadmin-ksysv

%if %kuser
%files kuser
#%config %_datadir/config/kuserrc
%_bindir/kuser
%_sbindir/kuser
%_datadir/apps/kuser
%Kmenudir/kuser.desktop
%_datadir/icons/*/*/apps/kuser*
%config(noreplace) %_sysconfdir/pam.d/kuser
%config(noreplace) %_sysconfdir/security/console.apps/kuser
%doc %_docdir/HTML/en/kuser
%_menudir/kdeadmin-kuser
%endif

%if %kwuftpd
%files kwuftpd
%_bindir/kwuftpd
%_sbindir/kwuftpd
%Kmenudir/kwuftpd.desktop
%config(noreplace) %_sysconfdir/pam.d/kwuftpd
%config(noreplace) %_sysconfdir/security/console.apps/kwuftpd
%doc %_docdir/HTML/en/kwuftpd
%_menudir/kdeadmin-kwuftpd
%endif

%if %kcmlinuz
%files kcmlinuz
%_datadir/apps/kcmlinuz
%Kmenudir/linuz.desktop
%_libdir/kde3/kcm_linuz*
%_menudir/kdeadmin-kcmlinuz
%endif

%if %lilo
%files lilo
%Kmenudir/lilo.desktop
%_libdir/kde3/kcm_lilo*
%_menudir/kdeadmin-lilo
%endif

%if %kxconfig
%files kxconfig
%_bindir/kxconfig
%_datadir/apps/kxconfig
%_iconsdir/*/*/*/kxconfig.png
%doc %_docdir/HTML/en/kxconfig
#
%Kmenudir/kxconfig.desktop
%_menudir/kdeadmin-kxconfig
%endif

%files secpolicy
%_bindir/secpolicy

%changelog

Полный changelog можно просмотреть здесь

 
design & coding: Vladimir Lettiev aka crux © 2004-2005