Bug 55186 - Doxygen 1.3.1 build fails on Alpha
Summary: Doxygen 1.3.1 build fails on Alpha
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: freebsd-kde (group)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-08-02 16:40 UTC by idart
Modified: 2004-02-29 15:10 UTC (History)
0 users

See Also:


Attachments
Makefile.patch (1.79 KB, patch)
2003-08-02 16:40 UTC, idart
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description idart 2003-08-02 16:40:09 UTC
	Doxygen (1.3.1) fails to build from ports on an Alpha. Here's the
    last part of the output:
    
    gmake[2]: Entering directory `/usr/ports/devel/doxygen/work/doxygen-1.3.1/src'
    c++ -c -O1 -pipe -mcpu=ev56 -D_THREAD_SAFE -Wall -W -I../qtools -I../libpng -I. -o ../objects/main.o main.cpp
    c++  -o ../bin/doxygen ../objects/main.o  -L../lib -ldoxygen -ldoxycfg -lqtools -lpng -pthread
    /usr/libexec/elf/ld: ../lib/libdoxygen.a(language.o): .got subsegment exceeds 64K (size 94168)
    /usr/libexec/elf/ld: failed to set dynamic section sizes: File format not recognized

    The error indicates that ld can't have more than 64K symbols in any
    one object file, but apparently languages.o has more. 

    This seems to be Alpha spesific, as all references I found to it was
    from Linux/Alpha users, but I'm not 100% sure.

Fix: I've attached a patch against the ports' makefile that changes the default
    build to only build with English, as opposed to all supported languages
    which is the default now. I've also added a WITH-LANGS switch which will
    allow building with other languages.
    
    The suggested output should be changed, as the configure script isn't
    available .pre-everyting, but you get the point.

    I propose to apply this regardless of platform (Alpha or not) since I
    can't imagine anyone actually needing all the supported languanges. And
    with the WITH_LANGS switch, it should be easy enough to add this to
    pkgtools.conf for automatic builds.

    With this applied, I was able to build Doxygen with WITH_LANGS=no (no
    as in "Norwegian", not no as opposed to yes).

    One more thing; I've seen some package build logs for Doxygen on Alpha
    that indicates the build as "runaway". This happens while compiling
    a Flex generated config.cpp. It's actually not "runaway", it just takes
    an awfull long time to compile that file (between 12 and 24 hours on my
    164LX, 533MHz).
How-To-Repeat:     Try to build Doxygen 1.3.1 from ports/devel/doxygen on an Alpha.
    In my case, I did the build with HAVE_LATEX=yes, but that's not
    significant.
Comment 1 Kirill Ponomarev freebsd_committer freebsd_triage 2003-08-03 08:10:53 UTC
Responsible Changed
From-To: freebsd-ports-bugs->kde

Over to maintainer.
Comment 2 Tilman Keskinoz freebsd_committer freebsd_triage 2003-08-19 14:51:36 UTC
State Changed
From-To: open->feedback

I have updated the port to a new version. Did that fix your problem? 
Sorry for missing this patch before.
Comment 3 idart 2003-09-29 22:27:50 UTC
The following was reply was sent to responsible parties on the 22th
August 2003. I just now saw that I forgot to send a copy to gnats.
I'm very sorry for the dealy, but the reply is still releveant:

No, I'm afraid not. Same problem. Complete build log can be found here:
http://www.performancedesign.no/~idart/doxygen.log
Here's just the part with the error:

-----
usr/libexec/elf/ld: ../lib/libdoxygen.a(language.o): .got subsegment
exceeds 64K (size 94856)
/usr/libexec/elf/ld: failed to set dynamic section sizes: File format
not recognized
gmake[2]: *** [../bin/doxygen] Error 1
gmake[2]: Leaving directory
`/usr/ports/devel/doxygen/work/doxygen-1.3.3/src'
gmake[1]: *** [all] Error 2
gmake[1]: Leaving directory
`/usr/ports/devel/doxygen/work/doxygen-1.3.3/src'
gmake: *** [all] Error 2
*** Error code 2
-----

I'm sorry it took some time to answer, but it now took 60 hours to
complete the comilation of config.cpp, this one:

-----
gmake -f Makefile.libdoxycfg PERL=/usr/bin/perl all
gmake[2]: Entering directory
`/usr/ports/devel/doxygen/work/doxygen-1.3.3/src'
flex -PconfigYY -t config.l >config.cpp 
c++ -c -O1 -pipe -mcpu=ev56 -D_THREAD_SAFE -Wall -W -I../qtools -o
../objects/config.o config.cpp
-----

I'm beginning to think something is seriously wrong with this machine,
or the compiler settings. Other machines I've installed this one
(one i386 running Linux and two ppc running OS X) chewed trough that
file like any other file, they didn't take days to compile it.

Anyhow, the reported problem should probably go to the Doxygen
developers. It can be fixed by rearranging the source code so
that not so many symbols end up in language.o. The patch I
suggested for the Makefile will mean package building with
support for either english only or just a selected set of
languages (as many as can be stuffed in there under the 64K limit).
If the Doxygen developers where to refactor the code instead,
we could avoid that.


- IT
Comment 4 Pav Lucistnik freebsd_committer freebsd_triage 2004-02-28 22:37:20 UTC
State Changed
From-To: feedback->open

Feedback received
Comment 5 Tilman Keskinoz freebsd_committer freebsd_triage 2004-02-28 23:01:01 UTC
State Changed
From-To: open->closed

I disabled foreign languages on alpha, so this should Fix your problem. 
Thank you very much for your long patience, and the extensive testing. 

I have not implemented the LANG switches, because I would like to keep the  
port simple. If someone needs them please speak up...
Comment 6 idart 2004-02-29 15:03:51 UTC
It "fixes" the problem in that it now builds fine on Alpha, but it also 
makes it useless for Alpha users who need other languages, such as 
myself. I still have to hack the Makefile when I upgrade the port to 
include support for Norwegian. However, I concede that I'm probably 
among very few who needs this, and I'm therefore prepared to continue 
doing so.

I will say, however, that I'm not buying the "keep it simple" argument. 
The Makefile for the port hardly qualifies as "simple" as it is. I fail 
to see how adding one more switch would complicate things so much it 
would make the port "complex".

I will go back and bug the Doxygen developers again to do something 
about the way languages are handled. Maybe we can get them to fix the 
real root of the problem.