Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
ce7f345c
Commit
ce7f345c
authored
Jan 22, 2010
by
Russ Cox
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gc: do not build builtin.c automatically; use golden copy instead.
R=r CC=golang-dev
https://golang.org/cl/190104
parent
c634189d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
17 deletions
+17
-17
src/cmd/gc/Makefile
src/cmd/gc/Makefile
+2
-3
src/cmd/gc/mkbuiltin
src/cmd/gc/mkbuiltin
+7
-14
src/cmd/gc/runtime.go
src/cmd/gc/runtime.go
+4
-0
src/cmd/gc/unsafe.go
src/cmd/gc/unsafe.go
+4
-0
No files found.
src/cmd/gc/Makefile
View file @
ce7f345c
...
...
@@ -54,9 +54,8 @@ y.tab.h: $(YFILES)
y.tab.c
:
y.tab.h
test
-f
y.tab.c
&&
touch
y.tab.c
builtin.c
:
runtime.go unsafe.go mkbuiltin1.c mkbuiltin
./mkbuiltin
||
\
(
echo
'mkbuiltin failed; using bootstrap copy of builtin.c'
;
cp
builtin.c.boot builtin.c
)
builtin.c
:
builtin.c.boot
cp
builtin.c.boot builtin.c
subr.$O
:
opnames.h
...
...
src/cmd/gc/mkbuiltin
View file @
ce7f345c
...
...
@@ -3,6 +3,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
# Generate builtin.c and builtin.c.boot from $* (runtime.go and unsafe.go).
# Run this after changing runtime.go and unsafe.go
# or after changing the export metadata format in the compiler.
# Either way, you need to have a working compiler binary first.
set
-e
GOBIN
=
"
${
GOBIN
:-
$HOME
/bin
}
"
...
...
@@ -22,19 +27,7 @@ do
done
# If _builtin.c has changed vs builtin.c.boot,
# check in the new change if being run by
# one of the people who tends to work on
# the compiler. This makes sure that changes
# don't get forgotten, without causing problems
# in end user Go repositories.
case
"
$USER
"
in
ken
|
r
|
rsc
)
if
!
cmp _builtin.c builtin.c.boot
>
/dev/null 2>/dev/null
then
PATH
=
$PATH
:/usr/local/bin
# find p4 on OS X
p4 open builtin.c.boot
>
/dev/null 2>/dev/null
||
true
# if p4 is missing, so be it
cp
_builtin.c builtin.c.boot
fi
esac
# check in the new change.
cmp
-s
_builtin.c builtin.c.boot
||
cp
_builtin.c builtin.c.boot
mv
_builtin.c builtin.c
src/cmd/gc/runtime.go
View file @
ce7f345c
...
...
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// NOTE: If you change this file you must run "./mkbuiltin"
// to update builtin.c.boot. This is not done automatically
// to avoid depending on having a working compiler binary.
package
PACKAGE
// emitted by compiler, not referred to by go programs
...
...
src/cmd/gc/unsafe.go
View file @
ce7f345c
...
...
@@ -2,6 +2,10 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// NOTE: If you change this file you must run "./mkbuiltin"
// to update builtin.c.boot. This is not done automatically
// to avoid depending on having a working compiler binary.
package
PACKAGE
type
Pointer
*
any
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment