Skip to content

Commit 2f6cf92

Browse files
committed
Add comments
1 parent 949e723 commit 2f6cf92

File tree

2 files changed

+156
-14
lines changed

2 files changed

+156
-14
lines changed

dist.sh

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,6 @@
44
# the `dist` directory as `mold-$version-$arch-linux.tar.gz` (e.g.
55
# `mold-2.40.0-x86_64-linux.tar.gz`).
66
#
7-
# The mold executable created by this script is statically linked to
8-
# libstdc++, but dynamically linked to libc, libm, libpthread and some
9-
# other libraries, as these libraries are almost always available on any
10-
# Linux system. We can't statically link libc because doing so would
11-
# disable dlopen(), which is required to load the LTO linker plugin.
12-
#
137
# This script aims to produce reproducible outputs. That means if you run
148
# the script twice on the same git commit, it should produce bit-for-bit
159
# identical binary files. This property is crucial as a countermeasure
@@ -23,6 +17,12 @@
2317
# but that shouldn't be a big problem for us because we only need that
2418
# site the first time.
2519
#
20+
# The mold executable created by this script is statically linked to
21+
# libstdc++, but dynamically linked to libc, libm and a few other
22+
# libraries, as these libraries are almost always available on any
23+
# Linux system. We can't statically link libc because doing so would
24+
# disable dlopen(), which is required to load the LTO linker plugin.
25+
#
2626
# We aim to use a reasonably old Debian version because we'll dynamically
2727
# link glibc to mold, and a binary linked against a newer version of glibc
2828
# won't work on a system with an older version of glibc.
@@ -201,7 +201,7 @@ esac
201201
version=$(sed -n 's/^project(mold VERSION \(.*\))/\1/p' CMakeLists.txt)
202202
dest=mold-$version-$arch-linux
203203

204-
# Source tarballs available on GitHub don't contain .git history.
204+
# Source tarballs available on GitHub don't contain .git directory.
205205
# Clone the repo if missing.
206206
[ -d .git ] || git clone --branch v$version --depth 1 --bare https://github.com/rui314/mold .git
207207

0 commit comments

Comments
 (0)