| # Copyright 2009 The Go Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style |
| # license that can be found in the LICENSE file. |
| include $(QUOTED_GOROOT)/src/Make.common |
| PREREQ+=$(patsubst %,%.make,$(DEPS)) |
| $(LD) $(LDIMPORTS) -o $@ _go_.$O |
| _go_.$O: $(GOFILES) $(PREREQ) |
| $(GC) $(GCFLAGS) $(GCIMPORTS) -o $@ $(GOFILES) |
| install: $(TARGDIR)/$(TARG) |
| $(TARGDIR)/$(TARG): $(TARG) |
| mkdir -p $(TARGDIR) && cp -f $(TARG) $(TARGDIR) |
| CLEANFILES+=$(TARG) _test _testmain.go test.out build.out |
| testpackage: _test/main.a |
| rm -f _test/main.a _gotest_.$O |
| _test/main.a: _gotest_.$O |
| gopack grc $@ _gotest_.$O |
| _gotest_.$O: $(GOFILES) $(GOTESTFILES) |
| $(GC) $(GCFLAGS) $(GCIMPORTS) -o $@ $(GOFILES) $(GOTESTFILES) |