summaryrefslogtreecommitdiff
path: root/Build/source/m4
diff options
context:
space:
mode:
authorLuigi Scarso <luigi.scarso@gmail.com>2022-08-22 21:33:05 +0000
committerLuigi Scarso <luigi.scarso@gmail.com>2022-08-22 21:33:05 +0000
commitbf1717d383aa30df85c1981587f04b53ccbaf608 (patch)
tree7aef294a0dec56a1cea52e6e88b3c90b3cab757f /Build/source/m4
parent7754712818064ff1f642a248ab9817ef4e2d7a90 (diff)
Potrace under libs (again) for dvisvgm and mflua/mfluajit.
git-svn-id: svn://tug.org/texlive/trunk@64168 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/m4')
-rw-r--r--Build/source/m4/ChangeLog5
-rw-r--r--Build/source/m4/kpse-pkgs.m42
-rw-r--r--Build/source/m4/kpse-potrace-flags.m431
3 files changed, 38 insertions, 0 deletions
diff --git a/Build/source/m4/ChangeLog b/Build/source/m4/ChangeLog
index a3e3c9f1f26..facc649163e 100644
--- a/Build/source/m4/ChangeLog
+++ b/Build/source/m4/ChangeLog
@@ -1,3 +1,8 @@
+2022-08-22 Luigi Scarso <luigi.scarso@gmail.com>
+
+ * kpse-pkgs.m4 (KPSE_LIBS_PKGS): add potrace.
+ * Add kpse-potrace-flags.m4.
+
2021-06-28 Karl Berry <karl@freefriends.org>
* README: list the macros obsoleted by autoconf 2.70 which we use.
diff --git a/Build/source/m4/kpse-pkgs.m4 b/Build/source/m4/kpse-pkgs.m4
index 5cba46b6bb1..197f39eb2ec 100644
--- a/Build/source/m4/kpse-pkgs.m4
+++ b/Build/source/m4/kpse-pkgs.m4
@@ -37,6 +37,7 @@ gmp
cairo
pixman
gd
+potrace
freetype2
libpng
libpaper
@@ -59,6 +60,7 @@ AC_REQUIRE([KPSE_KPATHSEA_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_PTEXENC_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_ZLIB_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_PPLIB_SYSTEM_FLAGS])[]dnl
+AC_REQUIRE([KPSE_POTRACE_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_LIBPAPER_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_LIBPNG_SYSTEM_FLAGS])[]dnl
AC_REQUIRE([KPSE_FREETYPE2_SYSTEM_FLAGS])[]dnl
diff --git a/Build/source/m4/kpse-potrace-flags.m4 b/Build/source/m4/kpse-potrace-flags.m4
new file mode 100644
index 00000000000..5d24df9ae3b
--- /dev/null
+++ b/Build/source/m4/kpse-potrace-flags.m4
@@ -0,0 +1,31 @@
+# Public macros for the TeX Live (TL) tree.
+# Copyright (C) 2022 Luigi Scarso <tex-live@tug.org>
+#
+# This file is free software; the copyright holder
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# serial 0
+
+# KPSE_POTRACE_FLAGS
+# ------------------
+# Provide the configure options '--with-system-potrace' (if in the TL tree),
+# '--with-potrace-includes', and '--with-potrace-libdir'.
+#
+# Set the make variables POTRACE_INCLUDES and POTRACE_LIBS to the CPPFLAGS and
+# LIBS required for the `-lpotrace' library in libs/potrace/ of the TL tree.
+AC_DEFUN([KPSE_POTRACE_FLAGS], [dnl
+AC_REQUIRE([KPSE_SAVE_FLAGS])[]dnl
+_KPSE_LIB_FLAGS([potrace], [potrace], [],
+ [-IBLD/libs/potrace/include], [BLD/libs/potrace/libpotrace.a], [],
+ [], [${top_builddir}/../../libs/potrace/include/potrace.h])[]dnl
+]) # KPSE_POTRACE_FLAGS
+
+# KPSE_POTRACE_OPTIONS([WITH-SYSTEM])
+# ----------------------------------
+AC_DEFUN([KPSE_POTRACE_OPTIONS], [_KPSE_LIB_OPTIONS([potrace], [$1])])
+
+# KPSE_POTRACE_SYSTEM_FLAGS
+# ------------------------
+AC_DEFUN([KPSE_POTRACE_SYSTEM_FLAGS], [dnl
+_KPSE_PKG_CONFIG_FLAGS([POTRACE], [POTRACE])])