Thanks Angus. I can also confirm that they work fine.
Stephen Harris wrote:
The *.cmap/cset etc. were installed to C:\Aspell\lib\aspell-0.60 as I think they are supposed to be. But the default on the installer reads C:\Aspell. Should this default read C:\Aspell\lib\aspell-0.60 like the default for the dictionary install? It doesn't work to change the default data install to C:\Aspell\lib\aspell-0.60 because an extra \lib gets inserted, so a user needs to keep the default of C:\Aspell.
The user should not have to worry about the specific location for the files but only have to tell the installer where to install Aspell. It would indeed be better to get that behavior as well for the dictionary installers.
Attached you'll find the dictionary installer script with this update. The data script only contains a small fix to allow compilation in locations other than C:\Aspell.
Joost
/* NSIS Script - Aspell 0.60.4 Data Instaler for Win32 Written by Joost Verburg Compile this script using makensis in a directory that contains an installed version of Aspell 0.60.4 You should also copy the file COPYING to this directory (for the license information). Note that this script does not install Aspell binaries, it only provides required data files for applications statically linked to Aspell. */ ;-------------------------------- ;Files !macro Files-Data ${COMMAND} "${DIRECTORY}ccpp.amf" ${COMMAND} "${DIRECTORY}comment.amf" ${COMMAND} "${DIRECTORY}cp1250.cmap" ${COMMAND} "${DIRECTORY}cp1250.cset" ${COMMAND} "${DIRECTORY}cp1251.cmap" ${COMMAND} "${DIRECTORY}cp1251.cset" ${COMMAND} "${DIRECTORY}cp1252.cmap" ${COMMAND} "${DIRECTORY}cp1252.cset" ${COMMAND} "${DIRECTORY}cp1253.cmap" ${COMMAND} "${DIRECTORY}cp1253.cset" ${COMMAND} "${DIRECTORY}cp1254.cmap" ${COMMAND} "${DIRECTORY}cp1254.cset" ${COMMAND} "${DIRECTORY}cp1255.cmap" ${COMMAND} "${DIRECTORY}cp1255.cset" ${COMMAND} "${DIRECTORY}cp1256.cmap" ${COMMAND} "${DIRECTORY}cp1256.cset" ${COMMAND} "${DIRECTORY}cp1257.cmap" ${COMMAND} "${DIRECTORY}cp1257.cset" ${COMMAND} "${DIRECTORY}cp1258.cmap" ${COMMAND} "${DIRECTORY}cp1258.cset" ${COMMAND} "${DIRECTORY}dvorak.kbd" ${COMMAND} "${DIRECTORY}email.amf" ${COMMAND} "${DIRECTORY}html.amf" ${COMMAND} "${DIRECTORY}iso-8859-1.cmap" ${COMMAND} "${DIRECTORY}iso-8859-1.cset" ${COMMAND} "${DIRECTORY}iso-8859-10.cmap" ${COMMAND} "${DIRECTORY}iso-8859-10.cset" ${COMMAND} "${DIRECTORY}iso-8859-11.cmap" ${COMMAND} "${DIRECTORY}iso-8859-11.cset" ${COMMAND} "${DIRECTORY}iso-8859-13.cmap" ${COMMAND} "${DIRECTORY}iso-8859-13.cset" ${COMMAND} "${DIRECTORY}iso-8859-14.cmap" ${COMMAND} "${DIRECTORY}iso-8859-14.cset" ${COMMAND} "${DIRECTORY}iso-8859-15.cmap" ${COMMAND} "${DIRECTORY}iso-8859-15.cset" ${COMMAND} "${DIRECTORY}iso-8859-16.cmap" ${COMMAND} "${DIRECTORY}iso-8859-16.cset" ${COMMAND} "${DIRECTORY}iso-8859-2.cmap" ${COMMAND} "${DIRECTORY}iso-8859-2.cset" ${COMMAND} "${DIRECTORY}iso-8859-3.cmap" ${COMMAND} "${DIRECTORY}iso-8859-3.cset" ${COMMAND} "${DIRECTORY}iso-8859-4.cmap" ${COMMAND} "${DIRECTORY}iso-8859-4.cset" ${COMMAND} "${DIRECTORY}iso-8859-5.cmap" ${COMMAND} "${DIRECTORY}iso-8859-5.cset" ${COMMAND} "${DIRECTORY}iso-8859-6.cmap" ${COMMAND} "${DIRECTORY}iso-8859-6.cset" ${COMMAND} "${DIRECTORY}iso-8859-7.cmap" ${COMMAND} "${DIRECTORY}iso-8859-7.cset" ${COMMAND} "${DIRECTORY}iso-8859-8.cmap" ${COMMAND} "${DIRECTORY}iso-8859-8.cset" ${COMMAND} "${DIRECTORY}iso-8859-9.cmap" ${COMMAND} "${DIRECTORY}iso-8859-9.cset" ${COMMAND} "${DIRECTORY}ispell" ${COMMAND} "${DIRECTORY}koi8-r.cmap" ${COMMAND} "${DIRECTORY}koi8-r.cset" ${COMMAND} "${DIRECTORY}koi8-u.cmap" ${COMMAND} "${DIRECTORY}koi8-u.cset" ${COMMAND} "${DIRECTORY}none.amf" ${COMMAND} "${DIRECTORY}nroff.amf" ${COMMAND} "${DIRECTORY}perl.amf" ${COMMAND} "${DIRECTORY}sgml.amf" ${COMMAND} "${DIRECTORY}spell" ${COMMAND} "${DIRECTORY}split.kbd" ${COMMAND} "${DIRECTORY}standard.kbd" ${COMMAND} "${DIRECTORY}tex.amf" ${COMMAND} "${DIRECTORY}texinfo.amf" ${COMMAND} "${DIRECTORY}url.amf" !macroend ;-------------------------------- ;Script macros !macro redef name value !ifdef "${name}" !undef "${name}" !endif !define "${name}" "${value}" !macroend ;-------------------------------- ;Include Modern UI !include "MUI.nsh" ;-------------------------------- ;General ;Name and output file Name "Aspell 0.60.4 Data" OutFile "AspellData-0.60.4.exe" ;Good compression SetCompressor /SOLID lzma ;Installation directory InstallDir "C:\Aspell" InstallDirRegKey HKLM "Software\Aspell" "" ;-------------------------------- ;Pages !insertmacro MUI_PAGE_WELCOME !insertmacro MUI_PAGE_LICENSE "C:\Aspell\COPYING" !insertmacro MUI_PAGE_DIRECTORY !insertmacro MUI_PAGE_INSTFILES !insertmacro MUI_PAGE_FINISH !insertmacro MUI_UNPAGE_WELCOME !insertmacro MUI_UNPAGE_CONFIRM !insertmacro MUI_UNPAGE_INSTFILES !insertmacro MUI_UNPAGE_FINISH ;-------------------------------- ;Languages !insertmacro MUI_LANGUAGE "English" ;-------------------------------- ;Installer Section Section "Install Aspell Data" ;Install files !insertmacro redef COMMAND "File" SetOutPath "$INSTDIR\lib\aspell-0.60" !insertmacro redef DIRECTORY "lib\aspell-0.60\" !insertmacro Files-Data ;Create uninstaller WriteUninstaller "$INSTDIR\Uninstall-AspellData.exe" ;Uninstaller information WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell" "UninstallString" "$\"$INSTDIR\Uninstall-AspellData.exe$\"" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell" "DisplayName" "Aspell 0.60.4 Data" WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell" "NoModify" 1 WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell" "NoRepair" 1 ;Directory information WriteRegStr HKLM "Software\Aspell" "" "$INSTDIR" SectionEnd ;-------------------------------- ;Uninstaller Section Section "Uninstall" ;Delete files !insertmacro redef COMMAND "Delete" !insertmacro redef DIRECTORY "$INSTDIR\lib\aspell-0.60\" !insertmacro Files-Data RMDir "$INSTDIR\lib\aspell-0.60" RMDir "$INSTDIR\lib" ;Delete uninstaller Delete "$INSTDIR\Uninstall-AspellData.exe" SetOutPath $TEMP RMDir "$INSTDIR" ;Remove uninstaller information DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell" ;Remove directory information DeleteRegKey HKLM "Software\Aspell" SectionEnd
/* NSIS Script - Aspell 0.6 Dictionary Installer for Win32 Written by Joost Verburg To be used with the shell script of Angus Leeming Required defines: LANG - language code INPUTDIR - directory with compiled dictionary files for the language LISTDIR - directory that contains the file ls_langcode (for example, ls_en) with the dictionary files to be installed. The format should be: ${COMMAND} "${DIRECTORY}filename" COPYRIGHTFILE - the file with the copyright information for the dictionary OUTPUTFILE - output file (compiled installer) Example of usage: makensis.exe /DLANG=en /DINPUTDIR=C:\Aspell\lib\aspell-0.60 /DLISTDIR=C:\AspellDicsList /DCOPYRIGHTFILE=C:\AspellDictSource\aspell6-en-6.0-0\Copyright /DOUTPUTFILE=C:\AspellDics\aspell6-en.exe AspellDicts.nsi */ ;-------------------------------- ;Script macros !macro redef name value !ifdef "${name}" !undef "${name}" !endif !define "${name}" "${value}" !macroend ;-------------------------------- ;Include Modern UI !include "MUI.nsh" ;-------------------------------- ;General ;Name and output file Name "Aspell 0.6 Dictionary (Language: ${LANG})" OutFile "${OUTPUTFILE}" ;Good compression SetCompressor /SOLID lzma ;Default installation directory InstallDir "C:\Aspell" ;-------------------------------- ;Pages !insertmacro MUI_PAGE_LICENSE "${COPYRIGHTFILE}" !insertmacro MUI_PAGE_DIRECTORY !insertmacro MUI_PAGE_INSTFILES !insertmacro MUI_UNPAGE_CONFIRM !insertmacro MUI_UNPAGE_INSTFILES ;-------------------------------- ;Languages ;Probably no need to add multiple languages for such a simple thing !insertmacro MUI_LANGUAGE "English" ;-------------------------------- ;Installer Section Section "Install Dictionary" ;Install files !insertmacro redef COMMAND "File" SetOutPath "$INSTDIR\lib\aspell-0.60" !insertmacro redef DIRECTORY "${INPUTDIR}\" !include "${LISTDIR}\ls_${LANG}" ;Create uninstaller WriteUninstaller "$INSTDIR\Uninstall-AspellDict-${LANG}.exe" ;Uninstaller information WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-${LANG}" "UninstallString" "$\"$INSTDIR\Uninstall-AspellDict-${LANG}.exe$\"" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-${LANG}" "DisplayName" "Aspell 0.6 Dictionary (Language: ${LANG})" WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-${LANG}" "NoModify" 1 WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-${LANG}" "NoRepair" 1 SectionEnd ;-------------------------------- ;Installer Functions Function .onInit ;Try to find Aspell location ReadRegStr $R0 HKLM "Software\Aspell" "" StrCmp $R0 "" no_location StrCpy $INSTDIR $R0 no_location: FunctionEnd ;-------------------------------- ;Uninstaller Section Section "Uninstall" ;Delete files !insertmacro redef COMMAND "Delete" !insertmacro redef DIRECTORY "$INSTDIR\lib\aspell-0.60\" !include "${LISTDIR}\ls_${LANG}" ;Delete uninstaller Delete "$INSTDIR\Uninstall-AspellDict-${LANG}.exe" ;Remove uninstaller information DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Aspell6-Dictionary-${LANG}" SectionEnd