Today I had a hard time helping a student trying to build PETSc on a
Ubuntu box he has at home... For some unknow reason, the configure
step let pass '-PIC' as a valid GCC flag... The relevant parts of the
configure log are shown below... (the <...> represent uninteresting
output)
TEST checkPIC from
config.setCompilers(/home/nisi/petsc-3.0.0-p5/config/BuildSystem/config/setCompilers.py:807)
TESTING: checkPIC from
config.setCompilers(config/BuildSystem/config/setCompilers.py:807)
Determine the PIC option for each compiler
- There needs to be a test that checks that the functionality
is actually working
Pushing language C
Trying C compiler flag -PIC
<.....>
sh: gcc -o conftest -PIC conftest.o
Executing: gcc -o conftest -PIC conftest.o
sh:
Possible ERROR while running linker: gcc: no se reconoce la opci?n '-PIC'
output: error message = {gcc: no se reconoce la opci?n '-PIC'
}
<.....>
Valid C linker flag -PIC
Adding C compiler flag -PIC
sh: gcc -c -o conftest.o -PIC conftest.c
Executing: gcc -c -o conftest.o -PIC conftest.c
sh:
Possible ERROR while running compiler: error message = {gcc: no se
reconoce la opci?n '-PIC'
}
<.....>
Added C compiler flag -PIC
What's going on?? My guess was that BuildSystem is not prepared for
Spanish words :-)
I asked the guy to start the whole process again, but this time begin doing:
$ export LANG=en_US.UTF-8
and now things worked out of the box...
Is this issue documented somewhere? There is anything we can do to
improve this? What is the minimal Python version BuildSystem should
require? Scanning stdout/stderr for guessing failures is really
fragile...
--
Lisandro Dalc?n
---------------
Centro Internacional de M?todos Computacionales en Ingenier?a (CIMEC)
Instituto de Desarrollo Tecnol?gico para la Industria Qu?mica (INTEC)
Consejo Nacional de Investigaciones Cient?ficas y T?cnicas (CONICET)
PTLC - G?emes 3450, (3000) Santa Fe, Argentina
Tel/Fax: +54-(0)342-451.1594