%define upstream_name lib-abs %define upstream_version 0.91 Name: perl-%{upstream_name} Version: %perl_convert_version %{upstream_version} Release: %mkrel 1 Summary: Get pathname of current working directory License: GPL+ or Artistic Group: Development/Perl Url: http://search.cpan.org/dist/%{upstream_name} Source0: http://www.cpan.org/modules/by-module/lib/%{upstream_name}-%{upstream_version}.tar.gz BuildRequires: perl(Cwd) BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(Test::More) BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release} Provides: perl(lib::abs) %description The main reason of this library is transformate relative paths to absolute at the 'BEGIN' stage, and push transformed to '@INC'. Relative path basis is not the current working directory, but the location of file, where the statement is (caller file). When using common 'lib', relative paths stays relative to curernt working directory, # For ex: # script: /opt/scripts/my.pl use lib::abs '../lib'; # We run `/opt/scripts/my.pl` having cwd /home/mons # The @INC will contain '/opt/lib'; %prep %setup -q -n %{upstream_name}-%{upstream_version} %build %{__perl} Makefile.PL INSTALLDIRS=vendor %{make} %check %{make} test %install rm -rf %buildroot %makeinstall_std %clean rm -rf %buildroot %files %defattr(-,root,root) %doc Changes README %{_mandir}/man3/* %perl_vendorlib/* %changelog * Sun Feb 28 2010 Jérôme Quelin <jquelin@mandriva.org> 0.910.0-1mdv2010.1 + Revision: 512602 - update to 0.91 * Thu Jul 23 2009 Jérôme Quelin <jquelin@mandriva.org> 0.900.0-1mdv2010.0 + Revision: 398842 - import perl-lib-abs * Thu Jul 23 2009 cpan2dist 0.90-1mdv - initial mdv release, generated with cpan2dist