From 3dab3e65d8fceff2b8989796d315bc382b7005c8 Mon Sep 17 00:00:00 2001 From: Rob Pike Date: Fri, 3 Jul 2009 12:54:59 -0700 Subject: [PATCH] put gob into the standard build R=rsc DELTA=77 (76 added, 0 deleted, 1 changed) OCL=31147 CL=31147 --- src/pkg/Make.deps | 3 +- src/pkg/Makefile | 2 ++ src/pkg/gob/Makefile | 77 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 81 insertions(+), 1 deletion(-) create mode 100644 src/pkg/gob/Makefile diff --git a/src/pkg/Make.deps b/src/pkg/Make.deps index 4a8444b3c9..84e6b13167 100644 --- a/src/pkg/Make.deps +++ b/src/pkg/Make.deps @@ -23,12 +23,13 @@ go/parser.install: bytes.install container/vector.install fmt.install go/ast.ins go/printer.install: fmt.install go/ast.install go/token.install io.install os.install reflect.install strings.install go/scanner.install: go/token.install strconv.install unicode.install utf8.install go/token.install: strconv.install +gob.install: fmt.install io.install math.install os.install reflect.install strings.install sync.install unicode.install hash.install: io.install hash/adler32.install: hash.install os.install hash/crc32.install: hash.install os.install http.install: bufio.install bytes.install container/vector.install fmt.install io.install log.install net.install os.install path.install strconv.install strings.install utf8.install io.install: bytes.install os.install strings.install sync.install -json.install: bytes.install container/vector.install fmt.install io.install math.install reflect.install strconv.install strings.install utf8.install +json.install: bytes.install container/vector.install fmt.install math.install reflect.install strconv.install strings.install utf8.install log.install: fmt.install io.install os.install runtime.install time.install malloc.install: math.install: diff --git a/src/pkg/Makefile b/src/pkg/Makefile index 817e7f8a54..3c16395f51 100644 --- a/src/pkg/Makefile +++ b/src/pkg/Makefile @@ -37,6 +37,7 @@ DIRS=\ go/printer\ go/scanner\ go/token\ + gob\ hash\ hash/adler32\ hash/crc32\ @@ -89,6 +90,7 @@ TEST=\ fmt\ go/parser\ go/scanner\ + gob\ hash/adler32\ hash/crc32\ http\ diff --git a/src/pkg/gob/Makefile b/src/pkg/gob/Makefile new file mode 100644 index 0000000000..e41eac3a95 --- /dev/null +++ b/src/pkg/gob/Makefile @@ -0,0 +1,77 @@ +# 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. + + +# DO NOT EDIT. Automatically generated by gobuild. +# gobuild -m >Makefile + +D= + +include $(GOROOT)/src/Make.$(GOARCH) +AR=gopack + +default: packages + +clean: + rm -rf *.[$(OS)] *.a [$(OS)].out _obj + +test: packages + gotest + +coverage: packages + gotest + 6cov -g $$(pwd) | grep -v '_test\.go:' + +%.$O: %.go + $(GC) -I_obj $*.go + +%.$O: %.c + $(CC) $*.c + +%.$O: %.s + $(AS) $*.s + +O1=\ + type.$O\ + +O2=\ + encode.$O\ + +O3=\ + decode.$O\ + + +phases: a1 a2 a3 +_obj$D/gob.a: phases + +a1: $(O1) + $(AR) grc _obj$D/gob.a type.$O + rm -f $(O1) + +a2: $(O2) + $(AR) grc _obj$D/gob.a encode.$O + rm -f $(O2) + +a3: $(O3) + $(AR) grc _obj$D/gob.a decode.$O + rm -f $(O3) + + +newpkg: clean + mkdir -p _obj$D + $(AR) grc _obj$D/gob.a + +$(O1): newpkg +$(O2): a1 +$(O3): a2 +$(O4): a3 + +nuke: clean + rm -f $(GOROOT)/pkg/$(GOOS)_$(GOARCH)$D/gob.a + +packages: _obj$D/gob.a + +install: packages + test -d $(GOROOT)/pkg && mkdir -p $(GOROOT)/pkg/$(GOOS)_$(GOARCH)$D + cp _obj$D/gob.a $(GOROOT)/pkg/$(GOOS)_$(GOARCH)$D/gob.a -- 2.48.1