Potsdam Institute for Climate Impact Research (PIK)
Interdisciplinary Center for Dynamics of Complex Systems (University of Potsdam)
Cardiovascular Physics Group (Humboldt-Universität zu Berlin)
PIK Logo
TOCSY - Toolboxes for Complex Systems
PIK/ Antique/ Blue
Home Home
ACE - Nonlinear Regression Analysis ACE
Adaptive Filtering Procedure Adaptive Filtering
CoinCalc - Event Coincidence Analysis CoinCalc
COPRA - Constructing Proxy Records From Age Models COPRA
Cross Recurrence Plot Toolbox CRP Toolbox
Commandline Recurrence Plots Commandline RPs
Analyse Coupling of Transient Dynamics Coupling Analysis
Identification of Coupling Direction Coupling Direction
Inner Composition Alignment IOTA
Dynamical Invariants by Recurrence Plots K2
Toolbox for the analysis of non-equidistantly sampled time series NEST
DSProlog DSProlog
PECUZAL PECUZAL
Permutation Entropy PETROPY
pyunicorn ‐ UNIfied COmplex Network and Recurrence aNalysis toolbox pyunicorn
Recurrence flow RECFLOW
Symbolic Dynamics from Recurrence Plots RECGRAM
Recurrence lacunarity RECLAC
Recurrence Plots for MATLAB RP
Recurrence Structure Analysis RSA
Wavelet and Coherence Analysis SOWAS
System Identification Tool System Identification
Time Series Graph and Momentary Information Transfer Estimation TiGraMITe

MAKEINSTALL for Matlab®

the easy way of distributing matlab toolboxes

Makeinstall needs at least Matlab 5.3.


The Makeinstall tool was selected on Oct. 3, 2014, as the Mathworks File Exchange Pick of the Week!
»  Pick of the Week

Description

You have a created a toolbox with a lot of Matlab files and now you need a simple way to distribute this toolbox? With Makeinstall you will be able to automatically create a single install.m file, which includes a simple installation routine and all the Matlab programmes needed for the toolbox. The install script modifies the system in order to use the toolbox instantly. If the Contents.m file is missing, it will be automatically created. Furthermore the command tbclean will be added to the toolbox folder, which enables to remove the toolbox folder and the entries in startup.m.

If the toolbox is Octave compatible, the install file can install the toolbox also within the Octave environment.

This tool uses consequently the Matlab potential, e.g. the Matlab standard variables or commands for modifying the Matlab system (cf. Whitepaper for further details).

Makeinstall is free software; you can redistribute it and/or modify it under the terms of the BSD License.

This programme is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the BSD License for more details.


Usage

Call makeinstall in the toolbox folder or specify this folder with makeinstall tb-folder, for example

    makeinstall CRPtool

In order to initialize some needed variables, call this programme the first time and then modify the entries in the automatically created resource file makeinstall.rc. After modifying the resource file, recall makeinstall or makeinstall tb-folder, respectively.

Please note, that further files will be automatically generated in the toolbox folder if they do not exist yet: Contents.m, info.xml and tbclean.m.

The contents of Contents.m will be generated from the help lines in the M-files. If there are no help lines or if this help text is not correctly placed, a warning message will occur. Please ensure that the help text corresponds with the predefined structure of M-files:

    function p = angle(h)
    % ANGLE Polar angle.
    %   ANGLE(H) returns the phase angles, in radians, of 
    %   a matrix with complex elements. Use ABS for the 
    %   magnitudes.
    p = atan2(imag(h),real(h));
where there is a first help line (H1) below the function line and a following help text. The H1 line is used also by other functions like lookfor. If you like to generate Contents.m automatically with makeinstall although Contents.m already exists, you have to remove the old Contents.m file. Thus, manual modifications will be kept.

The contents of info.xml can be modified with some variables in the resource file makeinstall.rc. However, you have to remove the old info.xml file, if you like to modify it the next time with makeinstall. Thus, manual modifications will be preserved.

The generated file install.m will be stored in the folder, from which makeinstall was called. It contains the installation script and the Matlab programmes from the toolbox. This single file can be sent by email or distributed otherwise. Calling install from the Matlab shell extracts the Matlab programmes into the standard toolbox folder (e.g. ~/matlab/CRPtool or C:\Program Files\Matlab\toolbox\crptool) or a predefined folder (specified during running the Makeinstall script or by calling the install file with a specific folder, e.g. install /my/folder) and, optionally, adds the needed toolbox entry permanently in the Matlab startup.m file (at top or end of the startup.m, default is end). The M-files will be automatically precompiled with pcode. If the toolbox is already installed, the user will be asked whether the old toolbox should be removed and finally replaced.

For each toolbox folder a separate resource file makeinstall.rc can be created. The resource files stores the source and destination directories, the toolbox names and the name of the install file.

To view the text of the BSD License, type makeinstall bsd.


License

This software is licensed under the BSD License.

BSD License

Warning

I give no warranty for the tool. Users should make backup files before playing with it.


Screenshot

The screenshot shows the result of calling install.

screenshot

Example

An illustration of the install script can be found in the Cross Recurrence Plot Toolbox.


Pre-compiling and Compiling of MEX-Files

The install script precompiles the M-files. In principle, it would be also possible to compile potential C or Fortran MEX-files in the same way. However, I have not yet implemented this feature, because I support cross-platform development, and the compiling of MEX-files requires C or Fortran, which is not available on all computers (of course, they could be installed on every platform, but not everyone would like to do this). Moreover, with a consequent vectorized Matlab development the MEX-file progamming can, sometimes, be obsolete.


Note on including p-files

Per default, p-files (pcoded m-files) are not included in install file, but will be created during the installation process. However, the inclusion of p-files can be forced by setting include_pfiles=1 in the makeinstall.rc file, if there is a need to distribute p-coded scripts and programmes.


How to get/ Installation

  • Download the Matlab script (66k)
  • Matlab Central
  • Mathtools.net

Put the file makeinstall.m into a folder, which can be found by Matlab (e.g. the matlabroot folder).


Version History

  • Current Version: 3.36 - Last Revision: 2017/11/02 20:49:22
  • 3.36 updating ignore list
  • 3.35 problem of rare case of empty userpath variable (Linux) fixed
  • 3.34 GIT tag support added (used for version number)
  • 3.33 new feature: option for exclusive PC usage (toolbox will not work under other systems)
  • 3.32 avoid addpath of package directories (+folders)
  • 3.31 fid-bug in error handling fixed, extension of ignoring of further non-Matlab files
  • 3.30 fix for rare cases when userpath variable is empty
  • 3.29 bug in ignoring files (.git*, .svn*, etc) fixed
  • 3.28 bugfixes for MS Windows Octave
  • 3.27 fix a bug when pkg('prefix') in octave points to the system package path of Octave instead to the user pckage path
  • 3.26 fix that startup.m entries were written although when "NO" was selected
  • 3.25 DOS line endings changed to standard line endings for archive file
  • 3.24 git files
  • 3.23 isoctave bug in deinstall script fixed
  • 3.22 octave compatibility for windows added
  • 3.21 added octave compatibility (default path and .octaverc support)
  • 3.20 changed toolbox location from general Matlab folder to user's matlab folder in Windows
  • 3.19 change from GPL to BSD License
  • 3.18 updated contact data and copyright address
  • 3.17 fixed checksum error on 64bit machines
  • 3.16 several bug fixes and upwards compatibility
  • 3.15 subdirectories support included
  • 3.14 checksum error bug in Matlab 2006a solved
  • 3.13 code optimised and flattened
  • 3.12 pcode bug resolved (R14 incompatibility)
  • 3.11 fixed downwards compatibility of mfilename command
  • 3.10 bug in relative-to-absolute-path conversion fixed
    confusing of DOS and Unix fileseparators resolved
    bug due to DOS line end (CR instead of LF) resolved
    bug due to Makeinstall self packaging resolved (Makeinstall.m now excluded)
  • 3.9 comment combination (for container) changed, small bug fixes
  • 3.8 windoof bug fixed (ocurred during removing of old toolbox)
  • 3.7 change addpath -end to addpath -begin
  • 3.6 CVS compatibility included
  • 3.4 Root folder of the toolbox can be modified; startup.m-entry is now optional
  • 3.3 Writing and reading the installation container is speeded up
  • 3.2 A checksum based test of the archive is included
  • 3.1 Supports sub-directories
  • 3.0 Supports binary data, creates a missing Contents.m file
  • 2.3 Adding clean file for removing toolbox
  • 2.2 Change to more general applicability, usage of resource files
  • 2.1 Minor changes and corrections on the way to a more general applicability
  • 2.0 The install.m file also contains the archive; makeinstall consists only of one file
  • 1.x Undocumented changes and developing stages
  • 1.0 First version, uses two makeinstall files and creates the install.m and an archive file

To Do

  • compression (fast compression)

White Paper

A description about the technology behind the Makeinstall script can be found in a whitepaper.


Bugs/ Problems

Please send me bug reports or if any problem occured. Don't forget to send me the makeinstall.rc and the install.m file (if it was created):

    Norbert2s378.Marwan@gmx.net
    (remove the red part to obtain a valid email address.)


Thanks

I'm grateful for every suggestion and hint which improves this programme. Thanks to Gaetan Koers of Vrije Universiteit Brussel for hints about Windows compatibility and improvement the help-text parser. Thanks also to Volkmar Glauche of University of Hamburg (Universitätsklinikum) and Eduard vander Zwan (Wageningen Universiteit) for usefule hints and comments about the root-folder of the toolbox and the startup.m entries.


Contact

Norbert Marwan, Potsdam, Germany

last changes: Fri, 21 Aug 2020 12:45:27 UTC  

© 2004-2023 SOME RIGHTS RESERVED
University of Potsdam, Interdisciplinary Center for Dynamics of Complex Systems, Germany
Potsdam Institute for Climate Impact Research, Complexity Science, Germany

This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 2.0 Germany License.
Imprint, Data policy, Disclaimer, Accessibility statement

Please respect the copyrights! The content is protected by the Creative Commons License. If you use the provided programmes, text or figures, you have to refer to the given publications and this web site (tocsy.pik-potsdam.de) as well.

@MEMBER OF PROJECT HONEY POT
Spam Harvester Protection Network
provided by Unspam