Python-2.2.1, Solaris7, make test fails...

Hugh Sasse Staff Elec Eng hgs at dmu.ac.uk
Thu Apr 18 11:11:03 EDT 2002


On 18 Apr 2002, Martin v. [iso-8859-1] Löwis wrote:

> Hugh Sasse Staff Elec Eng <hgs at dmu.ac.uk> writes:
>
> > I can't yet: I don't know which properties are reversed:
> >  * Modules included in the config.c file
> >  * List of objects to be added to library archive
> >  * linker options added to linker options
> >  * Rules added to Makefile
> >  * Names collected in SHAREDMODS variable.
>
> The state of 'will the following modules be static or dynamic'. In a
> Setup file, you can have
>
        [*shared*, *static* intereaved]

But to change the wording one needs to know which of the above
properties are reversed, and how commenting out modules affects them in
each case.
> ...
>
> > > Use 'gcc --print-prog-name=ld' to find out which ld binary gcc uses.
> > /usr/local/sparc-sun-solaris2.7/bin/ld
> > /usr/local/sparc-sun-solaris2.7/bin/ld --version gives
> >
> > GNU ld version 2.12
> > Copyright 2002 Free Software Foundation, Inc.
>
> Ok; that explains it: configure does
>
>    $CC -Xlinker -V 2>&1 | grep BFD

gcc -Xlinker -V on my system gives:
Script started on Thu 18 Apr 2002 16:07:12 BST
neelix hgs 11 %> gcc -Xlinker -V
/usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crt1.o: In function `_start':
/usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.3/crt1.o(.text+0x5c): undefined reference to `main'
GNU ld version 2.12
  Supported emulations:
   elf32_sparc
   elf64_sparc
collect2: ld returned 1 exit status
neelix hgs 12 %> exit
neelix hgs 13 %>
script done on Thu 18 Apr 2002 16:07:52 BST
>
> expecting that the linker output reads like
>
> GNU ld version 2.11.2 (with BFD 2.11.2)
>   Supported emulations:
>    elf32_sparc
>    elf64_sparc
>
> Apparently, in binutils 2.12, GNU ld stops printing BFD in its
> output. The proper fix is to invoke --help instead, and to see whether
> export-dynamic appears in the output.
output from :  /usr/local/sparc-sun-solaris2.7/bin/ld --help  is [rather
long!]:

Usage: /usr/local/sparc-sun-solaris2.7/bin/ld [options] file...
Options:
  -a KEYWORD                  Shared library control for HP/UX compatibility
  -A ARCH, --architecture ARCH
                              Set architecture
  -b TARGET, --format TARGET  Specify target for following input files
  -c FILE, --mri-script FILE  Read MRI format linker script
  -d, -dc, -dp                Force common symbols to be defined
  -e ADDRESS, --entry ADDRESS Set start address
  -E, --export-dynamic        Export all dynamic symbols
  -EB                         Link big-endian objects
  -EL                         Link little-endian objects
  -f SHLIB, --auxiliary SHLIB Auxiliary filter for shared object symbol table
  -F SHLIB, --filter SHLIB    Filter for shared object symbol table
  -g                          Ignored
  -G SIZE, --gpsize SIZE      Small data size (if no size, same as --shared)
  -h FILENAME, -soname FILENAME
                              Set internal name of shared library
  -I PROGRAM, --dynamic-linker PROGRAM
                              Set PROGRAM as the dynamic linker to use
  -l LIBNAME, --library LIBNAME
                              Search for library LIBNAME
  -L DIRECTORY, --library-path DIRECTORY
                              Add DIRECTORY to library search path
  -m EMULATION                Set emulation
  -M, --print-map             Print map file on standard output
  -n, --nmagic                Do not page align data
  -N, --omagic                Do not page align data, do not make text readonly
  -o FILE, --output FILE      Set output file name
  -O                          Optimize output file
  -Qy                         Ignored for SVR4 compatibility
  -q, --emit-relocs           Generate relocations in final output
  -r, -i, --relocateable      Generate relocateable output
  -R FILE, --just-symbols FILE
                              Just link symbols (if directory, same as --rpath)
  -s, --strip-all             Strip all symbols
  -S, --strip-debug           Strip debugging symbols
  -t, --trace                 Trace file opens
  -T FILE, --script FILE      Read linker script
  -u SYMBOL, --undefined SYMBOL
                              Start with undefined reference to SYMBOL
  --unique [=SECTION]         Don't merge input [SECTION | orphan] sections
  -Ur                         Build global constructor/destructor tables
  -v, --version               Print version information
  -V                          Print version and emulation information
  -x, --discard-all           Discard all local symbols
  -X, --discard-locals        Discard temporary local symbols (default)
  --discard-none              Don't discard any local symbols
  -y SYMBOL, --trace-symbol SYMBOL
                              Trace mentions of SYMBOL
  -Y PATH                     Default search path for Solaris compatibility
  -(, --start-group           Start a group
  -), --end-group             End a group
  -assert KEYWORD             Ignored for SunOS compatibility
  -Bdynamic, -dy, -call_shared
                              Link against shared libraries
  -Bstatic, -dn, -non_shared, -static
                              Do not link against shared libraries
  -Bsymbolic                  Bind global references locally
  --check-sections            Check section addresses for overlaps (default)
  --no-check-sections         Do not check section addresses for overlaps
  --cref                      Output cross reference table
  --defsym SYMBOL=EXPRESSION  Define a symbol
  --demangle [=STYLE]         Demangle symbol names [using STYLE]
  --embedded-relocs           Generate embedded relocs
  -fini SYMBOL                Call SYMBOL at unload-time
  --force-exe-suffix          Force generation of file with .exe suffix
  --gc-sections               Remove unused sections (on some targets)
  --no-gc-sections            Don't remove unused sections (default)
  --help                      Print option help
  -init SYMBOL                Call SYMBOL at load-time
  -Map FILE                   Write a map file
  --no-define-common          Do not define Common storage
  --no-demangle               Do not demangle symbol names
  --no-keep-memory            Use less memory and more disk I/O
  --no-undefined              Allow no undefined symbols
  --allow-shlib-undefined     Allow undefined symbols in shared objects
  --no-warn-mismatch          Don't warn about mismatched input files
  --no-whole-archive          Turn off --whole-archive
  --noinhibit-exec            Create an output file even if errors occur
  -nostdlib                   Only use library directories specified on
				the command line
  --oformat TARGET            Specify target of output file
  -qmagic                     Ignored for Linux compatibility
  --relax                     Relax branches on certain targets
  --retain-symbols-file FILE  Keep only symbols listed in FILE
  -rpath PATH                 Set runtime shared library search path
  -rpath-link PATH            Set link time shared library search path
  -shared, -Bshareable        Create a shared library
  --sort-common               Sort common symbols by size
  --spare-dynamic-tags COUNT  How many tags to reserve in .dynamic section
  --split-by-file [=SIZE]     Split output sections every SIZE octets
  --split-by-reloc [=COUNT]   Split output sections every COUNT relocs
  --stats                     Print memory usage statistics
  --target-help               Display target specific options
  --task-link SYMBOL          Do task level linking
  --traditional-format        Use same format as native linker
  --section-start SECTION=ADDRESS
                              Set address of named section
  -Tbss ADDRESS               Set address of .bss section
  -Tdata ADDRESS              Set address of .data section
  -Ttext ADDRESS              Set address of .text section
  --verbose                   Output lots of information during link
  --version-script FILE       Read version information script
  --version-exports-section SYMBOL
                              Take export symbols list from .exports, using
				SYMBOL as the version.
  --warn-common               Warn about duplicate common symbols
  --warn-constructors         Warn if global constructors/destructors are seen
  --warn-multiple-gp          Warn if the multiple GP values are used
  --warn-once                 Warn only once per undefined symbol
  --warn-section-align        Warn if start of section changes due to alignment
  --fatal-warnings            Treat warnings as errors
  --whole-archive             Include all objects from following archives
  --wrap SYMBOL               Use wrapper functions for SYMBOL
  --mpc860c0 [=WORDS]         Modify problematic branches in last WORDS (1-10,
				default 5) words of a page
