Skip to content

Commit 50c7a85

Browse files
committed
Try to enable readline again.
1 parent 5f21d69 commit 50c7a85

File tree

3 files changed

+13
-6
lines changed

3 files changed

+13
-6
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
- if: ${{ startsWith(matrix.os, 'ubuntu') }}
4848
run: |
4949
sudo apt update
50-
sudo apt install gcc-10 g++-10 -y
50+
sudo apt install -y gcc-10 g++-10 libreadline-dev libncurses5-dev
5151
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-10 100 --slave /usr/bin/g++ g++ /usr/bin/g++-10 --slave /usr/bin/gcov gcov /usr/bin/gcov-10
5252
- run: npm install --ignore-scripts
5353
- run: npm run build-debug
@@ -120,7 +120,7 @@ jobs:
120120
needs: test
121121
steps:
122122
- uses: actions/checkout@v4
123-
- run: apk add build-base git python3 py3-setuptools libstdc++ --update-cache
123+
- run: apk add build-base git python3 py3-setuptools libstdc++ readline-dev ncurses-dev --update-cache
124124
- run: npm install --ignore-scripts
125125
- run: ${{ env.NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}
126126

@@ -140,7 +140,7 @@ jobs:
140140
- uses: docker/setup-qemu-action@v3
141141
- run: |
142142
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:20-alpine -c "\
143-
apk add build-base git python3 py3-setuptools libstdc++ --update-cache && \
143+
apk add build-base git python3 py3-setuptools libstdc++ readline-dev ncurses-dev --update-cache && \
144144
cd /tmp/project && \
145145
npm install --ignore-scripts && \
146146
${{ env.NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}"
@@ -163,4 +163,4 @@ jobs:
163163
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:20-bullseye -c "\
164164
cd /tmp/project && \
165165
npm install --ignore-scripts && \
166-
${{ env.NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}"
166+
${{ env.NODE_BUILD_CMD }} -u ${{ secrets.GITHUB_TOKEN }}"

binding.gyp

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,15 @@
6060
# This is currently required by better-sqlite3.
6161
'SQLITE_ENABLE_COLUMN_METADATA',
6262
],
63-
}]
63+
}],
64+
['OS=="linux"', {
65+
'defines': ['HAVE_READLINE=1'],
66+
'libraries': ['-lreadline', '-lncurses'],
67+
}],
68+
['OS=="mac"', {
69+
'defines': ['HAVE_EDITLINE=1'],
70+
'libraries': ['-ledit', '-lncurses'],
71+
}],
6472
],
6573
'configurations': {
6674
'Debug': {

deps/download.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ DEFINES="
2525
HAVE_INT16_T=1
2626
HAVE_INT32_T=1
2727
HAVE_INT8_T=1
28-
HAVE_READLINE=1
2928
HAVE_STDINT_H=1
3029
HAVE_UINT16_T=1
3130
HAVE_UINT32_T=1

0 commit comments

Comments
 (0)