Bug 93595 - ruby 1.8_4_1 doesn't like openssl overwrite base
Summary: ruby 1.8_4_1 doesn't like openssl overwrite base
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Dirk Meyer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-20 14:20 UTC by Michael Scheidell
Modified: 2006-04-30 22:22 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Scheidell 2006-02-20 14:20:14 UTC
ruby looks for /usr/local/lib/libcrypto.so.3 even though 
openssl_overrite_base only puts it in /usr/lib.

===>   ruby-1.8.4_4,1 depends on file: /usr/local/lib/libcrypto.so.3 - 
not found
===>    Verifying install for /usr/local/lib/libcrypto.so.3 in 
/usr/ports/security/openssl-stable
===>  Installing for openssl-stable-overwrite-base-0.9.7i
===>   Generating temporary packing list
===>  Checking if security/openssl-stable already installed
===>   openssl-stable-overwrite-base-0.9.7i is already installed
      You may wish to ``make deinstall'' and install this port again
      by ``make reinstall'' to upgrade it properly.
      If you really wish to overwrite the old port of 
security/openssl-stable
      without deleting it first, set the variable "FORCE_PKG_REGISTER"
      in your environment or the "make install" command line.
*** Error code 1

Stop in /usr/ports/security/openssl-stable.
*** Error code 1

Stop in /usr/ports/lang/ruby18.

Fix: 

suggested change: look for OPENSSL_OVERWRITE_BASE=YES and set prefix. to 
/usr/lib not /usr/local/lib when checking for libraries.

workaround: copy /usr/lib/libcrypto.so.3 to /usr/local/lib
How-To-Repeat: 
   installed earlier version of openssl with overwrite-base.
verified:
ls -ltd /var/db/pkg/openssl*
drwxr-xr-x  2 root  wheel  512 Feb 20 08:36 
/var/db/pkg/openssl-stable-overwrite-base-0.9.7i

  since it has portsaudit complaint, upgraded it
(needed to add WITH_OPENSSL_STABLE=yes or ports complained)
upgraded with portupgrade -rR openssl-overwrite-base
(port informed me of port name change to {}stable)

then upgrade ruby:
cd /usr/ports/lang/ruby
make
Comment 1 Michael Scheidell 2006-02-20 14:32:43 UTC
This is a multi-part message in MIME format.

------=_NextPart_000_0002_01C63600.99C78ED0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

might be whole ports base:  wget didn't like it either.
(again, reminder,  openssl-stable-overwite-base-0.9.7i IS installed.  =
should look for libcrypt0.so.3 in /usr/lib  not /usr/local/lib.


===>   wget-1.10.2 depends on file: /usr/local/lib/libcrypto.so.3 =
- not found
===>    Verifying install for /usr/local/lib/libcrypto.so.3 in =
/usr/ports/security/openssl-stable
===>  Installing for openssl-stable-overwrite-base-0.9.7i
===>   Generating temporary packing list
===>  Checking if security/openssl-stable already installed
===>   openssl-stable-overwrite-base-0.9.7i is already installed
      You may wish to ``make deinstall'' and install this port again
      by ``make reinstall'' to upgrade it properly.
      If you really wish to overwrite the old port of =
security/openssl-stable
      without deleting it first, set the variable "FORCE_PKG_REGISTER"
      in your environment or the "make install" command line.
*** Error code 1

Stop in /usr/ports/security/openssl-stable.
*** Error code 1

Stop in /usr/ports/ftp/wget.


Stop in /usr/ports/security/openssl-stable.
*** Error code 1
Comment 2 Michael Scheidell 2006-02-20 15:20:44 UTC
This is a multi-part message in MIME format.

------=_NextPart_000_0002_01C63607.4F3B38B0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

I don't know what this will break, but this fixed it for me:
http://www.freebsd.org/cgi/query-pr.cgi?pr=93595

in /usr/ports/Mk:

diff -bBru bsd.openssl.mk.orig bsd.openssl.mk
--- bsd.openssl.mk.orig Fri Nov 11 20:00:11 2005
+++ bsd.openssl.mk      Mon Feb 20 10:16:14 2006
@@ -57,7 +57,7 @@
 WITH_OPENSSL_BASE=yes
 .endif

-.if defined(WITH_OPENSSL_BASE)
+.if defined(WITH_OPENSSL_BASE) || defined(OPENSSL_OVERWRITE_BASE)
 OPENSSLBASE=           /usr
 OPENSSLDIR=            /etc/ssl
Comment 3 Mark Linimon freebsd_committer freebsd_triage 2006-02-21 15:20:03 UTC
Responsible Changed
From-To: freebsd-ports-bugs->dinoex

Over to maintainer of bsd.openssl.mk.
Comment 4 Dirk Meyer freebsd_committer freebsd_triage 2006-02-22 17:07:36 UTC
State Changed
From-To: open->analyzed

- your patch does not solve the problem. 
As a side effect a dependecy to a base file gest registered. 

- you have to set  
WITH_OPENSSL_BASE=yes 
so all ports know they have to link against the base.
Comment 5 Dirk Meyer freebsd_committer freebsd_triage 2006-02-25 12:41:53 UTC
State Changed
From-To: analyzed->feedback


Please check again. 

if you build a port with OPENSSL_OVERWRITE_BASE 

There should no reason any openssl application 
sucks in the ports. 

You may have clobbered your user/local/lib/ 
By overwriten an installed port, without uninstalling it. 

[...] 
#       if no preference was set, check for an installed base version 
#       but give an installed port preference over it. 
.if     !defined(WITH_OPENSSL_BASE) &&  
!defined(WITH_OPENSSL_BETA) &&  
!defined(WITH_OPENSSL_PORT) &&  
!defined(WITH_OPENSSL_STABLE) &&  
!exists(${LOCALBASE}/lib/libcrypto.so) &&  
exists(/usr/include/openssl/opensslv.h) 
WITH_OPENSSL_BASE=yes 
.endif 
[...]
Comment 6 Dirk Meyer freebsd_committer freebsd_triage 2006-02-25 14:02:48 UTC
State Changed
From-To: feedback->patched


Please try this patch instead: 

--- /usr/ports/Mk/bsd.openssl.mk	Sat Nov 12 07:00:27 2005 
+++ public_html/ports/Mk/bsd.openssl.mk	Sat Feb 25 13:45:56 2006 
@@ -52,6 +52,7 @@ 
!defined(WITH_OPENSSL_BETA) &&  
!defined(WITH_OPENSSL_PORT) &&  
!defined(WITH_OPENSSL_STABLE) &&  
+	!defined(OPENSSL_OVERWRITE_BASE) &&  
!exists(${LOCALBASE}/lib/libcrypto.so) &&  
exists(/usr/include/openssl/opensslv.h) 
WITH_OPENSSL_BASE=yes 


I will commit this after the freeze
Comment 7 Dirk Meyer freebsd_committer freebsd_triage 2006-04-30 22:21:56 UTC
State Changed
From-To: patched->closed

committed, thanks.