Update script for dependencies on Cygwin

This commit is contained in:
q3aql 2022-01-02 17:02:55 +01:00
parent 4e37689196
commit 75cd8bc8cc

View File

@ -2,171 +2,31 @@
# Copy necessary tools for Cygwin/Windows version # Copy necessary tools for Cygwin/Windows version
# After, you must copy all files to /bin directory # After, you must copy all files to /bin directory
mkdir -p ${HOME}/ks-tools mkdir -p ${HOME}/ks-tools/bin/
cd /usr/bin cd /usr/bin
# All executables # All executables
cp -rfv bash.exe ${HOME}/ks-tools
cp -rfv bashbug ${HOME}/ks-tools
cp -rfv cat.exe ${HOME}/ks-tools
cp -rfv clear.exe ${HOME}/ks-tools
cp -rfv cut.exe ${HOME}/ks-tools
cp -rfv cygwin-console-helper.exe ${HOME}/ks-tools
cp -rfv date.exe ${HOME}/ks-tools
cp -rfv echo.exe ${HOME}/ks-tools
cp -rfv expr.exe ${HOME}/ks-tools
cp -rfv ffmpeg.exe ${HOME}/ks-tools
cp -rfv ffprobe.exe ${HOME}/ks-tools
cp -rfv find.exe ${HOME}/ks-tools
cp -rfv ftp.exe ${HOME}/ks-tools
cp -rfv grep.exe ${HOME}/ks-tools
cp -rfv head.exe ${HOME}/ks-tools
cp -rfv ls.exe ${HOME}/ks-tools
cp -rfv md5sum.exe ${HOME}/ks-tools
cp -rfv mkdir.exe ${HOME}/ks-tools
cp -rfv mv.exe ${HOME}/ks-tools
cp -rfv cp.exe ${HOME}/ks-tools
cp -rfv rm.exe ${HOME}/ks-tools
cp -rfv rsync.exe ${HOME}/ks-tools
cp -rfv scp.exe ${HOME}/ks-tools
cp -rfv sed.exe ${HOME}/ks-tools
cp -rfv sleep.exe ${HOME}/ks-tools
cp -rfv ssh-add.exe ${HOME}/ks-tools
cp -rfv ssh-agent.exe ${HOME}/ks-tools
cp -rfv ssh-keygen.exe ${HOME}/ks-tools
cp -rfv ssh-keyscan.exe ${HOME}/ks-tools
cp -rfv ssh.exe ${HOME}/ks-tools
cp -rfv sshpass.exe ${HOME}/ks-tools
cp -rfv tail.exe ${HOME}/ks-tools
cp -rfv tr.exe ${HOME}/ks-tools
cp -rfv wc.exe ${HOME}/ks-tools
cp -rfv pwd.exe ${HOME}/ks-tools
cp -rfv mintty.exe ${HOME}/ks-tools
cp -rfv x264.exe ${HOME}/ks-tools
cp -rfv zenity.exe ${HOME}/ks-tools
cp -rfv xvidcore.dll ${HOME}/ks-tools
cp -rfv file.exe ${HOME}/ks-tools
cp -rfv ldd.exe ${HOME}/ks-tools
cp -rfv touch.exe ${HOME}/ks-tools
cp -rfv nano.exe ${HOME}/ks-tools
# All libraries list_binary="bash bashbug cat clear cut cygwin-console-helper.exe date echo expr ffmpeg ffprobe find ftp grep head ls md5sum mkdir mv cp rm rsync scp sed sleep ssh-add ssh-agent ssh-keygen ssh-keyscan ssh sshpass tail tr wc pwd mintty x264 zenity file ldd touch nano"
cp -rfv cygwin1.dll ${HOME}/ks-tools
cp -rfv cygz.dll ${HOME}/ks-tools
cp -rfv cygattr-1.dll ${HOME}/ks-tools
cp -rfv cygcom_err-2.dll ${HOME}/ks-tools
cp -rfv cygcrypto-1.1.dll ${HOME}/ks-tools
cp -rfv cyggcc_s-1.dll ${HOME}/ks-tools
cp -rfv cyggmp-10.dll ${HOME}/ks-tools
cp -rfv cyggssapi_krb5-2.dll ${HOME}/ks-tools
cp -rfv cygiconv-2.dll ${HOME}/ks-tools
cp -rfv cygintl-8.dll ${HOME}/ks-tools
cp -rfv cygk5crypto-3.dll ${HOME}/ks-tools
cp -rfv cygkrb5-3.dll ${HOME}/ks-tools
cp -rfv cygkrb5support-0.dll ${HOME}/ks-tools
cp -rfv cygncursesw-10.dll ${HOME}/ks-tools
cp -rfv cygpcre-1.dll ${HOME}/ks-tools
cp -rfv cygpopt-0.dll ${HOME}/ks-tools
cp -rfv cygreadline7.dll ${HOME}/ks-tools
cp -rfv cygFLAC-8.dll ${HOME}/ks-tools
cp -rfv cygcaca-0.dll ${HOME}/ks-tools
cp -rfv cygexpat-1.dll ${HOME}/ks-tools
cp -rfv cygfontconfig-1.dll ${HOME}/ks-tools
cp -rfv cygfreetype-6.dll ${HOME}/ks-tools
cp -rfv cygfribidi-0.dll ${HOME}/ks-tools
cp -rfv cyggnutls-30.dll ${HOME}/ks-tools
cp -rfv cygiconv-2.dll ${HOME}/ks-tools
cp -rfv cygmp3lame-0.dll ${HOME}/ks-tools
cp -rfv cygncursesw-10.dll ${HOME}/ks-tools
cp -rfv cygpng16-16.dll ${HOME}/ks-tools
cp -rfv cygpopt-0.dll ${HOME}/ks-tools
cp -rfv cygpulse-0.dll ${HOME}/ks-tools
cp -rfv cygtheoradec-1.dll ${HOME}/ks-tools
cp -rfv cygtheoraenc-1.dll ${HOME}/ks-tools
cp -rfv cygtwolame-0.dll ${HOME}/ks-tools
cp -rfv cygvorbis-0.dll ${HOME}/ks-tools
cp -rfv cygvorbisenc-2.dll ${HOME}/ks-tools
cp -rfv cygvpx-5.dll ${HOME}/ks-tools
cp -rfv cygwavpack-1.dll ${HOME}/ks-tools
cp -rfv cygwebp-7.dll ${HOME}/ks-tools
cp -rfv cygmagic-1.dll ${HOME}/ks-tools
cp -rfv cygbz2-1.dll ${HOME}/ks-tools
cp -rfv cygSDL2-2-0-0.dll ${HOME}/ks-tools
cp -rfv cygopenal-1.dll ${HOME}/ks-tools
cp -rfv cygxcb-shm-0.dll ${HOME}/ks-tools
cp -rfv cygxcb-1.dll ${HOME}/ks-tools
cp -rfv cygcairo-2.dll ${HOME}/ks-tools
cp -rfv cygglib-2.0-0.dll ${HOME}/ks-tools
cp -rfv cyggobject-2.0-0.dll ${HOME}/ks-tools
cp -rfv cyggsm-1.dll ${HOME}/ks-tools
cp -rfv cyglzma-5.dll ${HOME}/ks-tools
cp -rfv cygopenjp2-7.dll ${HOME}/ks-tools
cp -rfv cygopus-0.dll ${HOME}/ks-tools
cp -rfv cygrsvg-2-2.dll ${HOME}/ks-tools
cp -rfv cygsnappy-1.dll ${HOME}/ks-tools
cp -rfv cygwebpmux-3.dll ${HOME}/ks-tools
cp -rfv cygass-9.dll ${HOME}/ks-tools
cp -rfv cygbs2b-0.dll ${HOME}/ks-tools
cp -rfv cygflite*.dll ${HOME}/ks-tools
cp -rfv cygsoxr-0.dll ${HOME}/ks-tools
cp -rfv cygGLU-1.dll ${HOME}/ks-tools
cp -rfv cygGL-1.dll ${HOME}/ks-tools
cp -rfv cygglut-3.dll ${HOME}/ks-tools
cp -rfv cyggme-0.dll ${HOME}/ks-tools
cp -rfv cygssh-4.dll ${HOME}/ks-tools
cp -rfv cygxml2-2.dll ${HOME}/ks-tools
cp -rfv cygzmq-5.dll ${HOME}/ks-tools
cp -rfv cygX11-6.dll ${HOME}/ks-tools
cp -rfv cygdbus-1-3.dll ${HOME}/ks-tools
cp -rfv cygpulsecommon-11.1.dll ${HOME}/ks-tools
cp -rfv cygharfbuzz-0.dll ${HOME}/ks-tools
cp -rfv cygffi-6.dll ${HOME}/ks-tools
cp -rfv cygcroco-0.6-3.dll ${HOME}/ks-tools
cp -rfv cyggdk_pixbuf-2.0-0.dll ${HOME}/ks-tools
cp -rfv cyggio-2.0-0.dll ${HOME}/ks-tools
cp -rfv cygXdmcp-6.dll ${HOME}/ks-tools
cp -rfv cygXau-6.dll ${HOME}/ks-tools
cp -rfv cygstdc++-6.dll ${HOME}/ks-tools
cp -rfv cyguuid-1.dll ${HOME}/ks-tools
cp -rfv cygbrotlidec-1.dll ${HOME}/ks-tools
cp -rfv cygsodium-23.dll ${HOME}/ks-tools
cp -rfv cyghogweed-4.dll ${HOME}/ks-tools
cp -rfv cygidn2-0.dll ${HOME}/ks-tools
cp -rfv cygpixman-1-0.dll ${HOME}/ks-tools
cp -rfv cygxcb-render-0.dll ${HOME}/ks-tools
cp -rfv cygXext-6.dll ${HOME}/ks-tools
cp -rfv cygXrender-1.dll ${HOME}/ks-tools
cp -rfv cygpango-1.0-0.dll ${HOME}/ks-tools
cp -rfv cygpangocairo-1.0-0.dll ${HOME}/ks-tools
cp -rfv cygpangoft2-1.0-0.dll ${HOME}/ks-tools
cp -rfv cygogg-0.dll ${HOME}/ks-tools
cp -rfv cygnettle-6.dll ${HOME}/ks-tools
cp -rfv cygtasn1-6.dll ${HOME}/ks-tools
cp -rfv cygp11-kit-0.dll ${HOME}/ks-tools
cp -rfv cygunistring-2.dll ${HOME}/ks-tools
cp -rfv cyggomp-1.dll ${HOME}/ks-tools
cp -rfv cygthai-0.dll ${HOME}/ks-tools
cp -rfv cyggmodule-2.0-0.dll ${HOME}/ks-tools
cp -rfv cygXi-6.dll ${HOME}/ks-tools
cp -rfv cygXrandr-2.dll ${HOME}/ks-tools
cp -rfv cygX11-xcb-1.dll ${HOME}/ks-tools
cp -rfv cygxcb-glx-0.dll ${HOME}/ks-tools
cp -rfv cygglapi-0.dll ${HOME}/ks-tools
cp -rfv cygasyncns-0.dll ${HOME}/ks-tools
cp -rfv cygsndfile-1.dll ${HOME}/ks-tools
cp -rfv cygwrap-0.dll ${HOME}/ks-tools
cp -rfv cyggraphite2-3.dll ${HOME}/ks-tools
cp -rfv cygbrotlicommon-1.dll ${HOME}/ks-tools
cp -rfv cygdatrie-1.dll ${HOME}/ks-tools
cp -rfv cyglz4-1.dll ${HOME}/ks-tools
cp -rfv cygzstd-1.dll ${HOME}/ks-tools
# Strip libraries for binary in ${list_binary} ; do
strip --strip-all ${HOME}/ks-tools/* echo "* Copying binary ${binary}"
cp -rfv cygwin1.dll ${HOME}/ks-tools cp -rfv /usr/bin/${binary}.exe ${HOME}/ks-tools/bin/
cp -rfv cygz.dll ${HOME}/ks-tools echo "* Searching dependencies for ${binary}"
ldd /usr/bin/${binary}.exe | grep "/bin/" | cut -d ">" -f 2 | cut -d "(" -f 1 | tr -s " " > /tmp/deps.txt
file_size=$(cat /tmp/deps.txt | wc -l)
file_scan=1
echo "* Copying dependencies for ${binary}"
while [ ${file_scan} -le ${file_size} ] ; do
library=$(cat /tmp/deps.txt | head -${file_scan} | tail -1)
cp -rfv ${library} ${HOME}/ks-tools/bin/
file_scan=$(expr ${file_scan} + 1)
done
done
strip --strip-all ${HOME}/ks-tools/bin/*
cp -rfv /usr/bin/cyggcc_s-*.dll ${HOME}/ks-tools/bin/
cp -rfv /usr/bin/cygwin1.dll ${HOME}/ks-tools/bin/
cp -rfv /usr/bin/cygz.dll ${HOME}/ks-tools/bin/
# FFmpeg build parameters
#./configure --prefix=/home/q3aql/ffmpeg-build --extra-version=ks-tools --enable-gpl --disable-stripping --disable-ffplay --enable-avresample --disable-filter=resample --enable-gnutls --enable-libass --enable-libbs2b --enable-libcaca --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librsvg --enable-libsnappy --enable-libsoxr --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libxml2 --enable-libxvid --enable-libzmq --enable-openal --enable-sdl2 --enable-libx264 --enable-shared --enable-static --enable-version3 --disable-doc
# Finally, copy ks-tools scripts here. # Finally, copy ks-tools scripts here.