[master] 1d4950a3c Fix build order of BUILD_VMOD_$NAME m4 macro

Nils Goroll nils.goroll at uplex.de
Mon Feb 26 14:20:07 UTC 2024


commit 1d4950a3c93a0bd86d4be0d583dcf5a969950858
Author: Steven Wojcik <steven.wojcik at disneystreaming.com>
Date:   Fri Feb 23 10:08:16 2024 -0500

    Fix build order of BUILD_VMOD_$NAME m4 macro
    
    When a VMOD adds a CFLAG with `libvmod_$1_la_CFLAGS` the object name is no
    longer `vmod_$name.lo` but `$library-vmod_name.lo` this changes the
    build order such that the VCC autogenerated files would not be
    guaranteed to compile first causing compilation issues.

diff --git a/varnish.m4 b/varnish.m4
index 80846579c..e7e596717 100644
--- a/varnish.m4
+++ b/varnish.m4
@@ -213,9 +213,9 @@ AC_DEFUN([_VARNISH_VMOD], [
 
 	AC_SUBST(m4_toupper(BUILD_VMOD_$1), ["
 
-vmod_$1.lo: vcc_$1_if.c vcc_$1_if.h
+\$(libvmod_$1_la_OBJECTS): vcc_$1_if.c vcc_$1_if.h
 
-vmod_$1.lo: \$(nodist_libvmod_$1_la_SOURCES)
+\$(libvmod_$1_la_OBJECTS): \$(nodist_libvmod_$1_la_SOURCES)
 
 vcc_$1_if.h vmod_$1.rst vmod_$1.man.rst: vcc_$1_if.c
 


More information about the varnish-commit mailing list