[perl-Coro] Allow building on systems without %%fix_shbang_line macro (needed for EL6)

Mathieu Bridon bochecha at fedoraproject.org
Mon Jan 24 02:07:11 UTC 2011


commit 5957571cd52410147f76405082291536c72f2d55
Author: Mathieu Bridon <bochecha at fedoraproject.org>
Date:   Fri Jan 21 12:31:23 2011 +0800

    Allow building on systems without %%fix_shbang_line macro (needed for EL6)

 perl-Coro.spec |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/perl-Coro.spec b/perl-Coro.spec
index 2883892..3c082e0 100644
--- a/perl-Coro.spec
+++ b/perl-Coro.spec
@@ -1,6 +1,6 @@
 Name:           perl-Coro
 Version:        5.25
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        The only real threads in perl
 License:        GPL+ or Artistic
 Group:          Development/Libraries
@@ -59,7 +59,12 @@ programming much safer and easier than using other thread models.
 %ifnarch %{ix86} x86_64
 %patch0 -p1 -b .ucontext-default
 %endif
+%if 0%{?fix_shbang_line}
 %fix_shbang_line eg/myhttpd
+%else
+# at least EL6 doesn't have the %%fix_shbang_line macro
+sed -i -e '/^#!/ s|.*|#!%{__perl}|' eg/myhttpd
+%endif
 
 %build
 # Interractive configuration. Use default values.
@@ -87,6 +92,9 @@ make test
 %{_mandir}/man3/*
 
 %changelog
+* Fri Jan 21 2011 Mathieu Bridon <bochecha at fedoraproject.org> 5.25-3
+- Allow building on systems without %%fix_shbang_line macro (needed for EL6)
+
 * Mon Jan 10 2011 Dan Horák <dan[at]danny.cz> 5.25-2
 - use ucontext backend on non-x86
 


More information about the scm-commits mailing list