[Lldb-commits] [lldb] r124892 - in /lldb/trunk: include/lldb/Host/Config.h include/lldb/Host/freebsd/ include/lldb/Host/freebsd/Config.h include/lldb/Host/linux/ include/lldb/Host/linux/Config.h include/lldb/Host/macosx/ include/lldb/Host/macosx/Config.h include/lldb/Host/mingw/ include/lldb/Host/mingw/Config.h lldb.xcodeproj/project.pbxproj
Greg Clayton
gclayton at apple.com
Fri Feb 4 13:15:01 PST 2011
My one complaint with the not defining something if it is not available, is if you have an IDE that can take you to the definition of a #define, then it takes you nowhere when it isn't defined.
If it is defined to zero, the it will be defined, and your IDE can take you to the place in the Config.h that has it set to zero, possibly with an explanation of why it is set to zero for this current build. I know IDEs have find in all files too, but that kicks up all the matches, not the one that you actually care about.
I know this is a little different than the way things are done now, but I do like this approach a bit better.
Does that make sense to everyone? Comments? Likes? Dislikes?
I am open to going either way. I just want to bring it up for discussion.
Greg Clayton
On Feb 4, 2011, at 12:38 PM, Stephen Wilson wrote:
>
> Hi Greg,
>
> Greg Clayton <gclayton at apple.com> writes:
>> Added the start of platform configuration designed for internal LLDB use.
>> Internal use means for compiling the LLDB debug engine and plug-ins, but it
>> should never make it into the public API.
>
> This is great!
>
>> Since we don't currently have a configuration script that detects avaiable
>> functionality in the LLDB build system, we are hard coding #define values
>> in the host specific "Config.h" files.
>>
>> #define values in these Config.h header files should set the value to zero or
>> one:
>>
>> #define LLDB_CONFIG_TERMIOS_SUPPORTED 1
>>
>> #define LLDB_CONFIG_OTHER 0
>
> Hmmm. This goes against the well established practice of #define'ing
> things IFF they are available:
>
>
> #if defined(HAVE_TERMIOS)
> ...
> #else
> ...
> #endif
>
>
> It would be great to have a configure script available for LLDB.
> Adhering to the established practice would make things much easier if we
> were to generate a configure script and config.h headers using tools
> like autoconf.
>
>
> --
> steve
More information about the lldb-commits
mailing list