On FreeBSD, NetBSD, and OpenBSD 'make' fails with an error similar to
the following:
$ make
make all-recursive
Making all in po
make[2]: don't know how to make ./lib/libhello.a. Stop
make[2]: stopped making "all-am" in /usr/home/collinfunk/hello
*** Error code 1
[...]
This is because the target lacks the "./" prefix that is in the
dependency.
* NEWS: Mention the improvement.
* Makefile.am (hello_LDADD): Remove $(top_builddir) prefix.
---
Makefile.am | 2 +-
NEWS | 4 ++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/Makefile.am b/Makefile.am
index 6f9556b..d1fc912 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -35,7 +35,7 @@ SUBDIRS = po
bin_PROGRAMS = hello
hello_SOURCES = src/hello.c src/system.h
-hello_LDADD = $(top_builddir)/lib/lib$(PACKAGE).a \
+hello_LDADD = lib/lib$(PACKAGE).a \
$(HARD_LOCALE_LIB) \
$(LIBC32CONV) \
$(LIBICONV) \
diff --git a/NEWS b/NEWS
index 176baaf..54a755f 100644
--- a/NEWS
+++ b/NEWS
@@ -7,6 +7,10 @@ removed in release 2.11.
Update gnulib for compatibility with glibc-2.43.
+GNU hello no longer fails to build with BSD implementations of the
+'make' command. Previously they would be unable to find a target
+required listed as a dependency of the 'hello' program.
+
* Noteworthy changes in release 2.12.2 (2025-05-19) [stable]
Update gnulib, and support latest versions of automake and autoconf.
--
2.53.0