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

📄 makefile

📁 GNU Sed GNU Sed GNU Sed
💻
字号:
#
# Hacked up Nmake makefile for GNU Sed.
#
# TimF, ArdenW	17-Apr-92
#


# You must have a couple of environment variables set:
#
# 	BUILD_DEFAULT_TARGETS must be set to one of "-mips" or "-386",
#		Build for mips assumes r4000.
#
#	INC must ne set the full path to your NT .h files.
#
#	LIB must be set to the full path to your NT .lib files.
#		(coffbase.txt must be at $(LIB)\..\coffbase.txt
#
#
!IF "$(CPU)" == "i386"
BUILD_DEFAULT_TARGETS=-386
!ENDIF
!IF "$(CPU)" == "MIPS"
BUILD_DEFAULT_TARGETS=-mips
!ENDIF
INC=$(INCLUDE)

!IF "$(BUILD_DEFAULT_TARGETS)" == "-mips"
# Set up the compiler flags for building on mips

# I wonder how many of the flags aren't required for anything but building a
# kernel...

CFLAGS = -std -Wb,-dwalign -G 0 -std -checkstack 4096 -excpt -g0 -O -EL	\
	-c -Wab,-mips2 -Wab,-diag -DMIPS=1 -DNO_EXT_KEYS -DMIPSEL 	\
	-DCONDITION_HANDLING=1 -DNT_INST=0 -DNT_UP=1 -DJAZZ -DR4000

!ELSE
!IF "$(BUILD_DEFAULT_TARGETS)" == "-386"
# Set up the compiler flags for building on x86

CFLAGS = -nologo -Di386=1 -DCONDITION_HANDLING=1 -DNT_UP=1 -DNT_INST=0	\
	-DDBG=1 -DDEVL=1 -c -Zel -W4 -H63 -G3d -Ox -Zd

!ELSE
!ERROR You must specify BUILD_DEFAULT_TARGETS as either -386 or -mips.
!ENDIF
!ENDIF


!IFNDEF INC
!ERROR You need to set INC to the NT .h files directory.
!ELSE
INCP = -I. -I$(INC) -I$(INC)\crt
!ENDIF


!IFNDEF LIB
!ERROR You need to set LIB to the NT .lib files directory.
!ENDIF


GENERICFLAGS = -DWINDOWSNT=1 -DSTDC_HEADERS=1


NAME =	sed

TARGET= $(BLD)\$(NAME).exe
TLIB =	$(BLD)\$(NAME).lib
TOBJ =	$(BLD)\$(NAME).obj

BLD =	obj


OBJ =	$(BLD)\alloca.obj	\
	$(BLD)\getopt.obj	\
	$(BLD)\getopt1.obj	\
	$(BLD)\malloc.obj	\
	$(BLD)\regex.obj	\
	$(BLD)\utils.obj


LIBS =	$(TLIB)			\
	$(LIB)\setargv.obj	\
	$(LIB)\kernel32.lib	\
	$(LIB)\libc.lib		\
	$(LIB)\ntdll.lib


!IF "$(BUILD_DEFAULT_TARGETS)" == "-mips"
$(TARGET): $(LIBS) $(TOBJ)
	@- coff -LINK -out:$(TARGET) -debug:PARTIAL -machine:mips -subsystem:console -entry:mainCRTStartup $(TOBJ) $(LIBS)

$(TLIB): $(OBJ)
	@- coff -lib -out:$(TLIB) $**

.c{$(BLD)}.obj:
	@- if not exist $(BLD) md $(BLD) >nul 2>&1
	@- chmode -r $@ >nul 2>&1
	@- del $@ >nul 2>&1
	@- echo cc $<
	@- cc $(CFLAGS) $(GENERICFLAGS) $(INCP) -Olimit 1250 -o $@ $<
	@- mip2coff $@
!ELSE
$(TARGET): $(LIBS) $(TOBJ)
	link -out:$(TARGET) -debug:PARTIAL -machine:i386 -align:0x1000 -subsystem:console -entry:mainCRTStartup $(TOBJ) $(LIBS)

$(TLIB): $(OBJ)
	lib -out:$(TLIB) $**

.c{$(BLD)}.obj:
	@- if not exist $(BLD) md $(BLD) >nul 2>&1
	@- chmode -r $@ >nul 2>&1
	@- del $@ >nul 2>&1
	cl386 $(CFLAGS) $(GENERICFLAGS) $(INCP) -Fo$@ $<
	@- cvtomf $@
!ENDIF


⌨️ 快捷键说明

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