Bug 177760

Summary: circular dependency with libiconv/gettext
Product: Ports & Packages Reporter: sadsfae
Component: Individual Port(s)Assignee: autotools
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   

Description sadsfae 2013-04-10 19:30:00 UTC
When following the UPDATING.txt instructions up to or prior to 20130316 (my ports were dated 2014-02-25) the following error occurs -after- removal of gettext and during the build of libiconv.

Shared object "libintl.so.9" not found, required by "sed" 

# pkg delete -f devel/gettext (goes ok)
# portmaster converters/libiconv devel/gettext (libiconv build fails to error above)

Because devel/gettext is removed the system is left unusable for many applications.  In my case I simply restored from ZFS root snapshot to troubleshoot various approaches with help from folks in the FreeBSD forums.

The only make config option set for converters/libiconv was [x] Encodings: Include extra character sets

Full details are here:
https://forums.freebsd.org/showthread.php?t=38970

Fix: 

To workaround this issue the following needs to be done:

# cp /usr/local/lib/libintl.so.9 /usr/local/lib/libintl.so.9.new
# pkg delete -f devel/gettext
# cp /usr/local/lib/libintl.so.9.new /usr/local/lib/libintl.so.9
# portmaster converters/libiconv devel/gettext
How-To-Repeat: From ports dated prior or up to 20130316 attempt to follow /usr/ports/UPDATING.txt instructions where libiconv now handles the lib/charset.alias file instead of devel/gettext:

# pkg delete -f devel/gettext
# portmaster converters/libiconv devel/gettext

Removal of devel/gettext port removes the library "/usr/local/lib/libintl.so.9" which is needed by sed during the build of libiconv.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2013-04-10 20:36:46 UTC
Responsible Changed
From-To: freebsd-amd64->freebsd-ports-bugs

ports PR.
Comment 2 Scot Hetzel 2013-04-11 01:44:12 UTC
According to the forum posts you have the following ports installed:

converters/libiconv
devel/gettext
textproc/gsed

textproc/gsed has a dependancy on devel/gettext if the NLS option is
selected.

The problem you are encountering is that the configure script for
converters/libiconv is using /usr/local/bin/sed instead of the base systems
sed.  This is what is causing the libintl.so.9 not found error.

You will need to re-install textproc/gsed before upgrading
converters/libiconv.  If you don't need NLS support in gsed, then just
uncheck that option before rebuilding textproc/gsed.

-- 
DISCLAIMER:

No electrons were maimed while sending this message. Only slightly bruised.
Comment 3 Scot Hetzel 2013-04-11 02:06:16 UTC
One thing I missed in the forum posts is that you tried de-installing
textproc/gsed before re-installing converters/libiconv.

Does /usr/local/bin/sed still exists after de-installing textproc/gsed?

What does the following show had installed sed?

pkg which /usr/local/bin/sed

If it wasn't installed by textproc/gsed, then you will need to re-install
that port.

-- 
DISCLAIMER:

No electrons were maimed while sending this message. Only slightly bruised.
Comment 4 sadsfae 2013-04-11 08:21:50 UTC
Thanks for the replies, prior to copying the libintl.so.9 around I tried
both removing gsed and simply renaming the /usr/local/bin/sed binary so
that it might use the system sed - neither worked prior to following the
UPDATING.txt steps.

pkg which "/usr/local/bin/sed"
/usr/local/bin/sed was not found in the database

I certainly have sed (at least gsed) installed however [gsed-4.2.1_2]

-will
Comment 5 Mark Linimon freebsd_committer freebsd_triage 2013-04-15 03:06:08 UTC
Responsible Changed
From-To: freebsd-ports-bugs->autotools

Over to maintainer(s).
Comment 6 Ade Lovett freebsd_committer freebsd_triage 2013-08-12 21:35:53 UTC
State Changed
From-To: open->closed

Old PR.  With the addition of Templates/config.* this is now a non-issue.