2008-09-23 12:17:44 -06:00
|
|
|
# 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.
|
|
|
|
|
|
|
|
# -*- Makefile -*-
|
|
|
|
|
|
|
|
GO = /home/iant/go/bin/gccgo
|
|
|
|
|
|
|
|
LDFLAGS = -Wl,-R,/home/iant/go/lib
|
|
|
|
|
2008-10-16 16:28:36 -06:00
|
|
|
PRETTY_OBJS = \
|
2008-10-20 16:03:40 -06:00
|
|
|
ast.o \
|
2008-10-16 16:28:36 -06:00
|
|
|
pretty.o \
|
2008-10-24 15:04:54 -06:00
|
|
|
compilation.go \
|
2008-10-16 16:28:36 -06:00
|
|
|
parser.o \
|
|
|
|
platform.o \
|
|
|
|
printer.o \
|
|
|
|
scanner.o \
|
|
|
|
utils.o \
|
|
|
|
flag.o \
|
|
|
|
fmt.o \
|
|
|
|
|
|
|
|
pretty: $(PRETTY_OBJS)
|
|
|
|
$(GO) $(LDFLAGS) -o $@ $(PRETTY_OBJS)
|
2008-09-23 12:17:44 -06:00
|
|
|
|
|
|
|
test: pretty
|
2008-10-17 17:19:31 -06:00
|
|
|
test.sh
|
2008-09-23 12:17:44 -06:00
|
|
|
|
|
|
|
install: pretty
|
|
|
|
cp pretty $(HOME)/bin/pretty
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f pretty *.o *~
|
|
|
|
|
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
pretty.o: platform.o printer.o compilation.o
|
2008-09-23 12:17:44 -06:00
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
compilation.o: platform.o scanner.o parser.o ast.o
|
2008-10-24 15:04:54 -06:00
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
ast.o: scanner.o
|
2008-10-24 15:04:54 -06:00
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
scanner.o: utils.o
|
2008-09-23 12:17:44 -06:00
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
parser.o: scanner.o ast.o
|
2008-10-15 18:13:00 -06:00
|
|
|
|
2008-10-26 22:32:30 -06:00
|
|
|
platform.o: utils.o
|
|
|
|
|
|
|
|
printer.o: scanner.o ast.o
|
2008-10-24 15:04:54 -06:00
|
|
|
|
|
|
|
|
2008-09-24 23:01:52 -06:00
|
|
|
flag.o: fmt.o
|
|
|
|
$(GO) -O2 -c -g $(GOROOT)/src/lib/flag.go
|
|
|
|
|
|
|
|
fmt.o:
|
|
|
|
$(GO) -O2 -c -g $(GOROOT)/src/lib/fmt.go
|
|
|
|
|
2008-09-23 12:17:44 -06:00
|
|
|
.SUFFIXES:
|
|
|
|
.SUFFIXES: .go .o
|
|
|
|
|
|
|
|
.go.o:
|
|
|
|
$(GO) -O2 -c -g $<
|