Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37777546
en ru br
ALT Linux repos
S:2.0.0-alt1.qa2
5.0: 2.0.0-alt1
4.1: 2.0.0-alt1
4.0: 2.0.0-alt0.M40.1

Group :: File tools
RPM: docbook-to-man

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Patch: 0005-makefile.patch
Download


From: Philipp Benner <philipp@debian.org>
Date: Fri, 12 May 2017 10:49:00 +0200
Subject: makefile
Fix bad use of CFLAGS in Makefiles
===================================================================
---
 Instant/Makefile           | 5 +++--
 Instant/tptregexp/Makefile | 5 ++++-
 2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/Instant/Makefile b/Instant/Makefile
index 47e230b..02c691c 100644
--- a/Instant/Makefile
+++ b/Instant/Makefile
@@ -76,8 +76,6 @@ DEFINES		= -DDEF_TPT_LIB=\"$(TPTLIB)\" $(XDEFINES)
 CC	= gcc
 
 OPT	= -g
-CFLAGS	= $(OPT) $(REGEX_INC) $(DEFINES)
-LDFLAGS	= $(OPT)
 REGEX	= -L$(REGEX_LIB) -ltptregexp
 
 CFILES	= main.c util.c info.c translate.c traninit.c tranvar.c tables.c \
@@ -89,6 +87,9 @@ PROGS	= instant
 
 all:	dotptregexp $(PROGS)
 
+%.o : %.c
+	$(CC) -c $(CFLAGS) $(OPT) $(REGEX_INC) $(DEFINES) $< -o $@
+
 dotptregexp:
 	cd tptregexp; $(MAKE) all
 
diff --git a/Instant/tptregexp/Makefile b/Instant/tptregexp/Makefile
index 77f9c16..3d1cfa1 100644
--- a/Instant/tptregexp/Makefile
+++ b/Instant/tptregexp/Makefile
@@ -50,7 +50,7 @@ TEST=	-I.
 # -p			profiler
 PROF=
 
-CFLAGS=-O $(ENV) $(TEST) $(PROF)
+CFLAGS=-O $(ENV)
 LINTFLAGS=$(LENV) $(TEST) -ha
 LDFLAGS=
 
@@ -67,6 +67,9 @@ install: libtptregexp.a
 try:	try.o $(OBJ)
 	$(CC) $(LDFLAGS) try.o $(OBJ) -o try
 
+%.o : %.c
+	$(CC) -c $(CFLAGS) $(TEST) $(PROF) $< -o $@
+
 # Making timer will probably require putting stuff in $(PROF) and then
 # recompiling everything; the following is just the final stage.
 timer:	timer.o $(OBJ)
 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin