The check for C functions fails with '-Werror' in GCC (5.2).
return (int)p;
^
The cast here triggers this error:
error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
p=(void*)(%s);
^
This conversion triggers another error with '-pedantic -Werror':
error: ISO C forbids conversion of function pointer to object pointer type [-Werror=pedantic]
This patch fixes both errors.
Signed-off-by: Mohammad Alsaleh <CE.Mohammad.AlSaleh@gmail.com>
`-Kpic` had been used to generate position-indenpendent code for Sun CC.
This permits only 2^10 unqiue symbols per shared object on 64-bit
systems. This is an unreasonably small default. Switching to `-KPIC`
increases the number to 2^29.
According to
http://docs.oracle.com/cd/E37069_01/html/E37074/bjapp.html#OSSCGbjatt,
both `-Kpic` and `-KPIC` have been deprecated, and the `-xcode` option
should be used instead. `-xcode` has been available since at least Sun
Studio 8.
is found that matches the user's options. This happens during autodetect only
when the new option msvc_lazy_autodetect or env.MSVC_LAZY_AUTODETECT is set.
A prelude will be added from the variable env.WAF_CONFIG_H_PRELUDE if provided. This
can be used to insert complex macros or include guards::
def configure(conf):
conf.env.WAF_CONFIG_H_PRELUDE = '#include <unistd.h>\\n'
conf.write_config_header('config.h')
Rather than using an inline interpolated heredoc string, or generating
the file in a pre-build step, allow the macplist task itself to
perform string interpolation on the contents of a plist file.
For ELF binaries (e.g., Linux): default compatible version (SONAME =
`<library-name>.so.<MAJOR>`) can be specialized using additional `cnum`
parameter to `<library-name>.so.<MAJOR>.<MINOR>` or
`<library-name>.so.<MAJOR>.<MINOR>.<PATCH>`.
For Mach-O binaries (e.g., OS X):
- (bugfix) install-name points to compatible version (not absolute path
to a non-versioned library)
- Default install-name `<install-path>/<library-name>.<MAJOR>.dylib` can
be specialized using `cnum` parameter to
`<install-path>/<library-name>.<MAJOR>.<MINOR>.dylib` or
`<install-path>/<library-name>.<MAJOR>.<MINOR>.<PATCH>.dylib`
- `-Wl,-compatibility_version` and `-Wl,-current_version` flags use
version from cnum/vnum (default cnum is vnum.split('.')[0])
The actual compiler option is named '--thread', not '--threading'.
Renames the waf option for 'thread': it shouldn't be breaking anyone as
it was not even working.