⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 makefile

📁 No7信令,我需要交换类似的代码, 请店长审核,谢谢了,急着交换,谢谢
💻
字号:
# =============================================================================# # @(#) Makefile,v 0.7.8.2 2001/12/11 13:31:19 brian Exp# # -----------------------------------------------------------------------------# # Copyright (C) 2001  OpenSS7 Corporation <http://www.openss7.com># # All Rights Reserved.# # This program is free software; you can redistribute it and/or modify it under# the terms of the GNU General Public License as published by the Free Software# Foundation; either version 2 of the License, or (at your option) any later# version.# # This program is distributed in the hope that it will be useful, but WITHOUT# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more# details.# # You should have received a copy of the GNU General Public License along with# this program; if not, write to the Free Software Foundation, Inc., 675 Mass# Ave, Cambridge, MA 02139, USA.# # -----------------------------------------------------------------------------# # U.S. GOVERNMENT RESTRICTED RIGHTS.  If you are licensing this Software on# behalf of the U.S. Government ("Government"), the following provisions apply# to you.  If the Software is supplied by the Department of Defense ("DoD"), it# is classified as "Commercial Computer Software" under paragraph 252.227-7014# of the DoD Supplement to the Federal Acquisition Regulations ("DFARS") (or any# successor regulations) and the Government is acquiring only the license rights# granted herein (the license rights customarily provided to non-Government# users).  If the Software is supplied to any unit or agency of the Government# other than DoD, it is classified as "Restricted Computer Software" and the# Government's rights in the Software are defined in paragraph 52.227-19 of the# Federal Acquisition Regulations ("FAR") (or any success regulations) or, in# the cases of NASA, in paragraph 18.52.227-86 of the NASA Supplement to the FAR# (or any successor regulations).# # -----------------------------------------------------------------------------# # Last Modified 2001/12/11 13:31:19 by brian## =============================================================================-include /usr/src/LiS/config.in-include ../../.config.inINCDIR ?= $(shell ( cd ../../include; pwd ))SRCDIR ?= $(shell ( pwd ))LIS_HOME ?= /usr/src/LiSLIS_INCL ?= $(LIS_HOME)/includeSCTP_N_CMAJOR ?= 230SCTP_T_CMAJOR ?= 231MODCONF ?= /etc/conf.modulesINCLUDES = \    -I$(INCDIR) \    -I$(LIS_INCL) \    -I/usr/src/linux/include \    -I/usr/include \MAKEFILE = MakefileCOFLAGS = -lOFLAGS ?= \    -O2 \DFLAGS ?= \    -D_SAFE \WFLAGS ?= \    -Wall \    -Wunused \    -Wpointer-arith \    -Wcast-qual \    -Wcast-align \    -Waggregate-return \    -Wnested-externs \    -Winline \    -Wold-style-cast \    -finline \    -finline-functions \    -fno-keep-inline-functions \    -fomit-frame-pointer \    -fno-strict-aliasing#    -Werror \#    -Wbad-function-cast \MFLAGS ?= \    -m486 \    -malign-loops=2 \    -malign-jumps=2 \    -malign-functions=2 \CFLAGS = \    -DLINUX \    -D__KERNEL__ \    -DMODULE \    -DMODVERSIONS \    $(OFLAGS) \    $(WFLAGS) \    $(INCLUDES) \    -pipe \    -DSCTP_N_CMAJOR=$(SCTP_N_CMAJOR)    -DSCTP_T_CMAJOR=$(SCTP_T_CMAJOR)CCFLAGS = \    -nostdlib \    -D__KERNEL__ \    -DMODULE \    -DMODVERSIONS \    -DEXPORT_SYMTAB \    $(OFLAGS) \    -W \    -Wall \    -Winline \    $(INCLUDES) \CC ?= gccCCC = g++%_i.c : %.c ; $(CC) -E $(DFLAGS) $(CFLAGS) $< | sed -e "/^ *$$/d" > $@%.s : %.c ; $(CC) -S $(DFLAGS) $(CFLAGS) $< -o $@%.o : %.c ; $(CC) -c $(DFLAGS) $(CFLAGS) $< -o $@%_i.cc : %.cc ; $(CCC) -E $(DFLAGS) $(CCFLAGS) $< | sed -e "/^ *$$/d" > $@%.s : %.cc ; $(CCC) -S $(DFLAGS) $(CCFLAGS) $< -o $@%.o : %.cc ; $(CCC) -c $(DFLAGS) $(CCFLAGS) $< -o $@# Extract version number from headers.VER = $(shell awk -F\" '/REL/ {print $$2}' /usr/src/linux/include/linux/version.h)XCCP =XPRG =CTST =TSTS =OBJS = $(TSTS) $(CTST) $(XPRG) $(XCPP)BINS = sctp_input.o sctp_output.o sctp_n.o sctp_t.o sctp.o sctp_cookie.o sctp_hash.o sctp_cache.o sctp_route.o sctp_msg.oSRCS = sctp_input.c sctp_output.c sctp_n.c sctp_t.c sctp.c sctp_cookie.c sctp_hash.c sctp_cache.c sctp_route.c sctp_msg.cINCS = sctp_input.h sctp_output.h sctp_n.h sctp_t.h sctp.h sctp_cookie.h sctp_hash.h sctp_cache.h sctp_route.h sctp_msg.h \       sctp_debug.h sctp_bufq.h sctp_defs.hRMES = # README.thingstodo README.planCVSS = $(SRCS) $(INCS) $(RMES) $(TSTS:%=%.c) $(XPRG:%=%.c) $(CTST:%=%.cc) $(XCPP:%=%.cc) $(MAKEFILE)LOGS = $(CVSS:%=%.log)all:: streams-sctp.o tags#$(CVSS):#	cvs update $@#$(SRCS): $(MAKEFILE)#$(INCS): $(MAKEFILE)streams-sctp.o: $(BINS)	$(LD) -r $^ -o $@$(XCPP): %: %.cc	$(CCC) -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib -lXaw -lc $< -o $@$(XCPP:%=%.s): %.s: %.cc	$(CCC) -S -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib $< -o $@$(XCPP:%=%_i.cc): %_i.cc: %.cc	$(CCC) -E -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib $< | sed -e "/^ *$$/d" > $@$(XPRG): %: %.c	$(CC) -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib -lXaw -lc $< -o $@$(XPRG:%=%.s): %.s: %.c	$(CC) -S -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib $< -o $@$(XPRG:%=%_i.c): %_i.c: %.c	$(CC) -E -Wall -ggdb $(OFLAGS) -I/usr/X11/include -L/usr/X11/lib $< | sed -e "/^ *$$/d" > $@$(TSTS): %: %.c	$(CC) -Wall -ggdb $(OFLAGS) -lpanel -lncurses $< -o $@$(TSTS:%=%.s): %.s: %.c	$(CC) -S -Wall -ggdb $(OFLAGS) $< -o $@$(TSTS:%=%_i.c): %_i.c: %.c	$(CC) -E -Wall -ggdb $(OFLAGS) $< | sed -e "/^ *$$/d" >  $@$(CTST): %: %.cc	$(CCC) -Wall -ggdb $(OFLAGS) -lpanel -lncurses $< -o $@$(CTST:%=%.s): %.s: %.cc	$(CCC) -S -Wall -ggdb $(OFLAGS) $< -o $@$(CTST:%=%_i.cc): %_i.cc: %.cc	$(CCC) -E -Wall -ggdb $(OFLAGS) $< | sed -e "/^ *$$/d" > $@assem:: $(BINS:%.o=%.s) $(TSTS:%=%.s) $(CTST:%=%.s) $(XPRG:%=%.s) $(XCPP:%=%.s)prep:: $(BINS:%.o=%_i.c) $(TSTS:%=%_i.c) $(CTST:%=%_i.ci) $(XPRG:%=%_i.c) $(XCPP:%=%_i.cc)tags: $(SRCS) $(INCS) $(wildcard $(INCDIR)/sys/*.h)	ctags $(SRCS) $(INCS) $(wildcard $(INCDIR)/sys/*.h)$(LOGS): %.log: %	cvs log $< | sed -e "1d" > $@logs:: $(LOGS)$(MAKEFILE): $(SRCS) $(INCS)	mv $(MAKEFILE) $(MAKEFILE).bak	cat $(MAKEFILE).bak | sed -e "/^# Depend/,$$ d" > $(MAKEFILE)	echo "# Dependencies" >> $(MAKEFILE)	echo "" >> $(MAKEFILE)	for i in $(SRCS); do $(CC) -MM $(INCLUDES) $(MOREINCLUDE) $(CFLAGS) $$i >> $(MAKEFILE); done	for i in $(CTST); do $(CCC) -MM $$i.cc | sed -e "s/\.o:/:/" >> $(MAKEFILE); done	for i in $(TSTS); do $(CC) -MM $$i.c | sed -e "s/\.o:/:/" >> $(MAKEFILE); done	for i in $(XPRG); do $(CC) -MM -I/usr/X11/include $$i.c | sed -e "s/\.o:/:/" >> $(MAKEFILE); done	for i in $(XCPP); do $(CC) -MM -I/usr/X11/include $$i.cc | sed -e "s/\.o:/:/" >> $(MAKEFILE); done#	mv $(MAKEFILE) $(MAKEFILE)~#	cat $(MAKEFILE)~ | sed -e "/^# Depend/,$$ s/:/: $(MAKEFILE)/" > $(MAKEFILE)#	rm $(MAKEFILE)~depend:: $(MAKEFILE)root-check::	@ if [ $$(id -u) -ne 0 ]; then \	    echo -e "\nYou must be superuser to install!\n"; \	    exit 1; \	fiinstall-headers:: root-check	install -C $(INCDIR)/sys/xti_ip.h   $(LIS_INCL)/sys	install -C $(INCDIR)/sys/xti_sctp.h $(LIS_INCL)/sys	install -C $(INCDIR)/sys/npi.h      $(LIS_INCL)/sys	install -C $(INCDIR)/sys/npi_sctp.h $(LIS_INCL)/sys	install -C $(INCDIR)/sys/tpi.h      $(LIS_INCL)/sys	install -C $(INCDIR)/sys/tpi_sctp.h $(LIS_INCL)/sysinstall:: install-headers streams-sctp.o	install -d /lib/modules/$(VER)/misc /lib/modules/misc	install -c streams-sctp.o /lib/modules/$(VER)/misc	install -c streams-sctp.o /lib/modules/misc	rm -f /dev/sctp_n; mknod -m 666 /dev/sctp_n c $(SCTP_N_CMAJOR) 0	rm -f /dev/sctp_t; mknod -m 666 /dev/sctp_t c $(SCTP_T_CMAJOR) 0	@ cat $(MODCONF) | sed -e "/^[ \t]*alias[ \t]*char-major-\($(SCTP_N_CMAJOR)\|$(SCTP_T_CMAJOR)\)/d" > $(MODCONF).new	@ echo "alias char-major-$(SCTP_N_CMAJOR)  streams-sctp                # driver sctp npi" >> $(MODCONF).new	@ echo "alias char-major-$(SCTP_T_CMAJOR)  streams-sctp                # driver sctp tpi" >> $(MODCONF).new	@ mv -fb $(MODCONF).new $(MODCONF)	depmod -a	@ if grep "streams-sctp" /proc/modules >/dev/null; then \		rmmod streams-sctp; \	ficlean::	rm -f *.o *.s *_i.c *_i.cc *.log *~ core $(TSTS) $(CTST) $(XPRG) $(XCPP) $(MAKEFILE).bakrealclean::	cvs commit	rm -f $(SRCS) $(INCS) $(RMES) $(BINS) $(OBJS) \		$(BINS:%.o=%.s) $(BINS:%.o=%_i.c) \		$(MAKEFILE).bak *~ core \	$(TSTS) $(TSTS:%=%.c) $(TSTS:%=%.s) $(TSTS:%=%_i.c) \	$(XPRG) $(XPRG:%=%.c) $(XPRG:%=%.s) $(XPRG:%=%_i.c) \	$(XCPP) $(XCPP:%=%.cc) $(XCPP:%=%.s) $(XCPP:%=%_i.cc) \	$(CTST) $(CTST:%=%.cc) $(CTST:%=%.s) $(CTST:%=%_i.cc).lines:   $(SRCS) $(INCS) $(MAKEFILE)	cat $^ | wc -l > .lines	cat .lines# Dependenciessctp_input.o: sctp_input.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_route.h sctp_msg.h sctp_input.h \  sctp_output.hsctp_output.o: sctp_output.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_route.h sctp_msg.h sctp_output.hsctp_n.o: sctp_n.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_msg.h sctp_n.hsctp_t.o: sctp_t.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_msg.h sctp_t.hsctp.o: sctp.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h sctp_hash.h \  sctp_cache.h sctp_n.h sctp_t.h sctp_input.hsctp_cookie.o: sctp_cookie.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_cookie.hsctp_hash.o: sctp_hash.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_cache.h sctp_hash.hsctp_cache.o: sctp_cache.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_msg.hsctp_route.o: sctp_route.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_cache.h sctp_route.h sctp_output.hsctp_msg.o: sctp_msg.c sctp_debug.h sctp_bufq.h sctp.h sctp_defs.h \  sctp_hash.h sctp_cache.h sctp_route.h sctp_cookie.h sctp_output.h \  sctp_msg.h

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -