Bump version
[idzebra-moved-to-github.git] / win / zebra.nsi
1 ; $Id: zebra.nsi,v 1.9 2003-02-20 21:13:37 adam Exp $
2
3 !define VERSION "1.3.5"
4
5 Name "Zebra"
6 Caption "Index Data Yebra ${VERSION} Setup"
7 OutFile "idzebra_${VERSION}.exe"
8
9 LicenseText "You must read the following license before installing:"
10 LicenseData license.txt
11
12 ComponentText "This will install Zebra on your computer:"
13 InstType "Full (w/ Source)"
14 InstType "Lite (w/o Source)"
15
16 ; Some default compiler settings (uncomment and change at will):
17 ; SetCompress auto ; (can be off or force)
18 ; SetDatablockOptimize on ; (can be off)
19 ; CRCCheck on ; (can be off)
20 ; AutoCloseWindow false ; (can be true for the window go away automatically at end)
21 ; ShowInstDetails hide ; (can be show to have them shown, or nevershow to disable)
22 ; SetDateSave off ; (can be on to have files restored to their orginal date)
23
24 InstallDir "$PROGRAMFILES\Zebra"
25 InstallDirRegKey HKLM "SOFTWARE\Index Data\Zebra" ""
26 DirShow show ; (make this hide to not let the user change it)
27 DirText "Select the directory to install Zebra in:"
28
29 Section "" ; (default section)
30         SetOutPath "$INSTDIR"
31         ; add files / whatever that need to be installed here.
32         WriteRegStr HKLM "SOFTWARE\Index Data\Zebra" "" "$INSTDIR"
33         WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Zebra" "DisplayName" "Zebra ${VERSION} (remove only)"
34         WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Zebra" "UninstallString" '"$INSTDIR\uninst.exe"'
35         ; write out uninstaller
36         WriteUninstaller "$INSTDIR\uninst.exe"
37         SetOutPath "$SMPROGRAMS\Index Data\Zebra\"
38         CreateShortCut "$SMPROGRAMS\Index Data\Zebra\Zebra Program Directory.lnk" \
39                  "$INSTDIR"
40         WriteINIStr "$SMPROGRAMS\Index Data\Zebra\Zebra Home page.url" \
41               "InternetShortcut" "URL" "http://www.indexdata.dk/zebra/"
42         CreateShortCut "$SMPROGRAMS\Index Data\Zebra\Uninstall Zebra.lnk" \
43                 "$INSTDIR\uninst.exe"
44         SetOutPath $INSTDIR
45         File ..\LICENSE.zebra
46         File ..\README
47         SetOutPath $INSTDIR
48         File /r ..\tab
49 SectionEnd ; end of default section
50
51 Section "Zebra Runtime"
52         SectionIn 1 2
53         SetOutPath $INSTDIR\bin
54         File ..\bin\*.exe
55         File ..\bin\*.dll
56 SectionEnd
57
58 Section "Zebra Development"
59         SectionIn 1
60         SetOutPath $INSTDIR\include
61         File ..\include\*.h
62         SetOutPath $INSTDIR\lib
63         File ..\lib\*.lib
64 SectionEnd
65
66 Section "Zebra Documentation"
67         SectionIn 1 2
68         SetOutPath $INSTDIR
69         File /r ..\doc
70         SetOutPath "$SMPROGRAMS\Index Data\Zebra\"
71         CreateShortCut "$SMPROGRAMS\Index Data\Zebra\HTML Documentation.lnk" \
72                  "$INSTDIR\doc\zebra.html"
73         CreateShortCut "$SMPROGRAMS\Index Data\Zebra\PDF Documentaion.lnk" \
74                  "$INSTDIR\doc\zebra.pdf"
75 SectionEnd
76
77 Section "Zebra Examples"
78         SectionIn 1 2
79
80         SetOutPath $INSTDIR
81
82         File /r ..\test
83 ;       File /r ..\examples
84 SectionEnd
85
86 Section "Zebra Source"
87         SectionIn 1
88         SetOutPath $INSTDIR\util
89         File ..\util\*.c
90         SetOutPath $INSTDIR\dfa
91         File ..\dfa\*.c
92         File ..\dfa\*.h
93         SetOutPath $INSTDIR\index
94         File ..\index\*.c
95         File ..\index\*.h
96         SetOutPath $INSTDIR\isams
97         File ..\isams\*.c
98         SetOutPath $INSTDIR\isam
99         File ..\isam\*.c
100         File ..\isam\*.h
101         SetOutPath $INSTDIR\isamc
102         File ..\isamc\*.c
103         File ..\isamc\*.h
104         SetOutPath $INSTDIR\isamb
105         File ..\isamb\*.c
106         SetOutPath $INSTDIR\data1
107         File ..\data1\*.c
108         SetOutPath $INSTDIR\recctrl
109         File ..\recctrl\*.c
110         File ..\recctrl\*.h
111         SetOutPath $INSTDIR\dict
112         File ..\dict\*.c
113         SetOutPath $INSTDIR\bfile
114         File ..\bfile\*.c
115         File ..\bfile\*.h
116         SetOutPath $INSTDIR\rset
117         File ..\rset\*.c
118         SetOutPath $INSTDIR\test\api
119         File ..\test\api\*.c
120         File ..\test\api\*.cfg
121         SetOutPath $INSTDIR\win
122         File makefile
123         File *.nsi
124         File *.txt
125 SectionEnd
126
127 ; begin uninstall settings/section
128 UninstallText "This will uninstall Zebra ${VERSION} from your system"
129
130 Section Uninstall
131 ; add delete commands to delete whatever files/registry keys/etc you installed here.
132         Delete "$INSTDIR\uninst.exe"
133         DeleteRegKey HKLM "SOFTWARE\Index Data\Zebra"
134         DeleteRegKey HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Zebra"
135         ExecWait '"$INSTDIR\bin\zebrasrv" -remove'
136         RMDir /r "$SMPROGRAMS\Index Data\Zebra"
137         RMDir /r $INSTDIR
138         IfFileExists $INSTDIR 0 Removed 
139                 MessageBox MB_OK|MB_ICONEXCLAMATION \
140                  "Note: $INSTDIR could not be removed."
141 Removed:
142 SectionEnd
143 ; eof