Commit Graph

920 Commits

Author SHA1 Message Date
Dan McGregor 442664d94f cf: Honour OpenSSL library and include paths
Check for OpenSSL features while LDFLAGS and CFLAGS are set with
the paths provided in the configure command line. This allows
detecting a non-default OpenSSL's version correctly, such as
on FreeBSD with one of the OpenSSL 3.0 ports.
2023-05-19 11:39:19 -05:00
Luke Howard 37f7c5476d roken: fix Solaris build
libroken needs to be linked against libnsl for inet_ntoa()
2023-01-07 11:40:44 +11:00
Brian May 73b42d3238 Build rk_closefrom even if including in libc 2023-01-04 00:43:35 -06:00
Nicolas Williams 83cd1255f6 cf: Check for OpenSSL FIPS 2022-11-22 11:34:54 -05:00
Nicolas Williams ac8c1341fb cf: Check for OpenSSL 3.0
This check is admittedly lame.  But it's all I have time for at the
moment.  A better check would be a program that includes the correct
headers and succeeds if the OpenSSL version macro indicates it's at
3.0 or higher.  Or perhaps we could run the openssl(1) version command-
line and parse its output.  But checking for functions that are in 3.0
and not 1.1 will do for the time being.
2022-11-22 11:34:54 -05:00
Nicolas Williams e50abd5aa0 cf: Disable broken-getaddrinfo test (fixes check-iprop on OS X) 2022-11-01 16:10:58 -05:00
Nicolas Williams 944c71020e cf: Disable BROKEN_REALLOC workaround 2022-11-01 16:10:57 -05:00
Nicolas Williams 00b065bc80 cf: Do not redefine realloc() when ASAN is used 2022-11-01 16:10:57 -05:00
Nicolas Williams 92d5b74c05 cf: Import AX_CHECK_SIGNED() autoconf macro 2022-02-15 17:00:19 -06:00
Nicolas Williams 37f10aaf85 cf: Restore AC_KRB_PROG_YACC to life
Using `AC_PROG_YACC` means accepting that `bison` gets invoked in yacc
compatibility mode (i.e., with the `-y` command-line option).  In recent
versions Bison has started to warn about use of Bison extensions when in
yacc compatibility mode -- even for things yacc itself accepts but which
it doesn't document.

I've confirmed that `bison -d` and `byacc -d` both work for the ASN.1
compiler.
2022-01-21 22:37:04 -06:00
Nicolas Williams febdcd4cbd cf: Make clang-format style common makefile macro 2022-01-16 14:07:03 -06:00
Nicolas Williams 94bb267a8b roken: Delete getcap/cgetent/cgetstr() 2022-01-14 12:01:33 -06:00
Nicolas Williams 0c7b06f9ca cf: Check cc support of -Werror=enum-conversion 2022-01-13 15:33:04 -06:00
Nicolas Williams 04523254c1 asn1: Restore styling of generated sources 2022-01-11 17:45:27 -06:00
Jeffrey Altman 7cae05061a cf: check libdb-6 for db_create
787d9ceec9 ("check for db6/db.h")
added a check for the db6 header defining HAVE_DB6_DB_H but failed
to add a check for existence of db_create() in the libdb-6 library.
2022-01-03 18:09:08 +11:00
Jeffrey Altman 0fbd163640 cf: db.m4 remove db_create check in non-existent libdb5
The correct library name is libdb-5.
2022-01-03 18:09:08 +11:00
Nicolas Williams ed6f3f1786 autoconf: Remove unused tests 2021-11-30 11:42:00 -05:00
Andrew Bartlett 7686028718 Use UTF-8 in KTH copyright notice
Samba is starting to protect against bi-di attacks and the starting point
is to require that input files be fully UTF-8.  In 2021 this is a reasonable
starting point anyway.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2021-11-29 12:50:26 +11:00
Robert Crowston be2c28cc34 Check CLANG_FORMAT is executable.
If clang-format is not available, AC_CHECK_PROG sets CLANG_FORMAT=no,
not empty string. This results in an error at build time for those
without clang-format installed. Instead check if the program is
executable.
2021-09-07 12:50:25 +10:00
Luke Howard 2f4619fbbd cf: check for undefined variables
The w32-hh-toc-from-info.pl script would fail with more recent versions
of Perl, as it attempted to access undefined variables.
2021-08-12 08:46:03 +10:00
Lars Wendler 22352b90e7 autoconf-2.70 fix
autoconf-2.70 and newer are more strict with quoting etc. and thus generate
a broken configure file:

  configure: 20855: Syntax error: ")" unexpected (expecting "fi")

Gentoo-bug: https://bugs.gentoo.org/776241
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
2021-03-17 13:05:46 -04:00
Nicolas Williams b440b29394 clang-format w/ Mozilla style for generated code
Mozilla puts function names on column 1.  That's better.
2021-02-01 22:52:18 -06:00
Nicolas Williams 6d85ba384f clang-format generated code for easier debugging 2021-01-20 18:56:03 -06:00
Luke Howard 1c74afb01a roken: add mergesort_r()
Add mergesort_r() as a stable sort function that can be used by other
components of Heimdal. Note that there is no standardized prototype for this
function, however it appears that both FreeBSD and glibc would adopt the glibc
convention (where the private data argument appears last). See:

    https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=214248
