<NME> Makefile
<BEF> COMMONFLAGS := -W -Wall -W -Werror -MMD -MP -O -g -Wno-missing-field-initializers
CFLAGS := -std=gnu99 $(COMMONFLAGS) -Wno-missing-field-initializers
CXXFLAGS := -std=c++11 $(COMMONFLAGS)

uname := $(shell uname)
ifneq (,$(findstring arm,$(shell uname -m)))
ARCH := arm
else
ARCH := x86
endif

ELI := out/eli
ELC := out/elc
8CC := out/8cc
8CC_SRCS := \
	8cc/buffer.c \
	8cc/cpp.c \
	8cc/debug.c \
	8cc/dict.c \
	8cc/encoding.c \
	8cc/error.c \
	8cc/file.c \
	8cc/gen.c \
	8cc/lex.c \
	8cc/main.c \
	8cc/map.c \
	8cc/parse.c \
	8cc/path.c \
	8cc/set.c \
	8cc/vector.c

BINS := $(8CC) $(ELI) $(ELC) out/dump_ir out/befunge out/bfopt out/cmake_putc_helper out/subleq out/whirl
LIB_IR_SRCS := ir/ir.c ir/table.c
LIB_IR := $(LIB_IR_SRCS:ir/%.c=out/%.o)

ELC_EIR := out/elc.c.eir.c.gcc.exe

all: build
	@echo ''
	@echo 'Now you have tools such as out/8cc and out/elc'
	@echo ''
	@echo 'Use following targets to build/run tests for backend xxx:'
	@echo ''
	@echo '- `make build-xxx`: Compile all tests to xxx backend'
	@echo '   (e.g., out/lisp.c.eir.xxx will be built from test/lisp.c)'
	@echo '- `make test-xxx` or `make xxx`: Run tests for xxx backend'
	@echo '   (e.g., out/lisp.c.eir.xxx.out.diff will be output)'
	@echo '- `make test-xxx-full`: Run target/xxx.c on ELVM'
	@echo '   (this checks if the target xxx can self-host)'
	@echo '- `make test`: Build and run all tests'
	@echo '   (WARNING: will take a lot of time/disk)'
	@echo ''

out/git_submodule.stamp: .git/index
	git submodule update --init
	touch $@

$(8CC_SRCS) lci/install.py Whitespace/whitespace.c tinycc/configure: out/git_submodule.stamp

Whitespace/whitespace.out: Whitespace/whitespace.c
	$(MAKE) -C Whitespace 'MAX_SOURCE_SIZE:=100000000' 'MAX_BYTECODE_SIZE:=16777216' 'MAX_N_LABEL:=1048576' 'HEAP_SIZE:=16777224' 'STACK_SIZE:=16777224'

lci/lci: lci/install.py
	cd lci && python ./install.py || test -e lci

out/befunge: tools/befunge.cc
	$(CXX) $(CXXFLAGS) $< -o $@

out/bfopt: tools/bfopt.cc
	$(CXX) $(CXXFLAGS) $< -o $@

out/cmake_putc_helper: tools/cmake_putc_helper.c
	$(CC) $(CFLAGS) $< -o $@

out/subleq: tools/subleq.c
	$(CC) $(CFLAGS) $< -o $@

out/tm: tools/tm.c
	$(CC) $(CFLAGS) $< -o $@

out/whirl: tools/whirl.cc
	$(CXX) $(CXXFLAGS) $< -o $@

out/wmc: tools/wmc/Cargo.toml
	cargo +nightly -Z unstable-options build --manifest-path $< --out-dir $@ --target-dir $@/obj

tinycc/tcc: tinycc/config.h
	$(MAKE) -C tinycc tcc libtcc1.a

tinycc/config.h: tinycc/configure
	cd tinycc && ./configure

out/elc.c.eir.c.gcc.exe: out/elc.c.eir.c
	$(CC) -o $@ $<

CSRCS := $(LIB_IR_SRCS) ir/dump_ir.c ir/eli.c
COBJS := $(addprefix out/,$(notdir $(CSRCS:.c=.o)))
$(COBJS): out/%.o: ir/%.c
	$(CC) -c -I. $(CFLAGS) $< -o $@

ELC_SRCS := \
	elc.c \
	util.c \
	asmjs.c \
	arm.c \
	awk.c \
	bef.c \
	bf.c \
	blc.c \
	c.c \
	cl.c \
	cmake.c \
	cpp.c \
	cpp_template.c \
	cr.c \
	cs.c \
	el.c \
	forth.c \
	f90.c \
	fs.c \
	go.c \
	hell.c \
	hs.c \
	i.c \
	j.c \
	java.c \
	js.c \
	kx.c \
	lam.c \
	lazy.c \
	lua.c \
	ll.c \
	lol.c \
	mcfunction.c \
	oct.c \
	php.c \
	piet.c \
	pietasm.c \
	pl.c \
	py.c \
	ps.c \
	qftasm.c \
	rb.c \
	rs.c \
	sed.c \
	sh.c \
	sqlite3.c \
	scala.c \
	scm_sr.c \
	scratch3.c \
	subleq.c \
	swift.c \
	tcl.c \
	tex.c \
	tf.c \
	tm.c \
	ulamb.c \
	unl.c \
	vim.c \
	w.c \
	wasi.c \
	wasm.c \
	whirl.c \
	wm.c \
	ws.c \
	x86.c \

ELC_SRCS := $(addprefix target/,$(ELC_SRCS))
COBJS := $(addprefix out/,$(notdir $(ELC_SRCS:.c=.o)))
$(COBJS): out/%.o: target/%.c
	$(CC) -c -I. $(CFLAGS) $< -o $@

out/dump_ir: $(LIB_IR) out/dump_ir.o
	$(CC) $(CFLAGS) -DTEST $^ -o $@

$(ELI): $(LIB_IR) out/eli.o
	$(CC) $(CFLAGS) $^ -o $@

$(ELC): $(LIB_IR) $(ELC_SRCS:target/%.c=out/%.o)
	$(CC) $(CFLAGS) $^ -o $@

$(8CC): $(8CC_SRCS)
	$(MAKE) -C 8cc && cp 8cc/8cc $@

# Stage tests

$(shell mkdir -p out)
TEST_RESULTS :=

