Skip to content

Commit e778bd7

Browse files
liblol: add glibc patches
to introduce ucontext compatibility which is required by chromium
1 parent afe1ffe commit e778bd7

File tree

4 files changed

+660
-4
lines changed

4 files changed

+660
-4
lines changed

autobuild/build

+17-4
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,13 @@ glibc_source() {
167167
-xvJ \
168168
--strip-components=1 \
169169
-f "$GLIBC_SRC_TAR"
170+
abinfo "Applying Glibc patches ..."
171+
while IFS= read -r patch; do
172+
abinfo "Applying $patch ..."
173+
patch -p 1 -d "$BLDDIR/src/glibc" \
174+
< "$SRCDIR/autobuild/patches/glibc/$patch"
175+
done <"$SRCDIR/autobuild/patches/glibc/series"
176+
170177
}
171178

172179
glibc_build() {
@@ -208,16 +215,22 @@ EOF
208215
env -i "PATH=$new_PATH" "MAKEFLAGS=$MAKEFLAGS" \
209216
make "$PWD/libc_pic.a"
210217
env -i "PATH=$new_PATH" "MAKEFLAGS=$MAKEFLAGS" \
211-
make "$PWD/elf/ld.so.1" \
218+
make -C "$BLDDIR/src/glibc/elf" "$PWD/elf/ld.so.1" \
212219
subdir=elf \
213-
-C "$BLDDIR/src/glibc/elf" \
214220
..=../ \
215221
objdir="$PWD"
216222
env -i "PATH=$new_PATH" "MAKEFLAGS=$MAKEFLAGS" \
217-
make "$PWD/elf/libc.so"
223+
make "$PWD/libc.so" "nptl/subdir_lib"
218224
env -i "PATH=$new_PATH" \
219225
make elf/ldso_install "$PKGDIR$LOLPREFIX/lib/$OWTARGET/libc.so.6" \
220-
DESTDIR="$PKGDIR" \
226+
DESTDIR="$PKGDIR"
227+
env -i "PATH=$new_PATH" \
228+
make -C "$BLDDIR/src/glibc/nptl" \
229+
"$PKGDIR$LOLPREFIX/lib/$OWTARGET/libpthread.so" \
230+
subdir=nptl \
231+
..=../ \
232+
objdir="$PWD" \
233+
DESTDIR="$PKGDIR"
221234

222235
mkdir -pv "$PKGDIR/usr/lib" #/lib64 is /usr/lib on AOSC
223236
ln -sfvr "$PKGDIR$LOLPREFIX/lib/$OWTARGET/ld-$GLIBC_VER.so" \

autobuild/patch

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
: "Do nothing"

0 commit comments

Comments
 (0)