Try to make windows installer work with wx 2.9.4.
[dcpomatic.git] / windows / installer.nsi.64.in
1 !include "MUI2.nsh"
2 !include "x64.nsh"
3
4 Name "DVD-o-matic"
5
6 RequestExecutionLevel admin
7
8 outFile "DVD-o-matic @version@ 64-bit Installer.exe"
9 !define MUI_ICON "%resources%/dvdomatic.ico"
10 !define MUI_UNICON "%resources%/dvdomatic.ico"
11 !define MUI_SPECIALBITMAP "%resources%/dvdomatic.bmp"
12
13 InstallDir "$PROGRAMFILES\DVD-o-matic"
14
15 !insertmacro MUI_PAGE_WELCOME
16 !insertmacro MUI_PAGE_LICENSE "../../COPYING"
17 !insertmacro MUI_PAGE_DIRECTORY
18 !insertmacro MUI_PAGE_INSTFILES
19 !insertmacro MUI_PAGE_FINISH
20
21 !insertmacro MUI_UNPAGE_WELCOME
22 !insertmacro MUI_UNPAGE_CONFIRM
23 !insertmacro MUI_UNPAGE_INSTFILES
24 !insertmacro MUI_UNPAGE_FINISH
25  
26 !insertmacro MUI_LANGUAGE "English"
27
28 Section "install" "Installation info"
29
30 ${If} ${RunningX64}
31    DetailPrint "Installer running on 64-bit host"
32    ; disable registry redirection (enable access to 64-bit portion of registry)
33    SetRegView 64
34    ; change install dir
35    StrCpy $INSTDIR "$PROGRAMFILES64\DVD-o-matic"
36 ${EndIf}
37
38 SetOutPath "$INSTDIR\bin"
39
40 File "%deps%/bin/asdcp-libdcp.dll"
41 File "%deps%/bin/avcodec-54.dll"
42 File "%deps%/bin/avfilter-3.dll"
43 File "%deps%/bin/avformat-54.dll"
44 File "%deps%/bin/avutil-51.dll"
45 File "%deps%/bin/dcp.dll"
46 File "%deps%/bin/libintl-8.dll"
47 File "%deps%/bin/kumu-libdcp.dll"
48 File "%deps%/bin/libboost_chrono-mt.dll"
49 File "%deps%/bin/libboost_filesystem-mt.dll"
50 File "%deps%/bin/libboost_system-mt.dll"
51 File "%deps%/bin/libboost_thread_win32-mt.dll"
52 File "%deps%/bin/libboost_date_time-mt.dll"
53 File "%deps%/bin/libeay32.dll"
54 File "%deps%/bin/libgcc_s_sjlj-1.dll"
55 File "%deps%/bin/libgio-2.0-0.dll"
56 File "%deps%/bin/libglib-2.0-0.dll"
57 File "%deps%/bin/libgobject-2.0-0.dll"
58 File "%deps%/bin/libiconv-2.dll"
59 File "%deps%/bin/libjpeg-8.dll"
60 File "%deps%/bin/libMagick++-5.dll"
61 File "%deps%/bin/libMagickCore-5.dll"
62 File "%deps%/bin/libMagickWand-5.dll"
63 File "%deps%/bin/libopenjpeg-1.dll"
64 File "%deps%/bin/libpng15-15.dll"
65 File "%deps%/bin/libsigc-2.0-0.dll"
66 File "%deps%/bin/libsndfile-1.dll"
67 File "%deps%/bin/libssh.dll"
68 File "%deps%/bin/libstdc++-6.dll"
69 File "%deps%/bin/postproc-52.dll"
70 File "%deps%/bin/swresample-0.dll"
71 File "%deps%/bin/swscale-2.dll"
72 File "%deps%/bin/zlib1.dll"
73 File "%deps%/bin/libjpeg-8.dll"
74 File "%deps%/bin/wxbase294u_gcc_custom.dll"
75 File "%deps%/bin/wxmsw294u_core_gcc_custom.dll"
76 File "%deps%/bin/wxmsw294u_adv_gcc_custom.dll"
77 File "%deps%/bin/libcairo-2.dll"
78 File "%deps%/bin/libfreetype-6.dll"
79 File "%deps%/bin/libgthread-2.0-0.dll"
80 File "%deps%/bin/libpango-1.0-0.dll"
81 File "%deps%/bin/libgmodule-2.0-0.dll"
82 File "%deps%/bin/libpangocairo-1.0-0.dll"
83 File "%deps%/bin/libpangowin32-1.0-0.dll"
84 File "%deps%/bin/libtiff-5.dll"
85 File "%deps%/bin/libglibmm-2.4-1.dll"
86 File "%deps%/bin/libxml++-2.6-2.dll"
87 File "%deps%/bin/libxml2-2.dll"
88
89 File "%binaries%/src/wx/dvdomatic-wx.dll"
90 File "%binaries%/src/lib/dvdomatic.dll"
91 File "%binaries%/src/tools/dvdomatic.exe"
92 File "%binaries%/src/tools/servomatic_cli.exe"
93 File "%binaries%/src/tools/servomatic_gui.exe"
94
95 # I don't know why, but sometimes it seems that 
96 # delegates.xml must be in with the binaries, and
97 # sometimes in the $PROFILE.  Meh.
98 File "%deps%/etc/ImageMagick/delegates.xml"
99 SetOutPath "$PROFILE\.magick"
100 File "%deps%/etc/ImageMagick/delegates.xml"
101
102 CreateShortCut "$DESKTOP\DVD-o-matic.lnk" "$INSTDIR\bin\dvdomatic.exe" ""
103 CreateShortCut "$DESKTOP\DVD-o-matic encode server.lnk" "$INSTDIR\bin\servomatic_gui.exe" ""
104  
105 CreateDirectory "$SMPROGRAMS\DVD-o-matic"
106 CreateShortCut "$SMPROGRAMS\DVD-o-matic\Uninstall.lnk" "$INSTDIR\Uninstall.exe" "" "$INSTDIR\Uninstall.exe" 0
107 CreateShortCut "$SMPROGRAMS\DVD-o-matic\DVD-o-matic.lnk" "$INSTDIR\bin\dvdomatic.exe" "" "$INSTDIR\bin\dvdomatic.exe" 0
108 CreateShortCut "$SMPROGRAMS\DVD-o-matic\DVD-o-matic encode server.lnk" "$INSTDIR\bin\servomatic_gui.exe" "" "$INSTDIR\bin\servomatic_gui.exe" 0
109  
110 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\DVD-o-matic" "DisplayName" "DVD-o-matic (remove only)"
111 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\DVD-o-matic" "UninstallString" "$INSTDIR\Uninstall.exe"
112  
113 WriteUninstaller "$INSTDIR\Uninstall.exe"
114  
115 SectionEnd
116  
117  
118 Section "Uninstall"
119  
120 RMDir /r "$INSTDIR\*.*"    
121 RMDir "$INSTDIR"
122 Delete "$DESKTOP\DVD-o-matic.lnk"
123 Delete "$DESKTOP\DVD-o-matic encode server.lnk"
124 Delete "$SMPROGRAMS\DVD-o-matic\*.*"
125 RmDir  "$SMPROGRAMS\DVD-o-matic"
126 DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\DVD-o-matic"
127 DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\DVD-o-matic"
128  
129 SectionEnd