Blob Blame History Raw
Name:           perl-Text-Shellwords
Version:        1.08
Release:        4%{?dist}
Summary:        A thin wrapper around the shellwords.pl package

Group:          Development/Libraries
License:        GPL+ or Artistic
URL:            http://search.cpan.org/dist/Text-Shellwords/
Source0:        http://www.cpan.org/authors/id/L/LD/LDS/Text-Shellwords-1.08.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:      noarch
BuildRequires:  perl(ExtUtils::MakeMaker)
Requires:  perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))

%description
This is a thin wrapper around the shellwords.pl package, which comes
preinstalled with Perl.  This module imports a single subroutine,
shellwords().  The shellwords() routine parses lines of text and
returns a set of tokens using the same rules that the Unix shell does
for its command-line arguments.  Tokens are separated by whitespace,
and can be delimited by single or double quotes.  The module also
respects backslash escapes.


%prep
%setup -q -n Text-Shellwords-%{version}
# Clean up /usr/local/bin/perl mess
#%{__perl} -pi -e 's|/usr/local/bin/perl\b|%{__perl}|' \
#  qd.pl bdf_scripts/cvtbdf.pl demos/{*.{pl,cgi},truetype_test}

# avoid dependencies
#chmod 644 examples/* 


%build 
%{__perl} Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags} 


%install
rm -rf $RPM_BUILD_ROOT
make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -a \( -name .packlist \
  -o \( -name '*.bs' -a -empty \) \) -exec rm -f {} ';'
find $RPM_BUILD_ROOT -type d -depth -exec rmdir {} 2>/dev/null ';'


%check || :
make test


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root,-)
%doc Changes README
%{perl_vendorlib}/*
%{_mandir}/man3/*.3*


%changelog
* Tue Mar 04 2008 Tom "spot" Callaway <tcallawa@redhat.com> 1.08-4
- rebuild for new perl

* Mon Oct 15 2007 Alex Lancaster <alexl@users.sourceforge.net> 1.08-3
- Add missing BR: perl(ExtUtils::MakeMaker)

* Tue Sep 04 2007 Alex Lancaster <alexl@users.sourceforge.net> 1.08-2
- Clarified license terms: GPL+ or Artistic

* Wed Mar 23 2007 Alex Lancaster <alexl@users.sourceforge.net> 1.08-1
- Updated to 1.08
- Removed superfluous BR: Perl as per suggestion from Ralf Corsepius

* Wed Apr 06 2005 Hunter Matthews <thm@duke.edu> 1.07-2
- Review suggestions by José Pedro Oliveira

* Tue Mar 22 2005 Hunter Matthews <thm@duke.edu> 1.07-1
- Initial build.