Advertisement
Guest User

Untitled

a guest
Jan 3rd, 2015
249
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.76 KB | None | 0 0
  1. # Contributor: not_anonymous <nmlibertarian@gmail.com>
  2. # Generator : CPANPLUS::Dist::Arch 1.29
  3.  
  4. pkgname='perl-alien-wxwidgets'
  5. pkgver='0.65'
  6. pkgrel='2'
  7. pkgdesc="building, finding and using wxWidgets binaries"
  8. arch=('any')
  9. license=('PerlArtistic' 'GPL')
  10. options=('!emptydirs')
  11. depends=('perl-module-pluggable>=2.6' 'perl>=5.006')
  12. makedepends=('wxgtk>=3.0.2')
  13. url='http://search.cpan.org/dist/Alien-wxWidgets'
  14. source=('http://search.cpan.org/CPAN/authors/id/M/MD/MDOOTSON/Alien-wxWidgets-0.65.tar.gz'
  15. 'wx-config-version-and-env.patch'
  16. 'Alien-wxWidgets-0.64-returnor.patch')
  17. md5sums=('219a4f572d24eaa98c3dc2d118c5d9f0'
  18. '5a716e70d33bf5bd6fcb2fc15a93eec8'
  19. '518bcff0a51eb93bc86e75d6ea891018')
  20. _distdir="Alien-wxWidgets-0.65"
  21.  
  22. prepare() {
  23. cd "$srcdir/$_distdir"
  24. patch -Np0 -i ../wx-config-version-and-env.patch
  25. patch -Np0 -i ../Alien-wxWidgets-0.64-returnor.patch
  26. }
  27.  
  28. build() {
  29. ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \
  30. PERL_AUTOINSTALL=--skipdeps \
  31. PERL_MM_OPT="INSTALLDIRS=vendor DESTDIR='$pkgdir'" \
  32. PERL_MB_OPT="--installdirs vendor --destdir '$pkgdir'" \
  33. MODULEBUILDRC=/dev/null
  34.  
  35. cd "$srcdir/$_distdir"
  36. /usr/bin/perl Makefile.PL
  37. make
  38. )
  39. }
  40.  
  41. check() {
  42. cd "$srcdir/$_distdir"
  43. ( export PERL_MM_USE_DEFAULT=1 PERL5LIB=""
  44. make test
  45. )
  46. }
  47.  
  48. package() {
  49. cd "$srcdir/$_distdir"
  50. make install
  51.  
  52. find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
  53. }
  54.  
  55. # Local Variables:
  56. # mode: shell-script
  57. # sh-basic-offset: 2
  58. # End:
  59. # vim:set ts=2 sw=2 et:
  60.  
  61.  
  62. $ cat wx-config-version-and-env.patch
  63. --- Build.PL 2014-03-23 15:48:03.000000000 +0100
  64. +++ Build.PL 2014-08-17 17:43:36.000000000 +0200
  65. @@ -150,11 +150,11 @@
  66. EOP
  67. } else {
  68. require My::Build::Base;
  69. - my $wx_config = My::Build::Base->awx_path_search( 'wx-config' );
  70. + my $wx_config = $ENV{WX_CONFIG} || My::Build::Base->awx_path_search( 'wx-config' );
  71. if( $wx_config ) {
  72. - my $ans = `wx-config --version`;
  73. - if( $ans =~ /^2\./ ) {
  74. - my $prefix = `wx-config --prefix`;
  75. + my $ans = `$wx_config --version`;
  76. + if( $ans =~ /^[23]\./ ) {
  77. + my $prefix = `$wx_config --prefix`;
  78. chomp foreach $ans, $prefix;
  79. if( _check_installed_widgets_ok($ans, $prefix) ) {
  80. $build_wx_dflt = 'no' ;
  81.  
  82. $ cat Alien-wxWidgets-0.64-returnor.patch
  83. --- lib/Alien/wxWidgets/Utility.pm 2013-04-13 03:15:38.000000000 -0500
  84. +++ lib/Alien/wxWidgets/Utility.pm 2013-07-19 16:24:57.200682998 -0500
  85. @@ -74,7 +74,7 @@
  86. sub awx_cc_is_msvc {
  87. my( $cc ) = @_;
  88.  
  89. - return $^O =~ /MSWin32/ and $cc =~ /^cl/i;
  90. + return ($^O =~ /MSWin32/ and $cc =~ /^cl/i);
  91. }
  92.  
  93. sub awx_cc_is_gcc {
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement