ports/92226: Make sure Opera finds FreeBSD 4 compat libraries

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

ports/92226: Make sure Opera finds FreeBSD 4 compat libraries

Arjan van Leeuwen-2

>Number:         92226
>Category:       ports
>Synopsis:       Make sure Opera finds FreeBSD 4 compat libraries
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:      
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 23 22:10:08 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Arjan van Leeuwen
>Release:        FreeBSD 6.0-RELEASE i386
>Organization:
>Environment:


System: FreeBSD 6.0-RELEASE #13: Sun Nov  6 14:50:54 CET 2005
    [hidden email]:/usr/obj/usr/src/sys/WINSTON



>Description:


This patch changes the opera wrapper script so that /usr/local/lib/compat is added to
LD_LIBRARY_PATH, to allow for the case where compatxx is installed but
compatxx_enable is not set in /etc/rc.conf (required to add the directory to ldconfig with
the new compat ports).

This allows Opera to run from a clean install on FreeBSD 5.x or 6.x again, without
needing changes to /etc/rc.conf.

Update pkg-message while I'm here.


>How-To-Repeat:





>Fix:


--- opera.diff begins here ---
diff -urN /usr/ports/www/opera/files/patch-install.sh opera/files/patch-install.sh
--- /usr/ports/www/opera/files/patch-install.sh Tue Nov 22 22:58:50 2005
+++ opera/files/patch-install.sh Mon Jan 23 22:57:04 2006
@@ -1,5 +1,5 @@
 --- install.sh.orig Mon Nov 14 14:51:18 2005
-+++ install.sh Tue Nov 22 21:53:58 2005
++++ install.sh Mon Jan 23 22:56:49 2006
 @@ -381,7 +381,7 @@
     mvv=''    # SunOS mv (no -v verbose option)
  ;;
@@ -18,7 +18,7 @@
     wrapper_ibmjava="
     IBMJava2-142/jre \\
     IBMJava2-141/jre \\
-@@ -796,6 +796,12 @@
+@@ -796,10 +796,19 @@
 
      wrapper_contain="#!/bin/sh
 
@@ -31,7 +31,14 @@
  # Location of the Opera binaries
  OPERA_BINARYDIR=${str_localdirexec}
  export OPERA_BINARYDIR
-@@ -844,6 +850,9 @@
+
++# Make sure the compat libraries are found
++test -d /usr/local/lib/compat/ && LD_LIBRARY_PATH=\"\${LD_LIBRARY_PATH}:/usr/local/lib/compat/\"
++
+ # Parse commandline parameters
+ toset=
+ for arg
+@@ -844,6 +853,9 @@
  OPERA_LD_PRELOAD=\"\${LD_PRELOAD}\"
  export OPERA_LD_PRELOAD
 
@@ -41,7 +48,7 @@
  # Native Java enviroment
  if test -f \"\${OPERA_PERSONALDIR}/javapath.txt\"; then
      INIJAVA=\`cat \${OPERA_PERSONALDIR}/javapath.txt\`
-@@ -867,65 +876,12 @@
+@@ -867,65 +879,12 @@
 
  if test ! \"\${OPERA_JAVA_DIR}\"; then
 
@@ -110,7 +117,7 @@
  ; do
  for PREFIX in \${PREFIXES}; do
     if test -f \"\${PREFIX}/\${SUNJAVA}/lib/${wrapper_sunjava_machine}/libjava.so\"; then OPERA_JAVA_DIR=\"\${PREFIX}/\${SUNJAVA}/lib/${wrapper_sunjava_machine}\" && break; fi
-@@ -976,11 +932,8 @@
+@@ -976,11 +935,8 @@
 
  # Acrobat Reader
  for BINDIR in \\
@@ -124,7 +131,7 @@
      ; do
      if test -d \${BINDIR} ; then PATH=\${PATH}:\${BINDIR}; fi
  done
-@@ -991,12 +944,13 @@
+@@ -991,12 +947,13 @@
  LD_LIBRARY_PATH=\"\${OPERA_BINARYDIR}\${LD_LIBRARY_PATH:+:}\${LD_LIBRARY_PATH}\"
  export LD_LIBRARY_PATH
 
@@ -140,7 +147,7 @@
          LD_LIBRARY_PATH=\"\${LD_LIBRARY_PATH}:\${LIBASPELL_DIR}\"
      fi
  done
-@@ -1086,7 +1040,7 @@
+@@ -1086,7 +1043,7 @@
      chop "${OPERADESTDIR}" "str_localdirshare"
      chop "${OPERADESTDIR}" "str_localdirplugin"
 
@@ -149,7 +156,7 @@
 
      # Executable
      debug_msg 1 "Executable"
-@@ -1300,49 +1254,13 @@
+@@ -1300,49 +1257,13 @@
 
      if test -z "${OPERADESTDIR}"
      then
@@ -199,7 +206,7 @@
  fi
 
      fi # OPERADESTDIR
-@@ -1487,48 +1405,43 @@
+@@ -1487,48 +1408,43 @@
      # This function searches for common gnome icon paths.
      debug_msg 1 "in gnome()"
 
@@ -271,7 +278,7 @@
 
      elif test -d /usr/share/gnome/
      then
-@@ -1576,9 +1489,9 @@
+@@ -1576,9 +1492,9 @@
      # This function searches for common kde2 and kde 3 icon paths.
      debug_msg 1 "in kde()"
 
@@ -283,7 +290,7 @@
  if test -d "$DIR_HI" -a -w "$DIR_HI"
  then
     if test -d "$DIR_HI"/48x48/apps -a -w "$DIR_HI"/48x48/apps
-@@ -1592,7 +1505,7 @@
+@@ -1592,7 +1508,7 @@
     fi
  fi
 
@@ -292,7 +299,7 @@
  if test -d $DIR_LO -a -w $DIR_LO
  then
     if test -d $DIR_LO/32x32/apps -a -w $DIR_LO/32x32/apps
-@@ -1606,15 +1519,15 @@
+@@ -1606,15 +1522,15 @@
     fi
  fi
 
diff -urN /usr/ports/www/opera/pkg-message opera/pkg-message
--- /usr/ports/www/opera/pkg-message Sun Aug 29 00:50:43 2004
+++ opera/pkg-message Mon Jan 23 23:06:53 2006
@@ -1,12 +1,5 @@
-If you are running FreeBSD 5.x and are experiencing a core dump when starting
-Opera, try updating the compat4x port.
+If you are running FreeBSD 5.x or 6.x and are experiencing a core dump when
+starting Opera, try updating the compat4x port.
 
-*** IMPORTANT: users with custom search.ini ***
+Plugins do not work in FreeBSD 5.x or higher - please disable them.
 
-If you have a custom search.ini and you've used opera 7.51 or an earlier
-version before this upgrade, edit ~/.opera/search.ini _before_ running the
-upgraded Opera for the first time, and change the file version to 4. It should
-look like this:
-
-[Version]
-File Version=4
--- opera.diff ends here ---



>Release-Note:
>Audit-Trail:
>Unformatted:
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: ports/92226: Make sure Opera finds FreeBSD 4 compat libraries

Arjan van Leeuwen-2
The following reply was made to PR ports/92226; it has been noted by GNATS.

From: Arjan van Leeuwen <[hidden email]>
To: [hidden email],
 [hidden email],
 [hidden email]
Cc:  
Subject: Re: ports/92226: Make sure Opera finds FreeBSD 4 compat libraries
Date: Wed, 25 Jan 2006 19:03:22 +0100

 --Boundary-00=_q171DnZTUTZ4qy4
 Content-Type: text/plain;
   charset="us-ascii"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: inline
 
  Andrey Slusar (anray at freebsd dt org) noticed that compat libraries don't
 have to be in /usr/local: use ${LOCALBASE} instead. New patch is attached.
 Thanks Andrey!
 
 --Boundary-00=_q171DnZTUTZ4qy4
 Content-Type: text/x-diff;
   charset="us-ascii";
   name="opera.diff"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: attachment;
  filename="opera.diff"
 
 diff -urN /usr/ports/www/opera/files/patch-install.sh opera/files/patch-install.sh
 --- /usr/ports/www/opera/files/patch-install.sh Tue Nov 22 22:58:50 2005
 +++ opera/files/patch-install.sh Wed Jan 25 18:59:26 2006
 @@ -1,5 +1,5 @@
  --- install.sh.orig Mon Nov 14 14:51:18 2005
 -+++ install.sh Tue Nov 22 21:53:58 2005
 ++++ install.sh Wed Jan 25 18:59:13 2006
  @@ -381,7 +381,7 @@
       mvv=''    # SunOS mv (no -v verbose option)
    ;;
 @@ -18,7 +18,7 @@
       wrapper_ibmjava="
       IBMJava2-142/jre \\
       IBMJava2-141/jre \\
 -@@ -796,6 +796,12 @@
 +@@ -796,10 +796,19 @@
   
       wrapper_contain="#!/bin/sh
   
 @@ -31,7 +31,14 @@
   # Location of the Opera binaries
   OPERA_BINARYDIR=${str_localdirexec}
   export OPERA_BINARYDIR
 -@@ -844,6 +850,9 @@
 +
 ++# Make sure the compat libraries are found
 ++test -d %%LOCALBASE%%/lib/compat/ && LD_LIBRARY_PATH=\"\${LD_LIBRARY_PATH}:%%LOCALBASE%%/lib/compat/\"
 ++
 + # Parse commandline parameters
 + toset=
 + for arg
 +@@ -844,6 +853,9 @@
   OPERA_LD_PRELOAD=\"\${LD_PRELOAD}\"
   export OPERA_LD_PRELOAD
   
 @@ -41,7 +48,7 @@
   # Native Java enviroment
   if test -f \"\${OPERA_PERSONALDIR}/javapath.txt\"; then
       INIJAVA=\`cat \${OPERA_PERSONALDIR}/javapath.txt\`
 -@@ -867,65 +876,12 @@
 +@@ -867,65 +879,12 @@
   
   if test ! \"\${OPERA_JAVA_DIR}\"; then
   
 @@ -110,7 +117,7 @@
    ; do
    for PREFIX in \${PREFIXES}; do
       if test -f \"\${PREFIX}/\${SUNJAVA}/lib/${wrapper_sunjava_machine}/libjava.so\"; then OPERA_JAVA_DIR=\"\${PREFIX}/\${SUNJAVA}/lib/${wrapper_sunjava_machine}\" && break; fi
 -@@ -976,11 +932,8 @@
 +@@ -976,11 +935,8 @@
   
   # Acrobat Reader
   for BINDIR in \\
 @@ -124,7 +131,7 @@
       ; do
       if test -d \${BINDIR} ; then PATH=\${PATH}:\${BINDIR}; fi
   done
 -@@ -991,12 +944,13 @@
 +@@ -991,12 +947,13 @@
   LD_LIBRARY_PATH=\"\${OPERA_BINARYDIR}\${LD_LIBRARY_PATH:+:}\${LD_LIBRARY_PATH}\"
   export LD_LIBRARY_PATH
   
 @@ -140,7 +147,7 @@
           LD_LIBRARY_PATH=\"\${LD_LIBRARY_PATH}:\${LIBASPELL_DIR}\"
       fi
   done
 -@@ -1086,7 +1040,7 @@
 +@@ -1086,7 +1043,7 @@
       chop "${OPERADESTDIR}" "str_localdirshare"
       chop "${OPERADESTDIR}" "str_localdirplugin"
   
 @@ -149,7 +156,7 @@
   
       # Executable
       debug_msg 1 "Executable"
 -@@ -1300,49 +1254,13 @@
 +@@ -1300,49 +1257,13 @@
   
       if test -z "${OPERADESTDIR}"
       then
 @@ -199,7 +206,7 @@
    fi
   
       fi # OPERADESTDIR
 -@@ -1487,48 +1405,43 @@
 +@@ -1487,48 +1408,43 @@
       # This function searches for common gnome icon paths.
       debug_msg 1 "in gnome()"
   
 @@ -271,7 +278,7 @@
   
       elif test -d /usr/share/gnome/
       then
 -@@ -1576,9 +1489,9 @@
 +@@ -1576,9 +1492,9 @@
       # This function searches for common kde2 and kde 3 icon paths.
       debug_msg 1 "in kde()"
   
 @@ -283,7 +290,7 @@
    if test -d "$DIR_HI" -a -w "$DIR_HI"
    then
       if test -d "$DIR_HI"/48x48/apps -a -w "$DIR_HI"/48x48/apps
 -@@ -1592,7 +1505,7 @@
 +@@ -1592,7 +1508,7 @@
       fi
    fi
   
 @@ -292,7 +299,7 @@
    if test -d $DIR_LO -a -w $DIR_LO
    then
       if test -d $DIR_LO/32x32/apps -a -w $DIR_LO/32x32/apps
 -@@ -1606,15 +1519,15 @@
 +@@ -1606,15 +1522,15 @@
       fi
    fi
   
 diff -urN /usr/ports/www/opera/pkg-message opera/pkg-message
 --- /usr/ports/www/opera/pkg-message Sun Aug 29 00:50:43 2004
 +++ opera/pkg-message Mon Jan 23 23:06:53 2006
 @@ -1,12 +1,5 @@
 -If you are running FreeBSD 5.x and are experiencing a core dump when starting
 -Opera, try updating the compat4x port.
 +If you are running FreeBSD 5.x or 6.x and are experiencing a core dump when
 +starting Opera, try updating the compat4x port.
 
 -*** IMPORTANT: users with custom search.ini ***
 +Plugins do not work in FreeBSD 5.x or higher - please disable them.
 
 -If you have a custom search.ini and you've used opera 7.51 or an earlier
 -version before this upgrade, edit ~/.opera/search.ini _before_ running the
 -upgraded Opera for the first time, and change the file version to 4. It should
 -look like this:
 -
 -[Version]
 -File Version=4
 
 --Boundary-00=_q171DnZTUTZ4qy4--
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: ports/92226: Make sure Opera finds FreeBSD 4 compat libraries

Andrey Slusar-2
In reply to this post by Arjan van Leeuwen-2
Synopsis: Make sure Opera finds FreeBSD 4 compat libraries

Responsible-Changed-From-To: freebsd-ports-bugs->anray
Responsible-Changed-By: anray
Responsible-Changed-When: Fri Jan 27 11:02:19 UTC 2006
Responsible-Changed-Why:
I'll take it.

http://www.freebsd.org/cgi/query-pr.cgi?pr=92226
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: ports/92226: Make sure Opera finds FreeBSD 4 compat libraries

Stuart Barkley
On Fri, 27 Jan 2006 at 11:02 -0000, Andrey Slusar wrote:

> Synopsis: Make sure Opera finds FreeBSD 4 compat libraries
>
> Responsible-Changed-From-To: freebsd-ports-bugs->anray
> Responsible-Changed-By: anray
> Responsible-Changed-When: Fri Jan 27 11:02:19 UTC 2006
> Responsible-Changed-Why:
> I'll take it.
>
> http://www.freebsd.org/cgi/query-pr.cgi?pr=92226

This patch has been applied today.  This seems like a pragmatic but
very broken way to deal with the problem.

If the user has the compat4x package installed but not enabled then
other packages should not be grovelling into compat4x.

More appropriate solutions would seem to be:

- Fix the compat4x package to default to enabling the compatibility
libraries.  The compat4x and compat5x packages are currently broken
anyway.  They generate confusing warnings on system boot since they
don't have an explicit default of enable=YES or enable=NO.  There may
be other issues with why compat4x and compat5x don't default to
enabled but this seems a reasonable default.  The enable knob is
important to have and I do like that many packages default to not
enabled but for libraries defaulting to disabled seems not necessary.

- Put a note in pkg-message that enable_compat4x="YES" is required.

- Put code in the install script which warns if the required libraries
are not found.
_______________________________________________
[hidden email] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports-bugs
To unsubscribe, send any mail to "[hidden email]"