Makefile revision 3f54fd611f536639ec30dd53c48e5ec1897cc7d9
132N/A/*
132N/A * standalone versions of -lcmd builtins
132N/A */
132N/A
132N/A:PACKAGE: ast cmd:space
132N/A
132N/ALICENSE = since=1992,author=gsf+dgk
132N/A
132N/A:ALL:
132N/A
132N/A:: cmdlib.h builtin.c
132N/A
132N/ACMD_BUILTIN ==
132N/ACMD_DYNAMIC ==
132N/ACMD_STANDALONE ==
132N/A
132N/ALINKS = cp: ln mv cksum: md5sum sum
132N/ANOBIN = getconf
132N/A
132N/ACAT = $(STDCAT|"cat")
1149N/ACMP = $(STDCMP|"cmp") 2>/dev/null
132N/ACP = $(STDCP|"cp")
132N/ALN = $(STDLN|"ln")
215N/ARM = $(STDRM|"rm")
132N/A
1215N/ABUILTINS :COMMAND: cmdlist.h
1215N/A $(SED) -e '/^CMDLIST(.*)$/!d' -e 's/CMDLIST(\(.*\))/\1/' $(NOBIN:C,.*,-e '/^&$/d',) $(LINKS:N!=*[:]:C,.*,-e '/^&$/d',) $(*)
1318N/A
1176N/A.INIT : .builtin
132N/A
132N/A.builtin : .MAKE .VIRTUAL .FORCE
132N/A local T I
132N/A if T = "$(NOBIN:D=$(BINDIR):B:S:T=F)"
132N/A { $(RM) $(RMFLAGS) $(T) }
132N/A end
132N/A :ALL: $(BUILTINS)
132N/A T = -lcmd
132N/A if "$(PACKAGE_OPTIONS:N=optimize-space)" && "$(T:T=F)" == "-lcmd"
132N/A T := $(BUILTINS:O=1)
132N/A $(T) :: CMD_BUILTIN=1 CMD_DYNAMIC=1 builtin.c -lcmd -ldll
132N/A for I $(BUILTINS:O>1)
132N/A $(I) :LINK: $(T)
132N/A end
132N/A for I $(LINKS)
132N/A if I != "*:"
132N/A $(I) :LINK: $(T)
132N/A end
132N/A end
132N/A else
132N/A $(BINDIR) :INSTALLDIR: $(BUILTINS)
132N/A $(BUILTINS) : .COMMAND $(&$("%.c":T=SM%)) CMD_BUILTIN=b_$$(<:B) builtin.c $(*$("%.c":T=SM%))
132N/A $(CAT) $(*:N=*builtin.c) > $(<).c
132N/A $(RM) $(RMFLAGS) $(<)
132N/A $(@$("%.c":T=SM%):/.*builtin.c$/$(<).c/)
132N/A $(RM) $(RMFLAGS) $(<).c
132N/A for I $(LINKS)
132N/A if I == "*:"
132N/A T := $(I:/.$//)
132N/A else
132N/A $(I) :LINK: $(T)
132N/A end
132N/A end
132N/A end
132N/A
132N/A":BUILTIN:" : .MAKE .OPERATOR
132N/A local T P
132N/A for T $(>)
132N/A if T == "*=*"
132N/A $(P).o : $(T)
132N/A elif T == "[-+]l*"
132N/A $(P) : $(T)
132N/A else
132N/A eval
132N/A $(T) :: CMD_STANDALONE=b_$(T) $(T).c
132N/A end
132N/A P := $(T)
132N/A end
132N/A end
132N/A
132N/A:BUILTIN: dlls LICENSE=since=2002,author=gsf -ldll look mime \
132N/A pty LICENSE=since=2001,author=gsf+dgk -lutil \
132N/A nl LICENSE=since=2003,author=dgk asa od pr \
132N/A strings tr uudecode -luu uuencode -luu what who
132N/A
132N/Adontcare -lutil
132N/A
132N/A:: PROMO.mm RELEASE
132N/A
132N/A:TEST: asa cat chmod chown cksum cmp cp cut date expr fmt head join ln \
132N/A look mkdir mkfifo mktemp mv nl od paste rm tail tr uniq uuencode wc
132N/A