summaryrefslogtreecommitdiff
path: root/common.once.head.mk
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-05-25 23:32:14 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-05-25 23:32:14 -0400
commit0629b78d815ce6a0b65aecc02fb18a122226274c (patch)
tree4715d40a85a08ea4f5fcbb30ca70db70d31e23b1 /common.once.head.mk
parentf5e7d6cf6b513104f051442b01e8b3bca7523709 (diff)
stuff
Diffstat (limited to 'common.once.head.mk')
-rw-r--r--common.once.head.mk25
1 files changed, 23 insertions, 2 deletions
diff --git a/common.once.head.mk b/common.once.head.mk
index 3a084ff51f..85c2898e88 100644
--- a/common.once.head.mk
+++ b/common.once.head.mk
@@ -20,15 +20,17 @@
#
# You should have received a copy of the GNU Lesser General Public License
# along with systemd; If not, see <http://www.gnu.org/licenses/>.
+MAKEFLAGS += --no-builtin-rules
+
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
-AM_MAKEFLAGS = --no-print-directory
-AUTOMAKE_OPTIONS = color-tests parallel-tests
GCC_COLORS ?= 'ooh, shiny!'
export GCC_COLORS
SUBDIRS = . po
+CPPFLAGS += -include $(topoutdir)/config.h
+
# remove targets if the command fails
.DELETE_ON_ERROR:
@@ -50,3 +52,22 @@ define generate-sym-test
$(AM_V_at)printf 'return 0; }\n' >> $@
endef
+%-from-name.gperf: %-list.txt
+ $(AM_V_at)$(MKDIR_P) $(dir $@)
+ $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct $(notdir $*)_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, %s\n", $$1, $$1 }' <$< >$@
+
+%-from-name.h: %-from-name.gperf
+ $(AM_V_at)$(MKDIR_P) $(dir $@)
+ $(AM_V_GPERF)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_$(notdir $*) -H hash_$(notdir $*)_name -p -C <$< >$@
+
+# from GNU automake
+
+DEFAULT_INCLUDES = -I.
+depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp
+am__depfiles_maybe = depfiles
+DEPDIR = .deps
+
+am__mv = mv -f
+
+include $(topsrcdir)/am-pretty.mk
+include $(topsrcdir)/am-tools.mk