mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 12:03:31 +01:00
Everywhere: Remove everything non-essential for "make clean all"
This commit removes everything not strictly necessary for running "make clean all" inside jw-build. packaging jw-devtest. This cuts the repo down from 24077 to 4725 lines of code. The idea is to 1) Further remove bloat from the remaining bits 2) Re-add what's necessary to build and package other essential repos. The decision should be based on whether or not jw-build can also be useful in a non-janware context. Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
c36c83c164
commit
bc883deed4
199 changed files with 0 additions and 18851 deletions
|
|
@ -1,105 +0,0 @@
|
|||
# generic utility modules
|
||||
# (c) 2001 jannet it services
|
||||
# contact@jannet.de
|
||||
# $Id$
|
||||
|
||||
ifndef TARGETS_TOOLS_MK_INCLUDED
|
||||
TARGETS_TOOLS_MK_INCLUDED = true
|
||||
|
||||
include $(JWBDIR)/make/rules.mk
|
||||
|
||||
ifneq ($(strip $(SRC_ALL_CPP)),)
|
||||
|
||||
# mandatory targets
|
||||
all:
|
||||
# all.link
|
||||
install: $(ALL)
|
||||
|
||||
# convenience targets
|
||||
#link: all.link
|
||||
clean-link: clean.link
|
||||
|
||||
#all.link: $(HDRDIR_SCOPE_SUFFIX)
|
||||
|
||||
$(HDRDIR_SCOPE_SUFFIX):
|
||||
mkdir -p $(dir $(HDRDIR_SCOPE_SUFFIX))
|
||||
ln -s $(shell realpath -m . --relative-to $(dir $(HDRDIR_SCOPE_SUFFIX))) $@
|
||||
|
||||
ifeq ($(SCOPE_PREFIX),)
|
||||
#all.link: $(BUILD_HDRDIR)/$(HDRDIR_SCOPE_SUFFIX)
|
||||
|
||||
#$(BUILD_HDRDIR)/$(HDRDIR_SCOPE_SUFFIX):
|
||||
# cd $(BUILD_HDRDIR_BASE) && ln -s . $(HDRDIR_SCOPE_SUFFIX)
|
||||
endif
|
||||
|
||||
ifneq ($(TARGET),mingw)
|
||||
$(LIB_SO): $(BUILD_OBJ)
|
||||
endif
|
||||
|
||||
all.done: $(PREREQ_DONE) $(BUILD_HDR) $(BUILD_EXE_SH) $(MEMBERS) $(LIB_A) | $(HDRDIR_SCOPE_SUFFIX)
|
||||
|
||||
ifneq ($(TARGET),mingw)
|
||||
all.done: $(LIB_SO)
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
clean: objclean textclean localclean profclean clean.link
|
||||
|
||||
clean.link:
|
||||
if [ -L "$(HDRDIR_SCOPE_SUFFIX)" -a "`realpath --relative-to . $(HDRDIR_SCOPE_SUFFIX) 2>/dev/null`" = . ]; then \
|
||||
rm $(HDRDIR_SCOPE_SUFFIX) ;\
|
||||
rmdir -p $(dir $(HDRDIR_SCOPE_SUFFIX)) 2>/dev/null || : ;\
|
||||
fi
|
||||
|
||||
CLANG_TIDY_H_C_CPP := $(shell $(ECHO) $(LOCAL_H) | xargs -r $(GREP) -l 'extern *"C"')
|
||||
CLANG_TIDY_H_C := $(wildcard [a-z]*.h)
|
||||
CLANG_TIDY_H_CPP := $(wildcard [A-Z]*.h)
|
||||
#CLANG_TIDY_H_CPP := $(filter-out $(CLANG_TIDY_H_C),$(LOCAL_H))
|
||||
|
||||
# false positives on assert(), see https://reviews.llvm.org/D31130
|
||||
CLANG_TIDY_EXTRA_ARGS += -cppcoreguidelines-pro-bounds-array-to-pointer-decay
|
||||
|
||||
# keep va_args
|
||||
CLANG_TIDY_EXTRA_ARGS += -cppcoreguidelines-pro-type-vararg
|
||||
|
||||
# keep pointer arithmetic
|
||||
CLANG_TIDY_EXTRA_ARGS += -cppcoreguidelines-pro-bounds-pointer-arithmetic
|
||||
|
||||
# don't have GSL (for now)
|
||||
CLANG_TIDY_EXTRA_ARGS += -cppcoreguidelines-pro-bounds-constant-array-index
|
||||
|
||||
CLANG_TIDY_FILTER = $(SED) 's%\[\([a-z-]\+\)\]$$%[https://clang.llvm.org/extra/clang-tidy/checks/\1.html]%'
|
||||
CLANG_TIDY_CHECKS ?= -$(subst $(space),,*,clang-analyzer-*,-clang-analyzer-cplusplus*,modernize-*,portability-*,cppcoreguidelines-*$(addprefix $(comma),$(CLANG_TIDY_EXTRA_ARGS)))
|
||||
CLANG_TIDY ?= clang-tidy -checks=$(CLANG_TIDY_CHECKS)
|
||||
|
||||
clean: clang-tidy-clean
|
||||
clang-tidy-clean:
|
||||
rm -f clang-tidy-cache*.tmp
|
||||
CLANG_TIDY_CACHE_CPP = clang-tidy-cache-cpp.tmp
|
||||
$(CLANG_TIDY_CACHE_CPP): $(LOCAL_CPP)
|
||||
$(CLANG_TIDY) $(LOCAL_CPP) -- $(FINAL_INCLUDE) -x c++ | $(CLANG_TIDY_FILTER) | tee $@
|
||||
|
||||
clang-tidy-h-c-cpp:
|
||||
ifneq ($(CLANG_TIDY_H_C_CPP),)
|
||||
$(CLANG_TIDY) $(CLANG_TIDY_H_C_CPP) -- $(FINAL_INCLUDE)
|
||||
endif
|
||||
clang-tidy-h-c:
|
||||
ifneq ($(CLANG_TIDY_H_C_C),)
|
||||
$(CLANG_TIDY) $(CLANG_TIDY_H_C) -- $(FINAL_INCLUDE)
|
||||
endif
|
||||
clang-tidy-h-cpp:
|
||||
ifneq ($(CLANG_TIDY_H_CPP),)
|
||||
$(CLANG_TIDY) $(CLANG_TIDY_H_CPP) -- $(FINAL_INCLUDE) -x c++
|
||||
endif
|
||||
clang-tidy-h: clang-tidy-h-c clang-tidy-h-cpp clang-tidy-h-c-cpp
|
||||
|
||||
clang-tidy-c:
|
||||
ifneq ($(LOCAL_C),)
|
||||
$(CLANG_TIDY) $(LOCAL_C) -- $(FINAL_INCLUDE)
|
||||
endif
|
||||
clang-tidy-cpp: $(CLANG_TIDY_CACHE_CPP)
|
||||
cat $<
|
||||
clang-tidy: clang-tidy-h clang-tidy-c clang-tidy-cpp
|
||||
|
||||
endif # ifndef TARGETS_TOOLS_MK_INCLUDED
|
||||
Loading…
Add table
Add a link
Reference in a new issue