Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Windows Installer: Difference between revisions

From MoodleDocs
Line 39: Line 39:


=== Create a batch file ===
=== Create a batch file ===
 
The two batch files can be download on CVS: http://cvs.moodle.org/contrib/tools/m4w_builder/bin/batch/
==== 'Start Moodle.exe' ====
==== 'Start Moodle.exe' ====
This batch file readjusts, if needed, apache/mysql paths to the new location in hard disk. Then it launchs Apache and Mysql processes.
This batch file readjusts, if needed, apache/mysql paths to the new location in hard disk. Then it launchs Apache and Mysql processes.

Revision as of 08:10, 12 May 2008

Windows Installer Package

The Windows Installer is based on xampp 1.6 distribution. The package structure is the following:

  Root
  | Readme.txt
  | Start Moodle.exe
  | Stop Moodle.exe
  | server
    | apache_start.bat
    | apache_stop.bat
    | makecert.bat
    | mysql_start.bat
    | mysql_stop.bat
    | readme_de.txt
    | readme_en.txt
    | service.exe
    | setup_xampp.bat
    | xampp_restart.bat
    | xampp_start.exe
    | xampp_stop.exe
    | xampp_control.exe
    | xampp_portcheck.exe
    | apache
    | cgi-bin
    | install
    | licences
    | moodle
    | moodledata //this folder is created during the installation process
    | mysql
    | php
    | sendmail
    | tmp

Moodle folders

All moodle files must be located in server/moodle/

'Start/Stop Moodle.exe'

Windows Installer package comes with two root executable files. 'Start Moodle.exe' sets up the Xampp environment and launch Apache and Mysql processes. 'Stop Moodle.exe' stop the two processes. This section explains how to create these two executable files.

Create a batch file

The two batch files can be download on CVS: http://cvs.moodle.org/contrib/tools/m4w_builder/bin/batch/

'Start Moodle.exe'

This batch file readjusts, if needed, apache/mysql paths to the new location in hard disk. Then it launchs Apache and Mysql processes.

'Stop Moodle.exe'

This batch file stops the apache and mysql process.

Create an icon

In order to create an icon for the executable files you can use SnIco Edit. You need to save your icon as a .ico file.

Create an executable file

Once you've got a batch file and an icon, run bat_to_exe_converter.exe. Browse for the .bat file and the .ico file, then click on compile. An executable file is generated. The two files (and a Readme.txt) need to be copied into the generated zip at the root level. This is done by the sript shell generating the windows installer package.

Resources

You can find all resources in CVS: http://cvs.moodle.org/contrib/tools/m4w_builder/bin/