SRCS := $(sort $(wildcard test/*.eir))
DSTS := $(SRCS:test/%.eir=out/%.eir)
OUT.eir := $(DSTS)
$(DSTS): out/%.eir: test/%.eir
	cp $< $@.tmp && mv $@.tmp $@

SRCS := $(wildcard test/*.eir.rb)
DSTS := $(SRCS:test/%.eir.rb=out/%.eir)
OUT.eir += $(DSTS)
$(DSTS): out/%.eir: test/%.eir.rb
	ruby $< > $@.tmp && mv $@.tmp $@

SRCS := $(wildcard test/*.c)
DSTS := $(SRCS:test/%.c=out/%.c)
$(DSTS): out/%.c: test/%.c
	cp $< $@.tmp && mv $@.tmp $@
OUT.c := $(SRCS:test/%.c=out/%.c)

out/8cc.c: $(8CC_SRCS)
	cp 8cc/*.h 8cc/*.inc 8cc/include/*.h out
	cat $(8CC_SRCS) > $@.tmp && mv $@.tmp $@
OUT.c += out/8cc.c

out/elc.c: $(ELC_SRCS) $(LIB_IR_SRCS)
	cat $^ > $@.tmp && mv $@.tmp $@
OUT.c += out/elc.c

out/dump_ir.c: ir/dump_ir.c $(LIB_IR_SRCS)
	cat $^ > $@.tmp && mv $@.tmp $@
OUT.c += out/dump_ir.c

out/eli.c: ir/eli.c $(LIB_IR_SRCS)
	cat $^ > $@.tmp && mv $@.tmp $@
OUT.c += out/eli.c

# Build tests

TEST_INS := $(wildcard test/*.in)

include clear_vars.mk
SRCS := $(OUT.c)
EXT := exe
CMD = $(CC) -std=gnu99 -DNOFILE -include libc/_builtin.h -I. $2 -o $1
OUT.c.exe := $(SRCS:%=%.$(EXT))
include build.mk

include clear_vars.mk
SRCS := $(filter-out out/8cc.c.exe,$(OUT.c.exe))
EXT := out
DEPS := $(TEST_INS) runtest.sh
CMD = ./runtest.sh $1 $2
include build.mk

include clear_vars.mk
SRCS := out/8cc.c.exe
EXT := out
DEPS := $(TEST_INS)
# TODO: Hacky!
sharp := \#
CMD = $2 -S -o $1.S.tmp - < test/8cc.in.c && sed 's/ *$(sharp) .*//' $1.S.tmp > $1.S && (echo === test/8cc.in === && cat $1.S && echo) > $1.tmp && mv $1.tmp $1
include build.mk

include clear_vars.mk
SRCS := $(OUT.c)
EXT := eir
CMD = $(8CC) -S -I. -Ilibc -Iout -o $1.tmp $2 && mv $1.tmp $1
DEPS := $(wildcard libc/*.h)
OUT.eir += $(SRCS:%=%.$(EXT))
include build.mk

include clear_vars.mk
SRCS := $(OUT.eir)
EXT := out
DEPS := $(TEST_INS) runtest.sh
CMD = ./runtest.sh $1 $(ELI) $2
OUT.eir.out := $(SRCS:%=%.$(EXT))
include build.mk

include clear_vars.mk
OUT.c.exe.out := $(OUT.c.exe:%=%.out)
OUT.c.eir.out := $(OUT.c.exe.out:%.c.exe.out=%.c.eir.out)
EXPECT := c.exe.out
ACTUAL := c.eir.out
include diff.mk

build: $(TEST_RESULTS)

# Targets

TARGET := rb
RUNNER := ruby
include target.mk

TARGET := py
RUNNER := python
include target.mk

ifdef TF
TARGET := tf
RUNNER := python
include target.mk
endif

TARGET := kx
RUNNER := kinx
include target.mk

TARGET := f90
RUNNER := tools/runfortran.sh
TOOL := gfortran
include target.mk

TARGET := js
RUNNER := nodejs
include target.mk

TARGET := asmjs
RUNNER := nodejs
include target.mk

TARGET := wasi
# Run with wat
RUNNER := wasmtime
include target.mk


TARGET := cpp
RUNNER := tools/runcpp.sh
TOOL := g++-6
include target.mk
$(OUT.eir.cpp.out): tools/runcpp.sh

include target.mk

TARGET := el
RUNNER := emacs --no-site-file --script
include target.mk

TARGET := vim
RUNNER := tools/runvim.sh
TOOL := vim
include target.mk

TARGET := tex
RUNNER := tools/runtex.sh
TOOL := tex
include target.mk

TARGET := cl
RUNNER := sbcl --script
include target.mk

TARGET := sh
RUNNER := bash
ifndef FULL
TEST_FILTER := out/fizzbuzz_fast.c.eir.sh out/8cc.c.eir.sh out/eli.c.eir.sh out/dump_ir.c.eir.sh
endif
include target.mk

TARGET := sed
RUNNER := sed -n -f
# Sed backend is so slow.
ifndef FULL
TEST_FILTER := out/24_cmp.c.eir.sed out/24_cmp2.c.eir.sed out/24_muldiv.c.eir.sed out/bitops.c.eir.sed out/copy_struct.c.eir.sed out/eof.c.eir.sed out/fizzbuzz.c.eir.sed out/fizzbuzz_fast.c.eir.sed out/global_struct_ref.c.eir.sed out/lisp.c.eir.sed out/printf.c.eir.sed out/qsort.c.eir.sed out/8cc.c.eir.sed out/elc.c.eir.sed out/dump_ir.c.eir.sed out/eli.c.eir.sed
endif
# Only GNU sed can output NUL.
ifeq ($(findstring GNU,$(shell sed --version)),)
TEST_FILTER += out/04getc.eir.sed
endif
include target.mk

TARGET := java
RUNNER := tools/runjava.sh
TOOL := javac
include target.mk
$(OUT.eir.java.out): tools/runjava.sh

TARGET := scala
RUNNER := tools/runscala.sh
TOOL := scalac
include target.mk
$(OUT.eir.scala.out): tools/runscala.sh

TARGET := swift
RUNNER := tools/runswift.sh
TOOL := swiftc
include target.mk
$(OUT.eir.swift.out): tools/runswift.sh

TARGET := cr
RUNNER := tools/runcr.sh
TOOL := crystal
include target.mk
$(OUT.eir.crystal.out): tools/runcr.sh

TARGET := cs
RUNNER := tools/runcs.sh
CAN_BUILD := $(if $(or $(shell which dotnet),$(and $(shell which mono),$(shell which gmcs))),1,0)
include target.mk
$(OUT.eir.cs.out): tools/runcs.sh

TARGET := c
RUNNER := tools/runc.sh
include target.mk
$(OUT.eir.c.out): tools/runc.sh tinycc/tcc

TARGET := cpp
RUNNER := tools/runcpp.sh
TOOL := g++
include target.mk
$(OUT.eir.cpp.out): tools/runcpp.sh

ifdef CPP_TEMPLATE
TARGET := cpp_template
RUNNER := tools/runcpp_template.sh
TOOL := g++
include target.mk
$(OUT.eir.cpp_template.out): tools/runcpp_template.sh
endif

ifeq ($(uname),Linux)
TARGET := $(ARCH)
RUNNER :=
include target.mk
endif

TARGET := i
RUNNER := tools/runi.sh
TOOL := ick
# INTERCAL backend is 16bit.
TEST_FILTER := $(addsuffix .i,$(filter out/24_%.eir,$(OUT.eir))) out/eof.c.eir.i out/neg.c.eir.i
include target.mk
$(OUT.eir.i.out): tools/runi.sh tinycc/tcc

TARGET := ws
RUNNER := tools/runws.sh
TEST_FILTER := out/eli.c.eir.ws
include target.mk
$(OUT.eir.ws.out): tools/runws.sh Whitespace/whitespace.out tinycc/tcc

TARGET := bef
RUNNER := out/befunge
include target.mk

TARGET := bf
RUNNER := tools/runbf.sh
ifndef FULL
TEST_FILTER := out/eli.c.eir.bf out/dump_ir.c.eir.bf
endif
include target.mk
$(OUT.eir.bf.out): tools/runbf.sh tinycc/tcc

ifdef PIETASM
TARGET := pietasm
RUNNER := tools/runpietasm.sh
include target.mk
$(OUT.eir.piet.out): tools/runpietasm.sh
endif

ifdef PIET
TARGET := piet
RUNNER := tools/runpiet.sh
# Piet backend is 16bit.
TEST_FILTER := $(addsuffix .piet,$(filter out/24_%.c.eir,$(OUT.eir))) out/eof.c.eir.piet out/neg.c.eir.piet
include target.mk
$(OUT.eir.piet.out): tools/runpiet.sh
endif

TARGET := unl
RUNNER := tools/rununl.sh
ifndef FULL
TEST_FILTER := out/eli.c.eir.unl out/dump_ir.c.eir.unl
endif
include target.mk
$(OUT.eir.unl.out): tools/rununl.sh

TARGET := tm
RUNNER := out/tm -b
TEST_FILTER := out/24_cmp.c.eir.tm out/24_cmp2.c.eir.tm out/24_muldiv.c.eir.tm out/bitops.c.eir.tm out/copy_struct.c.eir.tm out/eof.c.eir.tm out/fizzbuzz.c.eir.tm out/fizzbuzz_fast.c.eir.tm out/global_struct_ref.c.eir.tm out/lisp.c.eir.tm out/printf.c.eir.tm out/qsort.c.eir.tm out/8cc.c.eir.tm out/elc.c.eir.tm out/dump_ir.c.eir.tm out/eli.c.eir.tm
include target.mk
$(OUT.eir.tm.out): out/tm

TARGET := forth
RUNNER := gforth --dictionary-size 16M
include target.mk

TARGET := fs
RUNNER := tools/runfs.sh
CAN_BUILD := $(if $(or $(shell which dotnet),$(and $(shell which mono),$(shell which fsharpc))),1,0)
include target.mk
$(OUT.eir.fs.out): tools/runfs.sh

TARGET := pl
RUNNER := perl
include target.mk

TARGET := go
RUNNER := go run
include target.mk

ifdef HELL
TARGET := hell
RUNNER := tools/runhell.sh
# these tests require an insane amount of RAM and computation time
TEST_FILTER := out/fizzbuzz.c.eir.hell out/qsort.c.eir.hell out/fizzbuzz_fast.c.eir.hell out/lisp.c.eir.hell out/8cc.c.eir.hell out/elc.c.eir.hell out/dump_ir.c.eir.hell out/eli.c.eir.hell
# these tests require a very huge amount of RAM and computation time
ifndef FULL
TEST_FILTER += out/bm_mov.eir.hell out/24_mem.eir.hell out/24_cmp2.c.eir.hell out/24_cmp.c.eir.hell out/24_muldiv.c.eir.hell out/array.c.eir.hell out/bitops.c.eir.hell out/bool.c.eir.hell out/cmp_eq.c.eir.hell out/cmp_ge.c.eir.hell out/cmp_gt.c.eir.hell out/cmp_le.c.eir.hell out/cmp_lt.c.eir.hell out/cmp_ne.c.eir.hell out/copy_struct.c.eir.hell out/eof.c.eir.hell out/field_addr.c.eir.hell out/func2.c.eir.hell out/func.c.eir.hell out/func_ptr.c.eir.hell out/global_array.c.eir.hell out/global.c.eir.hell out/global_struct_ref.c.eir.hell out/hello.c.eir.hell out/increment.c.eir.hell out/logic_val.c.eir.hell out/loop.c.eir.hell out/malloc.c.eir.hell out/muldiv.c.eir.hell out/nullptr.c.eir.hell out/printf.c.eir.hell out/print_int.c.eir.hell out/puts.c.eir.hell out/struct.c.eir.hell out/swapcase.c.eir.hell out/switch_case.c.eir.hell out/switch_op.c.eir.hell out/switch_range.c.eir.hell
endif
include target.mk
$(OUT.eir.hell.out): tools/runhell.sh
endif

TARGET := sqlite3
RUNNER := tools/runsqlite3.sh
TOOL := sqlite3
include target.mk

TARGET := subleq
RUNNER := out/subleq
TEST_FILTER := out/8cc.c.eir.subleq
include target.mk

TARGET := ps
RUNNER := gsnd -q -dBATCH --
include target.mk

TARGET := lua
RUNNER := lua
CAN_BUILD := $(shell lua -v 2>&1 | perl -ne 'print /^Lua (\d+)\.(\d+)/ && ($$1 >= 5 && $$2 >= 3) ? 1 : 0')
include target.mk

TARGET := ll
RUNNER := lli
include target.mk

TARGET := scm_sr
RUNNER := tools/runscm_sr.sh
TOOL := gosh
include target.mk

TARGET := hs
RUNNER := tools/runhs.sh
TOOL := ghc
include target.mk
$(OUT.eir.hs.out): tools/runhs.sh

TARGET := oct
RUNNER := octave -q
include target.mk

TARGET := rs
RUNNER := tools/runrs.sh
TOOL := rustc
include target.mk

TARGET := cmake
RUNNER := tools/runcmake.sh
TOOL := cmake
include target.mk

TARGET := whirl
RUNNER := out/whirl
include target.mk

TARGET := wm
RUNNER := tools/runwm.sh
TOOL := cargo
# Strip out 24-bit specific tests as well as tests that take more resources
# than my computer could handle
TEST_FILTER := out/24_cmp.c.eir.wm out/24_cmp2.c.eir.wm out/24_muldiv.c.eir.wm out/qsort.c.eir.wm out/lisp.c.eir.wm out/8cc.c.eir.wm out/elc.c.eir.wm out/dump_ir.c.eir.wm out/eli.c.eir.wm
include target.mk
$(OUT.eir.wm.out): out/wmc

TARGET := scratch3
RUNNER := tools/runscratch3.sh
CAN_BUILD := $(if $(and $(shell which nodejs),$(shell which npm),$(shell (npm list -g ; cd tools && npm list) 2>/dev/null | grep 'scratch-vm')),1,0)
TEST_FILTER := out/8cc.c.eir.scratch3 out/elc.c.eir.scratch3 out/dump_ir.c.eir.scratch3
ifndef FULL
TEST_FILTER += out/eli.c.eir.scratch3
endif
include target.mk

TARGET := lol
RUNNER := tools/runlol.sh
include target.mk

TARGET := awk
RUNNER := awk -b -f
include target.mk

TARGET := tcl
RUNNER := tclsh
include target.mk

TARGET := j
RUNNER := jconsole
CAN_BUILD := $(shell DISPLAY=fail jconsole -js "echo i.4" -js "exit 0" 2>&1 | perl -ne 'print /^0 1 2 3/ ? 1 : 0')
include target.mk

TARGET := qftasm
RUNNER := tools/runqftasm.sh
TOOL := python
# Since the QFTASM backend is 16-bit, 24-bit-related programs are filtered out.
TEST_FILTER := $(addsuffix .qftasm,$(filter out/24_%.c.eir,$(OUT.eir))) out/eof.c.eir.qftasm out/neg.c.eir.qftasm out/8cc.c.eir.qftasm out/elc.c.eir.qftasm out/dump_ir.c.eir.qftasm out/eli.c.eir.qftasm
include target.mk

TARGET := lazy
RUNNER := tools/runlazy.sh
ifndef FULL
TEST_FILTER := out/8cc.c.eir.lazy out/elc.c.eir.lazy out/eli.c.eir.lazy out/dump_ir.c.eir.lazy \
out/fizzbuzz.c.eir.lazy out/fizzbuzz_fast.c.eir.lazy out/qsort.c.eir.lazy
endif
include target.mk

TARGET := blc
RUNNER := tools/runblc.sh
ifndef FULL
TEST_FILTER := out/elc.c.eir.blc out/eli.c.eir.blc out/dump_ir.c.eir.blc
endif
include target.mk

TARGET := ulamb
RUNNER := tools/runulamb.sh
ifndef FULL
TEST_FILTER := out/8cc.c.eir.ulamb out/elc.c.eir.ulamb out/eli.c.eir.ulamb out/dump_ir.c.eir.ulamb
endif
include target.mk

TARGET := lam
RUNNER := tools/runlam.sh
ifndef FULL
TEST_FILTER := out/elc.c.eir.lam out/eli.c.eir.lam out/dump_ir.c.eir.lam
endif
include target.mk

TARGET := w
RUNNER := tools/runw.sh
ifndef FULL
TEST_FILTER := out/8cc.c.eir.w out/elc.c.eir.w out/eli.c.eir.w out/dump_ir.c.eir.w \
out/24_cmp.c.eir.w out/24_cmp2.c.eir.w out/24_muldiv.c.eir.w \
out/eof.c.eir.w out/fgets.c.eir.w out/fizzbuzz.c.eir.w out/fizzbuzz_fast.c.eir.w out/qsort.c.eir.w
endif
include target.mk

test: $(TEST_RESULTS)

.SUFFIXES:

-include */*.d

<MSG> Don't hardcode g++ version
<DFF> @@ -315,7 +315,7 @@ $(OUT.eir.c.out): tools/runc.sh tinycc/tcc
 
 TARGET := cpp
 RUNNER := tools/runcpp.sh
-TOOL := g++-6
+TOOL := g++
 include target.mk
 $(OUT.eir.cpp.out): tools/runcpp.sh
 

{'commit': 'diff --git a/Makefile b/Makefile\nindex d288cd5..b5ceaaf 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -315,7 +315,7 @@ $(OUT.eir.c.out): tools/runc.sh tinycc/tcc\n \n TARGET := cpp\n RUNNER := tools/runcpp.sh\n-TOOL := g++-6\n+TOOL := g++\n include target.mk\n $(OUT.eir.cpp.out): tools/runcpp.sh\n \n', 'commit_subject': "Don't hardcode g++ version", 'repo_name': 'shinh/elvm', 'committer': {'name': 'GitHub', 'email': '1505422b2465e9a84f6fdfaa161078890c593f06@github.com', 'time_sec': '1516908056', 'tz_offset': '-360', 'date': {'seconds': '1516908056'}}, 'commit_tree': 'dfb3323be0eca0e25d71b6d8f744c844fd87edff', 'commit_message': "Don't hardcode g++ version", 'language_name': 'C', 'license': 'mit', 'hunks': '@@ -315,7 +315,7 @@ $(OUT.eir.c.out): tools/runc.sh tinycc/tcc\n \n TARGET := cpp\n RUNNER := tools/runcpp.sh\n-TOOL := g++-6\n+TOOL := g++\n include target.mk\n $(OUT.eir.cpp.out): tools/runcpp.sh\n \n', 'addition_count': 1, 'deletion_count': 1, 'src_file': 'a/Makefile', 'tgt_file': 'b/Makefile', 'file_extension': '', 'before_file': 'COMMONFLAGS := -W -Wall -W -Werror -MMD -MP -O -g -Wno-missing-field-initializers\nCFLAGS := -std=gnu99 $(COMMONFLAGS) -Wno-missing-field-initializers\nCXXFLAGS := -std=c++11 $(COMMONFLAGS)\n\nuname := $(shell uname)\nifneq (,$(findstring arm,$(shell uname -m)))\nARCH := arm\nelse\nARCH := x86\nendif\n\nELI := out/eli\nELC := out/elc\n8CC := out/8cc\n8CC_SRCS := \\\n\t8cc/buffer.c \\\n\t8cc/cpp.c \\\n\t8cc/debug.c \\\n\t8cc/dict.c \\\n\t8cc/encoding.c \\\n\t8cc/error.c \\\n\t8cc/file.c \\\n\t8cc/gen.c \\\n\t8cc/lex.c \\\n\t8cc/main.c \\\n\t8cc/map.c \\\n\t8cc/parse.c \\\n\t8cc/path.c \\\n\t8cc/set.c \\\n\t8cc/vector.c\n\nBINS := $(8CC) $(ELI) $(ELC) out/dump_ir out/befunge out/bfopt out/cmake_putc_helper out/subleq out/whirl\nLIB_IR_SRCS := ir/ir.c ir/table.c\nLIB_IR := $(LIB_IR_SRCS:ir/%.c=out/%.o)\n\nELC_EIR := out/elc.c.eir.c.gcc.exe\n\nall: build\n\t@echo \'\'\n\t@echo \'Now you have tools such as out/8cc and out/elc\'\n\t@echo \'\'\n\t@echo \'Use following targets to build/run tests for backend xxx:\'\n\t@echo \'\'\n\t@echo \'- `make build-xxx`: Compile all tests to xxx backend\'\n\t@echo \'   (e.g., out/lisp.c.eir.xxx will be built from test/lisp.c)\'\n\t@echo \'- `make test-xxx` or `make xxx`: Run tests for xxx backend\'\n\t@echo \'   (e.g., out/lisp.c.eir.xxx.out.diff will be output)\'\n\t@echo \'- `make test-xxx-full`: Run target/xxx.c on ELVM\'\n\t@echo \'   (this checks if the target xxx can self-host)\'\n\t@echo \'- `make test`: Build and run all tests\'\n\t@echo \'   (WARNING: will take a lot of time/disk)\'\n\t@echo \'\'\n\nout/git_submodule.stamp: .git/index\n\tgit submodule update --init\n\ttouch $@\n\n$(8CC_SRCS) lci/install.py Whitespace/whitespace.c tinycc/configure: out/git_submodule.stamp\n\nWhitespace/whitespace.out: Whitespace/whitespace.c\n\t$(MAKE) -C Whitespace \'MAX_SOURCE_SIZE:=100000000\' \'MAX_BYTECODE_SIZE:=16777216\' \'MAX_N_LABEL:=1048576\' \'HEAP_SIZE:=16777224\' \'STACK_SIZE:=16777224\'\n\nlci/lci: lci/install.py\n\tcd lci && python ./install.py || test -e lci\n\nout/befunge: tools/befunge.cc\n\t$(CXX) $(CXXFLAGS) $< -o $@\n\nout/bfopt: tools/bfopt.cc\n\t$(CXX) $(CXXFLAGS) $< -o $@\n\nout/cmake_putc_helper: tools/cmake_putc_helper.c\n\t$(CC) $(CFLAGS) $< -o $@\n\nout/subleq: tools/subleq.c\n\t$(CC) $(CFLAGS) $< -o $@\n\nout/tm: tools/tm.c\n\t$(CC) $(CFLAGS) $< -o $@\n\nout/whirl: tools/whirl.cc\n\t$(CXX) $(CXXFLAGS) $< -o $@\n\nout/wmc: tools/wmc/Cargo.toml\n\tcargo +nightly -Z unstable-options build --manifest-path $< --out-dir $@ --target-dir $@/obj\n\ntinycc/tcc: tinycc/config.h\n\t$(MAKE) -C tinycc tcc libtcc1.a\n\ntinycc/config.h: tinycc/configure\n\tcd tinycc && ./configure\n\nout/elc.c.eir.c.gcc.exe: out/elc.c.eir.c\n\t$(CC) -o $@ $<\n\nCSRCS := $(LIB_IR_SRCS) ir/dump_ir.c ir/eli.c\nCOBJS := $(addprefix out/,$(notdir $(CSRCS:.c=.o)))\n$(COBJS): out/%.o: ir/%.c\n\t$(CC) -c -I. $(CFLAGS) $< -o $@\n\nELC_SRCS := \\\n\telc.c \\\n\tutil.c \\\n\tasmjs.c \\\n\tarm.c \\\n\tawk.c \\\n\tbef.c \\\n\tbf.c \\\n\tblc.c \\\n\tc.c \\\n\tcl.c \\\n\tcmake.c \\\n\tcpp.c \\\n\tcpp_template.c \\\n\tcr.c \\\n\tcs.c \\\n\tel.c \\\n\tforth.c \\\n\tf90.c \\\n\tfs.c \\\n\tgo.c \\\n\thell.c \\\n\ths.c \\\n\ti.c \\\n\tj.c \\\n\tjava.c \\\n\tjs.c \\\n\tkx.c \\\n\tlam.c \\\n\tlazy.c \\\n\tlua.c \\\n\tll.c \\\n\tlol.c \\\n\tmcfunction.c \\\n\toct.c \\\n\tphp.c \\\n\tpiet.c \\\n\tpietasm.c \\\n\tpl.c \\\n\tpy.c \\\n\tps.c \\\n\tqftasm.c \\\n\trb.c \\\n\trs.c \\\n\tsed.c \\\n\tsh.c \\\n\tsqlite3.c \\\n\tscala.c \\\n\tscm_sr.c \\\n\tscratch3.c \\\n\tsubleq.c \\\n\tswift.c \\\n\ttcl.c \\\n\ttex.c \\\n\ttf.c \\\n\ttm.c \\\n\tulamb.c \\\n\tunl.c \\\n\tvim.c \\\n\tw.c \\\n\twasi.c \\\n\twasm.c \\\n\twhirl.c \\\n\twm.c \\\n\tws.c \\\n\tx86.c \\\n\nELC_SRCS := $(addprefix target/,$(ELC_SRCS))\nCOBJS := $(addprefix out/,$(notdir $(ELC_SRCS:.c=.o)))\n$(COBJS): out/%.o: target/%.c\n\t$(CC) -c -I. $(CFLAGS) $< -o $@\n\nout/dump_ir: $(LIB_IR) out/dump_ir.o\n\t$(CC) $(CFLAGS) -DTEST $^ -o $@\n\n$(ELI): $(LIB_IR) out/eli.o\n\t$(CC) $(CFLAGS) $^ -o $@\n\n$(ELC): $(LIB_IR) $(ELC_SRCS:target/%.c=out/%.o)\n\t$(CC) $(CFLAGS) $^ -o $@\n\n$(8CC): $(8CC_SRCS)\n\t$(MAKE) -C 8cc && cp 8cc/8cc $@\n\n# Stage tests\n\n$(shell mkdir -p out)\nTEST_RESULTS :=\n\nSRCS := $(sort $(wildcard test/*.eir))\nDSTS := $(SRCS:test/%.eir=out/%.eir)\nOUT.eir := $(DSTS)\n$(DSTS): out/%.eir: test/%.eir\n\tcp $< $@.tmp && mv $@.tmp $@\n\nSRCS := $(wildcard test/*.eir.rb)\nDSTS := $(SRCS:test/%.eir.rb=out/%.eir)\nOUT.eir += $(DSTS)\n$(DSTS): out/%.eir: test/%.eir.rb\n\truby $< > $@.tmp && mv $@.tmp $@\n\nSRCS := $(wildcard test/*.c)\nDSTS := $(SRCS:test/%.c=out/%.c)\n$(DSTS): out/%.c: test/%.c\n\tcp $< $@.tmp && mv $@.tmp $@\nOUT.c := $(SRCS:test/%.c=out/%.c)\n\nout/8cc.c: $(8CC_SRCS)\n\tcp 8cc/*.h 8cc/*.inc 8cc/include/*.h out\n\tcat $(8CC_SRCS) > $@.tmp && mv $@.tmp $@\nOUT.c += out/8cc.c\n\nout/elc.c: $(ELC_SRCS) $(LIB_IR_SRCS)\n\tcat $^ > $@.tmp && mv $@.tmp $@\nOUT.c += out/elc.c\n\nout/dump_ir.c: ir/dump_ir.c $(LIB_IR_SRCS)\n\tcat $^ > $@.tmp && mv $@.tmp $@\nOUT.c += out/dump_ir.c\n\nout/eli.c: ir/eli.c $(LIB_IR_SRCS)\n\tcat $^ > $@.tmp && mv $@.tmp $@\nOUT.c += out/eli.c\n\n# Build tests\n\nTEST_INS := $(wildcard test/*.in)\n\ninclude clear_vars.mk\nSRCS := $(OUT.c)\nEXT := exe\nCMD = $(CC) -std=gnu99 -DNOFILE -include libc/_builtin.h -I. $2 -o $1\nOUT.c.exe := $(SRCS:%=%.$(EXT))\ninclude build.mk\n\ninclude clear_vars.mk\nSRCS := $(filter-out out/8cc.c.exe,$(OUT.c.exe))\nEXT := out\nDEPS := $(TEST_INS) runtest.sh\nCMD = ./runtest.sh $1 $2\ninclude build.mk\n\ninclude clear_vars.mk\nSRCS := out/8cc.c.exe\nEXT := out\nDEPS := $(TEST_INS)\n# TODO: Hacky!\nsharp := \\#\nCMD = $2 -S -o $1.S.tmp - < test/8cc.in.c && sed \'s/ *$(sharp) .*//\' $1.S.tmp > $1.S && (echo === test/8cc.in === && cat $1.S && echo) > $1.tmp && mv $1.tmp $1\ninclude build.mk\n\ninclude clear_vars.mk\nSRCS := $(OUT.c)\nEXT := eir\nCMD = $(8CC) -S -I. -Ilibc -Iout -o $1.tmp $2 && mv $1.tmp $1\nDEPS := $(wildcard libc/*.h)\nOUT.eir += $(SRCS:%=%.$(EXT))\ninclude build.mk\n\ninclude clear_vars.mk\nSRCS := $(OUT.eir)\nEXT := out\nDEPS := $(TEST_INS) runtest.sh\nCMD = ./runtest.sh $1 $(ELI) $2\nOUT.eir.out := $(SRCS:%=%.$(EXT))\ninclude build.mk\n\ninclude clear_vars.mk\nOUT.c.exe.out := $(OUT.c.exe:%=%.out)\nOUT.c.eir.out := $(OUT.c.exe.out:%.c.exe.out=%.c.eir.out)\nEXPECT := c.exe.out\nACTUAL := c.eir.out\ninclude diff.mk\n\nbuild: $(TEST_RESULTS)\n\n# Targets\n\nTARGET := rb\nRUNNER := ruby\ninclude target.mk\n\nTARGET := py\nRUNNER := python\ninclude target.mk\n\nifdef TF\nTARGET := tf\nRUNNER := python\ninclude target.mk\nendif\n\nTARGET := kx\nRUNNER := kinx\ninclude target.mk\n\nTARGET := f90\nRUNNER := tools/runfortran.sh\nTOOL := gfortran\ninclude target.mk\n\nTARGET := js\nRUNNER := nodejs\ninclude target.mk\n\nTARGET := asmjs\nRUNNER := nodejs\ninclude target.mk\n\nTARGET := wasi\n# Run with wat\nRUNNER := wasmtime\ninclude target.mk\n\n\nTARGET := cpp\nRUNNER := tools/runcpp.sh\nTOOL := g++-6\ninclude target.mk\n$(OUT.eir.cpp.out): tools/runcpp.sh\n\ninclude target.mk\n\nTARGET := el\nRUNNER := emacs --no-site-file --script\ninclude target.mk\n\nTARGET := vim\nRUNNER := tools/runvim.sh\nTOOL := vim\ninclude target.mk\n\nTARGET := tex\nRUNNER := tools/runtex.sh\nTOOL := tex\ninclude target.mk\n\nTARGET := cl\nRUNNER := sbcl --script\ninclude target.mk\n\nTARGET := sh\nRUNNER := bash\nifndef FULL\nTEST_FILTER := out/fizzbuzz_fast.c.eir.sh out/8cc.c.eir.sh out/eli.c.eir.sh out/dump_ir.c.eir.sh\nendif\ninclude target.mk\n\nTARGET := sed\nRUNNER := sed -n -f\n# Sed backend is so slow.\nifndef FULL\nTEST_FILTER := out/24_cmp.c.eir.sed out/24_cmp2.c.eir.sed out/24_muldiv.c.eir.sed out/bitops.c.eir.sed out/copy_struct.c.eir.sed out/eof.c.eir.sed out/fizzbuzz.c.eir.sed out/fizzbuzz_fast.c.eir.sed out/global_struct_ref.c.eir.sed out/lisp.c.eir.sed out/printf.c.eir.sed out/qsort.c.eir.sed out/8cc.c.eir.sed out/elc.c.eir.sed out/dump_ir.c.eir.sed out/eli.c.eir.sed\nendif\n# Only GNU sed can output NUL.\nifeq ($(findstring GNU,$(shell sed --version)),)\nTEST_FILTER += out/04getc.eir.sed\nendif\ninclude target.mk\n\nTARGET := java\nRUNNER := tools/runjava.sh\nTOOL := javac\ninclude target.mk\n$(OUT.eir.java.out): tools/runjava.sh\n\nTARGET := scala\nRUNNER := tools/runscala.sh\nTOOL := scalac\ninclude target.mk\n$(OUT.eir.scala.out): tools/runscala.sh\n\nTARGET := swift\nRUNNER := tools/runswift.sh\nTOOL := swiftc\ninclude target.mk\n$(OUT.eir.swift.out): tools/runswift.sh\n\nTARGET := cr\nRUNNER := tools/runcr.sh\nTOOL := crystal\ninclude target.mk\n$(OUT.eir.crystal.out): tools/runcr.sh\n\nTARGET := cs\nRUNNER := tools/runcs.sh\nCAN_BUILD := $(if $(or $(shell which dotnet),$(and $(shell which mono),$(shell which gmcs))),1,0)\ninclude target.mk\n$(OUT.eir.cs.out): tools/runcs.sh\n\nTARGET := c\nRUNNER := tools/runc.sh\ninclude target.mk\n$(OUT.eir.c.out): tools/runc.sh tinycc/tcc\n\nTARGET := cpp\nRUNNER := tools/runcpp.sh\nTOOL := g++\ninclude target.mk\n$(OUT.eir.cpp.out): tools/runcpp.sh\n\nifdef CPP_TEMPLATE\nTARGET := cpp_template\nRUNNER := tools/runcpp_template.sh\nTOOL := g++\ninclude target.mk\n$(OUT.eir.cpp_template.out): tools/runcpp_template.sh\nendif\n\nifeq ($(uname),Linux)\nTARGET := $(ARCH)\nRUNNER :=\ninclude target.mk\nendif\n\nTARGET := i\nRUNNER := tools/runi.sh\nTOOL := ick\n# INTERCAL backend is 16bit.\nTEST_FILTER := $(addsuffix .i,$(filter out/24_%.eir,$(OUT.eir))) out/eof.c.eir.i out/neg.c.eir.i\ninclude target.mk\n$(OUT.eir.i.out): tools/runi.sh tinycc/tcc\n\nTARGET := ws\nRUNNER := tools/runws.sh\nTEST_FILTER := out/eli.c.eir.ws\ninclude target.mk\n$(OUT.eir.ws.out): tools/runws.sh Whitespace/whitespace.out tinycc/tcc\n\nTARGET := bef\nRUNNER := out/befunge\ninclude target.mk\n\nTARGET := bf\nRUNNER := tools/runbf.sh\nifndef FULL\nTEST_FILTER := out/eli.c.eir.bf out/dump_ir.c.eir.bf\nendif\ninclude target.mk\n$(OUT.eir.bf.out): tools/runbf.sh tinycc/tcc\n\nifdef PIETASM\nTARGET := pietasm\nRUNNER := tools/runpietasm.sh\ninclude target.mk\n$(OUT.eir.piet.out): tools/runpietasm.sh\nendif\n\nifdef PIET\nTARGET := piet\nRUNNER := tools/runpiet.sh\n# Piet backend is 16bit.\nTEST_FILTER := $(addsuffix .piet,$(filter out/24_%.c.eir,$(OUT.eir))) out/eof.c.eir.piet out/neg.c.eir.piet\ninclude target.mk\n$(OUT.eir.piet.out): tools/runpiet.sh\nendif\n\nTARGET := unl\nRUNNER := tools/rununl.sh\nifndef FULL\nTEST_FILTER := out/eli.c.eir.unl out/dump_ir.c.eir.unl\nendif\ninclude target.mk\n$(OUT.eir.unl.out): tools/rununl.sh\n\nTARGET := tm\nRUNNER := out/tm -b\nTEST_FILTER := out/24_cmp.c.eir.tm out/24_cmp2.c.eir.tm out/24_muldiv.c.eir.tm out/bitops.c.eir.tm out/copy_struct.c.eir.tm out/eof.c.eir.tm out/fizzbuzz.c.eir.tm out/fizzbuzz_fast.c.eir.tm out/global_struct_ref.c.eir.tm out/lisp.c.eir.tm out/printf.c.eir.tm out/qsort.c.eir.tm out/8cc.c.eir.tm out/elc.c.eir.tm out/dump_ir.c.eir.tm out/eli.c.eir.tm\ninclude target.mk\n$(OUT.eir.tm.out): out/tm\n\nTARGET := forth\nRUNNER := gforth --dictionary-size 16M\ninclude target.mk\n\nTARGET := fs\nRUNNER := tools/runfs.sh\nCAN_BUILD := $(if $(or $(shell which dotnet),$(and $(shell which mono),$(shell which fsharpc))),1,0)\ninclude target.mk\n$(OUT.eir.fs.out): tools/runfs.sh\n\nTARGET := pl\nRUNNER := perl\ninclude target.mk\n\nTARGET := go\nRUNNER := go run\ninclude target.mk\n\nifdef HELL\nTARGET := hell\nRUNNER := tools/runhell.sh\n# these tests require an insane amount of RAM and computation time\nTEST_FILTER := out/fizzbuzz.c.eir.hell out/qsort.c.eir.hell out/fizzbuzz_fast.c.eir.hell out/lisp.c.eir.hell out/8cc.c.eir.hell out/elc.c.eir.hell out/dump_ir.c.eir.hell out/eli.c.eir.hell\n# these tests require a very huge amount of RAM and computation time\nifndef FULL\nTEST_FILTER += out/bm_mov.eir.hell out/24_mem.eir.hell out/24_cmp2.c.eir.hell out/24_cmp.c.eir.hell out/24_muldiv.c.eir.hell out/array.c.eir.hell out/bitops.c.eir.hell out/bool.c.eir.hell out/cmp_eq.c.eir.hell out/cmp_ge.c.eir.hell out/cmp_gt.c.eir.hell out/cmp_le.c.eir.hell out/cmp_lt.c.eir.hell out/cmp_ne.c.eir.hell out/copy_struct.c.eir.hell out/eof.c.eir.hell out/field_addr.c.eir.hell out/func2.c.eir.hell out/func.c.eir.hell out/func_ptr.c.eir.hell out/global_array.c.eir.hell out/global.c.eir.hell out/global_struct_ref.c.eir.hell out/hello.c.eir.hell out/increment.c.eir.hell out/logic_val.c.eir.hell out/loop.c.eir.hell out/malloc.c.eir.hell out/muldiv.c.eir.hell out/nullptr.c.eir.hell out/printf.c.eir.hell out/print_int.c.eir.hell out/puts.c.eir.hell out/struct.c.eir.hell out/swapcase.c.eir.hell out/switch_case.c.eir.hell out/switch_op.c.eir.hell out/switch_range.c.eir.hell\nendif\ninclude target.mk\n$(OUT.eir.hell.out): tools/runhell.sh\nendif\n\nTARGET := sqlite3\nRUNNER := tools/runsqlite3.sh\nTOOL := sqlite3\ninclude target.mk\n\nTARGET := subleq\nRUNNER := out/subleq\nTEST_FILTER := out/8cc.c.eir.subleq\ninclude target.mk\n\nTARGET := ps\nRUNNER := gsnd -q -dBATCH --\ninclude target.mk\n\nTARGET := lua\nRUNNER := lua\nCAN_BUILD := $(shell lua -v 2>&1 | perl -ne \'print /^Lua (\\d+)\\.(\\d+)/ && ($$1 >= 5 && $$2 >= 3) ? 1 : 0\')\ninclude target.mk\n\nTARGET := ll\nRUNNER := lli\ninclude target.mk\n\nTARGET := scm_sr\nRUNNER := tools/runscm_sr.sh\nTOOL := gosh\ninclude target.mk\n\nTARGET := hs\nRUNNER := tools/runhs.sh\nTOOL := ghc\ninclude target.mk\n$(OUT.eir.hs.out): tools/runhs.sh\n\nTARGET := oct\nRUNNER := octave -q\ninclude target.mk\n\nTARGET := rs\nRUNNER := tools/runrs.sh\nTOOL := rustc\ninclude target.mk\n\nTARGET := cmake\nRUNNER := tools/runcmake.sh\nTOOL := cmake\ninclude target.mk\n\nTARGET := whirl\nRUNNER := out/whirl\ninclude target.mk\n\nTARGET := wm\nRUNNER := tools/runwm.sh\nTOOL := cargo\n# Strip out 24-bit specific tests as well as tests that take more resources\n# than my computer could handle\nTEST_FILTER := out/24_cmp.c.eir.wm out/24_cmp2.c.eir.wm out/24_muldiv.c.eir.wm out/qsort.c.eir.wm out/lisp.c.eir.wm out/8cc.c.eir.wm out/elc.c.eir.wm out/dump_ir.c.eir.wm out/eli.c.eir.wm\ninclude target.mk\n$(OUT.eir.wm.out): out/wmc\n\nTARGET := scratch3\nRUNNER := tools/runscratch3.sh\nCAN_BUILD := $(if $(and $(shell which nodejs),$(shell which npm),$(shell (npm list -g ; cd tools && npm list) 2>/dev/null | grep \'scratch-vm\')),1,0)\nTEST_FILTER := out/8cc.c.eir.scratch3 out/elc.c.eir.scratch3 out/dump_ir.c.eir.scratch3\nifndef FULL\nTEST_FILTER += out/eli.c.eir.scratch3\nendif\ninclude target.mk\n\nTARGET := lol\nRUNNER := tools/runlol.sh\ninclude target.mk\n\nTARGET := awk\nRUNNER := awk -b -f\ninclude target.mk\n\nTARGET := tcl\nRUNNER := tclsh\ninclude target.mk\n\nTARGET := j\nRUNNER := jconsole\nCAN_BUILD := $(shell DISPLAY=fail jconsole -js "echo i.4" -js "exit 0" 2>&1 | perl -ne \'print /^0 1 2 3/ ? 1 : 0\')\ninclude target.mk\n\nTARGET := qftasm\nRUNNER := tools/runqftasm.sh\nTOOL := python\n# Since the QFTASM backend is 16-bit, 24-bit-related programs are filtered out.\nTEST_FILTER := $(addsuffix .qftasm,$(filter out/24_%.c.eir,$(OUT.eir))) out/eof.c.eir.qftasm out/neg.c.eir.qftasm out/8cc.c.eir.qftasm out/elc.c.eir.qftasm out/dump_ir.c.eir.qftasm out/eli.c.eir.qftasm\ninclude target.mk\n\nTARGET := lazy\nRUNNER := tools/runlazy.sh\nifndef FULL\nTEST_FILTER := out/8cc.c.eir.lazy out/elc.c.eir.lazy out/eli.c.eir.lazy out/dump_ir.c.eir.lazy \\\nout/fizzbuzz.c.eir.lazy out/fizzbuzz_fast.c.eir.lazy out/qsort.c.eir.lazy\nendif\ninclude target.mk\n\nTARGET := blc\nRUNNER := tools/runblc.sh\nifndef FULL\nTEST_FILTER := out/elc.c.eir.blc out/eli.c.eir.blc out/dump_ir.c.eir.blc\nendif\ninclude target.mk\n\nTARGET := ulamb\nRUNNER := tools/runulamb.sh\nifndef FULL\nTEST_FILTER := out/8cc.c.eir.ulamb out/elc.c.eir.ulamb out/eli.c.eir.ulamb out/dump_ir.c.eir.ulamb\nendif\ninclude target.mk\n\nTARGET := lam\nRUNNER := tools/runlam.sh\nifndef FULL\nTEST_FILTER := out/elc.c.eir.lam out/eli.c.eir.lam out/dump_ir.c.eir.lam\nendif\ninclude target.mk\n\nTARGET := w\nRUNNER := tools/runw.sh\nifndef FULL\nTEST_FILTER := out/8cc.c.eir.w out/elc.c.eir.w out/eli.c.eir.w out/dump_ir.c.eir.w \\\nout/24_cmp.c.eir.w out/24_cmp2.c.eir.w out/24_muldiv.c.eir.w \\\nout/eof.c.eir.w out/fgets.c.eir.w out/fizzbuzz.c.eir.w out/fizzbuzz_fast.c.eir.w out/qsort.c.eir.w\nendif\ninclude target.mk\n\ntest: $(TEST_RESULTS)\n\n.SUFFIXES:\n\n-include */*.d\n', 'message': "Don't hardcode g++ version", 'author_name': 'GitHub', 'lang': 'Makefile'}