Skip to content
Lieven Hollevoet edited this page Sep 22, 2014 · 1 revision

Table of Contents

Download & Install Misterhouse

The latest version of Misterhouse is available on github. It is usually accessed by using the git tool. This can complicate things for the beginner, but is a very powerful tool for the software developers who work on Misterhouse (which we hope you may become).

An easier way to install Misterhouse is to download the latest installer zip from the github (currently v2.200 2nd March 2013) to your client machine by whatever means is convenient for you. You will install these mh files in the /opt/misterhouse directory you created earlier. This is based on advice found in Neil Cherry's book “Linux Smart Homes for Dummies”.

__Transfer the zip file to your server__

On your client machine type: //**user@lan_client:/#**// cd ///[whatever]// //**user@lan_client:/#**// sudo sftp [username]@[ip]

At the sftp prompt type:

    • sftp>** cd /opt/misterhouse
    • sftp>** put misterhouse-v2.200.zip
    • sftp>** exit

__Unzip Files__

Now, ssh back into the MH server and untar the file: //**user@lan_client:/#**// ssh -l //[username]// //[ip]//

Now change to the MH folder, install the unzip program (it's not install by default), unzip the archive, rename the unzipped folder to the correct name, and delete the zip file.

//**root@mh_server:/#**// cd /opt/misterhouse //**root@mh_server:/#**// sudo apt-get install unzip //**root@mh_server:/#**// sudo unzip misterhouse-v2.200.zip //**root@mh_server:/#**// sudo mv misterhouse-master mh //**root@mh_server:/#**// sudo rm misterhouse-v2.200.zip

Just for completeness the file structure will look like this - || /opt/misterhouse || || || || || || mh.private.ini || || <- your custom mh settings file || || || /code || || <- your code directory || || || /data || || <- your data directory || || || || /logs || <- your log files, lists of what MH has been up to, mostly for debugging || || || /sounds || || <- your sounds dir (if you need them) || || || /mh || || <- the production mh code directory - MH runs from here || || || || /bin || <- MH production binaries || || || || /code || <- MH production code || || || || /data || <- MH production data || || || || /docs || <- MH help documents || || || || /lib || <- MH production libraries || || || || /sounds || <- MH production sounds || || || || /web || <- MH production web interface || || || /mh-old || || <- when you upgrade, rename mh folder above - this folder is ignored by mh at runtime || || || || /bin || but allows you to revert in case of any issues with the new version (rare) || || || || /code || || || || || /data || || || || || /docs || || || || || /libs || || || || || /sounds || || || || || web || || || || || || ||

__Convert Headers__

There is a script that comes with Misterhouse that, among other things, converts certain headers from C to Perl. The installation instructions on the mh site call for you to invoke this script, called “configure” which can be found in the /opt/mh/bin directory (assuming that you have installed the files as described above.) On Ubuntu, this script does not function correctly because it tries to place the converted headers in a directory that does not exist. Additionally most of the required headers already exist in the .ph form with these exceptions:

termios.ph bits/termios.ph linux/stddefs.ph (see note below) linux/compiler.ph

Convert these files using the program h2ph:

    • //root@mh_server:/#//** cd /usr/include
    • //root@mh_server:/#//** h2ph termios.h
    • //root@mh_server:/#//** h2ph bits/termios.h
    • //root@mh_server:/#//** h2ph linux/compiler.h
Note: I could not find the header file linux/stddefs.h or linux/stddefs.ph anywhere. I did not convert this header and so far have not seen any ill effects. A query of the mailing list seemed to indicate that other users don't have this file either and it has not been a problem.

__Clean Up__

There is a script that comes with the misterhouse distribution (/opt/misterhouse/mh/bin/configure) that does the header conversion we just competed above. I had some trouble with the h2ph command in this script trying to place files in a directory that did not exist. As a result, I converted only those header files that did not exist in .ph format by hand in the previous step. There are some things in the configure script that we do want to do, however, to clean things up. A modified version of this script is included below:

Open an empty file called 'ubuntu_configure':

    • //root@mh_server:/#//** sudo nano /opt/misterhouse/mh/bin/ubuntu_configure
The copy-paste the following text:
code format="bash"
  1. !/bin/sh
echo
  1. Deleting Windows-only files...
curdir=`pwd` cd /opt/misterhouse/mh/bin rm -f RasDial.txt rasdial.* rm -f *.bat *.exe *.EXE *.wbt rm -rf ../lib/site/Win32* rm -rf ../lib/site/auto/Win32* rm -rf ../lib/site_win*
  1. Making scripts executable
chmod +x * cd $curdir code

Save the file, exit, and make it executable:

    • //root@mh_server:/#//** sudo chmod +x /opt/misterhouse/mh/bin/ubuntu_configure
Then run it:
    • //root@mh_server:/#//** sudo /opt/misterhouse/mh/bin/ubuntu_configure
Next: Configure Misterhouse Back: Download & Install Support Packages Return to Index
Clone this wiki locally