Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[target.x86_64-unknown-linux-musl]
linker = "musl-gcc"
rustflags = [
"-C", "target-feature=+crt-static"
]
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,3 @@ Cargo.lock
/*.man
compile.fish
/*.profraw
.cargo
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ version = "1.2.1"
edition = "2021"
default-run = "gourd"
authors = [
"Mikołaj Gazeel <m.j.gazeel@student.tudelft.nl>",
"Mikołaj Gazeel <mgazeel@ethz.ch>",
"Lukáš Chládek <l@chla.cz>",
"Ανδρέας Τσατσάνης <a.tsatsanis@student.tudelft.nl>",
"Ανδρέας Τσατσάνης <atsatsanis@tudelft.nl>",
"Jan Piotrowski <me@jan.wf>",
"Rūta Giedrytė <r.giedryte@student.tudelft.nl>"
"Rūta Giedrytė <rgiedryte@tudelft.nl>"
]

build = "build.rs"
Expand Down
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,12 +98,13 @@ An artifact is available from the GitLab pipeline `documentation` job, or

### Authors

- Mikołaj Gazeel, m.j.gazeel@tudelft.nl
- Mikołaj Gazeel, mgazeel@ethz.ch
- Lukáš Chládek, l@chla.cz
- Ανδρέας Τσατσάνης, a.tsatsanis@tudelft.nl
- Rūta Giedrytė, r.giedryte@tudelft.nl
- Ανδρέας Τσατσάνης, atsatsanis@tudelft.nl
- Rūta Giedrytė, rgiedryte@tudelft.nl
- Jan Piotrowski, me@jan.wf

### Maintainers
- Ανδρέας Τσατσάνης, a.tsatsanis@tudelft.nl

- Ανδρέας Τσατσάνης, atsatsanis@tudelft.nl
- Lukáš Chládek, l@chla.cz
- Mikołaj Gazeel, m.j.gazeel@tudelft.nl
4 changes: 2 additions & 2 deletions docs/user/gourd-tutorial.7.tex
Original file line number Diff line number Diff line change
Expand Up @@ -364,9 +364,9 @@
\Prog{gourd.toml(5)}

\section{CONTACT}
Ανδρέας Τσατσάνης <\Email{a.tsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Ανδρέας Τσατσάνης <\Email{atsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Lukáš Chládek <\Email{l@chla.cz}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{m.j.gazeel@tudelft.nl}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{mgazeel@ethz.ch}>\\[0.1cm]\MANbr

%@% IF LATEX %@%
\end{adjustwidth}
Expand Down
4 changes: 2 additions & 2 deletions docs/user/gourd.1.tex
Original file line number Diff line number Diff line change
Expand Up @@ -574,9 +574,9 @@
\Prog{gourd.toml(5)}

\section{CONTACT}
Ανδρέας Τσατσάνης <\Email{a.tsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Ανδρέας Τσατσάνης <\Email{atsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Lukáš Chládek <\Email{l@chla.cz}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{m.j.gazeel@tudelft.nl}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{mgazeel@ethz.ch}>\\[0.1cm]\MANbr

%@% IF LATEX %@%
\end{adjustwidth}
Expand Down
4 changes: 2 additions & 2 deletions docs/user/gourd.toml.5.tex
Original file line number Diff line number Diff line change
Expand Up @@ -683,9 +683,9 @@
\Prog{gourd(1)} \Prog{gourd-tutorial(7)}

\section{CONTACT}
Ανδρέας Τσατσάνης <\Email{a.tsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Ανδρέας Τσατσάνης <\Email{atsatsanis@tudelft.nl}>\\[0.1cm]\MANbr
Lukáš Chládek <\Email{l@chla.cz}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{m.j.gazeel@tudelft.nl}>\\[0.1cm]\MANbr
Mikołaj Gazeel <\Email{mgazeel@ethz.ch}>\\[0.1cm]\MANbr

%@% IF LATEX %@%
\end{adjustwidth}
Expand Down
2 changes: 1 addition & 1 deletion docs/user/html/postamble.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<!-- MODIFIED: -->
<!-- Manos Pitsidianakis <manos@pitsidianak.is> -->
<!-- AND LATER: -->
<!-- Mikołaj Gazeel <M.J.Gazeel@student.tudelft.nl> -->
<!-- Mikołaj Gazeel <mgazeel@ethz.ch> -->


<hr />
Expand Down
2 changes: 1 addition & 1 deletion docs/user/html/preamble.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<!-- MODIFIED: -->
<!-- Manos Pitsidianakis <manos@pitsidianak.is> -->
<!-- AND LATER: -->
<!-- Mikołaj Gazeel <M.J.Gazeel@student.tudelft.nl> -->
<!-- Mikołaj Gazeel <mgazeel@ethz.ch> -->

<!doctype html>
<html lang="en">
Expand Down
27 changes: 26 additions & 1 deletion src/resources/build_builtin_examples.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,34 @@ fn compile_rust_file(path: &Path) -> Result<()> {

let str_compiled_path = compiled_path.to_str().ok_or_else(|| anyhow!(":("))?;

// on linux, we statically link the examples to musl in order to prevent glibc
// compatibility errors.
let target_triple = format!("{}-unknown-linux-musl", std::env::consts::ARCH);
let compile_args = if std::env::consts::OS == "linux" {
std::process::Command::new("rustup")
.arg("target")
.arg("add")
.arg(&target_triple)
.spawn()?
.wait()?;

vec![
"--target",
&target_triple,
"-C",
"target-feature=+crt-static",
"-O",
str_path,
"-o",
str_compiled_path,
]
} else {
vec!["-O", str_path, "-o", str_compiled_path]
};

let output = run_command(
"rustc",
&vec!["-O", str_path, "-o", str_compiled_path],
&compile_args,
Some(canon_path.parent().ok_or_else(|| anyhow!(":("))?.to_owned()),
)?;

Expand Down