Editing Checkinstall on Maemo
Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
[http://www.asic-linux.com.mx/~izto/checkinstall/index.php checkinstall] is a tool which helps to create Debian packages. (It also could help to create RedHat's and Slackware's packages). Instead of typing "make install" user can just write "checkinstall" and build .deb package for a software. | [http://www.asic-linux.com.mx/~izto/checkinstall/index.php checkinstall] is a tool which helps to create Debian packages. (It also could help to create RedHat's and Slackware's packages). Instead of typing "make install" user can just write "checkinstall" and build .deb package for a software. | ||
- | + | Building Debian package, instead of just installing software to prefix has several advantages: | |
- | Building Debian package, instead of just installing software to | + | |
* you may put the package into your own package repository and share with other people. | * you may put the package into your own package repository and share with other people. | ||
* you have advantages of package management, like ability to list package files, check which package installed a particular file, and, package manager won't allow to overwrite existing files, while "make install" does not care about this. | * you have advantages of package management, like ability to list package files, check which package installed a particular file, and, package manager won't allow to overwrite existing files, while "make install" does not care about this. | ||
- | As far as I know, you cannot commit packages generated | + | As far as I know, you cannot commit packages generated like that into official Maemo repositories. |
- | + | ||
- | + | ||
'''ATTENTION! ACHTUNG!''' | '''ATTENTION! ACHTUNG!''' | ||
'''Doing things described in this manual is dangerous. Don't follow these instructions unless you are confident GNU/Linux user, have a backup of a running system and know how to reflash bricked phone. | '''Doing things described in this manual is dangerous. Don't follow these instructions unless you are confident GNU/Linux user, have a backup of a running system and know how to reflash bricked phone. | ||
''' | ''' | ||
- | + | <br> | |
First, let's get the source: | First, let's get the source: | ||
<pre> | <pre> | ||
Line 25: | Line 22: | ||
</pre> | </pre> | ||
- | Also, change | + | Also, change makefile in the installwatch directory |
+ | |||
<pre> | <pre> | ||
#PREFIX=/usr/local | #PREFIX=/usr/local | ||
Line 31: | Line 29: | ||
</pre> | </pre> | ||
- | Now you also need to install | + | Now you also need to install gettext. For that, add temporarily sdk repository to the custom apt list:<pre>vi /etc/apt/sources.list.d/dev.list</pre> |
- | <pre>vi /etc/apt/sources.list.d/dev.list</pre> | + | |
- | + | ||
<pre>deb http://repository.maemo.org fremantle/sdk free non-free</pre> | <pre>deb http://repository.maemo.org fremantle/sdk free non-free</pre> | ||
DO NOT UPGRADE YOUR SYSTEM WITH THIS CONFIG LINE ENABLED! | DO NOT UPGRADE YOUR SYSTEM WITH THIS CONFIG LINE ENABLED! | ||
Line 40: | Line 36: | ||
apt-get install gettext | apt-get install gettext | ||
</pre> | </pre> | ||
- | You also need to install | + | You also need to install sed-gnu. It's in fremantle/free repository |
<pre> | <pre> | ||
apt-get install sed-gnu | apt-get install sed-gnu | ||
</pre> | </pre> | ||
- | + | Right sed binary now located in /usr/bin/gnu, so we need to have that directory in the path first, otherwise /bin/sed from busybox will be executed | |
<pre> | <pre> | ||
export PATH=/usr/bin/gnu:$PATH | export PATH=/usr/bin/gnu:$PATH | ||
</pre> | </pre> | ||
- | At the moment of successful compilation I also have in the system following packages with the | + | At the moment of successful compilation I also have in the system following packages with the gnu ending: |
+ | |||
<pre> | <pre> | ||
dpkg -l | grep gnu | dpkg -l | grep gnu | ||
Line 57: | Line 54: | ||
</pre> | </pre> | ||
- | I also have | + | I also have gcc and gnu make installed |
+ | We will need bash, I always have it as my defailt shell: | ||
<pre> | <pre> | ||
apt-get install bash3</pre> | apt-get install bash3</pre> | ||
<br> | <br> | ||
So, now it's time to type "make" | So, now it's time to type "make" | ||
+ | |||
<pre> | <pre> | ||
make | make | ||
Line 92: | Line 91: | ||
</pre> | </pre> | ||
- | We need | + | We need findutils-gnu for checkinstall to work. |
+ | |||
<pre> | <pre> | ||
apt-get install findutils-gnu | apt-get install findutils-gnu | ||
</pre> | </pre> | ||
- | In order to build | + | In order to build package well, you also need to install debianutils. |
+ | However, you cannot install debianutils, because it conflicts with busybox. | ||
+ | This is a dirty hack I suggest to use | ||
+ | |||
<pre> | <pre> | ||
cp /var/lib/dpkg/status /var/lib/dpkg/status.bak | cp /var/lib/dpkg/status /var/lib/dpkg/status.bak | ||
vi /var/lib/dpkg/status | vi /var/lib/dpkg/status | ||
</pre> | </pre> | ||
- | Find in this file | + | Find in this file "busybox" section. |
<pre> | <pre> | ||
Package: busybox | Package: busybox | ||
Line 129: | Line 132: | ||
Now let's change apt configuration in order to allow to overwrite busybox links: | Now let's change apt configuration in order to allow to overwrite busybox links: | ||
+ | |||
<pre> | <pre> | ||
vi /etc/apt/apt.conf.d/23overwrite | vi /etc/apt/apt.conf.d/23overwrite | ||
Line 146: | Line 150: | ||
} | } | ||
</pre> | </pre> | ||
- | Otherwise you will need to download package yourself, and install it with | + | Otherwise you will need to download package yourself, and install it with dpkg --force-overwrite. |
- | + | ||
<pre> | <pre> | ||
- | apt-get install debianutils | + | ]apt-get install debianutils |
Reading package lists... Done | Reading package lists... Done | ||
Building dependency tree | Building dependency tree | ||
Line 177: | Line 180: | ||
</pre> | </pre> | ||
- | As you see, | + | As you see, /usr/bin/which does not work, because it cannot find getopts. However, getopts is a bash command, so we can fix it by changing interpreter in the /usr/bin/which script from #!/bin/sh (which is a symlink to busybox) to #!/bin/bash. Then, also change the interpreter in the following scripts |
<pre> | <pre> | ||
/usr/bin/sensible-pager | /usr/bin/sensible-pager | ||
Line 185: | Line 188: | ||
</pre> | </pre> | ||
- | Now, type checkinstall | + | Now, type checkinstall |
+ | |||
<pre> | <pre> | ||
checkinstall 1.6.2, Copyright 2009 Felipe Eduardo Sanchez Diaz Duran | checkinstall 1.6.2, Copyright 2009 Felipe Eduardo Sanchez Diaz Duran | ||
Line 227: | Line 231: | ||
12 - Conflicts: [ ] | 12 - Conflicts: [ ] | ||
13 - Replaces: [ ] | 13 - Replaces: [ ] | ||
+ | |||
+ | |||
</pre> | </pre> | ||
- | "rev" utility is a part of util-linux. We can safely ignore the warning. However, checkinstall won't build a package unless we explicitly specify Name and Version of the package. | + | "rev" utility is a part of util-linux. We can safely ignore the warning. |
+ | However, checkinstall won't build a package unless we explicitly specify Name and Version of the package. | ||
This is it | This is it | ||
+ | |||
<pre> | <pre> | ||
Enter a number to change any of them or press ENTER to continue: 2 | Enter a number to change any of them or press ENTER to continue: 2 | ||
Line 475: | Line 483: | ||
</pre> | </pre> | ||
- | Now, you can use checkinstall in order to create | + | Now, you can use checkinstall in order to create debian packages for Maemo. |
- | + | ||
- | + |
Learn more about Contributing to the wiki.