new lyx port does not link -- gettext (-lintl is missing)
>Submitter-Id: current-users >Originator: Mikhail Teterin >Organization: Virtual Estates, Inc. >Confidential: no >Synopsis: new lyx port does not link -- gettext (-lintl is missing) >Severity: critical >Priority: medium >Category: ports >Release:FreeBSD 3.4-STABLE i386 >Class: sw-bug >Environment: >Description: It appears, the configure script does check for -lint, and finding it installed on the system already rightfully chooses not to use the included one. Unfortunately, it then does not set the INTLLIB to anything, which means lyx_LDADD in src/Makefile does not mention the -lintl at all and the following linker error is seen. g++295 -O2 -fexpensive-optimizations -pipe -mcpu=i686 -march=i686 -L/usr/X11R6/lib -o lyx BufferView.o Bullet.o Chktex.o DepTable.o FontInfo.o FontLoader.o ImportLaTeX.o ImportNoweb.o LaTeX.o LaTeXFeatures.o LaTeXLog.o Literate.o LyXAction.o LyXSendto.o LyXView.o PaperLayout.o ParagraphExtra.o Spacing.o TableLayout.o bmtable.o buffer.o bufferlist.o bufferparams.o bullet_forms.o bullet_forms_cb.o chset.o combox.o credits.o credits_form.o debug.o filedlg.o form1.o intl.o kbmap.o lastfiles.o latexoptions.o layout.o layout_forms.o lyx.o lyx_cb.o lyx_gui.o lyx_gui_misc.o lyx_main.o lyx_sendfax.o lyx_sendfax_main.o lyx_sty.o lyxdraw.o lyxfont.o lyxfr0.o lyxfr1.o lyxfunc.o lyxlex.o lyxlookup.o lyxrc.o lyxserver.o lyxvc.o main.o menus.o minibuffer.o paragraph.o print_form.o screen.o sp_form.o spellchecker.o table.o tex-accent.o tex-strings.o texoptions.o texrow.o text.o text2.o toolbar.o trans.o trans_mgr.o undo.o vc-backend.o vspace.o mathed/.libs/libmathed.a insets/.libs/libinsets.a! support/.libs/libsupport.a -lxforms -lXpm -lSM -lICE -liberty -lc -lm -L/usr/X11R6/lib -lX11 BufferView.o: In function `BufferView::resizeCurrentBuffer(void)': BufferView.o(.text+0x96c): undefined reference to `gettext' BufferView.o: In function `BufferView::gotoError(void)': BufferView.o(.text+0xe5b): undefined reference to `gettext' BufferView.o(.text+0xef9): undefined reference to `gettext' Chktex.o: In function `Chktex::scanLogFile(TeXErrors &)': Chktex.o(.text+0x5b3): undefined reference to `gettext' FontLoader.o: In function `FontLoader::doLoad(LyXFont::FONT_FAMILY, LyXFont::FONT_SERIES, LyXFont::FONT_SHAPE, LyXFont::FONT_SIZE)': FontLoader.o(.text+0xad3): undefined reference to `gettext' LaTeX.o(.text+0x591): more undefined references to `gettext' follow main.o: In function `main': main.o(.text+0x98): undefined reference to `bindtextdomain' main.o(.text+0xa8): undefined reference to `textdomain' menus.o: In function `Menus::openByName(lyxstring const &)': menus.o(.text+0x292): undefined reference to `gettext' menus.o(.text+0x2c3): undefined reference to `gettext' menus.o(.text+0x2f4): undefined reference to `gettext' menus.o(.text+0x32c): undefined reference to `gettext' menus.o(.text+0x35d): undefined reference to `gettext' menus.o(.text+0x38e): more undefined references to `gettext' follow collect2: ld returned 1 exit status *** Error code 1 Stop. [...] >How-To-Repeat: >Fix: A dirty fix is to add the -lintl to the lyx_LDADD line in src/Makefile after configure. A clean fix is too complicated I'm afraid of the configure.in/configure mess.
Re: new lyx port does not link -- gettext (-lintl is missing)
Mikhail Teterin <[EMAIL PROTECTED]> writes: | Stop. | [...] | >How-To-Repeat: | | | >Fix: | A dirty fix is to add the -lintl to the lyx_LDADD line | in src/Makefile after configure. A clean fix is too | complicated I'm afraid of the configure.in/configure | mess. I think the correct fix it to check if -lintl is needed when linking. This is not always the case, i.e. linux glibc systems does not need it. This should be done in similar fashion to the one we use for checking if -lc and -lm are needed on the link line. Lgb
Re: new lyx port does not link -- gettext (-lintl is missing)
> "Lars" == Lars Gullik Bjønnes <[EMAIL PROTECTED]> writes: Lars> Mikhail Teterin <[EMAIL PROTECTED]> writes: | Stop. | [...] Lars> | >How-To-Repeat: | | | >Fix: | A dirty fix is to add the -lintl Lars> to the lyx_LDADD line | in src/Makefile after configure. A clean Lars> fix is too | complicated I'm afraid of the Lars> configure.in/configure | mess. Lars> I think the correct fix it to check if -lintl is needed when Lars> linking. This is not always the case, i.e. linux glibc systems Lars> does not need it. Lars> This should be done in similar fashion to the one we use for Lars> checking if -lc and -lm are needed on the link line. I've seen a bug fix some time ago against gettext m4 files which deals with that. I'll try to find it again and apply it. The fact that gettext is not maintained is a real pain. One solution would be to take the version in latest fileutils, which is actively maintained. JMarc
Re: new lyx port does not link -- gettext (-lintl is missing)
> > "Mikhail" == Mikhail Teterin <[EMAIL PROTECTED]> writes: > > Mikhail> It appears, the configure script does check for -lint, and > Mikhail> finding it installed on the system already rightfully chooses > Mikhail> not to use the included one. Unfortunately, it then does not > Mikhail> set the INTLLIB to anything, which means lyx_LDADD in > Mikhail> src/Makefile does not mention the -lintl at all and the > Mikhail> following linker error is seen. > > Mikhail> g++295 -O2 -fexpensive-optimizations -pipe -mcpu=i686 A > Mikhail> dirty fix is to add the -lintl to the lyx_LDADD line in > Mikhail> src/Makefile after configure. A clean fix is too complicated > Mikhail> I'm afraid of the configure.in/configure mess. > > Thanks for the report. It will be fixed in next release. A simple > workaround is to configure with --with-included-gettext. Yikes! If every app does that, only harddrive manufacturers will prosper. If you'd like my opinion, stop repackaging the ``included-gettext'' altogether, and simply insist on its presense -- just like xforms, ispell, etc. -mi
Re: new lyx port does not link -- gettext (-lintl is missing)
> "Mikhail" == Mikhail Teterin <[EMAIL PROTECTED]> writes: Mikhail>It appears, the configure script does check for -lint, Mikhail> and finding it installed on the system already rightfully Mikhail> chooses not to use the included one. Unfortunately, it then Mikhail> does not set the INTLLIB to anything, which means lyx_LDADD Mikhail> in src/Makefile does not mention the -lintl at all and the Mikhail> following linker error is seen. Mikhail> g++295 -O2 -fexpensive-optimizations -pipe -mcpu=i686 Mikhail>A dirty fix is to add the -lintl to the lyx_LDADD line Mikhail> in src/Makefile after configure. A clean fix is too Mikhail> complicated I'm afraid of the configure.in/configure mess. Thanks for the report. It will be fixed in next release. A simple workaround is to configure with --with-included-gettext. JMarc
Re: new lyx port does not link -- gettext (-lintl is missing)
> "Mikhail" == Mikhail Teterin <[EMAIL PROTECTED]> writes: >> Thanks for the report. It will be fixed in next release. A simple >> workaround is to configure with --with-included-gettext. Mikhail> Yikes! If every app does that, only harddrive manufacturers Mikhail> will prosper. If you'd like my opinion, stop repackaging the Mikhail> ``included-gettext'' altogether, and simply insist on its Mikhail> presense -- just like xforms, ispell, etc. Note that I suggested --with-included-gettext just as a workaround for now. The fix I applied should be a real one :) JMarc