rpms/pl/F-8 pl-5.6.57-jpl-configure.patch, NONE, 1.1 pl-5.6.57-locale.patch, NONE, 1.1 pl.spec, 1.35, 1.36 pl-5.6.52-fix-java-directory.patch, 1.1, NONE

Mary Ellen Foster (mef) fedora-extras-commits at redhat.com
Wed Jul 2 13:34:34 UTC 2008


Author: mef

Update of /cvs/pkgs/rpms/pl/F-8
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv9516/F-8

Modified Files:
	pl.spec 
Added Files:
	pl-5.6.57-jpl-configure.patch pl-5.6.57-locale.patch 
Removed Files:
	pl-5.6.52-fix-java-directory.patch 
Log Message:
Commit JPL and locale changes to other branches too
(NB: must re-add jni patch to F-9)


pl-5.6.57-jpl-configure.patch:

--- NEW FILE pl-5.6.57-jpl-configure.patch ---
--- pl-5.6.57/packages/jpl/configure	2008-06-20 11:19:03.000000000 +0100
+++ /home/mef/rpmbuild/BUILD/pl-5.6.57/packages/jpl/configure	2008-07-02 14:11:55.000000000 +0100
@@ -3658,21 +3658,6 @@
     CWFLAGS="${CWFLAGS-}"
 fi
 
