I can confirm that the equivalent of this one-line change applied directly
to configure in 1.10.2rc1 fixed the problems I saw with the IBM and Studio
Fortran compilers and the use of non-default ABI flags in FCFLAGS.

-Paul

On Sat, Dec 19, 2015 at 4:08 PM, Paul Hargrove <[email protected]> wrote:

> The "loss" of FCFLAGS in the configure probes is very likely taking place
> at the following line in config/ompi_fortran_check_use_only.m4:
>
>     FCFLAGS=$FCFLAGS_save
>
> I did not find any code in the config/ directory that ever sets
> FCFLAGS_save!
> So, I strongly suspect the following (not yet tested) is the fix:
>
> --- config/ompi_fortran_check_use_only.m4~      Sat Dec 19 16:05:18 2015
> +++ config/ompi_fortran_check_use_only.m4       Sat Dec 19 16:05:25 2015
> @@ -35,6 +35,7 @@
>  AC_DEFUN([OMPI_FORTRAN_CHECK_USE_ONLY],[
>      AS_VAR_PUSHDEF([use_only_var], [ompi_cv_fortran_use_only])
>      OPAL_VAR_SCOPE_PUSH([FCFLAGS_save])
> +    FCFLAGS_save="$FCFLAGS"
>      FCFLAGS="-I. $FCFLAGS"
>
>      AC_CACHE_CHECK([if Fortran compiler supports USE...ONLY],
> use_only_var,
>
>
> -Paul
>
> On Sat, Dec 19, 2015 at 2:26 PM, Paul Hargrove <[email protected]> wrote:
>
>> The subject lines should have read "1.10.2rc1" not "rc2".
>> I have a lot of odd machines for testing, but no time machine :-)
>>
>> -Paul
>>
>> On Sat, Dec 19, 2015 at 1:25 PM, Paul Hargrove <[email protected]>
>> wrote:
>>
>>> I have confirmed identical failures of the 2.0.0rc1 and master tarballs.
>>> -Paul
>>>
>>> On Sat, Dec 19, 2015 at 12:50 PM, Paul Hargrove <[email protected]>
>>> wrote:
>>>
>>>> I am testing on a system with IBM's compilers which has worked for both
>>>> LP64 ({C,CXX,F}FLAGS=-q64) and ILP32 ({C,CXX,FC}FLAGS=-q32) builds on all
>>>> past releases.
>>>>
>>>> With the 1.10.2rc2 tarball, however, I see the following in the
>>>> configure output on the ILP32  configuration:
>>>>
>>>> checking if Fortran compiler and POSIX threads work with -lpthread... no
>>>> configure: error: Can not find working threads configuration.  aborting
>>>>
>>>> Examining the config.log (below) shows this test has run the Fortran
>>>> compiler *without* FCFLAGS (-q32).
>>>> The result is a failed attempt to link 32-bit and 64-bit object files
>>>> together:
>>>>
>>>> configure:64264: checking if Fortran compiler and POSIX threads work
>>>> with -lpthread
>>>> configure:64345: xlc -q32 -g -I. -c conftest.c
>>>> "conftest.c", line 27.18: 1506-280 (W) Function argument assignment
>>>> between types "unsigned long" and "unsigned long*" is not allowed.
>>>> configure:64352: $? = 0
>>>> configure:64362: xlf  conftestf.f conftest.o -o conftest  -lutil
>>>>  -lpthread
>>>> ** fpthread   === End of Compilation 1 ===
>>>> 1501-510  Compilation successful for file conftestf.f.
>>>> /usr/bin/ld: powerpc:common architecture of input file `conftest.o' is
>>>> incompatible with powerpc:common64 output
>>>> conftest.o: In function `pthreadtest_f':
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:23:
>>>> relocation truncated to fit: R_PPC_REL24 against `pthread_self'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:24:
>>>> relocation truncated to fit: R_PPC_REL24 against `pthread_attr_init'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:25:
>>>> relocation truncated to fit: R_PPC_REL24 against `__sigsetjmp'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:25:
>>>> relocation truncated to fit: R_PPC_REL24 against `__pthread_unwind_next'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:25:
>>>> relocation truncated to fit: R_PPC_REL24 against 
>>>> `__pthread_register_cancel'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:26:
>>>> relocation truncated to fit: R_PPC_REL24 against `pthread_create'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:27:
>>>> relocation truncated to fit: R_PPC_REL24 against `pthread_join'
>>>> /gpfs/vesta-fs0/projects/PARTS/hargrove/OMPI/openmpi-1.10.2rc1-linux-ppc32-xlc-12.1/BLD/conftest.c:28:
>>>> relocation truncated to fit: R_PPC_REL24 against
>>>> `__pthread_unregister_cancel'
>>>> configure:64369: $? = 1
>>>>
>>>>
>>>>
>>>> Note that tests of the Fortran compiler prior to the failure *are*
>>>> passing "-q32":
>>>>
>>>> configure:32543: checking if Fortran compiler works
>>>> configure:32572: xlf -o conftest -q32 -g   conftest.f  >&5
>>>> ** main   === End of Compilation 1 ===
>>>> 1501-510  Compilation successful for file conftest.f.
>>>> configure:32572: $? = 0
>>>>
>>>>
>>>> So, I don't believe this is anything specific to XLF, but rather an
>>>> issue that would appear on any system with a non-default ABI specified in
>>>> {C,CXX,F}FLAGS.
>>>>
>>>> I have *not* had the opportunity to test either master or the 2.0 RC on
>>>> this platform.
>>>>
>>>> -Paul
>>>>
>>>>
>>>> --
>>>> Paul H. Hargrove                          [email protected]
>>>> Computer Languages & Systems Software (CLaSS) Group
>>>> Computer Science Department               Tel: +1-510-495-2352
>>>> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>>>>
>>>
>>>
>>>
>>> --
>>> Paul H. Hargrove                          [email protected]
>>> Computer Languages & Systems Software (CLaSS) Group
>>> Computer Science Department               Tel: +1-510-495-2352
>>> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>>>
>>
>>
>>
>> --
>> Paul H. Hargrove                          [email protected]
>> Computer Languages & Systems Software (CLaSS) Group
>> Computer Science Department               Tel: +1-510-495-2352
>> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>>
>
>
>
> --
> Paul H. Hargrove                          [email protected]
> Computer Languages & Systems Software (CLaSS) Group
> Computer Science Department               Tel: +1-510-495-2352
> Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900
>



-- 
Paul H. Hargrove                          [email protected]
Computer Languages & Systems Software (CLaSS) Group
Computer Science Department               Tel: +1-510-495-2352
Lawrence Berkeley National Laboratory     Fax: +1-510-486-6900

Reply via email to