Browse Source

* perl-File-MMagic: updated to 1.27

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@5889 ec354946-7b23-47d6-9f5a-488ba84defc7
shaolin 13 năm trước cách đây
mục cha
commit
16377bf474
1 tập tin đã thay đổi với 31 bổ sung42 xóa
  1. 31 42
      p/perl-File-MMagic/perl-File-MMagic-vl.spec

+ 31 - 42
p/perl-File-MMagic/perl-File-MMagic-vl.spec

@@ -1,22 +1,19 @@
-%define _use_internal_dependency_generator 0
-%define perl_sitelib    %(eval "`perl -V:installsitelib`"; echo $installsitelib)
-%define perl_vendorarch    %(eval "`perl -V:installvendorarch`"; echo $installvendorarch)
-
-Summary:      file command like perl5 module
-Summary(ja):  file コマンド風 perl5 モジュール
-Name:         perl-File-MMagic
-Version:      1.27
-Release:      2%{_dist_release}
-Url:          http://search.cpan.org/~knok/File-MMagic/
-License:      distributable
-Group:        Development/Libraries
-Source:       http://www.perl.com/CPAN/modules/by-module/File/File-MMagic-%{version}.tar.gz
-Requires:     perl >= 1:5.8.6
-Buildroot:    %{_tmppath}/%{name}-%{version}-root
-BuildArch:    noarch
-
-Vendor:       Project Vine
-Distribution: Vine Linux
+Summary:        file command like perl5 module
+Summary(ja):    file コマンド風 perl5 モジュール
+Name:           perl-File-MMagic
+Version:        1.27
+Release:        3%{_dist_release}
+Url:            http://search.cpan.org/~knok/File-MMagic/
+License:        ASL 1.0 and BSD
+Group:          Development/Libraries
+Source:         http://www.perl.com/CPAN/modules/by-module/File/File-MMagic-%{version}.tar.gz
+Buildroot:      %{_tmppath}/%{name}-%{version}-root
+BuildArch:      noarch
+BuildRequires:  perl(ExtUtils::MakeMaker)
+Requires:       perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
+
+Vendor:         Project Vine
+Distribution:   Vine Linux
 
 %description
 This module is to guess file type from its contents like file(1)
@@ -26,44 +23,36 @@ command.
 このモジュールは、file(1)コマンドに相当する機能、すなわちファイルの内
 容からその種類を推測するためのものです。
 
-
-# Provide perl-specific find-{provides,requires}.
-%define __find_provides /usr/lib/rpm/find-provides.perl
-%define __find_requires /usr/lib/rpm/find-requires.perl
-
 %prep
 %setup -q -n File-MMagic-%{version} 
 
 %build
 CFLAGS="$RPM_OPT_FLAGS" perl Makefile.PL INSTALLDIRS="vendor"
 make
+
+%check
 make test
 
 %install
-[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
-make DESTDIR=$RPM_BUILD_ROOT install
-
-[ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress
-
-find $RPM_BUILD_ROOT \( -name perllocal.pod -o -name .packlist \) -exec rm -v {} \;
-
-find $RPM_BUILD_ROOT%{_prefix} -type f -print | 
-        sed "s@^$RPM_BUILD_ROOT@@g" | 
-        grep -v perllocal.pod | 
-        grep -v "\.packlist" > File-MMagic-%{version}-filelist
-if [ "$(cat File-MMagic-%{version}-filelist)X" = "X" ] ; then
-    echo "ERROR: EMPTY FILE LIST"
-    exit -1
-fi
+[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
+make pure_install PERL_INSTALL_ROOT=%{buildroot}
+find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
+find %{buildroot} -type d -depth -exec rmdir {} 2>/dev/null ';'
+chmod -R u+w %{buildroot}/*
 
 %clean
-[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
+[ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
 
-%files -f File-MMagic-%{version}-filelist
-%defattr(-,root,root)
+%files
+%defattr(-,root,root,-)
 %doc COPYING README.en README.ja ChangeLog
+%{perl_vendorlib}/*
+%{_mandir}/man3/*
 
 %changelog
+* Mon Mar 12 2012 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.27-3
+- rebuilt with perl-5.12.3; spec revamped
+
 * Wed Apr 08 2009 Shu KONNO <owa@bg.wakwak.com> 1.27-2vl5
 - spec in utf-8