Skip to content

Commit

Permalink
build: faster builds
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks committed Feb 15, 2025
1 parent 480595a commit d173d4a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
8 changes: 4 additions & 4 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,28 +47,28 @@ RUN \
git clone https://github.com/ada-url/ada.git --depth 1 -b "${LIBADA_VERSION}" && \
cd ada && \
cmake -B build -DCMAKE_BUILD_TYPE=Release -DADA_TOOLS=off -DADA_TESTING=off && \
cmake --build build && \
cmake --build build -j $(nproc) && \
cmake --install build

RUN \
wget -q -O - "https://github.com/nodejs/llhttp/archive/refs/tags/release/${LLHTTP_VERSION}.tar.gz" | tar xzf - && \
cd llhttp-release-v* && \
cmake -B build -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON && \
cmake --build build && \
cmake --build build -j $(nproc) && \
cmake --install build

RUN \
git clone https://github.com/nanodbc/nanodbc.git --depth 1 -b "${NANODBC_VERSION}" && \
cd nanodbc && \
CXX=g++ cmake -B build -DCMAKE_BUILD_TYPE=MinSizeRel -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON -DNANODBC_DISABLE_TESTS=ON -DNANODBC_DISABLE_EXAMPLES=ON -DNANODBC_DISABLE_LIBCXX=ON && \
cmake --build build && \
cmake --build build -j $(nproc) && \
cmake --install build

RUN \
wget -q -O - "https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-${LIBRESSL_VERSION#v}.tar.gz" | tar xzf - && \
cd libressl-* && \
cmake -B build -DCMAKE_BUILD_TYPE=Release -DLIBRESSL_APPS=OFF -DLIBRESSL_TESTS=OFF && \
cmake --build build && \
cmake --build build -j $(nproc) && \
cmake --install build

ENV CCC_CC=clang
Expand Down
8 changes: 4 additions & 4 deletions .github/actions/install-dependencies/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ runs:
git clone https://github.com/ada-url/ada.git --depth 1 -b "${LIBADA_VERSION}"
cd ada
cmake -B build -DCMAKE_BUILD_TYPE=MinSizeRel -DADA_TOOLS=off -DADA_TESTING=off -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build build
cmake --build build -j $(nproc)
sudo cmake --install build
- name: Install llhttp
Expand All @@ -53,7 +53,7 @@ runs:
wget -q -O - "https://github.com/nodejs/llhttp/archive/refs/tags/release/${LLHTTP_VERSION}.tar.gz" | tar xzf -
cd llhttp-release-v*
cmake -B build -DCMAKE_BUILD_TYPE=MinSizeRel -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build build
cmake --build build -j $(nproc)
sudo cmake --install build
- name: Install nanodbc
Expand All @@ -62,7 +62,7 @@ runs:
git clone https://github.com/nanodbc/nanodbc.git --depth 1 -b "${NANODBC_VERSION}"
cd nanodbc
CXX=g++ cmake -B build -DCMAKE_BUILD_TYPE=MinSizeRel -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=ON -DNANODBC_DISABLE_TESTS=ON -DNANODBC_DISABLE_EXAMPLES=ON -DNANODBC_DISABLE_LIBCXX=ON -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build build
cmake --build build -j $(nproc)
sudo cmake --install build
- name: Install libressl
Expand All @@ -71,5 +71,5 @@ runs:
wget -q -O - https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-${LIBRESSL_VERSION#v}.tar.gz | tar xzf -
cd libressl-*
cmake -B build -DCMAKE_BUILD_TYPE=MinSizeRel -DBUILD_SHARED_LIBS=OFF -DLIBRESSL_APPS=OFF -DLIBRESSL_TESTS=OFF -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build build
cmake --build build -j $(nproc)
sudo cmake --install build
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/.vscode/
/.cache/
/build/

0 comments on commit d173d4a

Please sign in to comment.