From ust@cert.siemens.de  Mon Mar 18 05:28:51 2002
Return-Path: <ust@cert.siemens.de>
Received: from goliath.siemens.de (goliath.siemens.de [192.35.17.28])
	by hub.freebsd.org (Postfix) with ESMTP
	id E2A4937B416; Mon, 18 Mar 2002 05:28:49 -0800 (PST)
Received: from mail3.siemens.de (mail3.siemens.de [139.25.208.14])
	by goliath.siemens.de (8.11.6/8.11.6) with ESMTP id g2IDSlR13757;
	Mon, 18 Mar 2002 14:28:48 +0100 (MET)
Received: from mars.cert.siemens.de (ust.mchp.siemens.de [139.23.201.17])
	by mail3.siemens.de (8.11.6/8.11.6) with ESMTP id g2IDSkk02612;
	Mon, 18 Mar 2002 14:28:46 +0100 (MET)
Received: from reims.mchp.siemens.de (alaska [139.23.202.134])
	by mars.cert.siemens.de (8.12.2/8.12.1/Siemens CERT [ $Revision: 1.23 ]) with ESMTP id g2IDSk6P032652;
	Mon, 18 Mar 2002 14:28:46 +0100 (CET)
Received: from reims.mchp.siemens.de (localhost [127.0.0.1])
	by reims.mchp.siemens.de (8.12.2/8.12.2/alaska [ $Revision: 1.11 ]) with ESMTP id g2IDSknI086017;
	Mon, 18 Mar 2002 14:28:46 +0100 (CET)
Received: (from ust@localhost)
	by reims.mchp.siemens.de (8.12.2/8.12.2/alaska [ $Revision: 1.2 ]) id g2IDSkOE086016;
	Mon, 18 Mar 2002 14:28:46 +0100 (CET)
Message-Id: <200203181328.g2IDSkOE086016@reims.mchp.siemens.de>
Date: Mon, 18 Mar 2002 14:28:46 +0100 (CET)
From: Udo Schweigert <udo.schweigert@siemens.com>
Reply-To: Udo Schweigert <udo.schweigert@siemens.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc: obrien@freebsd.org
Subject: vim/vim-lite use libiconv without proper LIB_DEPENDS
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         36046
>Category:       ports
>Synopsis:       vim/vim-lite use libiconv without proper LIB_DEPENDS
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 18 05:30:01 PST 2002
>Closed-Date:    Mon Mar 18 13:33:52 PST 2002
>Last-Modified:  Mon Mar 18 13:33:52 PST 2002
>Originator:     Udo Schweigert
>Release:        FreeBSD 4.5-STABLE i386
>Organization:
>Environment:

System: FreeBSD alaska.cert.siemens.de 4.5-STABLE FreeBSD 4.5-STABLE #54: Sun Mar 17 17:52:21 CET 2002 ust@alaska.cert.siemens.de:/usr/obj/work/src/RELENG_4/sys/alaska i386


>Description:

After the upgrade of the libiconv to libiconv.3 (from libiconv.2) I realized
that my vim-lite used libiconv.2 because libiconv was installed when I built
vim-lite. Since libiconv.2 wasn't there anymore (it's now libiconv.3) vim
complained about a missing libiconv.2.


>How-To-Repeat:
>Fix:

There are two possible fixes:

1. Add a LIB_DEPEND to the Makefile of vim, thus always using libiconv:

--- vim/Makefile.orig	Mon Mar 11 06:05:25 2002
+++ vim/Makefile	Mon Mar 18 14:02:21 2002
@@ -124,6 +124,7 @@
 MAKE_ARGS+=	CONF_OPT_GUI="--enable-gui=no --without-x --enable-multibyte"
 MAKE_ARGS+=	CONF_OPT_PERL="--disable-perlinterp --disable-pythoninterp --disable-tclinterp --disable-rubyinterp"
 .endif	# LITE
+LIB_DEPENDS+=	iconv.3:${PORTSDIR}/converters/libiconv
 
 # Until the bsd.gnome.mk people fix their damned file
 .if defined(WITH_GTK)

or 

2. Add a patch to the configure script not to use libiconv (unfortunately it
   is not configurable via a --without... option:

--- vim/files/patch-02.orig	Mon Nov  6 22:53:56 2000
+++ vim/files/patch-02	Mon Mar 18 14:17:48 2002
@@ -1,8 +1,32 @@
---- auto/configure.orig	Tue Oct 31 13:03:47 2000
-+++ auto/configure	Mon Nov  6 11:26:36 2000
-@@ -3171 +3171 @@
+--- auto/configure.orig	Sat Mar  9 19:14:07 2002
++++ auto/configure	Mon Mar 18 14:12:37 2002
+@@ -3420,11 +3420,11 @@
+ 
+   if test "x$gtk_config_prefix" != "x" ; then
+     gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix"
 -    GTK_CONFIG=$gtk_config_prefix/bin/gtk-config
 +    GTK_CONFIG=${GTK_CONFIG}
-@@ -3175 +3175 @@
+   fi
+   if test "x$gtk_config_exec_prefix" != "x" ; then
+     gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix"
 -    GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config
 +    GTK_CONFIG=${GTK_CONFIG}
+   fi
+   if test "X$GTK_CONFIG" = "X"; then
+     # Extract the first word of "gtk-config", so it can be a program name with args.
+@@ -5927,7 +5927,6 @@
+ if { (eval echo configure:5928: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+   rm -rf conftest*
+   echo "$ac_t""yes; with -liconv" 1>&6; cat >> confdefs.h <<\EOF
+-#define HAVE_ICONV 1
+ EOF
+ 
+ else
+@@ -5950,7 +5949,6 @@
+ if { (eval echo configure:5951: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+   rm -rf conftest*
+   echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
+-#define HAVE_ICONV 1
+ EOF
+ 
+ else
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: obrien 
State-Changed-When: Mon Mar 18 13:31:26 PST 2002 
State-Changed-Why:  
This is a local problem.  You must have had the lib installed and vim's 
autoconf script must have noticed this.  However, libiconv is not needed 
to build vim-lite, so I refuse to add the LIB_DEPEND. 

vim-lite$ make clean all 
..snip.. 
vim-lite$ ldd work/vim61b/src/vim 
work/vim61b/src/vim 
libncurses.so.5 => /usr/lib/libncurses.so.5 (0x28125000) 
libposix1e.so.2 => /usr/lib/libposix1e.so.2 (0x28167000) 
libc.so.5 => /usr/lib/libc.so.5 (0x2816d000) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=36046 
>Unformatted:
