- ccmalloc-Target

This commit is contained in:
Christian Schlittchen 2002-03-31 13:34:02 +00:00
parent 9a813092bb
commit a8bb24cf67
2 changed files with 14 additions and 5 deletions

View File

@ -96,6 +96,13 @@ ifeq ($(CONFIG), dmalloc)
LIBS += -ldmalloc LIBS += -ldmalloc
endif endif
ifeq ($(CONFIG), ccmalloc)
BUILD_DIR = Ccmalloc-$(ARCHITECTURE)
CFLAGS += -ggdb
LDFLAGS += -ggdb
LD = ccmalloc gcc
endif
# ifeq ($(CONFIG), lint) # ifeq ($(CONFIG), lint)
# BUILD_DIR = Lint-$(ARCHITECTURE) # BUILD_DIR = Lint-$(ARCHITECTURE)
# CC = lint # CC = lint
@ -132,7 +139,7 @@ PUBLISH_DIR = $(ERESSEA)/$(BUILD_DIR)
env: env:
@$(MAKEENV) @$(MAKEENV)
debug release profile dmalloc:: env $(PUBLISH_DIR) $(PUBLISH_DIR) debug release profile dmalloc ccmalloc:: env $(PUBLISH_DIR) $(PUBLISH_DIR)
$(MAKE) CONFIG=$@ recurse-subdirs-$@ $(MAKE) CONFIG=$@ recurse-subdirs-$@
## ##
@ -142,12 +149,13 @@ recurse-subdirs-debug:: subdirs-debug publish-debug
recurse-subdirs-release:: subdirs-release publish-release recurse-subdirs-release:: subdirs-release publish-release
recurse-subdirs-profile:: subdirs-profile publish-profile recurse-subdirs-profile:: subdirs-profile publish-profile
recurse-subdirs-dmalloc:: subdirs-dmalloc publish-dmalloc recurse-subdirs-dmalloc:: subdirs-dmalloc publish-dmalloc
recurse-subdirs-ccmalloc:: subdirs-ccmalloc publish-ccmalloc
recurse-lint:: lint recurse-lint:: lint
recurse-clean:: clean recurse-clean:: clean
recurse-depend:: depend recurse-depend:: depend
subdirs-debug subdirs-release subdirs-profile subdirs-dmalloc lint clean depend:: subdirs-debug subdirs-release subdirs-profile subdirs-dmalloc subdirs-ccmalloc lint clean depend::
@mkdir -p $(PUBLISH_DIR) @mkdir -p $(PUBLISH_DIR)
@if [ -n "$(SUBDIRS)" ]; then \ @if [ -n "$(SUBDIRS)" ]; then \
for subdir in x-placeholder-dir $(SUBDIRS); do \ for subdir in x-placeholder-dir $(SUBDIRS); do \
@ -163,11 +171,12 @@ publish-debug:: subdirs-debug
publish-release:: subdirs-release publish-release:: subdirs-release
publish-profile:: subdirs-profile publish-profile:: subdirs-profile
publish-dmalloc:: subdirs-dmalloc publish-dmalloc:: subdirs-dmalloc
publish-ccmalloc:: subdirs-ccmalloc
publish-debug publish-release publish-profile publish-dmalloc:: $(PUBLISH_DIR)/$(LIBRARY) $(PUBLISH_DIR)/$(BINARY) publish-debug publish-release publish-profile publish-ccmalloc:: $(PUBLISH_DIR)/$(LIBRARY) $(PUBLISH_DIR)/$(BINARY)
clean:: $(BUILD_DIR) $(PUBLISH_DIR) clean:: $(BUILD_DIR) $(PUBLISH_DIR)
rm -fr Release-$(ARCHITECTURE)/* Debug-$(ARCHITECTURE)/* Profile-$(ARCHITECTURE)/* Dmalloc-$(ARCHITECTURE)/* Lint-$(ARCHITECTURE)/* rm -fr Release-$(ARCHITECTURE)/* Debug-$(ARCHITECTURE)/* Profile-$(ARCHITECTURE)/* Dmalloc-$(ARCHITECTURE)/* Ccmalloc-$(ARCHITECTURE) Lint-$(ARCHITECTURE)/*
lint:: lint::
$(LINT) -I$(ERESSEA) $(INCLUDES) $(LINTFLAGS) *.c $(LINT) -I$(ERESSEA) $(INCLUDES) $(LINTFLAGS) *.c

View File

@ -72,7 +72,7 @@ static void
free_attribs(xml_attrib * xa) free_attribs(xml_attrib * xa)
{ {
free(xa->name); free(xa->name);
free(xa->value); if(xa->value) free(xa->value);
free(xa); free(xa);
} }