Makefile 458 Bytes
Newer Older
1 2 3 4 5 6 7
# 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.

O=6
GC=$(O)g

8
PKG=$(GOROOT)/pkg/os.a
9

10
O1=\
11
	os_error.$O
Rob Pike's avatar
Rob Pike committed
12
O2=\
Russ Cox's avatar
Russ Cox committed
13 14
	os_file.$O\
	os_time.$O\
15

16
install: nuke $(PKG)
17

Rob Pike's avatar
Rob Pike committed
18
$(PKG): a1 a2
19 20 21

a1: 	$(O1)
	$(O)ar grc $(PKG) $(O1)
22

Rob Pike's avatar
Rob Pike committed
23 24 25
a2: 	$(O2)
	$(O)ar grc $(PKG) $(O2)

26 27 28
$(O1): nuke
$(O2): a1

29
nuke:
30
	rm -f *.$(O) *.a $(PKG)
31 32 33 34 35 36

clean:
	rm -f *.$(O) *.a

%.$O:	%.go
	$(GC) $<