diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 7648d80..267cf4f 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -14,6 +14,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 + with: + submodules: recursive - name: Install xsltproc run: sudo apt-get install xsltproc - name: Build diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..0f8416f --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "support/XKCBuild"] + path = support/XKCBuild + url = https://github.com/XKCP/XKCBuild.git diff --git a/Makefile b/Makefile index dbf11de..bf58eb2 100644 --- a/Makefile +++ b/Makefile @@ -1,15 +1,2 @@ -_list: Makefile.build support/Build/ToGlobalMakefile.xsl - -bin/.build/Makefile: bin/.build/Makefile.expanded - mkdir -p $(dir $@) - xsltproc --xinclude -o $@ support/Build/ToGlobalMakefile.xsl $< - -bin/.build/Makefile.expanded: Makefile.build - mkdir -p $(dir $@) - xsltproc --xinclude -o $@ support/Build/ExpandProducts.xsl $< - --include bin/.build/Makefile - -.PHONY: clean -clean: - rm -rf bin/ +XKCBpath = support/XKCBuild +include $(XKCBpath)/src/Main.makefile diff --git a/support/Build/ExpandProducts.xsl b/support/Build/ExpandProducts.xsl deleted file mode 100644 index fb19f5c..0000000 --- a/support/Build/ExpandProducts.xsl +++ /dev/null @@ -1,79 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - diff --git a/support/Build/ToGlobalMakefile.xsl b/support/Build/ToGlobalMakefile.xsl deleted file mode 100644 index ac665e8..0000000 --- a/support/Build/ToGlobalMakefile.xsl +++ /dev/null @@ -1,206 +0,0 @@ - - - - - - - - - - - - - - - - - - - - : - - - - - .packs: - - - - - - .PHONY: - - - - - - - - - - - - : - - - - - - - - : - - - $(MAKE) -f - - - - - - - - : - - - - - $(MAKE) -f - - - - - - - - : - - - - - - : - - - - - mkdir -p - /config - cp - - - /config - xsltproc -o $@ support/Build/ToVCXProj.xsl - - - - - - : - - support/Build/ToTargetMakefile.xsl - mkdir -p $(dir $@) - xsltproc -o $@ support/Build/ToTargetMakefile.xsl $< - - - - : - - support/Build/ToTargetConfigFile.xsl - mkdir -p $(dir $@) - xsltproc -o $@ support/Build/ToTargetConfigFile.xsl $< - - - - : support/Build/ToOneTarget.xsl bin/.build/Makefile.expanded Makefile.build - mkdir -p $(dir $@) - xsltproc -o $@ -param nameTarget "' - - '" support/Build/ToOneTarget.xsl bin/.build/Makefile.expanded - - - - - - - .PHONY: - - - .packs - - - - - : - - - - .packs - : - .packs - - - - - - - - - - - @echo "+ - - [.packs]" - - - - - - - @echo "- - - [.pack|.vcxproj]" - - - - -.PHONY: _list -_list: - @echo "The defined targets (-) and groups of targets (+) are:" - - - @echo "+ - - [.packs]" - - - - - - - - .PHONY: - - - .packs - - - - - - - - diff --git a/support/Build/ToOneTarget.xsl b/support/Build/ToOneTarget.xsl deleted file mode 100644 index c4669a1..0000000 --- a/support/Build/ToOneTarget.xsl +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/support/Build/ToTargetConfigFile.xsl b/support/Build/ToTargetConfigFile.xsl deleted file mode 100644 index 47b6210..0000000 --- a/support/Build/ToTargetConfigFile.xsl +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - - - - #define - - - - - - - /* File generated by ToTargetConfigFile.xsl */ - - - - - - diff --git a/support/Build/ToTargetMakefile.xsl b/support/Build/ToTargetMakefile.xsl deleted file mode 100644 index 8947b91..0000000 --- a/support/Build/ToTargetMakefile.xsl +++ /dev/null @@ -1,298 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ifneq ($(UNAME_M),aarch64) -ifneq ($(UNAME_S),Darwin) - - - CFLAGS := $(CFLAGS) - - - - - endif -endif - - - - - - - - ifneq ($(UNAME_M),aarch64) -ifneq ($(UNAME_S),Darwin) - - - ASMFLAGS := $(ASMFLAGS) - - - - - endif -endif - - - - - - CFLAGS := $(CFLAGS) -D - - ="" - - - - - - - INCLUDEFLAGS := $(INCLUDEFLAGS) -I - - - - - - - - - HEADERS := $(HEADERS) - - - - SOURCES := $(SOURCES) - - - - - - - - - INCLUDES := $(INCLUDES) - - - - SOURCES := $(SOURCES) - - - - - - - - - -SOURCES := $(SOURCES) - - - - - $(BINDIR)/ - - - - .o - - - : - - $(HEADERS) $(INCLUDES) - - - - $(CC) $(INCLUDEFLAGS) $(ASMFLAGS) - - - $(CC) $(INCLUDEFLAGS) $(CFLAGS) - - - - -c $< -o $@ -OBJECTS := $(OBJECTS) - - - - - - - - - - - - - - - all: - - - - - : - - - - - .pack: - - - - - BINDIR = bin/.build/ - - -$(BINDIR): - mkdir -p $(BINDIR) - -MAKE ?= gmake -CC ?= gcc -AR = ar - -UNAME_S := $(shell uname -s) -ifeq ($(UNAME_S),Linux) - ASMFLAGS := -endif -ifeq ($(UNAME_S),Darwin) - ASMFLAGS := -x assembler-with-cpp -Wa,-defsym,old_gas_syntax=1 -Wa,-defsym,no_plt=1 -endif -ifneq (,$(findstring mingw32,$(CC))) - ASMFLAGS := -x assembler-with-cpp -Wa,-defsym,old_gas_syntax=1 -Wa,-defsym,no_plt=1 -endif -UNAME_M := $(shell uname -m) - - - - - CFLAGS := $(CFLAGS) -fpic - - - - HEADERS := $(HEADERS) - - - - - SOURCES := $(SOURCES) - - - - - INCLUDEFLAGS := $(INCLUDEFLAGS) -I - - - - - - - - - - -bin/ - - : $(BINDIR) $(OBJECTS) - mkdir -p $(dir $@) - - - - - mkdir -p $@.headers - cp -f $(HEADERS) $@.headers/ - $(AR) rcsv $@ $(OBJECTS) - - - - mkdir -p $@.headers - cp -f $(HEADERS) $@.headers/ - $(CC) -shared -o $@ $(OBJECTS) $(CFLAGS) - - - - mkdir -p $@.headers - cp -f $(HEADERS) $@.headers/ - $(CC) -dynamiclib -install_name @rpath/ - - $(OBJECTS) -o $@ - - - - $(CC) -o $@ $(OBJECTS) $(CFLAGS) - - - - - - - - - : $(SOURCES) - mkdir -p bin/.pack/ - - - rm -rf bin/.pack/ - - /* - cp $(SOURCES) bin/.pack/ - - / - cd bin/.pack/ ; tar -czf - - - - /* - - - - - diff --git a/support/Build/ToVCXProj.xsl b/support/Build/ToVCXProj.xsl deleted file mode 100644 index ca4f4dd..0000000 --- a/support/Build/ToVCXProj.xsl +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - - - - - - - - StaticLibrary - - - DynamicLibrary - - - Application - - - - - - - - - - Debug - Win32 - - - Debug - x64 - - - Debug - ARM64 - - - Release - Win32 - - - Release - x64 - - - Release - ARM64 - - - - {6F1C9407-7A01-444D-A07B-7DAE147F22A1} - XKCP - - - - MultiThreadedDebugDll - MultiThreadedDll - - - - true - v142 - MultiByte - - - - false - v142 - true - MultiByte - - - - - - - - - - - - - $(ProjectDir)\\$(Configuration)_$(Platform)\ - $(ProjectDir)\\$(Configuration)_$(Platform)\ - - - $(ProjectDir)\\$(Configuration)_$(Platform)\ - $(ProjectDir)\\$(Configuration)_$(Platform)\ - - - - $(RuntimeLibrary) - Level3 - Disabled - $(ProjectDir)\\config; - %(PreprocessorDefinitions) - - - - true - - - - - $(RuntimeLibrary) - Level3 - MaxSpeed - true - true - $(ProjectDir)\\config; - %(PreprocessorDefinitions) - - - - true - true - true - - - - - - - - - - - - - - - - - $(ProjectDir)..\..\ - - ; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - The file '' is a GCC assembly file and cannot be included in a Microsoft Visual Studio project. - - - - - - - - - ; - - - - - diff --git a/support/XKCBuild b/support/XKCBuild new file mode 160000 index 0000000..e395528 --- /dev/null +++ b/support/XKCBuild @@ -0,0 +1 @@ +Subproject commit e39552804c2cf65ef21d3a6b8e6e17281581a615