Linux-FSCrypt Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH v3 0/2] fsverity-utils Makefile fixes
@ 2020-05-20 21:25 Jes Sorensen
  2020-05-20 21:25 ` [PATCH 1/2] Fix Makefile to delete objects from the library on make clean Jes Sorensen
  2020-05-20 21:25 ` [PATCH 2/2] Let package manager override CFLAGS and CPPFLAGS Jes Sorensen
  0 siblings, 2 replies; 3+ messages in thread
From: Jes Sorensen @ 2020-05-20 21:25 UTC (permalink / raw)
  To: ebiggers; +Cc: linux-fscrypt, kernel-team, Jes Sorensen

From: Jes Sorensen <jsorensen@fb.com>

Hi,

This addresses the last comments, leaving the CPPFLAGS as override. I
checked that it doesn't break the rpm build as well.

Cheers,
Jes


Jes Sorensen (2):
  Fix Makefile to delete objects from the library on make clean
  Let package manager override CFLAGS and CPPFLAGS

 Makefile | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

-- 
2.26.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 1/2] Fix Makefile to delete objects from the library on make clean
  2020-05-20 21:25 [PATCH v3 0/2] fsverity-utils Makefile fixes Jes Sorensen
@ 2020-05-20 21:25 ` Jes Sorensen
  2020-05-20 21:25 ` [PATCH 2/2] Let package manager override CFLAGS and CPPFLAGS Jes Sorensen
  1 sibling, 0 replies; 3+ messages in thread
From: Jes Sorensen @ 2020-05-20 21:25 UTC (permalink / raw)
  To: ebiggers; +Cc: linux-fscrypt, kernel-team, Jes Sorensen

From: Jes Sorensen <jsorensen@fb.com>

Signed-off-by: Jes Sorensen <jsorensen@fb.com>
---
 Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 1a7be53..e7fb5cf 100644
--- a/Makefile
+++ b/Makefile
@@ -180,8 +180,8 @@ help:
 	done
 
 clean:
-	rm -f $(DEFAULT_TARGETS) $(TEST_PROGRAMS) $(LIB_OBJS) $(ALL_PROG_OBJ) \
-		.build-config
+	rm -f $(DEFAULT_TARGETS) $(TEST_PROGRAMS) \
+		lib/*.o programs/*.o .build-config
 
 FORCE:
 
-- 
2.26.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 2/2] Let package manager override CFLAGS and CPPFLAGS
  2020-05-20 21:25 [PATCH v3 0/2] fsverity-utils Makefile fixes Jes Sorensen
  2020-05-20 21:25 ` [PATCH 1/2] Fix Makefile to delete objects from the library on make clean Jes Sorensen
@ 2020-05-20 21:25 ` Jes Sorensen
  1 sibling, 0 replies; 3+ messages in thread
From: Jes Sorensen @ 2020-05-20 21:25 UTC (permalink / raw)
  To: ebiggers; +Cc: linux-fscrypt, kernel-team, Jes Sorensen

From: Jes Sorensen <jsorensen@fb.com>

Package managers such as RPM wants to build everything with their
preferred flags, and we shouldn't hard override flags.

Signed-off-by: Jes Sorensen <jsorensen@fb.com>
---
 Makefile | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/Makefile b/Makefile
index e7fb5cf..18f08c3 100644
--- a/Makefile
+++ b/Makefile
@@ -29,16 +29,12 @@
 cc-option = $(shell if $(CC) $(1) -c -x c /dev/null -o /dev/null &>/dev/null; \
 	      then echo $(1); fi)
 
-#### Common compiler flags.  You can add additional flags by defining CFLAGS
-#### and/or CPPFLAGS in the environment or on the 'make' command line.
-
-override CFLAGS := -O2 -Wall -Wundef				\
+CFLAGS := -O2 -Wall -Wundef				\
 	$(call cc-option,-Wdeclaration-after-statement)		\
 	$(call cc-option,-Wmissing-prototypes)			\
 	$(call cc-option,-Wstrict-prototypes)			\
 	$(call cc-option,-Wvla)					\
-	$(call cc-option,-Wimplicit-fallthrough)		\
-	$(CFLAGS)
+	$(call cc-option,-Wimplicit-fallthrough)
 
 override CPPFLAGS := -D_FILE_OFFSET_BITS=64 $(CPPFLAGS)
 
-- 
2.26.2


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-20 21:25 [PATCH v3 0/2] fsverity-utils Makefile fixes Jes Sorensen
2020-05-20 21:25 ` [PATCH 1/2] Fix Makefile to delete objects from the library on make clean Jes Sorensen
2020-05-20 21:25 ` [PATCH 2/2] Let package manager override CFLAGS and CPPFLAGS Jes Sorensen

Linux-FSCrypt Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-fscrypt/0 linux-fscrypt/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-fscrypt linux-fscrypt/ https://lore.kernel.org/linux-fscrypt \
		linux-fscrypt@vger.kernel.org
	public-inbox-index linux-fscrypt

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-fscrypt


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git