This is an automated email from Gerrit.

"zapb <d...@zapb.de>" just uploaded a new patch set to Gerrit, which you can 
find at https://review.openocd.org/c/openocd/+/8383

-- gerrit

commit 450af54643d96644640c97ca1134c5422b7d8632
Author: Marc Schink <d...@zapb.de>
Date:   Tue Jul 2 17:14:22 2024 +0200

    configure: Use pkg-config for jimtcl
    
    The jimtcl project supports pkg-config, use it for a simpler
    configuration of compiler and linker flags and to enforce the minimum
    required package version.
    
    Change-Id: I6fdcc818a8fdd205a126b0a46356434dbe890226
    Signed-off-by: Marc Schink <d...@zapb.de>

diff --git a/Makefile.am b/Makefile.am
index 647b571cfa..2230e628f8 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -48,6 +48,8 @@ AM_CPPFLAGS = $(HOST_CPPFLAGS)\
 if INTERNAL_JIMTCL
 AM_CPPFLAGS += -I$(top_srcdir)/jimtcl \
                           -I$(top_builddir)/jimtcl
+else
+AM_CPPFLAGS += $(JIMTCL_CFLAGS)
 endif
 EXTRA_DIST += \
        BUGS \
diff --git a/configure.ac b/configure.ac
index 6b5e90f1f0..87568b04ac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -594,6 +594,8 @@ AS_IF([test "x$use_internal_jimtcl" = "xyes"], [
   ], [
     AC_MSG_ERROR([jimtcl not found, run git submodule init and git submodule 
update.])
   ])
+], [
+  PKG_CHECK_MODULES([JIMTCL], [jimtcl >= 0.82])
 ])
 
 AS_IF([test "x$build_remote_bitbang" = "xyes"], [
diff --git a/src/Makefile.am b/src/Makefile.am
index 6d79cd6311..93d128e290 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -17,7 +17,7 @@ bin_PROGRAMS += %D%/openocd
 if INTERNAL_JIMTCL
 %C%_openocd_LDADD += $(top_builddir)/jimtcl/libjim.a
 else
-%C%_openocd_LDADD += -ljim
+%C%_openocd_LDADD += $(JIMTCL_LIBS)
 endif
 
 %C%_libopenocd_la_CPPFLAGS =

-- 

Reply via email to