Install Ubuntu: Difference between revisions

From Micro and Nano Mechanics Group
Jump to navigation Jump to search
No edit summary
Line 31: Line 31:


== Making DEB packages from installed software ==
== Making DEB packages from installed software ==

DEB packages is the format used by Ubuntu (and Debian) repositories of software. Once a package is converted into DEB format Ubuntu can easily manage installation and uninstallation of the program.

All free (free as in freedom) software that comes with Ubuntu does it in DEB format, however the repositories mantainer can't make and distribute DEB packages out of proprietary (privative) software. Fortunately nothing impedes us from building DEB packages as a backups of already installed software. Once the DEB package is made reinstalation is easy handled by Ubuntu.

So suppose we have the Mat-rix Lab-oratory program installed.

Briefly, lets review the instalation:

user@pc:/media/cdrom$ sudo ./install

Choose manual installation: click "Install manually without using the internet.". Accept licence: click "Yes". Set root directory: type "/opt/mat lab/r2008a". Confirm: "Create". Accept: "OK". Enter file installation key. Select items to install. Create symbolic links in "/usr/local/bin". Begin installation.

The installation takes ~10 minutes.

Activate the product: "Activate Manually without the internet", then select licence file. Run the program, try "1+1". Exit the program. Go to the command line, type "matlab" and try it again.

No to make the DEB package. Create a directory structure as follows.

cd ~
export version=version_name #(e.g. r2008a)
mkdir -p matlab-$version/debian
mkdir -p matlab-$version/src/i386/opt
mkdir -p matlab-$version/src/i386/usr/local/bin

Create the following files

touch matlab-$version/debian/changelog
touch matlab-$version/debian/compat
touch matlab-$version/debian/docs

and copy the lincense from the original installation

cp /opt/matlab/$version/license.txt matlab-$version/debian/copyright

and store the installation dir in

echo '/opt/matlab/$version' > matlab-$version/debian/dirs

Type some insformation in

echo 'This is repackaged for internal use' > matlab-$version/debian/README

create file named <code>matlab-$version/debian/control</code> with the following information

Source: matlabr2008a
Section: unknown
Priority: extra
Mantainer: user <user@pc.edu>
Build-Depends: debhelper (>=5)
Standards-Version: 3.7.2

Package: matlabr2008a
Architecture: any
Depends: libxext6, libxp6, libxt6
Description: MATLAB - The Language of Technical Computing
MATLAB is a high-level language and interactive environment that enables
you to perform computationally intensive tasks faster than with traditional
programming languages such as C, C++, and Fortran.

On the description field: leave a space in every. Set post-installation by editing
<code>matlab-$version/debian/postinst</code> with the instructions. For example,
"alternative" names can be installed for multiple version of the same problem
(see [http://www.debina-administration.org/articles/529 here] for more information on
setting up "alternatives").

Now build the package from the top directory.

dpkg-buildpackage

Revision as of 23:40, 29 August 2009

How to install Ubuntu in a PC

What is Ubuntu?

Ubuntu is a free operating system that has been developed by a community of computer scientists around the world. They have created this operating system to provide a free operating system for education and communication purposes around the world. To read more about Ubuntu mission and goals please visit: Ubuntu

There are four versions of Ubuntu that can be downloaded:

a. Ubuntu (GNOME/Linux based operating system, standard version) b. Xubuntu (GNU/Linux based operating system, lighter system) c. Edubuntu (Specifically designed for school environments) d. Kubuntu (KDE and K desktop environment, Mac-like version)

Once one has decided which version of Ubuntu to use, download it to the desktop. It is recommended to copy the downloaded package into a CD. Install the Ubuntu in the computer. The nice thing about this program is that when the computer is rebooted you can choose the operating system that one wants to use. Be sure to allocate enough space when partitioning your hard drive (7 GB or more).

Once Ubuntu has been installed in your computer, go to:

System -> Administration -> Sypnaptic Package Manager Enter root password Search for libxxf 86 (these X11 Direct Graphics Library Packages) Check them for installation click on apply download them and install them Search for Octave Check all octave packages for intallation click on apply download them and install them Close Synaptic Package Manager

These packages should help run MD++ properly.

Making DEB packages from installed software

DEB packages is the format used by Ubuntu (and Debian) repositories of software. Once a package is converted into DEB format Ubuntu can easily manage installation and uninstallation of the program.

All free (free as in freedom) software that comes with Ubuntu does it in DEB format, however the repositories mantainer can't make and distribute DEB packages out of proprietary (privative) software. Fortunately nothing impedes us from building DEB packages as a backups of already installed software. Once the DEB package is made reinstalation is easy handled by Ubuntu.

So suppose we have the Mat-rix Lab-oratory program installed.

Briefly, lets review the instalation:

 user@pc:/media/cdrom$ sudo ./install 

Choose manual installation: click "Install manually without using the internet.". Accept licence: click "Yes". Set root directory: type "/opt/mat lab/r2008a". Confirm: "Create". Accept: "OK". Enter file installation key. Select items to install. Create symbolic links in "/usr/local/bin". Begin installation.

The installation takes ~10 minutes.

Activate the product: "Activate Manually without the internet", then select licence file. Run the program, try "1+1". Exit the program. Go to the command line, type "matlab" and try it again.

No to make the DEB package. Create a directory structure as follows.

 cd ~
 export version=version_name #(e.g. r2008a)
 mkdir -p matlab-$version/debian
 mkdir -p matlab-$version/src/i386/opt
 mkdir -p matlab-$version/src/i386/usr/local/bin

Create the following files

 touch matlab-$version/debian/changelog
 touch matlab-$version/debian/compat
 touch matlab-$version/debian/docs

and copy the lincense from the original installation

 cp /opt/matlab/$version/license.txt matlab-$version/debian/copyright

and store the installation dir in

 echo '/opt/matlab/$version' > matlab-$version/debian/dirs

Type some insformation in

 echo 'This is repackaged for internal use' > matlab-$version/debian/README

create file named matlab-$version/debian/control with the following information

 Source: matlabr2008a
 Section: unknown
 Priority: extra
 Mantainer: user <user@pc.edu>
 Build-Depends: debhelper (>=5)
 Standards-Version: 3.7.2
 Package: matlabr2008a
 Architecture: any
 Depends: libxext6, libxp6, libxt6
 Description: MATLAB - The Language of Technical Computing
  MATLAB is a high-level language and interactive environment that enables
  you to perform computationally intensive tasks faster than with traditional
  programming languages such as C, C++, and Fortran.

On the description field: leave a space in every. Set post-installation by editing matlab-$version/debian/postinst with the instructions. For example, "alternative" names can be installed for multiple version of the same problem (see here for more information on setting up "alternatives").

Now build the package from the top directory.

 dpkg-buildpackage