-if test "x$JAVALIBS" = "x"; then
-  case "$PLARCH" in
-     *darwin*)
-	  JAVALIBS="-Wl,-framework,JavaVM"
-	  ;;
-     *powerpc-linux*)
-	  JAVALIBS="-ljava -ljvm"
-	  ;;
-     *)
-	  JAVALIBS="-ljava -lverify -ljvm"
-	  ;;
-  esac
-fi
-
-
 # Make sure we can run config.sub.
 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
   { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
@@ -4572,6 +4557,7 @@
         { echo "$as_me:$LINENO: checking symlink for $_cur" >&5
 echo $ECHO_N "checking symlink for $_cur... $ECHO_C" >&6; }
         _slink=`ls -ld "$_cur" | sed 's/.* -> //'`
+        if [ `basename $_slink` = "ecj" ]; then break; fi
         case "$_slink" in
         /*) _cur="$_slink";;
         # 'X' avoids triggering unwanted echo options.
@@ -4629,19 +4615,37 @@
 		_JNI_LIBSUBDIR="server"
 		;;
 	powerpc)
-		case "$host_os" in
-		linux*)
-			_JNI_LIBDIRS="bin"
-			_JNI_LIBSUBDIR="classic"
-			;;
-		*)
-			_JNI_LIBDIRS=""
-		esac
+		_JNI_LIBDIRS="lib/ppc"
+		_JNI_LIBSUBDIR="server"
+		;;
+	powerpc64)
+		_JNI_LIBDIRS="lib/ppc64"
+		_JNI_LIBSUBDIR="server"
 		;;
 	*)
 		_JNI_LIBDIRS=""
 esac
 
+# Set JAVALIBS differently if we're using GCJ
+if test "x$JAVALIBS" = "x"; then
+    if (echo $_JTOPDIR | grep gcj > /dev/null); then
+        JAVALIBS="-ljvm"
+    else
+        case "$PLARCH" in
+            *darwin*)
+            JAVALIBS="-Wl,-framework,JavaVM"
+            ;;
+            *powerpc-linux*)
+            JAVALIBS="-ljava -ljvm"
+            ;;
+            *)
+            JAVALIBS="-ljava -lverify -ljvm"
+            ;;
+        esac
+    fi
+fi
+
+
 for d in $_JNI_LIBDIRS; do
 	echo "Trying $_JTOPDIR/jre/$d/$_JNI_LIBSUBDIR"
 	if test -d $_JTOPDIR/jre/$d/$_JNI_LIBSUBDIR; then

pl-5.6.57-locale.patch:

--- NEW FILE pl-5.6.57-locale.patch ---
diff --git a/src/rc/access.c b/src/rc/access.c
index 59f0ef7..27a52dc 100644
--- a/src/rc/access.c
+++ b/src/rc/access.c
@@ -202,7 +202,7 @@ decode_member_header(RcArchive rca, RcMember mbr)
   memset(mbr, 0, sizeof(*mbr));
 
   while( html_fd_next_tag(rca->fd, tag, properties) )
-  { if ( strcasecmp(tag, "file") == 0 )
+  { if ( strmp(tag, "file") == 0 )
     { html_decode_tag(properties, make_file_tag_def(), mbr);
 
       if ( mbr->name )
@@ -279,7 +279,7 @@ find_archive_dimensions(RcArchive rca)
 { const char *data = rca->data;
   size_t alen = strlen(ARCHIVE_TAG);
 
-  if ( strncasecmp(data, ARCHIVE_TAG, alen) != 0 )
+  if ( strncmp(data, ARCHIVE_TAG, alen) != 0 )
   { const char *rc_end = &data[rca->size];
     const char *end = rc_end-1;
     const char *s;
@@ -298,7 +298,7 @@ find_archive_dimensions(RcArchive rca)
       { const char *start = end - len;
 	rc_size hdrlen = start - (const char *)rca->map_start;
 
-	if ( strncasecmp(start, ARCHIVE_TAG, alen) == 0 )
+	if ( strncmp(start, ARCHIVE_TAG, alen) == 0 )
 	{ rca->data  = (void *)start;
 	  rca->size -= hdrlen;
 
@@ -327,7 +327,7 @@ at_archive_start(RcArchive rca)
     return FALSE;
   }
 
-  if ( strncasecmp(buf, atag, alen) == 0 )
+  if ( strncmp(buf, atag, alen) == 0 )
     return TRUE;			/* fine, this is the start */
 
   rc_errno = RCE_NOERROR;
diff --git a/src/rc/build.c b/src/rc/build.c
index 6e148c3..670f1b3 100644
--- a/src/rc/build.c
+++ b/src/rc/build.c
@@ -3,9 +3,9 @@
     Part of SWI-Prolog
 
     Author:        Jan Wielemaker
-    E-mail:        jan at swi.psy.uva.nl
+    E-mail:        J.Wielemaker at science.uva.nl
     WWW:           http://www.swi-prolog.org
-    Copyright (C): 1985-2002, University of Amsterdam
+    Copyright (C): 1985-2008, University of Amsterdam
 
     This library is free software; you can redistribute it and/or
     modify it under the terms of the GNU Lesser General Public
@@ -176,16 +176,16 @@ rc_save_data(RcMember m, FILE *fd)
 
 static int
 rc_save_member(RcMember m, FILE *fd)
-{ fprintf(fd, "\n<FILE NAME=\"%s\" CLASS=\"%s\" ENCODING=\"%s\" SIZE=%ld",
+{ fprintf(fd, "\n<file name=\"%s\" class=\"%s\" encoding=\"%s\" size=%ld",
 	  m->name, m->rc_class, m->encoding, (long)m->size);
   if ( m->modified )
-    fprintf(fd, " MODIFIED=%ld", (long)m->modified);
+    fprintf(fd, " modified=%ld", (long)m->modified);
   fprintf(fd, ">\n");
 
   if ( !rc_save_data(m, fd) )
     return FALSE;
 
-  fprintf(fd, "\n</FILE>\n");
+  fprintf(fd, "\n</file>\n");
 
   return TRUE;
 }
@@ -212,7 +212,7 @@ rc_save_archive(RcArchive rca, const char *to)
       hdrlen = hdr->size;
     }
 
-    fprintf(fd, "<ARCHIVE>\n");
+    fprintf(fd, "<archive>\n");
     for( member = rca->members; member; member = member->next )
     { if ( strcmp(member->name, "$header") == 0 &&
 	   strcmp(member->rc_class, "$rc") == 0 )
@@ -223,9 +223,9 @@ rc_save_archive(RcArchive rca, const char *to)
 	return FALSE;
       }
     }
-    fprintf(fd, "</ARCHIVE>\n");
+    fprintf(fd, "</archive>\n");
     size = ftell(fd) - hdrlen;
-    fprintf(fd, "<FOOT CONTENTLENGTH=%ld>\n", (long)size);
+    fprintf(fd, "<foot contentlength=%ld>\n", (long)size);
     if ( fclose(fd) == EOF )
     { rc_errno = RCE_ERRNO;
       return FALSE;
diff --git a/src/rc/html.c b/src/rc/html.c
index 29996a4..fb03f0f 100644
--- a/src/rc/html.c
+++ b/src/rc/html.c
@@ -34,11 +34,6 @@
 #include "html.h"
 #include <stdlib.h>
 
-#if !defined(strncasecmp) && !defined(HAVE_STRCASECMP) && defined(HAVE_STRICMP) 
-#define strcasecmp stricmp
-#define strncasecmp strnicmp
-#endif
-
 #ifndef EOS
 #define EOS '\0'
 #endif
@@ -76,7 +71,7 @@ html_find_tag(const char *data, const char *end, const char *tag)
     if ( data == end )
       return NULL;
 
-    if ( strncasecmp(data+1, tag, len) == 0 )
+    if ( strncmp(data+1, tag, len) == 0 )
     { int c = data[len+1];
 
       if ( isspace(c) || c == '>' )
@@ -95,7 +90,7 @@ html_find_close_tag(const char *data, const char *tag)
   while(data)
   { if ( (data = strchr(data, '<')) &&
 	 data[1] == '/' &&
-	 strncasecmp(data+2, tag, len) == 0 &&
+	 strncmp(data+2, tag, len) == 0 &&
 	 data[len+2] == '>' )
       return (char *)data+len+3;
     if ( data )
@@ -240,7 +235,7 @@ html_decode_tag(const char *data, HtmlTagDef spec, void *dest)
     }
 
     for(d=spec; d->tag; d++)
-    { if ( strncasecmp(si, d->tag, ei-si) == 0 )
+    { if ( strncmp(si, d->tag, ei-si) == 0 )
       { void *dst = (char *)dest + d->offset;
 
 	(*d->convert)(sv, ev-sv, dst, d->closure);



Index: pl.spec
===================================================================
RCS file: /cvs/pkgs/rpms/pl/F-8/pl.spec,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- pl.spec	25 Jun 2008 17:59:43 -0000	1.35
+++ pl.spec	2 Jul 2008 13:33:38 -0000	1.36
@@ -1,15 +1,6 @@
-%define build_jpl 0
-%if 0%{fedora} > 8
-%define build_jpl 1
-%else
-%ifnarch ppc ppc64
-%define build_jpl 1
-%endif
-%endif
-
 Name:		pl
 Version:	5.6.57
-Release:	1%{?dist}
+Release:	2%{?dist}
 
 Summary:	SWI-Prolog - Edinburgh compatible Prolog compiler
 
@@ -21,9 +12,9 @@
 Source2:	http://gollem.science.uva.nl/cgi-bin/nph-download/xpce/doc/userguide/userguide.html.tgz
 Patch0:         %{name}-5.4.6-rpath.patch
 Patch1:         %{name}-5.6.0-multilib.patch
-Patch2:         %{name}-5.6.52-fix-java-directory.patch
+Patch2:         %{name}-5.6.57-jpl-configure.patch
 Patch3:         %{name}-5.6.52-jni.patch
-Patch4:         %{name}-5.6.55-configure.patch
+Patch4:         %{name}-5.6.57-locale.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:  gmp-devel
 BuildRequires:  libICE-devel
@@ -43,14 +34,8 @@
 BuildRequires:  readline-devel
 BuildRequires:  unixODBC-devel
 BuildRequires:  freetype-devel
-%if %{build_jpl}
 BuildRequires:  jpackage-utils
-%if 0%{fedora} > 8
-BuildRequires:  java-devel-openjdk
-%else
-BuildRequires:  java-devel-icedtea
-%endif
-%endif
+BuildRequires:  java-devel
 
 %description
 ISO/Edinburgh-style Prolog compiler including modules, autoload,
@@ -95,16 +80,11 @@
 # - Platform independent programs
 
 
-%if %{build_jpl}
 %package jpl
 Summary: A bidirectional Prolog/Java interface for SWI Prolog
 Group: Development/Languages
 Requires: %{name} = %{version}-%{release}
-%if 0%{fedora} > 8
-Requires: java-openjdk
-%else
-Requires: java-icedtea
-%endif
+Requires: java
 Requires: jpackage-utils
 
 %description jpl
@@ -112,7 +92,6 @@
 interface providing a bidirectional interface between Java and Prolog
 that can be used to embed Prolog in Java as well as for embedding Java
 in Prolog.  In both setups it provides a reentrant bidirectional interface.
-%endif
 
 
 %prep
@@ -121,7 +100,7 @@
 %patch1 -p1 -b .multilib
 %patch2 -p1 -b .libjvm
 %patch3 -p1 -b .jni
-# %patch4 -p1 -b .config
+%patch4 -p1 -b .locale
 (
    mkdir doc-install
    cd doc-install
@@ -143,11 +122,7 @@
 make COFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
 PATH=$PWD/src:$PATH
 cd packages
-%if %{build_jpl}
 %configure
-%else
-%configure --without-jpl
-%endif
 make COFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
 cd ..
 
@@ -165,7 +140,6 @@
 	mandir=$RPM_BUILD_ROOT%{_mandir}/man1
 )
 
-%if %{build_jpl}
 # Move the JPL JNI stuff to where the Java packaging guidelines 
 # say it should be
 mkdir -p $RPM_BUILD_ROOT%{_libdir}/%{name}-jpl
@@ -173,7 +147,6 @@
         $RPM_BUILD_ROOT%{_libdir}/%{name}-jpl/
 mv $RPM_BUILD_ROOT%{_libdir}/%{name}-%{version}/lib/jpl.jar \
         $RPM_BUILD_ROOT%{_libdir}/%{name}-jpl/
-%endif
 
 # Move the various include files into /usr/include
 mkdir -p $RPM_BUILD_ROOT%{_includedir}/%{name}/xpce
@@ -206,10 +179,8 @@
 %{_libdir}/%{name}-%{version}/*
 %{_bindir}/*
 # Exclude the files that are in the sub-packages
-%if %{build_jpl}
 # JPL
 %exclude %{_libdir}/%{name}-%{version}/library/jpl.pl
-%endif
 # Devel
 %exclude %{_libdir}/%{name}-%{version}/lib/*/libpl.so
 # Static
@@ -242,16 +213,18 @@
 %defattr(-,root,root,-)
 %{_libdir}/%{name}-%{version}/lib/*/libpl.a
 
-%if %{build_jpl}
 %files jpl
 %doc packages/jpl/docs/*
 %doc packages/jpl/examples
 %{_libdir}/%{name}-%{version}/library/jpl.pl
 %{_libdir}/%{name}-jpl
-%endif
 
 
 %changelog
+* Wed Jul  2 2008 Mary Ellen Foster <mefoster at gmail.com> - 5.6.57-2
+- Build using any Java
+- Include patch from SWI for Turkish locale (thanks to Keri Harris)
+
 * Wed Jun 25 2008 Mary Ellen Foster <mefoster at gmail.com> - 5.6.57-1
 - Another update, after vacation
 


--- pl-5.6.52-fix-java-directory.patch DELETED ---




More information about the fedora-extras-commits mailing list