Blame SOURCES/Text-Tabs+Wrap-2013.0523-Build-from-lib.patch

e77b0d
From 425354918f774c39c68b79de55691ee262cdcb84 Mon Sep 17 00:00:00 2001
e77b0d
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
e77b0d
Date: Wed, 25 Mar 2015 17:57:05 +0100
e77b0d
Subject: [PATCH] Build from lib
e77b0d
MIME-Version: 1.0
e77b0d
Content-Type: text/plain; charset=UTF-8
e77b0d
Content-Transfer-Encoding: 8bit
e77b0d
e77b0d
Building from lib.modern adds "modern::" prefix to manual pages.
e77b0d
e77b0d
This is a work-around for CPAN RT#103116. Creating symlink is not
e77b0d
enough for EU::MM.
e77b0d
e77b0d
Signed-off-by: Petr Písař <ppisar@redhat.com>
e77b0d
e77b0d
diff --git a/Makefile.PL b/Makefile.PL
e77b0d
index a8dbc7e..1b5b51a 100644
e77b0d
--- a/Makefile.PL
e77b0d
+++ b/Makefile.PL
e77b0d
@@ -1,10 +1,15 @@
e77b0d
 
e77b0d
 use ExtUtils::MakeMaker;
e77b0d
 
e77b0d
+if (!-d 'lib') {
e77b0d
+    rename (($] > 5.010 ? 'lib.modern' : 'lib.old'), 'lib') or
e77b0d
+        die "Could not rename to lib: $!";
e77b0d
+}
e77b0d
+
e77b0d
 WriteMakefile( 
e77b0d
 	'NAME'		=> 'Text-Wrap',
e77b0d
 	'DISTNAME'	  => 'Text-Tabs+Wrap',
e77b0d
-	'VERSION_FROM' => 'lib.modern/Text/Wrap.pm',
e77b0d
+	'VERSION_FROM' => 'lib/Text/Wrap.pm',
e77b0d
 	($] >= 5.005 ? 
e77b0d
 		(
e77b0d
 			ABSTRACT	=> 'Expand tabs and do simple line wrapping',
e77b0d
@@ -21,16 +26,5 @@ WriteMakefile(
e77b0d
 	'dist' => { COMPRESS=>"gzip", SUFFIX=>"gz" },
e77b0d
 	'INSTALLDIRS'	=> 'perl',
e77b0d
 
e77b0d
-	PM =>	($] > 5.010 ?
e77b0d
-		{
e77b0d
-			'lib.modern/Text/Tabs.pm'	=> '$(INST_LIBDIR)/Text/Tabs.pm',
e77b0d
-			'lib.modern/Text/Wrap.pm'	=> '$(INST_LIBDIR)/Text/Wrap.pm',
e77b0d
-		}
e77b0d
-		:
e77b0d
-		{
e77b0d
-			'lib.old/Text/Tabs.pm'	=> '$(INST_LIBDIR)/Text/Tabs.pm',
e77b0d
-			'lib.old/Text/Wrap.pm'	=> '$(INST_LIBDIR)/Text/Wrap.pm',
e77b0d
-		})
e77b0d
-
e77b0d
 	);
e77b0d
 
e77b0d
-- 
e77b0d
2.1.0
e77b0d