Annotation of nono/Makefile.inc, revision 1.1.1.1

1.1       root        1: #
                      2: # nono
                      3: # Copyright (C) 2018 [email protected]
                      4: #
                      5: 
                      6: .include "Makefile.cfg"
                      7: 
                      8: PROFOPT=       -g
                      9: #PROFOPT=      -g -pg
                     10: 
                     11: ## ASan for GCC
                     12: #PROFOPT+=     -fsanitize=address -fno-omit-frame-pointer -static-libstdc++
                     13: ## ASan for clang
                     14: #PROFOPT+=     -fsanitize=address -fno-omit-frame-pointer -O1
                     15: ## MSan for clang
                     16: #PROFOPT+=     -fsanitize=memory -fno-omit-frame-pointer -fno-optimize-sibling-calls -fsanitize-memory-track-origins=2 -O1
                     17: ## TSan
                     18: #PROFOPT+=     -fsanitize=thread
                     19: ## UBSan
                     20: #PROFOPT+=     -fsanitize=undefined
                     21: 
                     22: # CFLAGS は c/c++ 共通のコンパイルオプション
                     23: # CXXFLAGS は CFLAGS に追加する c++ 専用のコンパイルオプション
                     24: # CPPFLAGS は c/c++ 共通のプリプロセッサオプション
                     25: 
                     26: CXX+=          -std=c++11
                     27: 
                     28: CFLAGS+=       -O2
                     29: CFLAGS+=       ${PROFOPT}
                     30: CFLAGS+=       -Wall -Werror -Wshadow
                     31: CFLAGS+=       -Wno-sign-compare
                     32: CFLAGS+=       -Wno-unused-result
                     33: CFLAGS+=       -Wpointer-arith
                     34: 
                     35: .if ${NETDRIVER} == "tap"
                     36: CFLAGS+=       -DNETDRIVER_TAP
                     37: .endif
                     38: .if ${NETDRIVER} == "bpf"
                     39: CFLAGS+=       -DNETDRIVER_BPF
                     40: .endif
                     41: 
                     42: CXXFLAGS+=     -Wnon-virtual-dtor
                     43: 
                     44: LDFLAGS+=      ${PROFOPT}
                     45: 
                     46: # リンカに指定する引数
                     47: MYLIBS=        \
                     48:        ../vm/libnnvm.a \
                     49:        ../debugger/libnndebugger.a \
                     50:        ../m680x0/libnnm680x0.a \
                     51:        ../fpe/libnnfpe.a       \
                     52:        ../host/libnnhost.a \
                     53:        ../lib/libnnlib.a       \
                     54: 
                     55: all:   ${TARGETS}
                     56: 
                     57: .PHONY: clean
                     58: clean:
                     59:        rm -rf ${TARGETS} *.o ${CLEANFILES}
                     60: 
                     61: .PHONY: cleandir
                     62: cleandir:
                     63:        rm -rf .depends ${CLEANDIRFILES}
                     64: 
                     65: .PHONY: depend
                     66: .if "${CSRCS}" != "" || "${CXXSRCS}" != ""
                     67: .PHONY: ${CSRCS:.c=.d} ${CXXSRCS:.cpp=.d}
                     68: depend: ${CSRCS:.c=.d} ${CXXSRCS:.cpp=.d}
                     69:        cat ${.ALLSRC} > .depends
                     70:        rm -f *.d
                     71: .endif
                     72: 
                     73: .for f in ${CSRCS}
                     74: ${f:.c=.d}:
                     75:        ${CC} ${CPPFLAGS} -E -MM $f > $@
                     76: .endfor
                     77: .for f in ${CXXSRCS}
                     78: ${f:.cpp=.d}:
                     79:        ${CXX} ${CPPFLAGS} -E -MM $f > $@
                     80: .endfor
                     81: 
                     82: .if exists(${.CURDIR}/.depends)
                     83: .include "${.CURDIR}/.depends"
                     84: .endif
                     85: 
                     86: .c.o:
                     87:        ${CC} ${CFLAGS} ${CPPFLAGS} ${CFLAGS.$<} ${CPPFLAGS.$<} -c $< -o $@
                     88: 
                     89: .cpp.o:
                     90:        ${CXX} ${CXXFLAGS} ${CPPFLAGS} ${CXXFLAGS.$<} ${CPPFLAGS.$<} -c $< -o $@

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.