Source: blahtexml
Version: 0.9-1.1
User:
debian-arm@lists.debian.org
Usertags: pac-bti
Tags: patch
Hi,
blahtexml currently hardcodes CFLAGS in the Makefile. Additionally, it
does not use CXXFLAGS for C++ code and uses a deprecated debhelper compatibility level (7), which does not set environment variables listed
by dpkg-buildflags.
Please consider applying the attached patches to ensure the package uses
the default build flags set by dpkg-buildflags. This is necessary, among
other things, to enable PAC/BTI on arm64:
https://wiki.debian.org/ToolChain/PACBTI
From ab969b5f8620be60c2ad6aef144b99e1d254f5e6 Mon Sep 17 00:00:00 2001
From: Emanuele Rocca <
ema@debian.org>
Date: Fri, 14 Mar 2025 13:58:22 +0100
Subject: [PATCH 1/2] Do not override CFLAGS, use CXXFLAGS for cpp
---
makefile | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/makefile b/makefile
index 32490ff..e1c61f0 100644
--- a/makefile
+++ b/makefile
@@ -93,20 +93,18 @@ $(BINDIR)/InputSymbolTranslation.o: InputSymbolTranslation.cpp InputSymbolTransl
$(BINDIR_XMLIN)/InputSymbolTranslation.o: InputSymbolTranslation.cpp InputSymbolTranslation.inc
-CFLAGS = -O2
-
VPATH = Source:Source/BlahtexCore:Source/BlahtexXMLin
INCLUDES=-I. -ISource -ISource/BlahtexCore -ISource/BlahtexXMLin
$(BINDIR)/%.o:%.cpp
- $(CXX) $(INCLUDES) $(CFLAGS) -c $< -o $@
+ $(CXX) $(INCLUDES) $(CXXFLAGS) -c $< -o $@
$(BINDIR)/%.o:%.c
$(CC) $(INCLUDES) $(CFLAGS) -c $< -o $@
$(BINDIR_XMLIN)/%.o:%.cpp
- $(CXX) $(INCLUDES) $(CFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@
+ $(CXX) $(INCLUDES) $(CXXFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@
$(BINDIR_XMLIN)/%.o:%.c
$(CC) $(INCLUDES) $(CFLAGS) -DBLAHTEXML_USING_XERCES -c $< -o $@
@@ -115,13 +113,13 @@ blahtex-linux: $(BINDIR) $