Merge commit '1531d6e543
' as 'gitstatus'
This commit is contained in:
commit
97fac973af
62 changed files with 9401 additions and 0 deletions
36
gitstatus/Makefile
Normal file
36
gitstatus/Makefile
Normal file
|
@ -0,0 +1,36 @@
|
|||
APPNAME ?= gitstatusd
|
||||
OBJDIR ?= obj
|
||||
|
||||
CXX ?= g++
|
||||
|
||||
VERSION ?= $(shell . ./build.info && printf "%s" "$$gitstatus_version")
|
||||
|
||||
# Note: -fsized-deallocation is not used to avoid binary compatibility issues on macOS.
|
||||
#
|
||||
# Sized delete is implemented as __ZdlPvm in /usr/lib/libc++.1.dylib but this symbol is
|
||||
# missing in macOS prior to 10.13.
|
||||
CXXFLAGS += -std=c++14 -funsigned-char -O3 -DNDEBUG -DGITSTATUS_VERSION=$(VERSION) -Wall -Werror # -g -fsanitize=thread
|
||||
LDFLAGS += -pthread # -fsanitize=thread
|
||||
LDLIBS += -lgit2 # -lprofiler -lunwind
|
||||
|
||||
SRCS := $(shell find src -name "*.cc")
|
||||
OBJS := $(patsubst src/%.cc, $(OBJDIR)/%.o, $(SRCS))
|
||||
|
||||
all: $(APPNAME)
|
||||
|
||||
$(APPNAME): usrbin/$(APPNAME)
|
||||
|
||||
usrbin/$(APPNAME): $(OBJS)
|
||||
$(CXX) $(OBJS) $(LDFLAGS) $(LDLIBS) -o $@
|
||||
|
||||
$(OBJDIR):
|
||||
mkdir -p -- $(OBJDIR)
|
||||
|
||||
$(OBJDIR)/%.o: src/%.cc Makefile build.info | $(OBJDIR)
|
||||
$(CXX) $(CXXFLAGS) -MM -MT $@ src/$*.cc >$(OBJDIR)/$*.dep
|
||||
$(CXX) $(CXXFLAGS) -Wall -c -o $@ src/$*.cc
|
||||
|
||||
clean:
|
||||
rm -rf -- $(OBJDIR)
|
||||
|
||||
-include $(OBJS:.o=.dep)
|
Loading…
Add table
Add a link
Reference in a new issue