Skip to content
Snippets Groups Projects
Commit 102a8094 authored by Recolic Keghart's avatar Recolic Keghart
Browse files

Fix problems in nemu makefile, & remove shitting git-log-auto-pollution logic in nemu/Makefile.git.

parent d041c903
No related branches found
No related tags found
No related merge requests found
...@@ -16,10 +16,10 @@ include Makefile.git ...@@ -16,10 +16,10 @@ include Makefile.git
.DEFAULT_GOAL = app .DEFAULT_GOAL = app
# Compilation flags # Compilation flags
CC = gcc CC ?= gcc
LD = gcc LD = $(CC)
INCLUDES = $(addprefix -I, $(INC_DIR)) INCLUDES = $(addprefix -I, $(INC_DIR))
CFLAGS += -O2 -MMD -Wall -Werror -ggdb3 $(INCLUDES) -fomit-frame-pointer CFLAGS += -O2 -MMD -Wall -ggdb3 $(INCLUDES) -fomit-frame-pointer
CFLAGS += -DDIFF_TEST_QEMU CFLAGS += -DDIFF_TEST_QEMU
# Files to be compiled # Files to be compiled
...@@ -30,7 +30,7 @@ OBJS = $(SRCS:src/%.c=$(OBJ_DIR)/%.o) ...@@ -30,7 +30,7 @@ OBJS = $(SRCS:src/%.c=$(OBJ_DIR)/%.o)
$(OBJ_DIR)/%.o: src/%.c $(OBJ_DIR)/%.o: src/%.c
@echo + CC $< @echo + CC $<
@mkdir -p $(dir $@) @mkdir -p $(dir $@)
@$(CC) $(CFLAGS) $(SO_CFLAGS) -c -o $@ $< $(CC) $(CFLAGS) $(SO_CFLAGS) -c -o $@ $<
# Uncomment the below assignment for test # Uncomment the below assignment for test
# TESTCASE=dummy # TESTCASE=dummy
......
STUID = 171220000 STUID = U201614531
STUNAME = 张三 STUNAME = 刘本嵩
# DO NOT modify the following code!!! # DO NOT modify the following code!!!
GITFLAGS = -q --author='tracer-ics2018 <tracer@njuics.org>' --no-verify --allow-empty GITFLAGS = -q --author='tracer-ics2018 <tracer@njuics.org>' --no-verify --allow-empty
# prototype: git_commit(msg) # prototype: git_commit(msg)
define git_commit define git_commit_origin
-@git add .. -A --ignore-errors -@echo Generating HUST commit: "> $(1)"
# -@git add .. -A --ignore-errors
-@while (test -e .git/index.lock); do sleep 0.1; done -@while (test -e .git/index.lock); do sleep 0.1; done
-@(echo "> $(1)" && echo $(STUID) && id -un && uname -a && uptime && (head -c 20 /dev/urandom | hexdump -v -e '"%02x"') && echo) | git commit -F - $(GITFLAGS) -@(echo "> $(1)" && echo $(STUID) && id -un && uname -a && uptime && (head -c 20 /dev/urandom | hexdump -v -e '"%02x"') && echo) | git commit -F - $(GITFLAGS)
-@sync -@sync
endef endef
define git_commit
-@echo Recolic helped you to prevent fucking junks!
endef
git_gen:
ifeq ($(M),)
@echo 'Usage: make git_gen M="Some message"'
@echo ' or: env M="Some message" make git_gen'
else
$(call git_commit_origin, "Manual commit: " $(M))
endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment