couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mhamm...@apache.org
Subject svn commit: r836351 - in /couchdb/trunk/etc: Makefile.am windows/couchdb.iss.tpl
Date Sun, 15 Nov 2009 12:46:03 GMT
Author: mhammond
Date: Sun Nov 15 12:46:02 2009
New Revision: 836351

URL: http://svn.apache.org/viewvc?rev=836351&view=rev
Log:
add basic windows service support; auto build .md5 with .exe

Modified:
    couchdb/trunk/etc/Makefile.am
    couchdb/trunk/etc/windows/couchdb.iss.tpl

Modified: couchdb/trunk/etc/Makefile.am
URL: http://svn.apache.org/viewvc/couchdb/trunk/etc/Makefile.am?rev=836351&r1=836350&r2=836351&view=diff
==============================================================================
--- couchdb/trunk/etc/Makefile.am (original)
+++ couchdb/trunk/etc/Makefile.am Sun Nov 15 12:46:02 2009
@@ -28,7 +28,7 @@
 EXTRA_DIST = $(init_sysconf_data)
 
 if WINDOWS
-EXTRA_DIST += windows/setup-couchdb-@version@.exe
+EXTRA_DIST += windows/setup-couchdb-@version@.exe.md5
 endif
 
 CLEANFILES = $(init_DATA) $(default_sysconf_data) $(launchd_DATA)
@@ -84,6 +84,7 @@
 	    -e "s|%package_name%|@package_name@|g" \
 	    -e "s|%locallibbindir%|`cygpath -m @locallibbindir@`|g" \
 	    -e "s|%version%|@version@|g" \
+	    -e "s|%erts_version%|`$(ERL) -version 2>&1 | $(SED) 's/[^0-9\.]//g'`|g" \
 	    -e "s|%openssl_bin_dir%|@openssl_bin_dir@|g" \
 	    -e "s|%msvc_redist_dir%|@msvc_redist_dir@|g" \
 	    -e "s|%msvc_redist_name%|@msvc_redist_name@|g" \
@@ -95,6 +96,10 @@
 	$(INNO_COMPILER_EXECUTABLE) /q $<
 	@echo Windows Installer is at: `cygpath -a -w windows/setup-couchdb-@version@.exe`
 
+windows/setup-couchdb-@version@.exe.md5: windows/setup-couchdb-@version@.exe
+	md5sum $< > $@
+	@echo Windows Installer is at: `cygpath -a -w windows/setup-couchdb-@version@.exe`
+
 FORCE:
 
 endif

Modified: couchdb/trunk/etc/windows/couchdb.iss.tpl
URL: http://svn.apache.org/viewvc/couchdb/trunk/etc/windows/couchdb.iss.tpl?rev=836351&r1=836350&r2=836351&view=diff
==============================================================================
--- couchdb/trunk/etc/windows/couchdb.iss.tpl (original)
+++ couchdb/trunk/etc/windows/couchdb.iss.tpl Sun Nov 15 12:46:02 2009
@@ -30,7 +30,7 @@
 ; bin dir
 Source: "%locallibbindir%\*.*"; DestDir: "{app}\bin"; Flags: ignoreversion uninsrestartdelete
restartreplace recursesubdirs
 ; other dirs copied '*.*'
-Source: "%locallibbindir%\..\erts-5.7.2\*.*"; DestDir: "{app}\erts-5.7.2"; Flags: ignoreversion
uninsrestartdelete restartreplace recursesubdirs
+Source: "%locallibbindir%\..\erts-%erts_version%\*.*"; DestDir: "{app}\erts-%erts_version%";
Flags: ignoreversion uninsrestartdelete restartreplace recursesubdirs
 Source: "%locallibbindir%\..\lib\*.*"; DestDir: "{app}\lib"; Flags: ignoreversion uninsrestartdelete
restartreplace recursesubdirs
 Source: "%locallibbindir%\..\share\*.*"; DestDir: "{app}\share"; Flags: ignoreversion uninsrestartdelete
restartreplace recursesubdirs
 Source: "%locallibbindir%\..\releases\*.*"; DestDir: "{app}\releases"; Flags: ignoreversion
uninsrestartdelete restartreplace recursesubdirs
@@ -62,7 +62,23 @@
 Name: "{group}\Futon (CouchDB web interface)"; Filename: "http://127.0.0.1:5984/_utils"
 Name: "{group}\CouchDB Web Site"; Filename: "http://couchdb.apache.org/"
 
+[Tasks]
+Name: service; Description: "Install couchdb as a Windows service"
+Name: service\start; Description: "Start the service after installation"
+
 [Run]
 Filename: "{tmp}\%msvc_redist_name%"; Parameters: "/q"
 ; This is erlang's Install.exe which updates erl.ini correctly.
 Filename: "{app}\Install.exe"; Parameters: "-s"; Flags: runhidden
+
+; Commands for a service
+; First attempt to nuke an existing service of this name, incase they are
+; reinstalling without uninstalling
+Filename: "{app}\erts-%erts_version%\bin\erlsrv.exe"; Parameters: "remove ""%package_name%""";
Tasks: service
+; add a new one
+Filename: "{app}\erts-%erts_version%\bin\erlsrv.exe"; Parameters: "add ""%package_name%""
-w ""{app}\bin"" -ar ""-sasl errlog_type error -s couch"" -c ""%package_name% %version%""";
Tasks: service
+; and start it if requested
+Filename: "{app}\erts-%erts_version%\bin\erlsrv.exe"; Parameters: "start ""%package_name%""";
Tasks: service\start
+
+[UninstallRun]
+Filename: "{app}\erts-%erts_version%\bin\erlsrv.exe"; Parameters: "remove ""%package_name%""";
Tasks: service



Mime
View raw message