opnsense-src/secure/lib
Enji Cooper 85b1f782a1 crypto/openssl: make vendor imports easier/less error prone
This change adds a custom BSD makefile containing multiple high-level PHONY
targets, similar to targets provided by the ports framework.

The Makefile does the following:
- Reruns Configure with a deterministic set of arguments to ensure that
  all appropriate features have been enabled/disabled in OpenSSL.
- Preens the pkgconfig files to remove duplicate paths in their
  `CFLAGS` and `includedir` variables.
- Rebuilds all ASM files to ensure that the content contained is fresh.
- Rebuilds all manpages to ensure that the content contained in the
  manpages is fresh.

Some additional work needs to be done to make the manpage regeneration
"operation" reproducible (the date the manpages were generated is
embedded in the files).

All dynamic configuration previously captured in
`include/openssl/configuration.h` and `include/crypto/bn_conf.h` has been
moved to `freebsd/include/dynamic_freebsd_configuration.h` and
`freebsd/include/crypto/bn_conf.h`, respectively. This helps
ensure that future updates don't wipe out FreeBSD customizations to
these files, which tune behavior on a per-target architecture basis, e.g.,
ARM vs x86, 32-bit vs 64-bit, etc.

MFC after: 1 month
Differential Revision:	https://reviews.freebsd.org/D51663

Conflicts:
	crypto/openssl/apps/CA.pl
	crypto/openssl/configdata.pm
	crypto/openssl/include/openssl/configuration.h
	crypto/openssl/include/openssl/fipskey.h
	crypto/openssl/tools/c_rehash
	crypto/openssl/util/shlib_wrap.sh
	crypto/openssl/util/wrap.pl
	secure/lib/libcrypto/Makefile.inc

(cherry picked from commit 267f8c1f4b)
2026-04-30 07:39:19 +02:00
..
libcrypt Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
libcrypto crypto/openssl: make vendor imports easier/less error prone 2026-04-30 07:39:19 +02:00
libpkgecc secure: hook up libecc as libpkgecc 2025-01-10 20:48:24 -06:00
libssh ssh: Consolidate HAVE_LDNS / LIBWRAP in ssh.mk 2025-03-11 10:39:36 -04:00
libssl Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
tests Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
Makefile secure: hook up libecc as libpkgecc 2025-01-10 20:48:24 -06:00
Makefile.inc Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00