Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
cookbook
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Wildan Mubarok
cookbook
Commits
0192461e
Commit
0192461e
authored
8 years ago
by
Jeremy Soller
Browse files
Options
Downloads
Patches
Plain Diff
Fix gcc
parent
2f600514
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.cargo/config
+6
-0
6 additions, 0 deletions
.cargo/config
cook.sh
+11
-12
11 additions, 12 deletions
cook.sh
libc-artifacts
+1
-1
1 addition, 1 deletion
libc-artifacts
with
18 additions
and
13 deletions
.cargo/config
0 → 100644
+
6
−
0
View file @
0192461e
[target.x86_64-unknown-redox]
linker = "libc-artifacts/gcc.sh"
rustflags = [
"--verbose",
"-Z", "print-link-args"
]
This diff is collapsed.
Click to expand it.
cook.sh
+
11
−
12
View file @
0192461e
#!/bin/bash
#!/bin/bash
ROOT
=
"
$PWD
"
# Configuration
export
CARGOFLAGS
=
--verbose
export
CFLAGS
=
"-static -nostartfiles -nostdlib -nodefaultlibs
\
-undef -imacros
$ROOT
/libc-artifacts/define.h
\
-isystem
$ROOT
/libc-artifacts/usr/include
\
-L
$ROOT
/libc-artifacts/usr/lib
\
$ROOT
/libc-artifacts/usr/lib/crt0.o -lm -lc -lgcc
\
-fno-stack-protector -U_FORTIFY_SOURCE"
export
CARGO_BUILD_RUSTFLAGS
=
"--verbose -Z print-link-args -C linker=gcc -C link-args=
\"\$
CFLAGS
\"
"
export
TARGET
=
x86_64-unknown-redox
export
TARGET
=
x86_64-unknown-redox
# Automatic variables
ROOT
=
"
$PWD
"
REPO
=
"
$ROOT
/repo/
$TARGET
"
REPO
=
"
$ROOT
/repo/
$TARGET
"
export
CC
=
"
$ROOT
/libc-artifacts/gcc.sh"
# Variables to be overriden by recipes
export
CARGOFLAGS
=
--verbose
set
-e
set
-e
...
@@ -51,13 +50,13 @@ function op {
...
@@ -51,13 +50,13 @@ function op {
;;
;;
build
)
build
)
pushd
build
>
/dev/null
pushd
build
>
/dev/null
cp
-r
"
$ROOT
/Xargo.toml"
"
$ROOT
/libc-artifacts"
.
cp
-r
"
$ROOT
/Xargo.toml"
"
$ROOT
/.cargo"
"
$ROOT
/libc-artifacts"
.
xargo build
--target
"
$TARGET
"
--release
$CARGOFLAGS
xargo build
--target
"
$TARGET
"
--release
$CARGOFLAGS
popd
>
/dev/null
popd
>
/dev/null
;;
;;
test
)
test
)
pushd
build
>
/dev/null
pushd
build
>
/dev/null
cp
-r
"
$ROOT
/Xargo.toml"
"
$ROOT
/libc-artifacts"
.
cp
-r
"
$ROOT
/Xargo.toml"
"
$ROOT
/.cargo"
"
$ROOT
/libc-artifacts"
.
xargo
test
--no-run
--target
"
$TARGET
"
--release
$CARGOFLAGS
xargo
test
--no-run
--target
"
$TARGET
"
--release
$CARGOFLAGS
popd
>
/dev/null
popd
>
/dev/null
;;
;;
...
@@ -81,7 +80,7 @@ function op {
...
@@ -81,7 +80,7 @@ function op {
for
bin
in
$bins
for
bin
in
$bins
do
do
cp
-v
"
$bin
"
"../stage/bin/
$(
basename
$bin
)
"
cp
-v
"
$bin
"
"../stage/bin/
$(
basename
$bin
)
"
strip
-v
"../stage/bin/
$(
basename
$bin
)
"
#
strip -v "../stage/bin/$(basename $bin)"
done
done
fi
fi
fi
fi
...
...
This diff is collapsed.
Click to expand it.
libc-artifacts
@
fd716b6d
Compare
4bff613d
...
fd716b6d
Subproject commit
4bff613d3c4214ef4081427ab0a74d8f6f724935
Subproject commit
fd716b6dc0be2755a71ad40ddb6dfce49d5ffa91
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment