Преглед изворни кода

try to fix building under Fedora and NetBSD

Ralf S. Engelschall пре 20 година
родитељ
комит
ed427057da
2 измењених фајлова са 34 додато и 7 уклоњено
  1. 28 0
      wml/wml.patch
  2. 6 7
      wml/wml.spec

+ 28 - 0
wml/wml.patch

@@ -0,0 +1,28 @@
+Index: wml_aux/iselect/Makefile.in
+--- wml_aux/iselect/Makefile.in.orig	2002-10-18 22:06:44 +0200
++++ wml_aux/iselect/Makefile.in	2005-06-13 13:22:23 +0200
+@@ -12,7 +12,7 @@
+ 
+ #   compiler tools
+ CC      = @CC@
+-CFLAGS  = @CFLAGS@ -I.
++CFLAGS  = @CFLAGS@ -I. @CPPFLAGS@
+ LDFLAGS = @LDFLAGS@
+ LIBS    = @LIBS@
+ debug   = @debug@
+Index: wml_aux/tidy/Makefile
+sed: -e expression #1, char 23: unknown option to `s'
+Index: wml_common/gd/Makefile.PL.in
+--- wml_common/gd/Makefile.PL.in.orig	2000-03-12 17:22:30 +0100
++++ wml_common/gd/Makefile.PL.in	2005-06-13 11:51:23 +0200
+@@ -12,8 +12,8 @@
+ 
+     # Uncomment the line below if you're getting link errors
+     # having to do with missing math functions (like floor)
+-    'LIBS'      =>  ["-lm @LIBPNG@"],
+-    'DEFINE'	=> '@DEFS@'
++    'LIBS'      => ["-lm @LIBPNG@ -L/openpkg-dev/lib -lz"],
++    'DEFINE'	=> '@DEFS@ @CPPFLAGS@'
+     # Uncomment the line below if you're using a perl compiled
+     # for fastCGI (http://www.fastcgi.com/).
+     # 'DEFINE'	=> '-DFCGI'

+ 6 - 7
wml/wml.spec

@@ -33,7 +33,7 @@ Class:        BASE
 Group:        Language
 License:      GPL
 Version:      2.0.9
-Release:      20040609
+Release:      20050613
 
 #   list of sources
 Source0:      ftp://thewml.org/distrib/wml-%{version}.tar.gz
@@ -41,14 +41,15 @@ Source1:      configure.eperl
 Source2:      configure.gm4
 Source3:      configure.iselect
 Source4:      configure.gd
+Patch0:       wml.patch
 
 #   build information
 Prefix:       %{l_prefix}
 BuildRoot:    %{l_buildroot}
 BuildPreReq:  OpenPKG, openpkg >= 20040130, perl, gcc
 PreReq:       OpenPKG, openpkg >= 20040130, perl
-BuildPreReq:  png, zlib
-PreReq:       png, zlib
+BuildPreReq:  png, zlib, ncurses
+PreReq:       png, zlib, ncurses
 AutoReq:      no
 AutoReqProv:  no
 
@@ -75,18 +76,16 @@ AutoReqProv:  no
 
 %prep
     %setup -q
+    %patch -p0
     cp %{SOURCE configure.eperl} wml_backend/p3_eperl/configure
     cp %{SOURCE configure.gm4} wml_backend/p4_gm4/configure
     cp %{SOURCE configure.iselect} wml_aux/iselect/configure
     cp %{SOURCE configure.gd} wml_common/gd/configure
-    %{l_shtool} subst \
-        -e 's;^\([	 ]\{1,\}.LIBS.[	 ]\{1,\}=>\).*$;\1 [\"-lm @LIBPNG@ %{l_ldflags} -lz\"],;' \
-        wml_common/gd/Makefile.PL.in
 
 %build
     CC="%{l_cc}" \
     CFLAGS="%{l_cflags -O}" \
-    CPPFLAGS="%{l_cppflags}" \
+    CPPFLAGS="%{l_cppflags ncurses}" \
     LDFLAGS="%{l_ldflags}" \
     LIBS="%{l_ldflags} -lpng -lz -lm" \
     ./configure \