Skip to content

Commit 2238ca9

Browse files
authored
Un-force the openssl version on build.sh (#11)
* Un-force the openssl version on build.sh * tidy up action version numbers * bump package.json version * rm cat_slower, use no-tests instead of no-test
1 parent b0fe8c6 commit 2238ca9

File tree

6 files changed

+23
-36
lines changed

6 files changed

+23
-36
lines changed

.github/workflows/build-and-release.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
id: yarn-cache-dir
6767
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
6868
- name: Restore Yarn Cache
69-
uses: actions/cache@v2
69+
uses: actions/cache@v3
7070
id: yarn-cache
7171
with:
7272
path: ${{ steps.yarn-cache-dir.outputs.dir }}
@@ -75,7 +75,7 @@ jobs:
7575
v1-${{ runner.os }}-yarn-cache-${{ github.ref }}-
7676
v1-${{ runner.os }}-yarn-cache-
7777
- name: Restore libcurl deps cache
78-
uses: actions/cache@v2
78+
uses: actions/cache@v3
7979
id: libcurl-deps-cache
8080
with:
8181
path: |
@@ -92,7 +92,7 @@ jobs:
9292
GIT_COMMIT=${{ github.sha }} GIT_TAG=$GIT_TAG ./scripts/ci/build.sh
9393
- name: Upload artifacts
9494
if: always()
95-
uses: actions/upload-artifact@v2
95+
uses: actions/upload-artifact@v3
9696
with:
9797
name: build-logs-${{ matrix.os }}-${{ matrix.libcurl-release }}-${{ matrix.node }}
9898
path: ./logs/
@@ -146,7 +146,7 @@ jobs:
146146
id: yarn-cache-dir
147147
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
148148
- name: Restore Yarn Cache
149-
uses: actions/cache@v2
149+
uses: actions/cache@v3
150150
id: yarn-cache
151151
with:
152152
path: ${{ steps.yarn-cache-dir.outputs.dir }}
@@ -155,15 +155,15 @@ jobs:
155155
v1-${{ runner.os }}-yarn-cache-${{ github.ref }}-
156156
v1-${{ runner.os }}-yarn-cache-
157157
- name: Restore Electron Cache
158-
uses: actions/cache@v2
158+
uses: actions/cache@v3
159159
with:
160160
path: ~/Library/Caches/electron
161161
key: v1-${{ runner.os }}-electron-cache-${{ matrix.electron-version }}
162162
restore-keys: |
163163
v1-${{ runner.os }}-electron-cache-${{ matrix.electron-version }}
164164
v1-${{ runner.os }}-electron-cache-
165165
- name: Restore libcurl deps cache
166-
uses: actions/cache@v2
166+
uses: actions/cache@v3
167167
id: libcurl-deps-cache
168168
with:
169169
path: |
@@ -180,7 +180,7 @@ jobs:
180180
GIT_COMMIT=${{ github.sha }} GIT_TAG=$GIT_TAG ./scripts/ci/build.sh
181181
- name: Upload artifacts
182182
if: always()
183-
uses: actions/upload-artifact@v2
183+
uses: actions/upload-artifact@v3
184184
with:
185185
name: build-logs-${{ matrix.os }}-${{ matrix.libcurl-release }}-${{ matrix.electron-version }}
186186
path: ./logs/

.github/workflows/build-lint-test.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
- id: timestamp
4444
run: echo "timestamp=$(timestamp +%s)" >> $GITHUB_OUTPUT
4545
- name: Restore the previous run result
46-
uses: actions/cache@v2
46+
uses: actions/cache@v3
4747
with:
4848
path: |
4949
run_result
@@ -89,7 +89,7 @@ jobs:
8989
v1-${{ runner.os }}-yarn-cache-${{ github.ref }}-
9090
v1-${{ runner.os }}-yarn-cache-
9191
- name: Restore libcurl deps cache
92-
uses: actions/cache@v2
92+
uses: actions/cache@v3
9393
id: libcurl-deps-cache
9494
with:
9595
path: |
@@ -125,7 +125,7 @@ jobs:
125125
fail_ci_if_error: false
126126
- name: Upload artifacts
127127
if: always() && steps.run_result.outputs.run_result != 'success'
128-
uses: actions/upload-artifact@v2
128+
uses: actions/upload-artifact@v3
129129
with:
130130
name: build-logs-${{ matrix.os }}-${{ matrix.libcurl-release }}-${{ matrix.node }}
131131
path: ./logs/
@@ -156,7 +156,7 @@ jobs:
156156
- id: timestamp
157157
run: echo "timestamp=$(timestamp +%s)" >> $GITHUB_OUTPUT
158158
- name: Restore the previous run result
159-
uses: actions/cache@v2
159+
uses: actions/cache@v3
160160
with:
161161
path: |
162162
run_result
@@ -192,7 +192,7 @@ jobs:
192192
id: yarn-cache-dir
193193
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
194194
- name: Restore Yarn Cache
195-
uses: actions/cache@v2
195+
uses: actions/cache@v3
196196
id: yarn-cache
197197
with:
198198
path: ${{ steps.yarn-cache-dir.outputs.dir }}
@@ -201,15 +201,15 @@ jobs:
201201
v1-${{ runner.os }}-yarn-cache-${{ github.ref }}-
202202
v1-${{ runner.os }}-yarn-cache-
203203
- name: Restore Electron Cache
204-
uses: actions/cache@v2
204+
uses: actions/cache@v3
205205
with:
206206
path: ~/Library/Caches/electron
207207
key: v1-${{ runner.os }}-electron-cache-${{ matrix.electron-version }}
208208
restore-keys: |
209209
v1-${{ runner.os }}-electron-cache-${{ matrix.electron-version }}
210210
v1-${{ runner.os }}-electron-cache-
211211
- name: Restore libcurl deps cache
212-
uses: actions/cache@v2
212+
uses: actions/cache@v3
213213
id: libcurl-deps-cache
214214
with:
215215
path: |
@@ -230,7 +230,7 @@ jobs:
230230
./scripts/ci/build.sh
231231
- name: Upload artifacts
232232
if: always() && steps.run_result.outputs.run_result != 'success'
233-
uses: actions/upload-artifact@v2
233+
uses: actions/upload-artifact@v3
234234
with:
235235
name: build-logs-${{ matrix.os }}-${{ matrix.libcurl-release }}-${{ matrix.electron-version }}
236236
path: ./logs/

.github/workflows/codeql-analysis.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515

1616
steps:
1717
- name: Checkout repository
18-
uses: actions/checkout@v2
18+
uses: actions/checkout@v3
1919
with:
2020
# We must fetch at least the immediate parents so that if this is
2121
# a pull request then we can checkout the head.
@@ -50,14 +50,14 @@ jobs:
5050
- name: Get yarn cache directory path
5151
id: yarn-cache-dir-path
5252
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT
53-
- uses: actions/cache@v2
53+
- uses: actions/cache@v3
5454
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
5555
with:
5656
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
5757
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
5858
restore-keys: |
5959
${{ runner.os }}-yarn-
60-
- uses: actions/cache@v2
60+
- uses: actions/cache@v3
6161
id: deps-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
6262
with:
6363
path: ~/deps

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@getinsomnia/node-libcurl",
3-
"version": "2.3.5-5",
3+
"version": "2.3.5-6",
44
"description": "The fastest http(s) client (and much more) for Node.js - Node.js bindings for libcurl",
55
"keywords": [
66
"node-curl",

scripts/ci/build-openssl.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ if [ "$MACOS_UNIVERSAL_BUILD" == "true" ]; then
5757
-fPIC \
5858
--prefix=$build_folder \
5959
--openssldir=$build_folder \
60-
no-shared "${@:2}"
60+
no-tests no-shared "${@:2}"
6161

6262
make && make install_sw
6363

scripts/ci/build.sh

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -41,16 +41,6 @@ if [ "$(uname)" == "Darwin" ]; then
4141
export LDFLAGS="$MACOS_TARGET_FLAGS $MACOS_ARCH_FLAGS"
4242
fi
4343

44-
function cat_slower() {
45-
echo "cat_slower called"
46-
# Disabled, only really interesting if we need to debug something
47-
# # hacky way to slow down the output of cat
48-
# CI=${CI:-}
49-
# # the grep is to ignore lines starting with |
50-
# # which for config.log files are the source used to test something
51-
# [ "$CI" == "true" ] && (cat $1 | grep "^[^|]" | perl -pe 'select undef,undef,undef,0.0033333333') || true
52-
}
53-
5444
PREFIX_DIR=${PREFIX_DIR:-$HOME}
5545
STOP_ON_INSTALL=${STOP_ON_INSTALL:-false}
5646
RUN_PREGYP_CLEAN=${RUN_PREGYP_CLEAN:-true}
@@ -105,10 +95,7 @@ ls -al $LIBIDN2_BUILD_FOLDER/lib
10595
# Build OpenSSL
10696
###################
10797
# OpenSSL version must match Node.js one
108-
## OPENSSL_RELEASE=${OPENSSL_RELEASE:-$(node -e "console.log(process.versions.openssl.replace('+quic', ''))")}
109-
110-
# Forcing release to be 1.1.1r
111-
OPENSSL_RELEASE=1.1.1r
98+
OPENSSL_RELEASE=${OPENSSL_RELEASE:-$(node -e "console.log(process.versions.openssl.replace('+quic', ''))")}
11299

113100
OPENSSL_DEST_FOLDER=$PREFIX_DIR/deps/openssl
114101

@@ -251,9 +238,9 @@ if [[ $LIBCURL_RELEASE == "LATEST" ]]; then
251238
fi
252239
LIBCURL_DEST_FOLDER=$PREFIX_DIR/deps/libcurl
253240
echo "Building libcurl v$LIBCURL_RELEASE - Latest is v$LATEST_LIBCURL_RELEASE"
254-
./scripts/ci/build-libcurl.sh $LIBCURL_RELEASE $LIBCURL_DEST_FOLDER || (echo "libcurl failed build log:" && cat_slower $LIBCURL_DEST_FOLDER/source/$LIBCURL_RELEASE/config.log && exit 1)
241+
./scripts/ci/build-libcurl.sh $LIBCURL_RELEASE $LIBCURL_DEST_FOLDER || (echo "libcurl failed build log:" && cat $LIBCURL_DEST_FOLDER/source/$LIBCURL_RELEASE/config.log && exit 1)
255242
echo "libcurl successful build log:"
256-
cat_slower $LIBCURL_DEST_FOLDER/source/$LIBCURL_RELEASE/config.log
243+
cat $LIBCURL_DEST_FOLDER/source/$LIBCURL_RELEASE/config.log
257244

258245
export LIBCURL_BUILD_FOLDER=$LIBCURL_DEST_FOLDER/build/$LIBCURL_RELEASE
259246
ls -al $LIBCURL_BUILD_FOLDER/lib

0 commit comments

Comments
 (0)