diff options
author | Rob Pike <r@golang.org> | 2008-06-25 21:19:05 -0700 |
---|---|---|
committer | Rob Pike <r@golang.org> | 2008-06-25 21:19:05 -0700 |
commit | c87597de2c785245398b4be7a7075d555d032248 (patch) | |
tree | e63e4f4e8144018ba6276cd5403ee1ccf94dc415 /src/runtime/Makefile | |
parent | 250a091922af9661dd1f190e74cdddf55ba331c4 (diff) | |
download | go-c87597de2c785245398b4be7a7075d555d032248.tar.gz go-c87597de2c785245398b4be7a7075d555d032248.zip |
put a makefile into runtime
make the runtime library an archive (rt0 is still separate)
update 6l to use the archive
add fakeobj.c, missing from prior change
SVN=124762
Diffstat (limited to 'src/runtime/Makefile')
-rw-r--r-- | src/runtime/Makefile | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/runtime/Makefile b/src/runtime/Makefile new file mode 100644 index 0000000000..52741c1257 --- /dev/null +++ b/src/runtime/Makefile @@ -0,0 +1,40 @@ +# 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. + +CFLAGS= +O=6 +CC=$(O)c +AS=$(O)a + +LIB=lib_$(GOARCH)_$(GOOS).a + +RT0OFILES=\ + rt0_$(GOARCH)_$(GOOS).$O\ + +LIBOFILES=\ + rt1_$(GOARCH)_$(GOOS).$O\ + rt2_$(GOARCH).$O\ + +OFILES=$(RT0OFILES) $(LIBOFILES) +HFILES= + +install: rt0 $(LIB) + cp $(RT0OFILES) $(GOROOT)/lib + cp $(LIB) $(GOROOT)/lib + +rt0: $(RT0OFILES) + +$(LIB): $(LIBOFILES) + $(O)ar rc $(LIB) $(LIBOFILES) + +$(OFILES): $(HFILES) + +clean: + rm -f *.$(O) *.a + +%.$O: %.c + $(CC) $< + +%.$O: %.s + $(AS) $< |