From 59e5b86699b30dddbe173dac2e896764b2a88e46 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Tue, 24 Mar 2009 14:05:12 +0000 Subject: First cut at porting hubbub's buildsystem to the core tools svn path=/trunk/hubbub/; revision=6837 --- src/Makefile | 50 ++---------------------------------------------- src/charset/Makefile | 47 ++------------------------------------------- src/tokeniser/Makefile | 46 ++------------------------------------------ src/treebuilder/Makefile | 46 ++------------------------------------------ src/utils/Makefile | 46 ++------------------------------------------ 5 files changed, 10 insertions(+), 225 deletions(-) (limited to 'src') diff --git a/src/Makefile b/src/Makefile index 14c6d8b..a939c8b 100644 --- a/src/Makefile +++ b/src/Makefile @@ -1,50 +1,4 @@ -# Child makefile fragment for libhubbub -# -# Toolchain is provided by top-level makefile -# -# Variables provided by top-level makefile -# -# COMPONENT The name of the component -# EXPORT The location of the export directory -# TOP The location of the source tree root -# RELEASEDIR The place to put release objects -# DEBUGDIR The place to put debug objects -# -# do_include Canned command sequence to include a child makefile -# -# Variables provided by parent makefile: -# -# DIR The name of the directory we're in, relative to $(TOP) -# -# Variables we can manipulate: -# -# ITEMS_CLEAN The list of items to remove for "make clean" -# ITEMS_DISTCLEAN The list of items to remove for "make distclean" -# TARGET_TESTS The list of target names to run for "make test" -# -# SOURCES The list of sources to build for $(COMPONENT) -# -# Plus anything from the toolchain - -# Push parent directory onto the directory stack -sp := $(sp).x -dirstack_$(sp) := $(d) -d := $(DIR) - -# Manipulate include paths -CFLAGS := $(CFLAGS) -I$(d) $(shell $(PKGCONFIG) libparserutils --cflags) -LDFLAGS := $(LDFLAGS) $(shell $(PKGCONFIG) libparserutils --libs) - # Sources -SRCS_$(d) := hubbub.c parser.c - -# Append to sources for component -SOURCES += $(addprefix $(d), $(SRCS_$(d))) - -# Now include any children we may have -MAKE_INCLUDES := $(wildcard $(d)*/Makefile) -$(eval $(foreach INC, $(MAKE_INCLUDES), $(call do_include,$(INC)))) +DIR_SOURCES := hubbub.c parser.c -# Finally, pop off the directory stack -d := $(dirstack_$(sp)) -sp := $(basename $(sp)) +include build/makefiles/Makefile.subdir diff --git a/src/charset/Makefile b/src/charset/Makefile index 3bdb77f..c97d758 100644 --- a/src/charset/Makefile +++ b/src/charset/Makefile @@ -1,46 +1,3 @@ -# Child makefile fragment for libhubbub -# -# Toolchain is provided by top-level makefile -# -# Variables provided by top-level makefile -# -# COMPONENT The name of the component -# EXPORT The location of the export directory -# TOP The location of the source tree root -# RELEASEDIR The place to put release objects -# DEBUGDIR The place to put debug objects -# -# do_include Canned command sequence to include a child makefile -# -# Variables provided by parent makefile: -# -# DIR The name of the directory we're in, relative to $(TOP) -# -# Variables we can manipulate: -# -# ITEMS_CLEAN The list of items to remove for "make clean" -# ITEMS_DISTCLEAN The list of items to remove for "make distclean" -# TARGET_TESTS The list of target names to run for "make test" -# -# SOURCES The list of sources to build for $(COMPONENT) -# -# Plus anything from the toolchain +DIR_SOURCES := detect.c -# Push parent directory onto the directory stack -sp := $(sp).x -dirstack_$(sp) := $(d) -d := $(DIR) - -# Sources -SRCS_$(d) := detect.c - -# Append to sources for component -SOURCES += $(addprefix $(d), $(SRCS_$(d))) - -# Now include any children we may have -MAKE_INCLUDES := $(wildcard $(d)*/Makefile) -$(eval $(foreach INC, $(MAKE_INCLUDES), $(call do_include,$(INC)))) - -# Finally, pop off the directory stack -d := $(dirstack_$(sp)) -sp := $(basename $(sp)) +include build/makefiles/Makefile.subdir diff --git a/src/tokeniser/Makefile b/src/tokeniser/Makefile index be0699c..1dcb100 100644 --- a/src/tokeniser/Makefile +++ b/src/tokeniser/Makefile @@ -1,46 +1,4 @@ -# Child makefile fragment for libhubbub -# -# Toolchain is provided by top-level makefile -# -# Variables provided by top-level makefile -# -# COMPONENT The name of the component -# EXPORT The location of the export directory -# TOP The location of the source tree root -# RELEASEDIR The place to put release objects -# DEBUGDIR The place to put debug objects -# -# do_include Canned command sequence to include a child makefile -# -# Variables provided by parent makefile: -# -# DIR The name of the directory we're in, relative to $(TOP) -# -# Variables we can manipulate: -# -# ITEMS_CLEAN The list of items to remove for "make clean" -# ITEMS_DISTCLEAN The list of items to remove for "make distclean" -# TARGET_TESTS The list of target names to run for "make test" -# -# SOURCES The list of sources to build for $(COMPONENT) -# -# Plus anything from the toolchain - -# Push parent directory onto the directory stack -sp := $(sp).x -dirstack_$(sp) := $(d) -d := $(DIR) - # Sources -SRCS_$(d) := entities.c tokeniser.c - -# Append to sources for component -SOURCES += $(addprefix $(d), $(SRCS_$(d))) - -# Now include any children we may have -MAKE_INCLUDES := $(wildcard $(d)*/Makefile) -$(eval $(foreach INC, $(MAKE_INCLUDES), $(call do_include,$(INC)))) +DIR_SOURCES := entities.c tokeniser.c -# Finally, pop off the directory stack -d := $(dirstack_$(sp)) -sp := $(basename $(sp)) +include build/makefiles/Makefile.subdir diff --git a/src/treebuilder/Makefile b/src/treebuilder/Makefile index 28be92a..0bc8c25 100644 --- a/src/treebuilder/Makefile +++ b/src/treebuilder/Makefile @@ -1,38 +1,5 @@ -# Child makefile fragment for libhubbub -# -# Toolchain is provided by top-level makefile -# -# Variables provided by top-level makefile -# -# COMPONENT The name of the component -# EXPORT The location of the export directory -# TOP The location of the source tree root -# RELEASEDIR The place to put release objects -# DEBUGDIR The place to put debug objects -# -# do_include Canned command sequence to include a child makefile -# -# Variables provided by parent makefile: -# -# DIR The name of the directory we're in, relative to $(TOP) -# -# Variables we can manipulate: -# -# ITEMS_CLEAN The list of items to remove for "make clean" -# ITEMS_DISTCLEAN The list of items to remove for "make distclean" -# TARGET_TESTS The list of target names to run for "make test" -# -# SOURCES The list of sources to build for $(COMPONENT) -# -# Plus anything from the toolchain - -# Push parent directory onto the directory stack -sp := $(sp).x -dirstack_$(sp) := $(d) -d := $(DIR) - # Sources -SRCS_$(d) := treebuilder.c \ +DIR_SOURCES := treebuilder.c \ initial.c before_html.c before_head.c in_head.c \ in_head_noscript.c after_head.c in_body.c in_table.c \ in_caption.c in_column_group.c in_table_body.c in_row.c \ @@ -41,13 +8,4 @@ SRCS_$(d) := treebuilder.c \ after_frameset.c after_after_body.c after_after_frameset.c \ generic_rcdata.c -# Append to sources for component -SOURCES += $(addprefix $(d), $(SRCS_$(d))) - -# Now include any children we may have -MAKE_INCLUDES := $(wildcard $(d)*/Makefile) -$(eval $(foreach INC, $(MAKE_INCLUDES), $(call do_include,$(INC)))) - -# Finally, pop off the directory stack -d := $(dirstack_$(sp)) -sp := $(basename $(sp)) +include build/makefiles/Makefile.subdir diff --git a/src/utils/Makefile b/src/utils/Makefile index 0678442..3918256 100644 --- a/src/utils/Makefile +++ b/src/utils/Makefile @@ -1,46 +1,4 @@ -# Child makefile fragment for libhubbub -# -# Toolchain is provided by top-level makefile -# -# Variables provided by top-level makefile -# -# COMPONENT The name of the component -# EXPORT The location of the export directory -# TOP The location of the source tree root -# RELEASEDIR The place to put release objects -# DEBUGDIR The place to put debug objects -# -# do_include Canned command sequence to include a child makefile -# -# Variables provided by parent makefile: -# -# DIR The name of the directory we're in, relative to $(TOP) -# -# Variables we can manipulate: -# -# ITEMS_CLEAN The list of items to remove for "make clean" -# ITEMS_DISTCLEAN The list of items to remove for "make distclean" -# TARGET_TESTS The list of target names to run for "make test" -# -# SOURCES The list of sources to build for $(COMPONENT) -# -# Plus anything from the toolchain - -# Push parent directory onto the directory stack -sp := $(sp).x -dirstack_$(sp) := $(d) -d := $(DIR) - # Sources -SRCS_$(d) := dict.c errors.c string.c - -# Append to sources for component -SOURCES += $(addprefix $(d), $(SRCS_$(d))) - -# Now include any children we may have -MAKE_INCLUDES := $(wildcard $(d)*/Makefile) -$(eval $(foreach INC, $(MAKE_INCLUDES), $(call do_include,$(INC)))) +DIR_SOURCES := dict.c errors.c string.c -# Finally, pop off the directory stack -d := $(dirstack_$(sp)) -sp := $(basename $(sp)) +include build/makefiles/Makefile.subdir -- cgit v1.2.3