OS X 10.11.5: configure failed for isl; clang header file not found

339 views
Skip to first unread message

woll...@gmail.com

unread,
Jun 9, 2016, 9:39:11 AM6/9/16
to isl Development
Hi,

I am trying to install ppcg-0.06 (downloaded from http://ppcg.gforge.inria.fr). If I run ./configure I get the following output:

checking clang/Basic/SourceLocation.h usability... no
checking clang/Basic/SourceLocation.h presence... yes
configure: WARNING: clang/Basic/SourceLocation.h: present but cannot be compiled
configure: WARNING: clang/Basic/SourceLocation.h:     check for missing prerequisite headers?
configure: WARNING: clang/Basic/SourceLocation.h: see the Autoconf documentation
configure: WARNING: clang/Basic/SourceLocation.h:     section "Present But Cannot Be Compiled"
configure: WARNING: clang/Basic/SourceLocation.h: proceeding with the compiler's result
configure: WARNING:     ## ----------------------------------------------- ##
configure: WARNING:     ## Report this to isl-dev...@googlegroups.com ##
configure: WARNING:     ## ----------------------------------------------- ##
checking for clang/Basic/SourceLocation.h... no
configure: error: clang header file not found
configure: error: ./configure failed for isl

I think the problem is that the configure uses the system default clang of OS X, but I have another version of clang (clang-3.8) installed on my system. How can I tell configure to use a different clang version?

Thanks in advance. I attached the config.log file.
config.log

Sven Verdoolaege

unread,
Jun 9, 2016, 11:59:15 AM6/9/16
to woll...@gmail.com, isl Development
On Thu, Jun 09, 2016 at 06:39:11AM -0700, woll...@gmail.com wrote:
> checking for clang/Basic/SourceLocation.h... no
> configure: error: clang header file not found
> configure: error: ./configure failed for isl
>
> I think the problem is that the configure uses the system default clang of
> OS X, but I have another version of clang (clang-3.8) installed on my
> system. How can I tell configure to use a different clang version?

Use --with-clang-prefix (see README).

skimo

woll...@gmail.com

unread,
Jun 9, 2016, 12:09:46 PM6/9/16
to isl Development, woll...@gmail.com, sven.ver...@gmail.com
--with-clang-prefix does not change anything. I still get the same error message.

Alexandre Isoard

unread,
Jun 9, 2016, 6:11:09 PM6/9/16
to woll...@gmail.com, isl Development, Sven Verdoolaege
As an alternative solution, I regularly compile those tools on OS X against a custom llvm/clang tool chain but I use environment variables:

Add '/path/to/llvm/bin' to PATH
Add '/path/to/llvm/lib' to {DYLD_,LD_,}LIBRARY_PATH
Add '/path/to/llvm/include' to CPATH

Where '/path/to/llvm/' is the directory in which you installed your custom llvm (prefix at llvm/clang configuration).

--

---
You received this message because you are subscribed to the Google Groups "isl Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isl-developme...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alexandre Isoard
Doctorant, ENS de Lyon
Site Gerland, Batiment LUG, Bureau 279

Sven Verdoolaege

unread,
Jun 10, 2016, 2:20:41 AM6/10/16
to woll...@gmail.com, isl Development
On Thu, Jun 09, 2016 at 06:39:11AM -0700, woll...@gmail.com wrote:
> Thanks in advance. I attached the config.log file.

You sent PPCG's config.log, while the error occurs while configuring isl.
Pleas send isl/config.log.

skimo

woll...@gmail.com

unread,
Jun 10, 2016, 4:28:01 AM6/10/16
to isl Development, woll...@gmail.com, sven.ver...@gmail.com
I added the missing log file, sorry.
config.log

woll...@gmail.com

unread,
Jun 10, 2016, 4:29:02 AM6/10/16
to isl Development, woll...@gmail.com, sven.ver...@gmail.com
Unfortunately, this does not help.

Sven Verdoolaege

unread,
Jun 10, 2016, 5:25:37 AM6/10/16
to woll...@gmail.com, isl Development
On Fri, Jun 10, 2016 at 01:28:01AM -0700, woll...@gmail.com wrote:
> configure:17925: g++ -c -g -O2 -I/usr/local/include -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -std=c++11 -fno-exceptions -fno-rtti -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS conftest.cpp >&5
> In file included from /usr/local/include/llvm/Support/Casting.h:19:0,
> from /usr/local/include/clang/Basic/LLVM.h:22,
> from /usr/local/include/clang/Basic/SourceLocation.h:18,
> from conftest.cpp:71:
> /usr/local/include/llvm/Support/type_traits.h:37:29: error: 'is_trivially_copyable' is not a member of 'std'
> static const bool value = std::is_trivially_copyable<T>::value;
> ^
> /usr/local/include/llvm/Support/type_traits.h:37:57: error: expected primary-expression before '>' token
> static const bool value = std::is_trivially_copyable<T>::value;
> ^
> /usr/local/include/llvm/Support/type_traits.h:37:58: error: '::value' has not been declared
> static const bool value = std::is_trivially_copyable<T>::value;
> ^

It seems your g++ cannot parse the clang headers (at least not with
the options that were used when compiling clang).
Try compiling ppcg with the same compiler that was used to compile clang
(probably clang).

skimo

woll...@gmail.com

unread,
Jun 10, 2016, 5:45:09 AM6/10/16
to isl Development, woll...@gmail.com, sven.ver...@gmail.com
Is there an easy way to change that in the configure script?

Michael Kruse

unread,
Jun 10, 2016, 6:37:54 AM6/10/16
to woll...@gmail.com, isl Development, Sven Verdoolaege
2016-06-10 11:45 GMT+02:00 <woll...@gmail.com>:
> Is there an easy way to change that in the configure script?

The compiler to use can be set using the CC environment variable. Use

./configure CC=clang


Michael

--
Tardyzentrismus verboten!

woll...@gmail.com

unread,
Jun 10, 2016, 9:24:55 AM6/10/16
to isl Development
I installed the latest version of llvm and clang from the git repository and run configure for ppcg again with:

./configure CC=clang-3.9 --with-clang-prefix=/Users/c-Mac/Applications/llvm/install/llvm

My llvm and clang is installed in /Users/c-Mac/Applications/llvm/install/llvm

I configured the PATH, {DYLD,LD}_LIBRARY_PATH, and CPATH variables for my environment. I added the current config.log.

It fails again with:

checking clang/Basic/SourceLocation.h usability... no
checking clang/Basic/SourceLocation.h presence... yes
configure: WARNING: clang/Basic/SourceLocation.h: present but cannot be compiled
configure: WARNING: clang/Basic/SourceLocation.h:     check for missing prerequisite headers?
configure: WARNING: clang/Basic/SourceLocation.h: see the Autoconf documentation
configure: WARNING: clang/Basic/SourceLocation.h:     section "Present But Cannot Be Compiled"
configure: WARNING: clang/Basic/SourceLocation.h: proceeding with the compiler's result
configure: WARNING:     ## ----------------------------------------------- ##
configure: WARNING:     ## Report this to isl-dev...@googlegroups.com ##
configure: WARNING:     ## ----------------------------------------------- ##
checking for clang/Basic/SourceLocation.h... no
configure: error: clang header file not found
configure: error: ./configure failed for isl

Am Donnerstag, 9. Juni 2016 15:39:11 UTC+2 schrieb woll...@gmail.com:
Hi,

I am trying to install ppcg-0.06 (downloaded from http://ppcg.gforge.inria.fr). If I run ./configure I get the following output:

checking clang/Basic/SourceLocation.h usability... no
checking clang/Basic/SourceLocation.h presence... yes
configure: WARNING: clang/Basic/SourceLocation.h: present but cannot be compiled
configure: WARNING: clang/Basic/SourceLocation.h:     check for missing prerequisite headers?
configure: WARNING: clang/Basic/SourceLocation.h: see the Autoconf documentation
configure: WARNING: clang/Basic/SourceLocation.h:     section "Present But Cannot Be Compiled"
configure: WARNING: clang/Basic/SourceLocation.h: proceeding with the compiler's result
configure: WARNING:     ## ----------------------------------------------- ##
configure: WARNING:     ## Report this to isl-development@googlegroups.com ##
configure: WARNING:     ## ----------------------------------------------- ##
checking for clang/Basic/SourceLocation.h... no
configure: error: clang header file not found
configure: error: ./configure failed for isl
config.log

Michael Kruse

unread,
Jun 10, 2016, 9:31:58 AM6/10/16
to woll...@gmail.com, isl Development
Sorry for having forgotten to mention this:

The file in question is C++, i.e. set the C++ compiler (or both):

./configure CC=clang-3.9 CXX=clang++-3.9

Michael
>> I think the problem is that the configure uses the system default clang of
>> OS X, but I have another version of clang (clang-3.8) installed on my
>> system. How can I tell configure to use a different clang version?
>>
>> Thanks in advance. I attached the config.log file.
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups
> "isl Development" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to isl-developme...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



--
Tardyzentrismus verboten!

woll...@gmail.com

unread,
Jun 10, 2016, 9:36:57 AM6/10/16
to isl Development, woll...@gmail.com, re...@meinersbur.de
Thats's it! Thank you very much!

./configure CC=clang CXX=clang++

did the job!

woll...@gmail.com

unread,
Jun 10, 2016, 10:10:51 AM6/10/16
to isl Development, woll...@gmail.com, re...@meinersbur.de
So ./configure is working now on my system, but the make call fails with:

  CCLD     isl_test_int
Making all in interface
  CXX      extract_interface-python.o
  CXX      extract_interface-extract_interface.o
extract_interface.cc:359:10: error: reference to type 'const llvm::Triple' could not bind to an rvalue of type 'clang::LangStandard::Kind'
                                            LangStandard::lang_unspecified);
                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/c-Mac/Applications/llvm/install/llvm/include/clang/Frontend/CompilerInvocation.h:160:40: note: passing argument to parameter 'T' here
                   const llvm::Triple &T,
                                       ^
1 error generated.
make[3]: *** [extract_interface-extract_interface.o] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1

Sven Verdoolaege

unread,
Jun 10, 2016, 11:27:00 AM6/10/16
to woll...@gmail.com, isl Development, re...@meinersbur.de
On Fri, Jun 10, 2016 at 07:10:51AM -0700, woll...@gmail.com wrote:
> So ./configure is working now on my system, but the make call fails with:
>
> CCLD isl_test_int
> Making all in interface
> CXX extract_interface-python.o
> CXX extract_interface-extract_interface.o
> extract_interface.cc:359:10: error: reference to type 'const llvm::Triple'
> could not bind to an rvalue of type 'clang::LangStandard::Kind'
> LangStandard::lang_unspecified);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> /Users/c-Mac/Applications/llvm/install/llvm/include/clang/Frontend/CompilerInvocation.h:160:40:
> note: passing argument to parameter 'T' here
> const llvm::Triple &T,

Which version of the clang libraries are you compiling against?

skimo

Michael Kruse

unread,
Jun 10, 2016, 12:11:59 PM6/10/16
to woll...@gmail.com, isl Development, Michael Kruse
Hi,

ISL not support pre-release versions of clang.
CompilerInvocation::setLangDefaults introduced a fourth parameter
which did not exist in clang 3.8. Sven will probably add support for
it once clang-3.9 is released. Until then, please use clang-3.8 (or
earlier).

Michael

woll...@gmail.com

unread,
Jun 14, 2016, 5:11:39 AM6/14/16
to isl Development, woll...@gmail.com, re...@meinersbur.de
Hey,

thanks for the advice. I worked with llvm-3.9 and a switch to llvm-3.8 resolved my problem. Everything is working now.

Thanks for your help.
Reply all
Reply to author
Forward
0 new messages