3 # we assume this script is <ardour-src>/tools/x-win/package.sh
4 pushd "`/usr/bin/dirname \"$0\"`" > /dev/null; this_script_dir="`pwd`"; popd > /dev/null
7 . ../define_versions.sh
9 cd $this_script_dir/../..
11 test -f gtk2_ardour/wscript || exit 1
13 # Defaults (overridden by environment)
14 : ${XARCH=i686} # or x86_64
15 : ${ROOT=/home/ardour}
18 : ${SRCCACHE=/var/tmp/winsrc} # source-code tgz cache
20 # TODO: grep from build/config.log instead
21 while [ $# -gt 0 ] ; do
32 # see also wscript, video_tool_paths.cc, bundle_env_mingw.cc
33 # registry keys based on this are used there
36 PROGRAM_VERSION=${major_version}
38 LOWERCASE_DIRNAME=ardour${major_version}
39 STATEFILE_SUFFIX=ardour # see filename_extensions.cc
41 if test -n "$MIXBUS"; then
47 PRODUCT_ID=${PROGRAM_NAME}${PROGRAM_VERSION}
48 PRODUCT_EXE=${PRODUCT_NAME}.exe
49 PRODUCT_ICON=${PRODUCT_NAME}.ico
51 ###############################################################################
53 echo "Packaging $PRODUCT_ID"
55 if test "$XARCH" = "x86_64" -o "$XARCH" = "amd64"; then
56 echo "Target: 64bit Windows (x86_64)"
57 XPREFIX=x86_64-w64-mingw32
60 echo "Target: 32 Windows (i686)"
61 XPREFIX=i686-w64-mingw32
65 : ${PREFIX=${ROOT}/win-stack-$WARCH}
68 if [ "$(id -u)" = "0" ]; then
69 apt-get -y install nsis curl
74 echo "--- Downloading.. $2"
75 test -f ${SRCCACHE}/$1 || curl -k -L -o ${SRCCACHE}/$1 $2
78 ################################################################################
81 ARDOURVERSION=${release_version}
83 if ! test -f build/gtk2_ardour/ardour-${ARDOURVERSION}.exe; then
84 echo "*** Please compile ardour-${ARDOURVERSION}.exe first."
88 echo " === bundle to $DESTDIR"
92 ################################################################################
94 if test -z "$DESTDIR"; then
96 trap 'rm -rf $DESTDIR' exit SIGINT SIGTERM
99 echo " === bundle to $DESTDIR"
101 ALIBDIR=$DESTDIR/lib/${LOWERCASE_DIRNAME}
104 mkdir -p $DESTDIR/bin
105 mkdir -p $DESTDIR/share/
106 mkdir -p $ALIBDIR/surfaces
107 mkdir -p $ALIBDIR/backends
108 mkdir -p $ALIBDIR/panners
109 mkdir -p $ALIBDIR/vamp
110 mkdir -p $ALIBDIR/suil
112 cp build/libs/gtkmm2ext/gtkmm2ext-*.dll $DESTDIR/bin/
113 cp build/libs/midi++2/midipp-*.dll $DESTDIR/bin/
114 cp build/libs/evoral/evoral-*.dll $DESTDIR/bin/
115 cp build/libs/ardour/ardour-*.dll $DESTDIR/bin/
116 cp build/libs/timecode/timecode.dll $DESTDIR/bin/
117 cp build/libs/qm-dsp/qmdsp-*.dll $DESTDIR/bin/
118 cp build/libs/canvas/canvas-*.dll $DESTDIR/bin/
119 cp build/libs/pbd/pbd-*.dll $DESTDIR/bin/
120 cp build/libs/ptformat/ptformat-*.dll $DESTDIR/bin/
121 cp build/libs/audiographer/audiographer-*.dll $DESTDIR/bin/
122 cp build/libs/fst/ardour-vst-scanner.exe $DESTDIR/bin/ || true
123 cp `ls -t build/gtk2_ardour/ardour-*.exe | head -n1` $DESTDIR/bin/${PRODUCT_EXE}
125 mkdir -p $DESTDIR/lib/gtk-2.0/engines
126 cp build/libs/clearlooks-newer/clearlooks.dll $DESTDIR/lib/gtk-2.0/engines/libclearlooks.la
128 cp $PREFIX/bin/*dll $DESTDIR/bin/
129 cp $PREFIX/lib/*dll $DESTDIR/bin/
130 # special case libportaudio (wasapi), old stack has no wasapi and hence no .xp
131 cp $PREFIX/bin/libportaudio-2.xp $DESTDIR/bin/ || cp $PREFIX/bin/libportaudio-2.dll $DESTDIR/bin/libportaudio-2.xp
132 rm -rf $DESTDIR/bin/libjack*.dll
134 cp `find build/libs/surfaces/ -iname "*.dll"` $ALIBDIR/surfaces/
135 cp `find build/libs/backends/ -iname "*.dll"` $ALIBDIR/backends/
136 cp `find build/libs/panners/ -iname "*.dll"` $ALIBDIR/panners/
138 cp -r build/libs/LV2 $ALIBDIR/
139 cp -r build/libs/vamp-plugins/*ardourvampplugins*.dll $ALIBDIR/vamp/libardourvampplugins.dll
140 cp $PREFIX/lib/suil-*/*.dll $ALIBDIR/suil/ || true
142 # lv2 core, classifications etc - TODO check if we need the complete LV2 ontology
143 if test -d $PREFIX/lib/lv2/lv2core.lv2 ; then
144 cp -R $PREFIX/lib/lv2/lv2core.lv2 $ALIBDIR/LV2/
147 mv $ALIBDIR/surfaces/ardourcp*.dll $DESTDIR/bin/
149 # TODO use -static-libgcc -static-libstdc++ -- but for .exe files only
150 if update-alternatives --query ${XPREFIX}-gcc | grep Value: | grep -q win32; then
151 cp /usr/lib/gcc/${XPREFIX}/*-win32/libgcc_s_*.dll $DESTDIR/bin/
152 cp /usr/lib/gcc/${XPREFIX}/*-win32/libstdc++-6.dll $DESTDIR/bin/
153 elif update-alternatives --query ${XPREFIX}-gcc | grep Value: | grep -q posix; then
154 cp /usr/lib/gcc/${XPREFIX}/*-posix/libgcc_s_*.dll $DESTDIR/bin/
155 cp /usr/lib/gcc/${XPREFIX}/*-posix/libstdc++-6.dll $DESTDIR/bin/
157 cp /usr/lib/gcc/${XPREFIX}/*/libgcc_s_sjlj-1.dll $DESTDIR/bin/
158 cp /usr/lib/gcc/${XPREFIX}/*/libstdc++-6.dll $DESTDIR/bin/
160 #Ubuntu's 14.04's mingw needs this one for the std libs above
161 if test -f /usr/${XPREFIX}/lib/libwinpthread-1.dll; then
162 cp /usr/${XPREFIX}/lib/libwinpthread-1.dll $DESTDIR/bin/
165 cp -r $PREFIX/share/${LOWERCASE_DIRNAME} $DESTDIR/share/
166 cp -r $PREFIX/share/locale $DESTDIR/share/
167 cp -r $PREFIX/etc/${LOWERCASE_DIRNAME}/* $DESTDIR/share/${LOWERCASE_DIRNAME}/
169 cp COPYING $DESTDIR/share/
170 cp gtk2_ardour/icons/${PRODUCT_ICON} $DESTDIR/share/
171 cp gtk2_ardour/icons/ardour_bug.ico $DESTDIR/share/
173 # replace default cursor with square version (sans hotspot file)
174 cp gtk2_ardour/icons/cursor_square/* $DESTDIR/share/${LOWERCASE_DIRNAME}/icons/
176 # clean build-dir after depoyment
177 echo " === bundle completed, cleaning up"
182 ################################################################################
184 if test -z "$NOVIDEOTOOLS"; then
185 echo " === Including video-tools"
186 HARVID_VERSION=$(curl -s -S http://ardour.org/files/video-tools/harvid_version.txt)
187 XJADEO_VERSION=$(curl -s -S http://ardour.org/files/video-tools/xjadeo_version.txt)
189 rsync -a -q --partial \
190 rsync://ardour.org/video-tools/harvid_win-${HARVID_VERSION}.tar.xz \
191 "${SRCCACHE}/harvid_win-${HARVID_VERSION}.tar.xz"
193 rsync -a -q --partial \
194 rsync://ardour.org/video-tools/xjadeo_win-${XJADEO_VERSION}.tar.xz \
195 "${SRCCACHE}/xjadeo_win-${XJADEO_VERSION}.tar.xz"
198 tar -xf "${SRCCACHE}/harvid_win-${HARVID_VERSION}.tar.xz" -C "$DESTDIR/video/"
199 tar -xf "${SRCCACHE}/xjadeo_win-${XJADEO_VERSION}.tar.xz" -C "$DESTDIR/video/"
202 du -sh $DESTDIR/video
206 ################################################################################
207 ### include static gdb - re-zipped binaries from
208 ### http://sourceforge.net/projects/mingw/files/MinGW/Extension/gdb/gdb-7.6.1-1/gdb-7.6.1-1-mingw32-bin.tar.lzma
209 ### http://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win64/Personal%20Builds/mingw-builds/4.9.1/threads-win32/sjlj/x86_64-4.9.1-release-win32-sjlj-rt_v3-rev1.7z
210 if ! grep " using ./waf configure" build/config.log | grep -q -- "--optimize"; then
211 download gdb-static-win3264.tar.xz http://robin.linuxaudio.org/gdb-static-win3264.tar.xz
213 tar xf gdb-static-win3264.tar.xz
216 echo " === Creating debug.bat"
217 cp -r ${SRCCACHE}/gdb_$WARCH $DESTDIR/gdb
218 cat > $DESTDIR/debug.bat << EOF
220 START ..\\gdb\\bin\\gdb.exe -iex "set logging overwrite on" -iex "set height 0" -iex "set logging on %UserProfile%\\${PRODUCT_NAME}-debug.log" -iex "target exec ${PRODUCT_EXE}" -iex "run"
222 OUTFILE="${TMPDIR}/${PRODUCT_NAME}-${ARDOURVERSION}-dbg-${WARCH}-Setup.exe"
223 VERSIONINFO="Debug Version."
225 OUTFILE="${TMPDIR}/${PRODUCT_NAME}-${ARDOURVERSION}-${WARCH}-Setup.exe"
226 VERSIONINFO="Optimized Version."
229 ################################################################################
230 ### Mixbus plugins, etc
231 if test x$WITH_X42_LV2 != x ; then
232 mkdir -p $ALIBDIR/LV2
234 echo "Adding x42 Plugins"
236 METERS_VERSION=$(curl -s -S http://x42-plugins.com/x42/win/x42-meters.latest.txt)
237 rsync -a -q --partial \
238 rsync://x42-plugins.com/x42/win/x42-meters-lv2-${WARCH}-${METERS_VERSION}.zip \
239 "${SRCCACHE}/x42-meters-lv2-${WARCH}-${METERS_VERSION}.zip"
240 unzip -q -d "$ALIBDIR/LV2/" "${SRCCACHE}/x42-meters-lv2-${WARCH}-${METERS_VERSION}.zip"
242 SETBFREE_VERSION=$(curl -s -S http://x42-plugins.com/x42/win/setBfree.latest.txt)
243 rsync -a -q --partial \
244 rsync://x42-plugins.com/x42/win/setBfree-lv2-${WARCH}-${SETBFREE_VERSION}.zip \
245 "${SRCCACHE}/setBfree-lv2-${WARCH}-${SETBFREE_VERSION}.zip"
246 unzip -q -d "$ALIBDIR/LV2/" "${SRCCACHE}/setBfree-lv2-${WARCH}-${SETBFREE_VERSION}.zip"
248 MIDIFILTER_VERSION=$(curl -s -S http://x42-plugins.com/x42/win/x42-midifilter.latest.txt)
249 rsync -a -q --partial \
250 rsync://x42-plugins.com/x42/win/x42-midifilter-lv2-${WARCH}-${MIDIFILTER_VERSION}.zip \
251 "${SRCCACHE}/x42-midifilter-lv2-${WARCH}-${MIDIFILTER_VERSION}.zip"
252 unzip -q -d "$ALIBDIR/LV2/" "${SRCCACHE}/x42-midifilter-lv2-${WARCH}-${MIDIFILTER_VERSION}.zip"
255 if test x$WITH_HARRISON_LV2 != x ; then
256 mkdir -p $ALIBDIR/LV2
258 echo "Including Harrison LV2s"
260 curl -s -S --fail -# \
261 -z "${SRCCACHE}/harrison_lv2s.${WARCH}.zip" \
262 -o "${SRCCACHE}/harrison_lv2s.${WARCH}.zip" \
263 "http://www.harrisonconsoles.com/mixbus/mb3/beta/harrison-dsp/harrison_lv2s.${WARCH}.zip"
264 unzip -q -d "$ALIBDIR/LV2/" "${SRCCACHE}/harrison_lv2s.${WARCH}.zip"
267 if test -n "$MIXBUS"; then
268 echo "Deploying Harrison Mixbus Channelstrip"
270 mkdir -p $ALIBDIR/ladspa/strip
271 curl -s -S --fail -# \
272 -z "${SRCCACHE}/harrison_channelstrip.${WARCH}.dll" \
273 -o "${SRCCACHE}/harrison_channelstrip.${WARCH}.dll" \
274 "http://www.harrisonconsoles.com/mixbus/mb3/beta/harrison-dsp/harrison_channelstrip.${WARCH}.dll"
276 cp "${SRCCACHE}/harrison_channelstrip.${WARCH}.dll" \
277 "$ALIBDIR/ladspa/strip/harrison_channelstrip.dll"
280 ( cd $DESTDIR ; find . ) > ${TMPDIR}/file_list.txt
282 ################################################################################
283 echo " === Preparing Windows Installer"
284 NSISFILE=$DESTDIR/a3.nsis
286 if test "$WARCH" = "w64"; then
291 # TODO we should only add this for 32bit on 64bit windows!
295 if test -n "$QUICKZIP" ; then
296 cat > $NSISFILE << EOF
300 cat > $NSISFILE << EOF
301 SetCompressor /SOLID lzma
302 SetCompressorDictSize 32
306 cat >> $NSISFILE << EOF
307 !addincludedir "${this_script_dir}\\nsis"
309 !include FileAssociation.nsh
312 Name "${PROGRAM_NAME}${PROGRAM_VERSION}"
314 RequestExecutionLevel admin
315 InstallDir "\$${PGF}\\${PRODUCT_ID}"
316 InstallDirRegKey HKLM "Software\\${PROGRAM_NAME}\\${PRODUCT_ID}\\$WARCH" "Install_Dir"
317 !define MUI_ICON "share\\${PRODUCT_ICON}"
321 if test -n "$MIXBUS"; then
323 # TODO: proper welcome/finish text.
324 cat >> $NSISFILE << EOF
325 !define MUI_FINISHPAGE_TITLE "Welcome to Harrison Mixbus"
326 !define MUI_FINISHPAGE_TEXT "Thanks for your purchase of Mixbus!\$\\r\$\\nYou will find the Mixbus application in the Start Menu (or the All Apps panel for Windows 8) \$\\r\$\\nClick the link below to view the Mixbus manual, and learn ways to get involved with the Mixbus community."
327 !define MUI_FINISHPAGE_LINK "Mixbus Manual"
328 !define MUI_FINISHPAGE_LINK_LOCATION "http://www.harrisonconsoles.com/mixbus/mixbus3-live-manual"
329 !define MUI_FINISHPAGE_NOREBOOTSUPPORT
334 cat >> $NSISFILE << EOF
335 !define MUI_FINISHPAGE_TITLE "Welcome to Ardour"
336 !define MUI_FINISHPAGE_TEXT "This windows versions or Ardour is provided as-is.\$\\r\$\\nThe Ardour community currently has no expertise in supporting windows users, and there are no developers focusing on windows specific issues either.\$\\r\$\\nIf you like Ardour, please consider helping out."
337 !define MUI_FINISHPAGE_LINK "Ardour on Windows"
338 !define MUI_FINISHPAGE_LINK_LOCATION "http://ardour.org/windows.html"
339 #this would run as admin - see http://forums.winamp.com/showthread.php?t=353366
340 #!define MUI_FINISHPAGE_RUN "\$INSTDIR\\bin\\${PRODUCT_EXE}"
341 !define MUI_FINISHPAGE_NOREBOOTSUPPORT
346 cat >> $NSISFILE << EOF
347 !define MUI_ABORTWARNING
348 !insertmacro MUI_PAGE_LICENSE "share\\COPYING"
349 !insertmacro MUI_PAGE_COMPONENTS
350 !insertmacro MUI_PAGE_DIRECTORY
351 !insertmacro MUI_PAGE_INSTFILES
352 !insertmacro MUI_PAGE_FINISH
353 !insertmacro MUI_UNPAGE_CONFIRM
354 !insertmacro MUI_UNPAGE_INSTFILES
355 !insertmacro MUI_LANGUAGE "English"
357 Section "${PROGRAM_NAME}${PROGRAM_VERSION} (required)" SecMainProg
363 File /nonfatal debug.bat
364 File /nonfatal /r gdb
365 WriteRegStr HKLM "Software\\${PROGRAM_NAME}\\v${PROGRAM_VERSION}\\$WARCH" "Install_Dir" "\$INSTDIR"
366 WriteRegStr HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" "DisplayName" "${PROGRAM_NAME}${PROGRAM_VERSION}"
367 WriteRegStr HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" "UninstallString" '"\$INSTDIR\\uninstall.exe"'
368 WriteRegDWORD HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" "NoModify" 1
369 WriteRegDWORD HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" "NoRepair" 1
370 WriteUninstaller "\$INSTDIR\uninstall.exe"
371 CreateShortCut "\$INSTDIR\\${PROGRAM_NAME}${PROGRAM_VERSION}.lnk" "\$INSTDIR\\bin\\${PRODUCT_EXE}" "" "\$INSTDIR\\bin\\${PRODUCT_EXE}" 0
372 \${registerExtension} "\$INSTDIR\\bin\\${STATEFILE_SUFFIX}" ".${PRODUCT_NAME}" "${PROGRAM_NAME} Session"
375 Section "WASAPI sound driver" SecWASAPI
379 if test -z "$NOVIDEOTOOLS"; then
381 cat >> $NSISFILE << EOF
382 Section "Videotimeline Tools" SecVideo
383 WriteRegStr HKLM "Software\\${PROGRAM_NAME}\\v${PROGRAM_VERSION}\\video" "Install_Dir" "\$INSTDIR\\video"
391 cat >> $NSISFILE << EOF
392 Section "Start Menu Shortcuts" SecMenu
393 SetShellVarContext all
394 CreateDirectory "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}"
395 CreateShortCut "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}\\${PROGRAM_NAME}${PROGRAM_VERSION}.lnk" "\$INSTDIR\\bin\\${PRODUCT_EXE}" "" "\$INSTDIR\\bin\\${PRODUCT_EXE}" 0
398 if test -f "$DESTDIR/debug.bat"; then
399 cat >> $NSISFILE << EOF
400 CreateShortCut "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}\\${PROGRAM_NAME}${PROGRAM_VERSION} GDB.lnk" "\$INSTDIR\\debug.bat" "" "\$INSTDIR\\share\\ardour_bug.ico" 0
404 if test -z "$NOVIDEOTOOLS"; then
405 cat >> $NSISFILE << EOF
406 IfFileExists "\$INSTDIR\\video\\xjadeo\\xjadeo.exe" 0 +2
407 CreateShortCut "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}\\Video Monitor.lnk" "\$INSTDIR\\video\\xjadeo\\xjadeo.exe" "" "\$INSTDIR\\video\\xjadeo\\xjadeo.exe" 0
411 cat >> $NSISFILE << EOF
412 CreateShortCut "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}\\Uninstall.lnk" "\$INSTDIR\\uninstall.exe" "" "\$INSTDIR\\uninstall.exe" 0
414 LangString DESC_SecMainProg \${LANG_ENGLISH} "${PROGRAM_NAME} ${ARDOURVERSION}\$\\r\$\\n${VERSIONINFO}\$\\r\$\\n${ARDOURDATE}"
415 LangString DESC_SecWASAPI \${LANG_ENGLISH} "WASAPI Audio Driver\$\\r\$\\nOnly works on Vista or later. Windows 10 Users may currently also experience issues if this is installed."
418 if test -z "$NOVIDEOTOOLS"; then
419 cat >> $NSISFILE << EOF
420 LangString DESC_SecVideo \${LANG_ENGLISH} "Video Tools\$\\r\$\\nxjadeo-${XJADEO_VERSION}\$\\r\$\\nharvid-${HARVID_VERSION}"
424 cat >> $NSISFILE << EOF
425 LangString DESC_SecMenu \${LANG_ENGLISH} "Create Start-Menu Shortcuts (recommended)."
426 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
427 !insertmacro MUI_DESCRIPTION_TEXT \${SecMainProg} \$(DESC_SecMainProg)
428 !insertmacro MUI_DESCRIPTION_TEXT \${SecWASAPI} \$(DESC_SecWASAPI)
431 if test -z "$NOVIDEOTOOLS"; then
432 cat >> $NSISFILE << EOF
433 !insertmacro MUI_DESCRIPTION_TEXT \${SecVideo} \$(DESC_SecVideo)
437 cat >> $NSISFILE << EOF
438 !insertmacro MUI_DESCRIPTION_TEXT \${SecMenu} \$(DESC_SecMenu)
439 !insertmacro MUI_FUNCTION_DESCRIPTION_END
441 SetShellVarContext all
442 DeleteRegKey HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}"
443 DeleteRegKey HKLM "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}"
444 DeleteRegKey HKLM "Software\\${PROGRAM_NAME}\\v${PROGRAM_VERSION}"
445 RMDir /r "\$INSTDIR\\bin"
446 RMDir /r "\$INSTDIR\\lib"
447 RMDir /r "\$INSTDIR\\share"
448 RMDir /r "\$INSTDIR\\gdb"
449 RMDir /r "\$INSTDIR\\video"
450 Delete "\$INSTDIR\\debug.bat"
451 Delete "\$INSTDIR\\uninstall.exe"
452 Delete "\$INSTDIR\\${PROGRAM_NAME}${PROGRAM_VERSION}.lnk"
454 Delete "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}\\*.*"
455 RMDir "\$SMPROGRAMS\\${PRODUCT_ID}${SFX}"
456 \${unregisterExtension} ".${STATEFILE_SUFFIX}" "${PROGRAM_NAME} Session"
462 ReadRegStr \$R0 HKLM \
463 "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" \
467 MessageBox MB_OKCANCEL|MB_ICONEXCLAMATION \
468 "${PROGRAM_NAME} is already installed. Click 'OK' to remove the previous version or 'Cancel' to cancel this upgrade." \
474 ExecWait '\$R0 _?=\$INSTDIR'
475 IfErrors uninstall_error
477 ReadRegStr \$R1 HKLM \
478 "Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\${PRODUCT_ID}-${WARCH}" \
480 StrCmp \$R1 "" 0 done
482 Delete "\$INSTDIR\\uninstall.exe"
488 MessageBox MB_OK|MB_ICONEXCLAMATION \
489 "Uninstaller did not complete successfully. Continue at your own risk..." \
494 \${If} \${AtMostWinXP}
495 SectionSetFlags \${SecWASAPI} \${SF_RO}
497 SectionSetFlags \${SecWASAPI} \${SF_SELECTED}
502 Function .onInstSuccess
504 \${If} \${AtMostWinXP}
508 SectionGetFlags \${SecWASAPI} \$R0
510 IntOp \$R0 \$R0 & \${SF_SELECTED}
511 IntCmp \$R0 \${SF_SELECTED} pa_with_wasapi pa_no_wasapi
514 ; VISTA .. 9, libportaudio with WASAPI is good.
515 Delete "\$INSTDIR\\bin\\libportaudio-2.xp"
518 ; Windows XP lacks support for WASAPI, Windows10 on some system has issues
519 ; http://tracker.ardour.org/view.php?id=6507
521 Delete "\$INSTDIR\\bin\\libportaudio-2.dll"
522 Rename "\$INSTDIR\\bin\\libportaudio-2.xp" "\$INSTDIR\\bin\\libportaudio-2.dll"
530 echo " === OutFile: $OUTFILE"
532 if test -n "$QUICKZIP" ; then
533 echo " === Building Windows Installer (fast zip)"
535 echo " === Building Windows Installer (lzma compression takes ages)"
537 time makensis -V2 $NSISFILE