Репозитории ALT
S: | 2.9.11-alt1 |
5.1: | 2.8.13-alt1 |
4.1: | 2.8.13-alt0.M41.1 |
4.0: | 2.8.10-alt1 |
3.0: | 2.8.2-alt1 |
Группа :: Система/Библиотеки
Пакет: cracklib
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
%define _unpackaged_files_terminate_build 1
%def_disable python
%def_disable python2
Name: cracklib
Version: 2.9.11
Release: alt1
Summary: A password-checking library.
License: LGPL-2.1-or-later
Group: System/Libraries
Url: https://github.com/%name/%name
Source: https://github.com/%name/%name/releases/download/v%version/%name-%version.tar.xz
Requires: %name-utils = %EVR
BuildRequires: libX11-devel libICE-devel
BuildRequires: zlib-devel
%{?_enable_python:BuildRequires(pre): rpm-build-python3
BuildRequires: python3-devel}
%{?_enable_python2:BuildRequires(pre): rpm-build-python
BuildRequires: python-devel}
%package utils
Summary: The CrackLib utilities for the build dictionaries.
Group: System/Libraries
Requires: %name = %EVR
%package devel
Summary: %name link library & header file
Group: Development/C
Requires: %name = %EVR
%package -n python-module-%name
Summary: Python module of %name
Group: Development/Python
Requires: %name = %EVR
%package -n python3-module-%name
Summary: Python3 module of %name
Group: Development/Python
Requires: %name = %EVR
%description
CrackLib tests passwords to determine whether they match certain
security-oriented characteristics. You can use CrackLib to stop
users from choosing passwords which would be easy to guess. CrackLib
performs certain tests:
* It tries to generate words from a username and gecos entry and
checks those words against the password;
* It checks for simplistic patterns in passwords;
* It checks for the password in a dictionary.
CrackLib is actually a library containing a particular
C function which is used to check the password, as well as
other C functions. CrackLib is not a replacement for a passwd
program; it must be used in conjunction with an existing passwd
program.
Install the %name package if you need a program to check users'
passwords to see if they are at least minimally secure. If you
install CrackLib, you'll also want to install the %name-words
package.
%description devel
The %name devel package include the needed library link and
header files for development.
%description utils
The %name-utils package includes the utilities necessary to
create new dictionaries for Cracklib.
%description -n python-module-%name
This package includes Python module for Cracklib.
%description -n python3-module-%name
This package includes Python3 module for Cracklib.
%prep
%setup -n %name-%version
%{?_enable_python2:%setup -D -c -n %name-%version
mv %name-%version py2build
%autopatch -p1}
%build
%if_enabled python
export PYTHON=python3
export am_cv_python_version=%__python3_version%_python3_abiflags
%add_optflags `pkg-config --cflags python3`
%endif
%add_optflags %(getconf LFS_CFLAGS)
%autoreconf
%configure \
--disable-static \
%{?_disable_python:--without-python}
%nil
%make_build
%if_enabled python2
pushd py2build
export PYTHON=python2
export am_cv_python_version=%__python_version
%autoreconf
%configure \
--disable-static \
--with-x
%make_build
popd
%endif
%install
%makeinstall_std
%if_enabled python
%if "%_libsuff" == "64"
mv %buildroot%python3_sitelibdir_noarch/* \
%buildroot%python3_sitelibdir/
%endif
%endif
%if_enabled python2
pushd py2build
%makeinstall_std
%if "%_libsuff" == "64"
mv %buildroot%python_sitelibdir_noarch/* \
%buildroot%python_sitelibdir/
%endif
popd
%endif
# create words database
touch %buildroot%_datadir/%name/pw_dict.{hwm,pwd,pwi}
cat > %name.filetrigger << _EOF_
#!/bin/sh -e
dir=%_datadir/%name
grep -qs '^'\$dir'' && %_sbindir/%name-format \$dir/%{name}* | %_sbindir/%name-packer \$dir/pw_dict >/dev/null ||:
_EOF_
install -pD -m 755 %name.filetrigger %buildroot%_rpmlibdir/%name.filetrigger
mkdir -p %buildroot%_sysconfdir/%name
cat > %buildroot%_sysconfdir/%name/%name.conf << _EOF_
# This is configuration file for cracklib-update.
# See update-cracklib(8) for details.
_EOF_
%find_lang %name
%files -f %name.lang
%_libdir/*.so.*
%_datadir/%name/
%_rpmlibdir/%name.filetrigger
%doc AUTHORS ChangeLog NEWS README*
%files devel
%_includedir/*
%_libdir/*.so
%doc %_man3dir/*
%files utils
%_sysconfdir/%name/%name.conf
%_sbindir/*
%_man8dir/*
%if_enabled python
%files -n python3-module-%name
%python3_sitelibdir/*
%exclude %python3_sitelibdir/*.la
%endif
%if_enabled python2
%files -n python-module-%name
%python_sitelibdir/*
%exclude %python_sitelibdir/*.la
%endif
%changelog
…
Полный changelog можно просмотреть здесь
%def_disable python
%def_disable python2
Name: cracklib
Version: 2.9.11
Release: alt1
Summary: A password-checking library.
License: LGPL-2.1-or-later
Group: System/Libraries
Url: https://github.com/%name/%name
Source: https://github.com/%name/%name/releases/download/v%version/%name-%version.tar.xz
Requires: %name-utils = %EVR
BuildRequires: libX11-devel libICE-devel
BuildRequires: zlib-devel
%{?_enable_python:BuildRequires(pre): rpm-build-python3
BuildRequires: python3-devel}
%{?_enable_python2:BuildRequires(pre): rpm-build-python
BuildRequires: python-devel}
%package utils
Summary: The CrackLib utilities for the build dictionaries.
Group: System/Libraries
Requires: %name = %EVR
%package devel
Summary: %name link library & header file
Group: Development/C
Requires: %name = %EVR
%package -n python-module-%name
Summary: Python module of %name
Group: Development/Python
Requires: %name = %EVR
%package -n python3-module-%name
Summary: Python3 module of %name
Group: Development/Python
Requires: %name = %EVR
%description
CrackLib tests passwords to determine whether they match certain
security-oriented characteristics. You can use CrackLib to stop
users from choosing passwords which would be easy to guess. CrackLib
performs certain tests:
* It tries to generate words from a username and gecos entry and
checks those words against the password;
* It checks for simplistic patterns in passwords;
* It checks for the password in a dictionary.
CrackLib is actually a library containing a particular
C function which is used to check the password, as well as
other C functions. CrackLib is not a replacement for a passwd
program; it must be used in conjunction with an existing passwd
program.
Install the %name package if you need a program to check users'
passwords to see if they are at least minimally secure. If you
install CrackLib, you'll also want to install the %name-words
package.
%description devel
The %name devel package include the needed library link and
header files for development.
%description utils
The %name-utils package includes the utilities necessary to
create new dictionaries for Cracklib.
%description -n python-module-%name
This package includes Python module for Cracklib.
%description -n python3-module-%name
This package includes Python3 module for Cracklib.
%prep
%setup -n %name-%version
%{?_enable_python2:%setup -D -c -n %name-%version
mv %name-%version py2build
%autopatch -p1}
%build
%if_enabled python
export PYTHON=python3
export am_cv_python_version=%__python3_version%_python3_abiflags
%add_optflags `pkg-config --cflags python3`
%endif
%add_optflags %(getconf LFS_CFLAGS)
%autoreconf
%configure \
--disable-static \
%{?_disable_python:--without-python}
%nil
%make_build
%if_enabled python2
pushd py2build
export PYTHON=python2
export am_cv_python_version=%__python_version
%autoreconf
%configure \
--disable-static \
--with-x
%make_build
popd
%endif
%install
%makeinstall_std
%if_enabled python
%if "%_libsuff" == "64"
mv %buildroot%python3_sitelibdir_noarch/* \
%buildroot%python3_sitelibdir/
%endif
%endif
%if_enabled python2
pushd py2build
%makeinstall_std
%if "%_libsuff" == "64"
mv %buildroot%python_sitelibdir_noarch/* \
%buildroot%python_sitelibdir/
%endif
popd
%endif
# create words database
touch %buildroot%_datadir/%name/pw_dict.{hwm,pwd,pwi}
cat > %name.filetrigger << _EOF_
#!/bin/sh -e
dir=%_datadir/%name
grep -qs '^'\$dir'' && %_sbindir/%name-format \$dir/%{name}* | %_sbindir/%name-packer \$dir/pw_dict >/dev/null ||:
_EOF_
install -pD -m 755 %name.filetrigger %buildroot%_rpmlibdir/%name.filetrigger
mkdir -p %buildroot%_sysconfdir/%name
cat > %buildroot%_sysconfdir/%name/%name.conf << _EOF_
# This is configuration file for cracklib-update.
# See update-cracklib(8) for details.
_EOF_
%find_lang %name
%files -f %name.lang
%_libdir/*.so.*
%_datadir/%name/
%_rpmlibdir/%name.filetrigger
%doc AUTHORS ChangeLog NEWS README*
%files devel
%_includedir/*
%_libdir/*.so
%doc %_man3dir/*
%files utils
%_sysconfdir/%name/%name.conf
%_sbindir/*
%_man8dir/*
%if_enabled python
%files -n python3-module-%name
%python3_sitelibdir/*
%exclude %python3_sitelibdir/*.la
%endif
%if_enabled python2
%files -n python-module-%name
%python_sitelibdir/*
%exclude %python_sitelibdir/*.la
%endif
%changelog
…
Полный changelog можно просмотреть здесь