mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 03:53:32 +01:00
make, scripts: Re-add files necessary for building ytools
Re-add everthing needed for building and packaging ytools. This is a big commit, 2002 lines of code. It mostly consists of C/C++ machinery, plus some documentation-related stuff. Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
0a9340af49
commit
bf16c6714b
27 changed files with 1975 additions and 0 deletions
28
make/yapp.mk
Normal file
28
make/yapp.mk
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
SRC_ALL_CPP += main.cpp
|
||||
YAPP_INCLUDE_DIR ?= .
|
||||
YAPP_CLASS ?= $(firstword $(basename $(notdir $(wildcard $(addprefix \
|
||||
$(YAPP_INCLUDE_DIR)/, YApp*.h App*.h Y*.h *.h)))))
|
||||
YAPP_CLASS_H ?= $(firstword $(wildcard $(addsuffix /$(YAPP_CLASS).h,\
|
||||
$(YAPP_INCLUDE_DIR) $(subst -I,,$(FINAL_INCLUDE)))) $(YAPP_CLASS).h)
|
||||
YAPP_NAMESPACE ?=
|
||||
|
||||
ifneq ($(TARGET),mingw)
|
||||
FINAL_LDFLAGS += -rdynamic
|
||||
endif
|
||||
|
||||
include $(JWBDIR)/make/exe.mk
|
||||
|
||||
all: build_EXE
|
||||
install: install_EXE
|
||||
clean: clean.yapp
|
||||
distclean:
|
||||
|
||||
clean.yapp:
|
||||
$(RM) -f main.cpp
|
||||
|
||||
main.cpp: $(YAPP_CLASS_H)
|
||||
echo "#include \"$<\"" > $@.tmp
|
||||
if [ "$(YAPP_NAMESPACE)" ]; then echo "using namespace $(YAPP_NAMESPACE);" >> $@.tmp; fi
|
||||
echo "#include <ytools/YAppRunner.h>" >> $@.tmp
|
||||
echo "yapp_main($(YAPP_CLASS))" >> $@.tmp
|
||||
mv $@.tmp $@
|
||||
Loading…
Add table
Add a link
Reference in a new issue