2020-04-12 13:25:09 -05:00
Nicolas Williams a7359d6898 roken: Add mkdtemp() 2020-03-02 17:48:04 -06:00
Roland C. Dowdeswell 01126367d3 w32-check-exported-symbols: Eliminate perl warning
This will become fatal in the next version of Perl, so we need
to eliminate it now.
2019-11-20 18:14:44 -05:00
Roland C. Dowdeswell a8b749685c include <sys/exec_elf.h> if it's available.
This fixes the auxval logic on NetBSD.
2019-11-18 14:20:19 -06:00
Roland C. Dowdeswell 2e0366b7a0 Teach make-proto.pl about #define \-continuation. 2019-10-30 16:20:58 -05:00
Nicolas Williams 96d1e80bda roken: add mkostemp() 2019-10-03 13:09:18 -05:00
Nicolas Williams f31cdc30b2 roken: add rk_memmem() 2019-10-03 13:09:18 -05:00
Nicolas Williams 1ee136ce40 autoconf: look for unlinkat() 2019-10-03 13:09:18 -05:00
Jeffrey Altman dc46b1f82d solaris: Define _STDC_C11_BCI for memset_s prototype
On Solaris, the memset_s() prototype is only visible if _STDC_C11_BCI
is defined.

93518bfab4 ("use memset_s")
introduced warnings on Solaris

  warning: implicit declaration of function ‘memset_s’;
  did you mean ‘memset’? [-Wimplicit-function-declaration]

Change-Id: Ia02db5e96021a26fb30aa1a593ef6a2b3e3a5b5f
2019-05-23 19:04:42 -04:00
Jeffrey Altman bec4818943 WIN32: hint noreturn functions
apply __declspec(noreturn) compiler hints to functions that
do not return.

Change-Id: I3c6c4703c7235d1df3e21dccad5272ea4cddfd36
2019-01-02 10:23:39 -06:00
Nicolas Williams e2685c5b7c Add check for getpw*_r() 2018-12-25 22:11:19 -06:00
Nicolas Williams a988692434 Add check for getlogin_r() 2018-12-25 22:11:19 -06:00
Nicolas Williams 8fae8a1826 Remove iruserok() 2018-12-25 22:11:19 -06:00
Nicolas Williams 3b8c762dd0 Remove lib/roken glob()
We no longer use it since removing ftp from appl/.

Note that expansion of ~username/ couldn't have been working because
k_getpwnam() was being called with an unsigned short * that was forcibly
cast to char *, but it really was shorts, not chars...  Anyone who ever
feels like reviving lib/roken/glob.[ch] will want to fix that...
2018-12-25 22:11:19 -06:00
Daria Phoebe Brashear 1da17c2f22 roken: test for auxv_t in whichever of auxv.h or sys/auxv.h we find
on solaris it's in sys/auxv.h; so a test for it only in auxv.h isn't
enough
2018-04-17 21:32:36 -04:00
Daria Phoebe Brashear 0f5486eafc krb5: don't include plist support unless CoreFoundation is present
depending what's available when you compile for iOS it's possible to
be __APPLE__ and not have CF; actually test for it instead of blythely
assuming it can be used
2017-10-30 18:41:22 -04:00
Nicolas Williams 6d27e00489 Make builds reproduceable (#336) 2017-09-29 12:37:30 -05:00
David Mulder 2548b3b8aa Solaris 8 x86 uses ->d_fd not ->dd_fd or dirfd() 2017-09-25 18:26:35 -05:00
Nicolas Williams 07c34504a6 Fix gcov build 2017-05-29 01:18:48 -05:00
Nicolas Williams de7a1911cd Travis: attempt gcov build 2017-05-28 16:58:39 -05:00
Nicolas Williams cf4efe8de6 Add secure_getenv.c 2017-04-17 18:02:30 -04:00
Nicolas Williams 650ffdc964 Revamp lib/roken/getauxval.c 2017-04-17 18:02:30 -04:00
Nicolas Williams 097e96cbf4 Look for emalloc
Originally by Christos Zoulas.
2017-03-13 18:39:41 -04:00
Nicolas Williams 3a0bf8eb0c Allow choice of sqlite for HDB pref 2017-01-24 11:08:30 -06:00
Nicolas Williams fa2afcc5fc Add #ifndef DOXY guard to generated headers
cf/make-proto.pl copies Doxygen docs to -private and -protos headers.
We need to either extract these from those files but not source files,
or only from source files but not the generated headers.  This commit
does the latter.
2016-12-14 22:05:58 -06:00
Nicolas Williams 3422afb291 Fix -ldb-5 discovery (#215) 2016-12-08 18:30:58 -06:00
Nicolas Williams 27d7939d74 Improve valgrind suppressions 2016-12-06 22:44:23 -06:00