Skip to content

Commit

Permalink
debian: Add -fdebug-prefix-map to all builds
Browse files Browse the repository at this point in the history
This flag removes build paths from any elf files.

Signed-off-by: Keith Packard <keithp@keithp.com>
  • Loading branch information
keith-packard committed May 22, 2020
1 parent 2328a03 commit 5f4eaad
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion debian/rules
Expand Up @@ -7,6 +7,20 @@ export PREFIX=/usr
export CFLAGS_POSIX=$(shell dpkg-buildflags --get CFLAGS) $(shell dpkg-buildflags --get LDFLAGS)
export V=1

BUILDDIR = $(shell pwd)

SNEK_MOST_WARNINGS = \
-fdebug-prefix-map=$(BUILDDIR)=. \
-Wall \
-Wcast-align \
-Wextra \
-Wpointer-arith \
-Wstrict-prototypes \
-Wmissing-prototypes \
-Wmissing-declarations \
-Wnested-externs \
-Wshadow

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

Expand All @@ -22,8 +36,11 @@ override_dh_dwz:
override_dh_shlibdeps:
dh_shlibdeps -X.elf -Xsnek-ev3

override_dh_auto_build-indep:
dh_auto_build -- "SNEK_MOST_WARNINGS=$(SNEK_MOST_WARNINGS)"

override_dh_auto_build-arch:
dh_auto_build -- FIRMWARE=
dh_auto_build -- FIRMWARE= "SNEK_MOST_WARNINGS=$(SNEK_MOST_WARNINGS)"

override_dh_auto_test-arch:
dh_auto_test -- FIRMWARE= SNEK_RISCV= SNEK_ARM=
Expand Down

0 comments on commit 5f4eaad

Please sign in to comment.