Skip to content

Commit

Permalink
Merge pull request #1 from Littleora/main-1.0
Browse files Browse the repository at this point in the history
upgrade v8 commits from hy
  • Loading branch information
tianya8318 authored Sep 4, 2023
2 parents 5a5c91f + 4890489 commit de606a4
Show file tree
Hide file tree
Showing 13 changed files with 43 additions and 661 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ jobs:
run: |
export CI_PROJECT_DIR=`pwd`
cd /root/v8
git checkout remotes/origin/8.3-lkgr
git checkout remotes/origin/9.3-lkgr
cp -R /root/v8/include $CI_PROJECT_DIR/v8-build/v8
cd $CI_PROJECT_DIR/v8-build/v8/src
echo "1. build v8 project."
python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/8.3-lkgr
python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/9.3-lkgr
- name: "build jsenv"
run: |
mkdir -p third_party/android_tools/
Expand Down
6 changes: 3 additions & 3 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ build:
script:
# build v8
- cd /root/v8
- git checkout remotes/origin/8.3-lkgr
- git checkout remotes/origin/9.3-lkgr
- cp -R /root/v8/include $CI_PROJECT_DIR/v8-build/v8
- cd $CI_PROJECT_DIR/v8-build/v8/src
- echo "1. build v8 project."
- python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/8.3-lkgr
- python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/9.3-lkgr
# build jsenv
- cd $CI_PROJECT_DIR
- mkdir -p third_party/android_tools/
Expand All @@ -37,7 +37,7 @@ release:
- tags
script:
- cd /root/v8
- git checkout remotes/origin/8.3-lkgr
- git checkout remotes/origin/9.3-lkgr
- cd $CI_PROJECT_DIR
- mkdir -p third_party/android_tools/
- ln -s /root/v8/third_party/android_ndk third_party/android_tools/ndk
Expand Down
26 changes: 15 additions & 11 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:19.10
FROM ubuntu:20.04

ENV PATH=${PATH}:/root/depot_tools:/root/v8/tools/dev

Expand All @@ -20,16 +20,24 @@ RUN apt update -qq && apt upgrade -y && apt-get install -qq -y --no-install-reco
git

RUN apt-get install -y npm && \
npm i -g n && \
npm i -g yarn && \
n latest
npm i -g n && \
npm i -g yarn && \
n latest

RUN cd ~ && git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git --depth=1

RUN cd ~ && fetch v8 && cd ~/v8 && gclient sync
# Solve the problem of not being able to download android_ndk
RUN cd ~ && fetch v8 \
&& cd v8 && git checkout remotes/origin/9.3-lkgr \
&& sed -i 's/2c2138e811487b13020eb331482fb991fd399d4e/083aa67a0d3309ebe37eafbe7bfd96c235a019cf/g' DEPS \
&& echo "target_os = ['android']" >> ../.gclient \
&& gclient sync

RUN apt install gcc-9-arm-linux-gnueabihf -y
RUN apt autoremove -y

RUN cd ~/v8 && sed -i 's/${dev_list} snapcraft/${dev_list}/g' build/install-build-deps.sh && build/install-build-deps.sh --lib32
RUN cd ~/v8 && sed -i 's/${dev_list} snapcraft/${dev_list}/g' build/install-build-deps.sh \
&& build/install-build-deps.sh --lib32

CMD [ "fish" ]

Expand All @@ -39,13 +47,9 @@ ENV ANDROID_NDK_HOME=/root/v8/third_party/android_ndk
RUN apt install openjdk-8-jdk -y && update-java-alternatives -s java-1.8.0-openjdk-amd64

RUN cd ~/v8 && build/install-build-deps-android.sh
RUN cd ~/v8/build && git reset HEAD --hard

RUN cd ~/v8 && echo "target_os = ['android']" >> ../.gclient \
&& gclient sync


RUN apt update && apt install libatomic1:i386 -y
RUN apt install ninja-build

ENV PATH=${PATH}:${ANDROID_HOME}/cmdline-tools/latest/bin
ARG ANDROID_BUILD_VERSION=28
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ Public GN documents can be found at: [https://chromium.googlesource.com/chromium

## 1. Pull docker image and enter container.
```
docker pull quickapp/v8-build:200513
docker pull quickapp/v8-build:230901
```

## 2. build v8
```
export CI_PROJECT_DIR="/root/jsenv-runtime"
cd /root/v8
git checkout remotes/origin/8.3-lkgr
git checkout remotes/origin/9.3-lkgr
cp -R /root/v8/include $CI_PROJECT_DIR/v8-build/v8
cd $CI_PROJECT_DIR/v8-build/v8/src
python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/8.3-lkgr
python build_v8.py --target android --v8-source /root/v8 --remote-branch remotes/origin/9.3-lkgr
```
## 3. Link third_party.
```
Expand Down
197 changes: 0 additions & 197 deletions v8-build-patch/build_v8.py

This file was deleted.

39 changes: 0 additions & 39 deletions v8-build-patch/patch/BUILD.gn.patch

This file was deleted.

25 changes: 0 additions & 25 deletions v8-build-patch/patch/v8-debugger-agent-impl.cc.patch

This file was deleted.

Loading

0 comments on commit de606a4

Please sign in to comment.