Bug 20638

Summary: Cannot compile LyX 1.1.5.1
Product: Ports & Packages Reporter: Erich Zigler <erich>
Component: Individual Port(s)Assignee: dirk
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   

Description Erich Zigler 2000-08-16 07:50:00 UTC
BufferView2.o: In function `BufferView::insertLyXFile(lyxstring const &)':
BufferView2.o(.text+0x15a): undefined reference to `gettext'
BufferView2.o(.text+0x1a5): undefined reference to `gettext'
BufferView2.o(.text+0x5b6): undefined reference to `gettext'
BufferView2.o(.text+0x601): undefined reference to `gettext'
BufferView2.o: In function `BufferView::insertInset(Inset *, lyxstring const &, bool)':
BufferView2.o(.text+0xf78): undefined reference to `gettext'
BufferView2.o(.text+0xfba): more undefined references to `gettext' follow
main.o: In function `main':
main.o(.text+0x10a): undefined reference to `bindtextdomain'
main.o(.text+0x11a): undefined reference to `textdomain'
menus.o: In function `Menus::openByName(lyxstring const &)':
menus.o(.text+0x2f2): undefined reference to `gettext'
menus.o(.text+0x324): undefined reference to `gettext'
menus.o(.text+0x358): undefined reference to `gettext'
menus.o(.text+0x38c): undefined reference to `gettext'
menus.o(.text+0x3c0): undefined reference to `gettext'
menus.o(.text+0x3f4): more undefined references to `gettext' follow
gmake[3]: *** [lyx] Error 1
gmake[3]: Leaving directory `/usr/ports/print/lyx/work/lyx-1.1.5/src'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/usr/ports/print/lyx/work/lyx-1.1.5/src'
gmake[1]: *** [all-recursive-am] Error 2
gmake[1]: Leaving directory `/usr/ports/print/lyx/work/lyx-1.1.5/src'
gmake: *** [all-recursive] Error 1
*** Error code 2

How-To-Repeat: 
	cd /usr/ports/print/lyx && make
Comment 1 Chris D.Faulhaber freebsd_committer freebsd_triage 2000-08-18 14:15:15 UTC
Responsible Changed
From-To: freebsd-ports->dirk

Over to maintainer
Comment 2 Jose M. Alcaide 2000-09-04 00:08:13 UTC
I found that gmake is involved in this problem. If make(1) is used,
LyX is linked fine. It seems that gmake invokes the configure script
(for second time) just before starting the compilation. This second
invocation overwrites src/Makefile with a broken makefile which does
not include any "-lintl". I don't know why gmake invokes configure again.
This can be easily tested: type "make configure", and then check
src/Makefile: lyx_LDADD includes "-lintl". Then, type "make" to continue
building the port, and see how the configure script runs again. Interrupt
the compilation, and check again src/Makefile: "-lintl" is gone...

However, deleting "USE_GMAKE=yes" from the port's Makefile is not a
definitive solution. LyX is successfully built, indeed, but the
installation fails (see http://www.FreeBSD.org/cgi/query-pr.cgi?pr=20516).

I think that this port is suffering the chaos inherent to Linux and some
GNU tools :-(

There is also an ugly workaround: add "--with-included-gettext" to
CONFIGURE_ARGS in the port's Makefile.

-- JMA
****** Jose M. Alcaide  //  jose@we.lc.ehu.es  //  jmas@FreeBSD.org ******
** "Beware of Programmers who carry screwdrivers" --  Leonard Brandwein **
Comment 3 dirk freebsd_committer freebsd_triage 2000-09-10 12:09:12 UTC
State Changed
From-To: open->feedback

Please test the latest version of the lyx port and tell me if the 
problem still exists: 

Makefile: 
$FreeBSD: ports/print/lyx/Makefile,v 1.51 2000/09/10 11:06:01 dirk Exp $
Comment 4 dirk freebsd_committer freebsd_triage 2000-09-19 19:05:50 UTC
State Changed
From-To: feedback->closed

Timeout error... ;-) 

Other users reported that it works, now.