Towards 2.0.7
[yaz-moved-to-github.git] / win / yaz.nsi
index 3969c73..33927bc 100644 (file)
@@ -1,6 +1,6 @@
-; $Id: yaz.nsi,v 1.4 2002-03-16 17:37:40 adam Exp $
+; $Id: yaz.nsi,v 1.30 2003-12-16 14:45:59 adam Exp $
 
-!define VERSION "1.8.6"
+!define VERSION "2.0.7"
 
 Name "YAZ"
 Caption "Index Data YAZ ${VERSION} Setup"
@@ -39,19 +39,28 @@ Section "" ; (default section)
                  "$INSTDIR"
        WriteINIStr "$SMPROGRAMS\YAZ\YAZ Home page.url" \
               "InternetShortcut" "URL" "http://www.indexdata.dk/yaz/"
+       CreateShortCut "$SMPROGRAMS\YAZ\Uninstall YAZ.lnk" \
+               "$INSTDIR\uninst.exe"
        SetOutPath $INSTDIR
        File LICENSE.txt
        File ..\README
        SetOutPath $INSTDIR
-       File /r ..\tab
        SetOutPath $INSTDIR\ztest
        File ..\ztest\dummy-records
        File ..\ztest\dummy-grs
        File ..\ztest\dummy-words
+       SetOutPath $INSTDIR\etc
+       File ..\etc\*.xml
+       File ..\etc\*.xsl
+       File ..\etc\pqf.properties
+
 SectionEnd ; end of default section
 
 Section "YAZ Runtime"
-       SectionIn 12
+       SectionIn 1 2
+       IfFileExists "$INSTDIR\bin\yaz-ztest.exe" 0 Noservice
+       ExecWait '"$INSTDIR\bin\yaz-ztest.exe" -remove'
+Noservice:
        SetOutPath $INSTDIR\bin
        File ..\bin\*.exe
        File ..\bin\*.dll
@@ -68,7 +77,7 @@ Section "YAZ Runtime"
 SectionEnd
 
 Section "YAZ Development"
-       SectionIn 12
+       SectionIn 1 2
        SetOutPath $INSTDIR\include\yaz
        File ..\include\yaz\*.h
        SetOutPath $INSTDIR\lib
@@ -76,9 +85,16 @@ Section "YAZ Development"
 SectionEnd
 
 Section "YAZ Documentation"
-       SectionIn 12
-       SetOutPath $INSTDIR
-       File /r ..\doc
+       SectionIn 1 2
+       SetOutPath $INSTDIR\doc
+       File ..\doc\*.html
+       File ..\doc\*.png
+       File ..\doc\*.pdf
+       File ..\doc\*.xml
+       File ..\doc\*.in
+       File ..\doc\*.dsl
+       File ..\doc\*.xsl
+       File ..\doc\*.css
        SetOutPath $SMPROGRAMS\YAZ
        CreateShortCut "$SMPROGRAMS\YAZ\HTML Documentation.lnk" \
                  "$INSTDIR\doc\yaz.html"
@@ -90,29 +106,16 @@ Section "YAZ Source"
        SectionIn 1
        SetOutPath $INSTDIR\util
        File ..\util\*.c
-       File ..\util\*.tcl
-       SetOutPath $INSTDIR\odr
-       File ..\odr\*.c
-       SetOutPath $INSTDIR\z39.50
-       File ..\z39.50\*.c
-       File ..\z39.50\*.asn
-       SetOutPath $INSTDIR\ill
-       File ..\ill\*.c
-       File ..\ill\*.asn
-       SetOutPath $INSTDIR\zutil
-       File ..\zutil\*.c
-       SetOutPath $INSTDIR\ccl
-       File ..\ccl\*.c
+       File ..\util\yaz-asncomp
+       SetOutPath $INSTDIR\src
+       File ..\src\*.c
+       File ..\src\*.h
+       File ..\src\*.y
+       File ..\src\*.tcl
+       File ..\src\*.asn
+       File ..\src\*.sgm
        SetOutPath $INSTDIR\zoom
        File ..\zoom\*.c
-       File ..\zoom\*.h
-       SetOutPath $INSTDIR\comstack
-       File ..\comstack\*.c
-       SetOutPath $INSTDIR\server
-       File ..\server\*.c
-       File ..\server\*.h
-       SetOutPath $INSTDIR\retrieval
-       File ..\retrieval\*.c
        SetOutPath $INSTDIR\ztest
        File ..\ztest\*.c
        SetOutPath $INSTDIR\client
@@ -133,8 +136,12 @@ Section Uninstall
        Delete "$INSTDIR\uninst.exe"
        DeleteRegKey HKLM "SOFTWARE\Index Data\YAZ"
        DeleteRegKey HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\YAZ"
-       RMDir /r "$INSTDIR"
+       ExecWait '"$INSTDIR\bin\yaz-ztest" -remove'
        RMDir /r $SMPROGRAMS\YAZ
-SectionEnd ; end of uninstall section
-
+       RMDir /r $INSTDIR
+        IfFileExists $INSTDIR 0 Removed 
+               MessageBox MB_OK|MB_ICONEXCLAMATION \
+                 "Note: $INSTDIR could not be removed."
+Removed:
+SectionEnd
 ; eof