<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Fri, Sep 18, 2015 at 8:44 AM Justin Bogner <<a href="mailto:mail@justinbogner.com">mail@justinbogner.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">(Re-sending to the right list)<br>
<br>
NAKAMURA Takumi <<a href="mailto:geek4civic@gmail.com" target="_blank">geek4civic@gmail.com</a>> writes:<br>
> Author: chapuni<br>
> Date: Wed Jun 17 23:08:20 2015<br>
> New Revision: 239987<br>
><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=239987&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=239987&view=rev</a><br>
> Log:<br>
> config.h.*: Rework r210144. Don't edit <a href="http://config.h.in" rel="noreferrer" target="_blank">config.h.in</a> manually.<br>
><br>
>   - Generate #include in <a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a>.<br>
>   - Resurrect the copy of llvm-config.h.cmake into config.h.cmake.<br>
<br>
Sorry to bring up such an old thread, but *why* did you duplicate<br>
everything from llvm-config.h.cmake into config.h.cmake? This just makes<br>
it more error prone to try to update these, since they need to be<br>
updated in sync. config.h #includes llvm-config.h anyway...<br>
</blockquote><div><br></div><div>I dare to say again, "Don't edit <a href="http://config.h.in">config.h.in</a> manually."</div><div>As far as we maintain autoconf build, <a href="http://config.h.in">config.h.in</a> is generated by <a href="http://configure.ac">configure.ac</a>.<br></div><div><br></div><div>I suppose we were working for config.h.cmake in sync to <a href="http://config.h.in">config.h.in</a>.</div><div>That said, config.h.cmake can easily diverge from <a href="http://config.h.in">config.h.in</a>.</div><div><br></div><div>And, I suppose llvm-config.h.* may be subset of config.h.*.</div><div>I intended r239987 was "trying to keep config.h.cmake in sync to <a href="http://config.h.in">config.h.in</a>" rather than "copying back from llvm-config.h.cmake into config.h.cmake".</div><div><br></div><div>I know this is hairy.</div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
><br>
> Modified:<br>
>     llvm/trunk/autoconf/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
>     llvm/trunk/include/llvm/Config/config.h.cmake<br>
>     llvm/trunk/include/llvm/Config/<a href="http://config.h.in" rel="noreferrer" target="_blank">config.h.in</a><br>
><br>
> Modified: llvm/trunk/autoconf/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=239987&r1=239986&r2=239987&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=239987&r1=239986&r2=239987&view=diff</a><br>
> ==============================================================================<br>
><br>
> --- llvm/trunk/autoconf/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a> (original)<br>
> +++ llvm/trunk/autoconf/<a href="http://configure.ac" rel="noreferrer" target="_blank">configure.ac</a> Wed Jun 17 23:08:20 2015<br>
> @@ -2172,7 +2172,10 @@ dnl contains the same list of files as A<br>
>  dnl files can be updated automatically when their *.in sources change.<br>
>  AC_CONFIG_HEADERS([include/llvm/Config/config.h include/llvm/Config/llvm-config.h])<br>
>  AH_TOP([#ifndef CONFIG_H<br>
> -#define CONFIG_H])<br>
> +#define CONFIG_H<br>
> +<br>
> +/* Exported configuration */<br>
> +#include "llvm/Config/llvm-config.h"])<br>
>  AH_BOTTOM([#endif])<br>
><br>
>  AC_CONFIG_FILES([include/llvm/Config/Targets.def])<br>
><br>
> Modified: llvm/trunk/include/llvm/Config/config.h.cmake<br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Config/config.h.cmake?rev=239987&r1=239986&r2=239987&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Config/config.h.cmake?rev=239987&r1=239986&r2=239987&view=diff</a><br>
> ==============================================================================<br>
> --- llvm/trunk/include/llvm/Config/config.h.cmake (original)<br>
> +++ llvm/trunk/include/llvm/Config/config.h.cmake Wed Jun 17 23:08:20 2015<br>
> @@ -411,12 +411,103 @@<br>
>  /* Have host's ___chkstk_ms */<br>
>  #cmakedefine HAVE____CHKSTK_MS ${HAVE____CHKSTK_MS}<br>
><br>
> -/* Define if we link Polly to the tools */<br>
> -#cmakedefine LINK_POLLY_INTO_TOOLS<br>
> +/* Linker version detected at compile time. */<br>
> +#undef HOST_LINK_VERSION<br>
> +<br>
> +/* Installation directory for binary executables */<br>
> +#cmakedefine LLVM_BINDIR "${LLVM_BINDIR}"<br>
> +<br>
> +/* Time at which LLVM was configured */<br>
> +#cmakedefine LLVM_CONFIGTIME "${LLVM_CONFIGTIME}"<br>
> +<br>
> +/* Installation directory for data files */<br>
> +#cmakedefine LLVM_DATADIR "${LLVM_DATADIR}"<br>
> +<br>
> +/* Target triple LLVM will generate code for by default */<br>
> +#cmakedefine LLVM_DEFAULT_TARGET_TRIPLE "${LLVM_DEFAULT_TARGET_TRIPLE}"<br>
> +<br>
> +/* Installation directory for documentation */<br>
> +#cmakedefine LLVM_DOCSDIR "${LLVM_DOCSDIR}"<br>
> +<br>
> +/* Define if LLVM is built with asserts and checks that change the layout of<br>
> +   client-visible data structures.  */<br>
> +#cmakedefine LLVM_ENABLE_ABI_BREAKING_CHECKS<br>
> +<br>
> +/* Define if threads enabled */<br>
> +#cmakedefine01 LLVM_ENABLE_THREADS<br>
><br>
>  /* Define if zlib compression is available */<br>
>  #cmakedefine01 LLVM_ENABLE_ZLIB<br>
><br>
> +/* Installation directory for config files */<br>
> +#cmakedefine LLVM_ETCDIR "${LLVM_ETCDIR}"<br>
> +<br>
> +/* Has gcc/MSVC atomic intrinsics */<br>
> +#cmakedefine01 LLVM_HAS_ATOMICS<br>
> +<br>
> +/* Host triple LLVM will be executed on */<br>
> +#cmakedefine LLVM_HOST_TRIPLE "${LLVM_HOST_TRIPLE}"<br>
> +<br>
> +/* Installation directory for include files */<br>
> +#cmakedefine LLVM_INCLUDEDIR "${LLVM_INCLUDEDIR}"<br>
> +<br>
> +/* Installation directory for .info files */<br>
> +#cmakedefine LLVM_INFODIR "${LLVM_INFODIR}"<br>
> +<br>
> +/* Installation directory for man pages */<br>
> +#cmakedefine LLVM_MANDIR "${LLVM_MANDIR}"<br>
> +<br>
> +/* LLVM architecture name for the native architecture, if available */<br>
> +#cmakedefine LLVM_NATIVE_ARCH ${LLVM_NATIVE_ARCH}<br>
> +<br>
> +/* LLVM name for the native AsmParser init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_ASMPARSER LLVMInitialize${LLVM_NATIVE_ARCH}AsmParser<br>
> +<br>
> +/* LLVM name for the native AsmPrinter init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_ASMPRINTER LLVMInitialize${LLVM_NATIVE_ARCH}AsmPrinter<br>
> +<br>
> +/* LLVM name for the native Disassembler init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_DISASSEMBLER LLVMInitialize${LLVM_NATIVE_ARCH}Disassembler<br>
> +<br>
> +/* LLVM name for the native Target init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_TARGET LLVMInitialize${LLVM_NATIVE_ARCH}Target<br>
> +<br>
> +/* LLVM name for the native TargetInfo init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_TARGETINFO LLVMInitialize${LLVM_NATIVE_ARCH}TargetInfo<br>
> +<br>
> +/* LLVM name for the native target MC init function, if available */<br>
> +#cmakedefine LLVM_NATIVE_TARGETMC LLVMInitialize${LLVM_NATIVE_ARCH}TargetMC<br>
> +<br>
> +/* Define if this is Unixish platform */<br>
> +#cmakedefine LLVM_ON_UNIX ${LLVM_ON_UNIX}<br>
> +<br>
> +/* Define if this is Win32ish platform */<br>
> +#cmakedefine LLVM_ON_WIN32 ${LLVM_ON_WIN32}<br>
> +<br>
> +/* Installation prefix directory */<br>
> +#cmakedefine LLVM_PREFIX "${LLVM_PREFIX}"<br>
> +<br>
> +/* Define if we have the Intel JIT API runtime support library */<br>
> +#cmakedefine LLVM_USE_INTEL_JITEVENTS 1<br>
> +<br>
> +/* Define if we have the oprofile JIT-support library */<br>
> +#cmakedefine LLVM_USE_OPROFILE 1<br>
> +<br>
> +/* Major version of the LLVM API */<br>
> +#define LLVM_VERSION_MAJOR ${LLVM_VERSION_MAJOR}<br>
> +<br>
> +/* Minor version of the LLVM API */<br>
> +#define LLVM_VERSION_MINOR ${LLVM_VERSION_MINOR}<br>
> +<br>
> +/* Patch version of the LLVM API */<br>
> +#define LLVM_VERSION_PATCH ${LLVM_VERSION_PATCH}<br>
> +<br>
> +/* LLVM version string */<br>
> +#define LLVM_VERSION_STRING "${PACKAGE_VERSION}"<br>
> +<br>
> +/* Define if we link Polly to the tools */<br>
> +#cmakedefine LINK_POLLY_INTO_TOOLS<br>
> +<br>
>  /* Define if the OS needs help to load dependent libraries for dlopen(). */<br>
>  #cmakedefine LTDL_DLOPEN_DEPLIBS ${LTDL_DLOPEN_DEPLIBS}<br>
><br>
><br>
> Modified: llvm/trunk/include/llvm/Config/<a href="http://config.h.in" rel="noreferrer" target="_blank">config.h.in</a><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Config/config.h.in?rev=239987&r1=239986&r2=239987&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Config/config.h.in?rev=239987&r1=239986&r2=239987&view=diff</a><br>
> ==============================================================================<br>
> --- llvm/trunk/include/llvm/Config/<a href="http://config.h.in" rel="noreferrer" target="_blank">config.h.in</a> (original)<br>
> +++ llvm/trunk/include/llvm/Config/<a href="http://config.h.in" rel="noreferrer" target="_blank">config.h.in</a> Wed Jun 17 23:08:20 2015<br>
> @@ -3,6 +3,9 @@<br>
>  #ifndef CONFIG_H<br>
>  #define CONFIG_H<br>
><br>
> +/* Exported configuration */<br>
> +#include "llvm/Config/llvm-config.h"<br>
> +<br>
>  /* Bug report URL. */<br>
>  #undef BUG_REPORT_URL<br>
><br>
><br>
><br>
> _______________________________________________<br>
> llvm-commits mailing list<br>
> <a href="mailto:llvm-commits@cs.uiuc.edu" target="_blank">llvm-commits@cs.uiuc.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div></div>