/usr/local/sparc-sun-solaris2.7/bin/ld: supported targets: elf32-sparc elf64-sparc a.out-sunos-big elf64-little elf64-big elf32-little elf32-big srec symbolsrec tekhex binary ihex
/usr/local/sparc-sun-solaris2.7/bin/ld: supported emulations: elf32_sparc elf64_sparc
/usr/local/sparc-sun-solaris2.7/bin/ld: emulation specific options:
elf32_sparc:
  -Bgroup		Selects group name lookup rules for DSO
  --disable-new-dtags	Disable new dynamic tags
  --enable-new-dtags	Enable new dynamic tags
  --eh-frame-hdr	Create .eh_frame_hdr section
  -z combreloc		Merge dynamic relocs into one section and sort
  -z defs		Disallows undefined symbols
  -z initfirst		Mark DSO to be initialized first at runtime
  -z interpose		Mark object to interpose all DSOs but executable
  -z loadfltr		Mark object requiring immediate process
  -z nocombreloc	Don't merge dynamic relocs into one section
  -z nocopyreloc	Don't create copy relocs
  -z nodefaultlib	Mark object not to use default search paths
  -z nodelete		Mark DSO non-deletable at runtime
  -z nodlopen		Mark DSO not available to dlopen
  -z nodump		Mark DSO not available to dldump
  -z now		Mark object non-lazy runtime binding
  -z origin		Mark object requiring immediate $ORIGIN processing
			  at runtime
  -z KEYWORD		Ignored for Solaris compatibility
elf64_sparc:
  -Bgroup		Selects group name lookup rules for DSO
  --disable-new-dtags	Disable new dynamic tags
  --enable-new-dtags	Enable new dynamic tags
  --eh-frame-hdr	Create .eh_frame_hdr section
  -z combreloc		Merge dynamic relocs into one section and sort
  -z defs		Disallows undefined symbols
  -z initfirst		Mark DSO to be initialized first at runtime
  -z interpose		Mark object to interpose all DSOs but executable
  -z loadfltr		Mark object requiring immediate process
  -z nocombreloc	Don't merge dynamic relocs into one section
  -z nocopyreloc	Don't create copy relocs
  -z nodefaultlib	Mark object not to use default search paths
  -z nodelete		Mark DSO non-deletable at runtime
  -z nodlopen		Mark DSO not available to dlopen
  -z nodump		Mark DSO not available to dldump
  -z now		Mark object non-lazy runtime binding
  -z origin		Mark object requiring immediate $ORIGIN processing
			  at runtime
  -z KEYWORD		Ignored for Solaris compatibility

Report bugs to bug-binutils at gnu.org
>
> > I think I will delay doing that for now, because most of the tests
> > worked without using GCC.  Another post suggests that this is not common
> > to Solaris7, (referring to pre-releases of Python-2.2.1).  Therefore I
> > may not really be helping anyone else by exploring that.
>
> It turns out that you are the first one to use binutils 2.12 on
> Solaris, trying to build Python with that. So you are likely helping
> others; Python 2.2.2 (and perhaps 2.1.4) will have this problem
> corrected.

So the fastest fix is for me to doengrade binutils?
Can I provide any further diags at this point which might be helpful?
>
> Regards,
> Martin
>
        Thank you,
        Hugh
>







More information about the Python-list mailing list