[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] jitterc: do not JITTER_STRINGIFY paths
From: |
Arsen Arsenović |
Subject: |
[PATCH] jitterc: do not JITTER_STRINGIFY paths |
Date: |
Fri, 25 Nov 2022 13:10:35 +0100 |
This avoids tokens that could coincidentally appear in paths (such as ``unix''
or ``i386'') getting expanded erroneously and breaking the directory paths.
* jitterc/jitterc-main.c (JITTERC_DEFAULT_FLAG_DIRECTORY): Do not
stringify.
(JITTERC_DEFAULT_TEMPLATE_DIRECTORY): Ditto.
* Makefile.am (-DJITTER_TEMPLATEDIR): Define as a string.
(-DJITTER_FLAGDIR): Ditto.
---
Hi,
This fixes the issue we talked about on IRC (as written in the commit message).
AFAICT, there isn't any reason to have expanded macro names in these paths
passed down from configure, so I presume this was an error.
Thanks, and have a great day.
Makefile.am | 4 ++--
jitterc/jitterc-main.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 62594ee..e6841a0 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -116,8 +116,8 @@ endif # JITTER_SUBPACKAGE
# overridden with a command-line option) to access template files but the
prefix
# is only known very late, at make time.
CPPFLAGS_FOR_PATHS = \
- -DJITTER_FLAGDIR=$(flagdir) \
- -DJITTER_TEMPLATEDIR=$(templatedir)
+ -DJITTER_FLAGDIR=\"$(flagdir)\" \
+ -DJITTER_TEMPLATEDIR=\"$(templatedir)\"
# FIXME: I probably should do the same for headers.
# jitterincludedir = $(includedir)/$(PACKAGE)/$(VERSION)
diff --git a/jitterc/jitterc-main.c b/jitterc/jitterc-main.c
index 3b3d57d..f15e2a6 100644
--- a/jitterc/jitterc-main.c
+++ b/jitterc/jitterc-main.c
@@ -48,7 +48,7 @@
The macro definition is convenient as it is, without surrounding parens,
since it can be directly concatenated as a string literal. */
#define JITTERC_DEFAULT_FLAG_DIRECTORY \
- JITTER_STRINGIFY(JITTER_FLAGDIR)
+ JITTER_FLAGDIR
/* The directory where templates are. Of course this is only useful if the
package is installed, but this default can be changed with the command-line
@@ -56,7 +56,7 @@
The macro definition is convenient as it is, without surrounding parens,
since it can be directly concatenated as a string literal. */
#define JITTERC_DEFAULT_TEMPLATE_DIRECTORY \
- JITTER_STRINGIFY(JITTER_TEMPLATEDIR)
+ JITTER_TEMPLATEDIR
/* All the information encoded by the user in the command line. */
struct jitterc_command_line
--
2.38.1
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH] jitterc: do not JITTER_STRINGIFY paths,
Arsen Arsenović <=