Skip to content

Commit 56e6922

Browse files
committed
3.1.69.7bi
1 parent 3f3bf8e commit 56e6922

File tree

3 files changed

+104
-6
lines changed

3 files changed

+104
-6
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
runs-on: ubuntu-22.04
2020
env:
2121
BUILDS: 3.12 3.13 3.14
22-
EMFLAVOUR: tot
22+
EMFLAVOUR: latest
2323

2424
steps:
2525
- uses: actions/[email protected]

emsdk-cc

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -141,8 +141,13 @@ for argc, arg in enumerate(sys.argv):
141141
if arg.startswith('--preload-file') or arg.startswith('--embed-file'):
142142
USE_RAWFS = False
143143

144-
if arg.find("MAIN_MODULE") > 0 or EXE.endswith(".cjs") or EXE.endswith(".js"):
144+
if arg.find("MAIN_MODULE") > 0:
145145
MAIN_MODULE = True
146+
elif EXE.endswith(".cjs") or EXE.endswith(".js") or EXE.endswith(".html"):
147+
MAIN_MODULE = True
148+
149+
if arg == "-sENVIRONMENT=web":
150+
EXE = False
146151

147152
if arg.lower() in ("-fpic", "-latomic"):
148153
continue
@@ -170,11 +175,10 @@ for argc, arg in enumerate(sys.argv):
170175
COMPILE = True
171176
# TODO maybe add node runner for a .cjs
172177
elif arg == "-o":
178+
EXE_POS = argc + 1
173179
if IS_SHARED:
174-
EXE_POS = argc + 1
175180
SHARED_TARGET = sys.argv[EXE_POS]
176-
else:
177-
EXE_POS = argc + 1
181+
elif EXE=="":
178182
EXE = sys.argv[EXE_POS]
179183

180184
elif arg.endswith(".so") or arg == "-shared" or arg.find("SIDE_MODULE") > 0:
@@ -247,10 +251,12 @@ if SKIP:
247251
else:
248252
# should not happen
249253
if EXE:
250-
if EXE.endswith('.o') and '-c' not in out:
254+
if EXE.endswith('.o') and '-c' not in out:
251255
final.append('-c')
252256
EXE = False
253257
MAIN_MODULE = False
258+
elif EXE.endswith('.html'):
259+
EXE = False
254260

255261
if EXE:
256262
if EXE.endswith(".cjs") or EXE.endswith(".js"):

sources.wasm/5000-ncurses-65.sh

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
#!/bin/bash
2+
3+
. ${CONFIG:-config}
4+
5+
. scripts/emsdk-fetch.sh
6+
7+
# --disable-database --enable-termcap
8+
9+
NCOPTS="--enable-ext-colors --enable-ext-mouse --prefix=$PREFIX --disable-echo --without-pthread \
10+
--without-tests --without-tack --without-progs --without-manpages \
11+
--disable-db-install --without-cxx --without-cxx-binding --enable-pc-files \
12+
--with-pkg-config-libdir=$PREFIX/lib/pkgconfig \
13+
--with-termlib --enable-termcap --disable-database"
14+
15+
16+
export NCURSES=${NCURSES:-"ncurses-6.5"}
17+
export URL_NCURSES=${URL_NCURSES:-"https://invisible-mirror.net/archives/ncurses/$NCURSES.tar.gz"}
18+
19+
if cd ${ROOT}/src
20+
then
21+
22+
wget -c $URL_NCURSES && tar xfz $NCURSES.tar.gz
23+
24+
if cd ${ROOT}/src/$NCURSES
25+
then
26+
[ -f $NCURSES.done ] || patch -p1 < $SDKROOT/support/__EMSCRIPTEN__.deps/${NCURSES}_emscripten.patch
27+
touch $NCURSES.done
28+
fi
29+
30+
cd $ROOT
31+
mkdir -p ${ROOT}/build/ncurses/
32+
33+
if [ -f ../devices/emsdk/usr/lib/libncurses.a ]
34+
then
35+
echo "
36+
* skiping [ncurses] or already built
37+
" 1>&2
38+
else
39+
rm -rf ${ROOT}/build/ncurses/*
40+
cd ${ROOT}/build/ncurses
41+
42+
#CC=clang CFLAGS="-fpic -Wno-unused-command-line-argument" $ROOT/src/${NCURSES}/configure \
43+
# $NCOPTS && make && make install
44+
45+
CFLAGS="-fpic -Wno-unused-command-line-argument" emconfigure \
46+
$ROOT/src/${NCURSES}/configure \
47+
$NCOPTS
48+
49+
if true #patch -p1 < $SDKROOT/support/__EMSCRIPTEN__.deps/${NCURSES}_emscripten_make.patch
50+
then
51+
emmake make clean
52+
if emmake make
53+
then
54+
emmake make install
55+
fi
56+
fi
57+
fi
58+
59+
cd $ROOT
60+
mkdir -p ${ROOT}/build/ncurses/
61+
62+
if [ -f devices/emsdk/usr/lib/libncursesw.a ]
63+
then
64+
echo "
65+
* ncursesw already built
66+
" 1>&2
67+
else
68+
# build wide char
69+
rm -rf ${ROOT}/build/ncurses/*
70+
71+
cd ${ROOT}/build/ncurses
72+
73+
#CC=clang CFLAGS="-fpic -Wno-unused-command-line-argument" $ROOT/src/${NCURSES}/configure \
74+
# $NCOPTS --enable-widec && make && make install
75+
76+
CFLAGS="-fpic -Wno-unused-command-line-argument" emconfigure \
77+
$ROOT/src/${NCURSES}/configure $NCOPTS --enable-widec
78+
79+
cp ncurses/Makefile ncurses/Makefile.makew
80+
81+
if true #patch -p0 < $SDKROOT/support/__EMSCRIPTEN__.deps/${NCURSES}_emscripten_makew.patch
82+
then
83+
emmake make clean
84+
if emmake make
85+
then
86+
emmake make install
87+
fi
88+
fi
89+
fi
90+
91+
fi
92+

0 commit comments

Comments
 (0)