]> git.puffer.fish Git - mirror/frr.git/commitdiff
tools, ospfclient: add a config option to skip installing python scripts 16610/head
authorJafar Al-Gharaibeh <jafar@atcorp.com>
Tue, 20 Aug 2024 20:02:54 +0000 (15:02 -0500)
committerJafar Al-Gharaibeh <jafar@atcorp.com>
Thu, 22 Aug 2024 18:46:30 +0000 (13:46 -0500)
The new config option --disable-python-runtime allows make install to proceed
without installing any of the python scripts. When installing from deb/rpm
packages those are bundled as frr-pythontools, which is independent from the
frr binaries and can already be skipped. I.e, this PR gives the option to skip
those scripts when building/installing from sources too.

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
configure.ac
ospfclient/subdir.am
tools/subdir.am

index 59636194f770200d8370f2db33437c20ccc45b06..fe837e792b5c9bfcd98c3b772093921ad4cf3aed 100644 (file)
@@ -850,6 +850,9 @@ AC_ARG_WITH([frr-format],
 AC_ARG_ENABLE([version-build-config],
   AS_HELP_STRING([--disable-version-build-config], [do not include build configs in show version command]))
 
+AC_ARG_ENABLE([python_runtime],
+  AS_HELP_STRING([--disable-python-runtime], [do not install python scripts or have python runtime dependency]))
+
 #if openssl, else use the internal
 AS_IF([test "$with_crypto" = "openssl"], [
 AC_CHECK_LIB([crypto], [EVP_DigestInit], [LIBS="$LIBS -lcrypto"], [], [])
@@ -2811,6 +2814,9 @@ AM_CONDITIONAL([PATHD], [test "$enable_pathd" != "no"])
 AM_CONDITIONAL([PATHD_PCEP], [test "$enable_pathd" != "no"])
 AM_CONDITIONAL([DP_DPDK], [test "$enable_dp_dpdk" = "yes"])
 
+
+AM_CONDITIONAL([PYTHON_RUNTIME_DEPENDENCY], [test "$enable_python_runtime" != "no"])
+
 AC_CONFIG_FILES([Makefile],[
        test "$enable_dev_build" = "yes" && makefile_devbuild="--dev-build"
        ${PYTHON} "${ac_abs_top_srcdir}/python/makefile.py" ${makefile_devbuild} || exit 1
index 289ddd009d0f8bbd5b6ab3bdc27d996f37460d8a..2bf32544fda8c8cea327be2a1dcb4801db4d1dcf 100644 (file)
@@ -7,10 +7,13 @@ lib_LTLIBRARIES += ospfclient/libfrrospfapiclient.la
 noinst_PROGRAMS += ospfclient/ospfclient
 #man8 += $(MANBUILD)/frr-ospfclient.8
 
+if PYTHON_RUNTIME_DEPENDENCY
 sbin_SCRIPTS += \
        ospfclient/ospfclient.py \
        # end
 endif
+endif
+
 
 ospfclient_libfrrospfapiclient_la_LDFLAGS = $(LIB_LDFLAGS) -version-info 0:0:0
 ospfclient_libfrrospfapiclient_la_LIBADD = lib/libfrr.la
index 64ca0bd514e1709030b8dd7a74ad08898afdd5fe..f2ed2332b8bd27930ee21513cba1442b1edaf516 100644 (file)
@@ -13,15 +13,20 @@ EXTRA_PROGRAMS += \
        # end
 
 sbin_PROGRAMS += tools/ssd
+
+if PYTHON_RUNTIME_DEPENDENCY
 sbin_SCRIPTS += \
-       tools/frr-reload \
        tools/frr-reload.py \
+       tools/generate_support_bundle.py \
+       tools/frr_babeltrace.py
+endif
+
+sbin_SCRIPTS += \
+       tools/frr-reload \
        tools/frr \
        \
        tools/frrcommon.sh \
        tools/frrinit.sh \
-       tools/generate_support_bundle.py \
-       tools/frr_babeltrace.py \
        tools/watchfrr.sh \
        # end