[petsc-users] Cannot find a C preprocessor OSX

Satish Balay balay at mcs.anl.gov
Sat Mar 19 14:00:47 CDT 2016


But I would think 'mpicc -show' should show this. [if spack is setting
up these options via MPI wrappers]

Sometimes compilers pick up extra config from env variables - or from
default config locations. I don't see anything in env thats
significant..

> CC=/Users/davydden/spack/lib/spack/env/clang/clang

Ok - spack is building its own clang.

> /Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/bin/mpicc -c foo.c -show
> /usr/bin/clang -c foo.c -I/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/include

But mpicc is using apple's clang. [so spack can't be modifying apple's clang's config file..]

What do you get for:

mpicc -c -v foo.c [for any simple source file - say src/benchmarks/sizeof.c]

Satish

On Sat, 19 Mar 2016, Denis Davydov wrote:

> 
> 
> > On 19 Mar 2016, at 18:20, Satish Balay <balay at mcs.anl.gov> wrote:
> > 
> > If '-show' is not listing these -L options - where is mpicc picking them up from?
> 
> that’s how Spack does things somewhere behind the curtains.
> 
> Regards,
> Denis.
> 
> > 
> > Satish
> > 
> > On Fri, 18 Mar 2016, Denis Davydov wrote:
> > 
> >> Hi Satish,
> >> 
> >>> On 18 Mar 2016, at 19:01, Satish Balay <balay at mcs.anl.gov> wrote:
> >>> 
> >>> your mpicc is barfing stuff on stderr - thus confusing petsc configure.
> >> 
> >> yes, i noticed that. I don’t have that issue when using Homebrew’s build OpenMPI, and thus no confusion to petsc config.
> >> Also those things are just warnings, why are they reported to stderr is not clear…
> >> I will try suppressing it with -Qunused-arguments ...
> >> 
> >>> 
> >>> I don't see this issue with the old openmpi I have access to..
> >>> 
> >>> What do you have for:
> >> 
> >> Looks reasonable to me:
> >> 
> >>> 
> >>> /Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/bin/mpicc -show
> >>> touch foo.c
> >> /usr/bin/clang touch foo.c -I/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/include -L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/lib -lmpi
> >> 
> >>> /Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/bin/mpicc -c foo.c -show
> >> 
> >> /usr/bin/clang -c foo.c -I/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/include
> >> 
> >>> 
> >>> I'm not sure what to suggest.. Perhaps you can use --download-mpich
> >>> [or --download-openmpi] - but then I see you are building all these
> >>> packages using spack - so perhaps you should check with 'spack' folk..
> >> 
> >> Will certainly do that. I am just toying with spack to see how good is the support for OS-X.
> >> 
> >> Regards,
> >> Denis.
> >> 
> >>> 
> >>> Satish
> >>> 
> >>> ---------
> >>> 
> >>> Executing: /Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/bin/mpicc -c -o /var/folders/5k/sqpp24tx3ylds4fgm13pfht00000gn/T/petsc-8RPaEA/config.setCompilers/conftest.o -I/var/folders/5k/sqpp24tx3ylds4fgm13pfht00000gn/T/petsc-8RPaEA/config.setCompilers   /var/folders/5k/sqpp24tx3ylds4fgm13pfht00000gn/T/petsc-8RPaEA/config.setCompilers/conftest.c
> >>> Possible ERROR while running compiler:
> >>> stderr:
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/boost-1.60.0-eo7nn3v27nxa7lxqv5tttjzikshwt56i/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/bzip2-1.0.6-leelnsg3humpngfeofkrdpgtsofrm5ya/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openmpi-1.10.2-37xieeupgsteaq6btru6wmhxfi44xqtn/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/hwloc-1.11.2-pxsmp4nhfdjc3jb7odj5lhppu7wqna5b/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/libpciaccess-0.13.4-erc6tr3ghndi5ed3gbj6wtvw6zl4vobf/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/zlib-1.2.8-cyvcqvrzlgurne424y55hxvfucvz2354/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/hdf5-1.8.16-diujq2w7ew4qviquh67b3lkcqsxtf77y/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/hypre-2.10.1-4kql32qmjpp7ict2qczkyyv6a4mbrgbl/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openblas-0.2.16-qplsxnxlbaqnz2iltdo7fdhlayvuaxel/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/metis-5.1.0-i5y5b6r5ca4f77u5tketagpkn6joxasp/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/ncurses-6.0-sabhdwxbdbbapfo6wodglfmyo6u3c3hj/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/openssl-1.0.2g-answvmhu3lodpmgulgzryygkkimmsn34/lib'
> >>> clang: warning: argument unused during compilation: '-L/Users/davydden/spack/opt/spack/darwin-x86_64/clang-7.0.2-apple/parmetis-4.0.3-auubrjcwhqmqnpoqjwgwgz4bcjnxzunx/lib'
> >>> 
> >>> On Fri, 18 Mar 2016, Denis Davydov wrote:
> >>> 
> >>>> Dear all, 
> >>>> 
> >>>> Although I saw this issue on the mailing list, that was related to broken compilers, i don’t think it’s the case here as `mpicc -E` seems to be ok.
> >>>> Log is attached.
> >>>> 
> >>>> Kind regards,
> >>>> Denis 
> >>>> 
> >>>> 
> >> 
> >> 
> 
> 


More information about the petsc-users mailing list