-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9e055e9
commit 2d15018
Showing
21 changed files
with
738 additions
and
37 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Alternative GNU Make workspace makefile autogenerated by Premake | ||
|
||
ifndef config | ||
config=debug | ||
endif | ||
|
||
ifndef verbose | ||
SILENT = @ | ||
endif | ||
|
||
ifeq ($(config),debug) | ||
bake_lang_c_config = debug | ||
|
||
else ifeq ($(config),release) | ||
bake_lang_c_config = release | ||
|
||
else | ||
$(error "invalid configuration $(config)") | ||
endif | ||
|
||
PROJECTS := bake_lang_c | ||
|
||
.PHONY: all clean help $(PROJECTS) | ||
|
||
all: $(PROJECTS) | ||
|
||
bake_lang_c: | ||
ifneq (,$(bake_lang_c_config)) | ||
@echo "==== Building bake_lang_c ($(bake_lang_c_config)) ====" | ||
@${MAKE} --no-print-directory -C . -f bake_lang_c.make config=$(bake_lang_c_config) | ||
endif | ||
|
||
clean: | ||
@${MAKE} --no-print-directory -C . -f bake_lang_c.make clean | ||
|
||
help: | ||
@echo "Usage: make [config=name] [target]" | ||
@echo "" | ||
@echo "CONFIGURATIONS:" | ||
@echo " debug" | ||
@echo " release" | ||
@echo "" | ||
@echo "TARGETS:" | ||
@echo " all (default)" | ||
@echo " clean" | ||
@echo " bake_lang_c" | ||
@echo "" | ||
@echo "For more information, see https://github.com/premake/premake-core/wiki" |
136 changes: 136 additions & 0 deletions
136
drivers/lang/c/build-MSYS_NT-10.0-22000/bake_lang_c.make
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
# Alternative GNU Make project makefile autogenerated by Premake | ||
|
||
ifndef config | ||
config=debug | ||
endif | ||
|
||
ifndef verbose | ||
SILENT = @ | ||
endif | ||
|
||
.PHONY: clean prebuild | ||
|
||
SHELLTYPE := posix | ||
ifeq (.exe,$(findstring .exe,$(ComSpec))) | ||
SHELLTYPE := msdos | ||
endif | ||
|
||
# Configurations | ||
# ############################################# | ||
|
||
RESCOMP = windres | ||
TARGETDIR = .. | ||
TARGET = $(TARGETDIR)/bake_lang_c.dll | ||
INCLUDES += -I.. -I"$(BAKE_HOME)/include" | ||
FORCE_INCLUDE += | ||
ALL_CPPFLAGS += $(CPPFLAGS) -MD -MP $(DEFINES) $(INCLUDES) | ||
ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES) | ||
LIBS += -lbake_util | ||
LDDEPS += | ||
LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS) | ||
define PREBUILDCMDS | ||
endef | ||
define PRELINKCMDS | ||
endef | ||
define POSTBUILDCMDS | ||
endef | ||
|
||
ifeq ($(config),debug) | ||
OBJDIR = ../.bake_cache/debug | ||
DEFINES += -DDEBUG | ||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -g | ||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -g | ||
ALL_LDFLAGS += $(LDFLAGS) -L"$(BAKE_HOME)/lib" -shared -Wl,--out-implib="../bake_lang_c.lib" | ||
|
||
else ifeq ($(config),release) | ||
OBJDIR = ../.bake_cache/release | ||
DEFINES += -DNDEBUG | ||
ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -O2 | ||
ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -O2 | ||
ALL_LDFLAGS += $(LDFLAGS) -L"$(BAKE_HOME)/lib" -shared -Wl,--out-implib="../bake_lang_c.lib" -s | ||
|
||
endif | ||
|
||
# Per File Configurations | ||
# ############################################# | ||
|
||
|
||
# File sets | ||
# ############################################# | ||
|
||
GENERATED := | ||
OBJECTS := | ||
|
||
GENERATED += $(OBJDIR)/main.o | ||
OBJECTS += $(OBJDIR)/main.o | ||
|
||
# Rules | ||
# ############################################# | ||
|
||
all: $(TARGET) | ||
@: | ||
|
||
$(TARGET): $(GENERATED) $(OBJECTS) $(LDDEPS) | $(TARGETDIR) | ||
$(PRELINKCMDS) | ||
@echo Linking bake_lang_c | ||
$(SILENT) $(LINKCMD) | ||
$(POSTBUILDCMDS) | ||
|
||
$(TARGETDIR): | ||
@echo Creating $(TARGETDIR) | ||
ifeq (posix,$(SHELLTYPE)) | ||
$(SILENT) mkdir -p $(TARGETDIR) | ||
else | ||
$(SILENT) mkdir $(subst /,\\,$(TARGETDIR)) | ||
endif | ||
|
||
$(OBJDIR): | ||
@echo Creating $(OBJDIR) | ||
ifeq (posix,$(SHELLTYPE)) | ||
$(SILENT) mkdir -p $(OBJDIR) | ||
else | ||
$(SILENT) mkdir $(subst /,\\,$(OBJDIR)) | ||
endif | ||
|
||
clean: | ||
@echo Cleaning bake_lang_c | ||
ifeq (posix,$(SHELLTYPE)) | ||
$(SILENT) rm -f $(TARGET) | ||
$(SILENT) rm -rf $(GENERATED) | ||
$(SILENT) rm -rf $(OBJDIR) | ||
else | ||
$(SILENT) if exist $(subst /,\\,$(TARGET)) del $(subst /,\\,$(TARGET)) | ||
$(SILENT) if exist $(subst /,\\,$(GENERATED)) del /s /q $(subst /,\\,$(GENERATED)) | ||
$(SILENT) if exist $(subst /,\\,$(OBJDIR)) rmdir /s /q $(subst /,\\,$(OBJDIR)) | ||
endif | ||
|
||
prebuild: | $(OBJDIR) | ||
$(PREBUILDCMDS) | ||
|
||
ifneq (,$(PCH)) | ||
$(OBJECTS): $(GCH) | $(PCH_PLACEHOLDER) | ||
$(GCH): $(PCH) | prebuild | ||
@echo $(notdir $<) | ||
$(SILENT) $(CC) -x c-header $(ALL_CFLAGS) -o "$@" -MF "$(@:%.gch=%.d)" -c "$<" | ||
$(PCH_PLACEHOLDER): $(GCH) | $(OBJDIR) | ||
ifeq (posix,$(SHELLTYPE)) | ||
$(SILENT) touch "$@" | ||
else | ||
$(SILENT) echo $null >> "$@" | ||
endif | ||
else | ||
$(OBJECTS): | prebuild | ||
endif | ||
|
||
|
||
# File Rules | ||
# ############################################# | ||
|
||
$(OBJDIR)/main.o: ../src/main.c | ||
@echo "$(notdir $<)" | ||
$(SILENT) $(CC) $(ALL_CFLAGS) $(FORCE_INCLUDE) -o "$@" -MF "$(@:%.o=%.d)" -c "$<" | ||
|
||
-include $(OBJECTS:%.o=%.d) | ||
ifneq (,$(PCH)) | ||
-include $(PCH_PLACEHOLDER).d | ||
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
rm -rf build-Darwin | ||
rm -rf build-Linux | ||
rm -rf build-MSYS_NT-10.0-22000 | ||
../../../../premake5 --os=macosx gmake | ||
mv build build-Darwin | ||
../../../../premake5 --os=linux gmake | ||
mv build build-Linux | ||
../../../../premake5 --os=windows gmake2 | ||
mv build build-MSYS_NT-10.0-22000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Alternative GNU Make workspace makefile autogenerated by Premake | ||
|
||
ifndef config | ||
config=debug | ||
endif | ||
|
||
ifndef verbose | ||
SILENT = @ | ||
endif | ||
|
||
ifeq ($(config),debug) | ||
bake_lang_cpp_config = debug | ||
|
||
else ifeq ($(config),release) | ||
bake_lang_cpp_config = release | ||
|
||
else | ||
$(error "invalid configuration $(config)") | ||
endif | ||
|
||
PROJECTS := bake_lang_cpp | ||
|
||
.PHONY: all clean help $(PROJECTS) | ||
|
||
all: $(PROJECTS) | ||
|
||
bake_lang_cpp: | ||
ifneq (,$(bake_lang_cpp_config)) | ||
@echo "==== Building bake_lang_cpp ($(bake_lang_cpp_config)) ====" | ||
@${MAKE} --no-print-directory -C . -f bake_lang_cpp.make config=$(bake_lang_cpp_config) | ||
endif | ||
|
||
clean: | ||
@${MAKE} --no-print-directory -C . -f bake_lang_cpp.make clean | ||
|
||
help: | ||
@echo "Usage: make [config=name] [target]" | ||
@echo "" | ||
@echo "CONFIGURATIONS:" | ||
@echo " debug" | ||
@echo " release" | ||
@echo "" | ||
@echo "TARGETS:" | ||
@echo " all (default)" | ||
@echo " clean" | ||
@echo " bake_lang_cpp" | ||
@echo "" | ||
@echo "For more information, see https://github.com/premake/premake-core/wiki" |
Oops, something went wrong.