ports/databases/ldb28/files/patch-lib_replace_wscript
Mateusz Piotrowski 1aa6d61564 databases/ldb28: Add a new version of ldb
This port is based on ldb25. The changes are:

- Fix checks for Python support

  The bsd.port.pre.mk was included too early and USES=python wasn't
  processed as expected. As a result, the checks for Python support were
  broken.

- Switch from waf to configure and make.

  Upstream wants us to do it this way. Otherwise, the build system
  produces the following error message:

  > ===>  Configuring for ldb28-2.8.1
  > PYTHONHASHSEED=1 missing! Don't use waf directly, use ./configure and make!

  So, set HAS_CONFIGURE and BINARY_ALIAS to make the port build without
  waf.

- Clean up the makefile (sort variables and fix indentation)

- Drop the NO_PYTHON variable. It complicates the makefile
  unnecessarily. It is still possible to disable Python support by
  configuring the PYTHON3 option.

- Use WITH_DEBUG instead of option DEBUG.

- Enable PYTHON3 by default.

  The PYTHON3 option is required by net/samba419 to build without the
  bundled dependencies. The primary purpose of databases/ldb28 is to
  make it possible, so enable Python support by default.

PR:		280510
Sponsored by:	Klara, Inc.
2024-07-31 10:59:42 +02:00

12 lines
450 B
Plaintext

--- lib/replace/wscript.orig 2022-10-24 10:21:14 UTC
+++ lib/replace/wscript
@@ -122,7 +122,7 @@ def configure(conf):
conf.CHECK_HEADERS('sys/atomic.h stdatomic.h')
conf.CHECK_HEADERS('libgen.h')
- if conf.CHECK_CFLAGS('-Wno-format-truncation'):
+ if conf.CHECK_CFLAGS(['-Wno-format-truncation'] + conf.env.WERROR_CFLAGS):
conf.define('HAVE_WNO_FORMAT_TRUNCATION', '1')
if conf.CHECK_CFLAGS('-Wno-unused-function'):