Files
UltraGrid/.github/scripts/Windows/install_natpmp.sh
Martin Pulec 1cfc38cfb3 CI: fixed Windows natpmp build error
Fixes failed run  https://github.com/CESNET/UltraGrid/actions/runs/3894640814/jobs/6648919900.

cmd.exe script for unknown reason ceased to work, copied appropriate
parts of script to our script.

+ use shell debug flag for the script
2023-01-19 09:59:31 +01:00

16 lines
452 B
Bash
Executable File

#!/bin/sh -eux
git clone --depth 1 https://github.com/miniupnp/libnatpmp
cd libnatpmp
gcc -c -Wall -Os -DWIN32 -DNATPMP_STATICLIB -DENABLE_STRNATPMPERR getgateway.c
gcc -c -Wall -Os -DWIN32 -DNATPMP_STATICLIB -DENABLE_STRNATPMPERR natpmp.c
gcc -c -Wall -Os -DWIN32 wingettimeofday.c
ar cr natpmp.a getgateway.o natpmp.o wingettimeofday.o
cp natpmp.a /usr/local/lib/libnatpmp.a
cp natpmp_declspec.h natpmp.h /usr/local/include
cd -
rm -rf libnatpmp