Skip to content

Commit

Permalink
CI add type openssl-lite
Browse files Browse the repository at this point in the history
  • Loading branch information
lifenjoiner committed Jul 14, 2024
1 parent c4650b3 commit 5ae141a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 20 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/github-CI-Windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ jobs:
matrix:
#os: [ubuntu-latest, windows-latest] # run native test
bits: [32, 64]
ftype: [shared-full, static-lite]
ftype: [wintls-winhashes-shared-full, wintls-winhashes-static-lite, openssl-lite]
fail-fast: false
# https://github.com/actions/virtual-environments
name: mingw${{matrix.bits}}-wintls-winhashes-${{matrix.ftype}}
name: mingw${{matrix.bits}}-${{matrix.ftype}}
runs-on: windows-latest
env:
mingw: mingw${{matrix.bits}}
build_type: wintls-winhashes-${{matrix.ftype}}
build_type: ${{matrix.ftype}}
defaults:
run:
shell: msys2 {0}
Expand Down Expand Up @@ -72,6 +72,7 @@ jobs:
mingw-w64-${{env.arch}}-libidn2
mingw-w64-${{env.arch}}-libunistring
mingw-w64-${{env.arch}}-gettext
mingw-w64-${{env.arch}}-openssl
# In here, test requires linux flavor python!
- name: Hack python
Expand Down Expand Up @@ -140,7 +141,7 @@ jobs:
cd libmetalink-0.1.3
./configure --disable-xmltest
make install
elif [ "${{matrix.ftype}}" = "static-lite" ]; then
else
wget https://github.com/win-iconv/win-iconv/archive/refs/tags/v0.0.8.tar.gz
tar -xvzf v0.0.8.tar.gz
cd win-iconv-0.0.8
Expand All @@ -153,11 +154,13 @@ jobs:
mkdir -p $CDir
cd $CDir
pwd
export CFLAGS+=" -Wall -D_WIN32_WINNT=0x0600 -DGNULIB_defined_ESOCK -DSite=https://github.com/lifenjoiner/wget-for-windows"
export CFLAGS+=" -Wall -DGNULIB_defined_ESOCK -DSite=https://github.com/lifenjoiner/wget-for-windows"
if [ "${{matrix.ftype}}" = "shared-full" ]; then
CFLAGS+=" -O2" $BRoot/configure --prefix=$BRoot/$BDir --disable-rpath --with-cares --with-winidn --enable-threads=windows
CFLAGS+=" -D_WIN32_WINNT=0x0600 -O2" $BRoot/configure --prefix=$BRoot/$BDir --disable-rpath --with-cares --with-winidn --enable-threads=windows
elif [ "${{matrix.ftype}}" = "static-lite" ]; then
CFLAGS+=" -Os" LDFLAGS="-static -s" $BRoot/configure --prefix=$BRoot/$BDir --disable-debug --disable-rpath --disable-nls --without-libpsl --without-metalink --disable-pcre --disable-pcre2 --with-winidn --enable-threads=windows
CFLAGS+=" -D_WIN32_WINNT=0x0600 -Os" LDFLAGS="-static -s" $BRoot/configure --prefix=$BRoot/$BDir --disable-debug --disable-rpath --disable-nls --without-libpsl --without-metalink --disable-pcre --disable-pcre2 --with-winidn --enable-threads=windows
elif [ "${{matrix.ftype}}" = "openssl-lite" ]; then
CFLAGS+=" -Os" LDFLAGS="-static -s" $BRoot/configure --prefix=$BRoot/$BDir --with-ssl=openssl --disable-debug --disable-rpath --disable-nls --without-libpsl --without-metalink --disable-pcre --disable-pcre2 --with-winidn --enable-threads=windows
fi
# <--

Expand Down Expand Up @@ -229,7 +232,7 @@ jobs:
- name: Upload release assets
uses: softprops/action-gh-release@v2
if: ${{ startsWith(github.ref, 'refs/tags/') && matrix.ftype == 'static-lite' }}
if: ${{ startsWith(github.ref, 'refs/tags/') && endsWith(matrix.ftype, '-lite') }}
with:
draft: true
files: |
Expand Down
14 changes: 2 additions & 12 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ wget_SOURCES += mswindows.c mswindows.h
endif

if WITH_NTLM
if OS_MSWINDOWS
if WITH_WINTLS
wget_SOURCES += http-ntlm-ms.c http-ntlm.h
else
wget_SOURCES += http-ntlm.c http-ntlm.h
Expand All @@ -95,23 +95,13 @@ wget_SOURCES += gnutls.c
endif

if WITH_WINTLS
wget_SOURCES += wintls.c
wget_SOURCES += win-sspi.c win-sspi.h wintls.c
endif

if WITH_WINHASHES
wget_SOURCES += win-hashes.c win-hashes.h
endif

if OS_MSWINDOWS
if WITH_NTLM
wget_SOURCES += win-sspi.c win-sspi.h
else
if WITH_WINTLS
wget_SOURCES += win-sspi.c win-sspi.h
endif
endif
endif

nodist_wget_SOURCES = version.c
EXTRA_wget_SOURCES = iri.c metalink.c xattr.c
LDADD = $(CODE_COVERAGE_LIBS) $(LIBOBJS) ../lib/libgnu.a \
Expand Down

0 comments on commit 5ae141a

Please sign in to comment.