<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://www.slacky.eu/wikislack/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="it">
		<id>http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;feed=atom&amp;action=history</id>
		<title>Safeinstall - Cronologia</title>
		<link rel="self" type="application/atom+xml" href="http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;feed=atom&amp;action=history"/>
		<link rel="alternate" type="text/html" href="http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;action=history"/>
		<updated>2013-06-19T20:04:50Z</updated>
		<subtitle>Cronologia della pagina su questo sito</subtitle>
		<generator>MediaWiki 1.20.3</generator>

	<entry>
		<id>http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;diff=2461&amp;oldid=prev</id>
		<title>L1q1d il 09:54, 12 set 2006</title>
		<link rel="alternate" type="text/html" href="http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;diff=2461&amp;oldid=prev"/>
				<updated>2006-09-12T09:54:42Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
			&lt;tr style='vertical-align: top;'&gt;
			&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;← Versione meno recente&lt;/td&gt;
			&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Versione delle 09:54, 12 set 2006&lt;/td&gt;
			&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Riga 1:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Riga 1:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;+&lt;/td&gt;
  &lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;[[category:Script]]&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt; &lt;/td&gt;
  &lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;= Descrizione =&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt; &lt;/td&gt;
  &lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;= Descrizione =&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt; &lt;/td&gt;
  &lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;SafeInstall sostituisce &quot;make install&quot;, ma anziche' installare il software crea un pacchetto .tgz per Slackware, che puo' essere installato con &quot;installpkg&quot; e rimosso con &quot;removepkg&quot;. In questo modo il sistema resta pulito e si puo' tenere tracci&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt; &lt;/td&gt;
  &lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;SafeInstall sostituisce &quot;make install&quot;, ma anziche' installare il software crea un pacchetto .tgz per Slackware, che puo' essere installato con &quot;installpkg&quot; e rimosso con &quot;removepkg&quot;. In questo modo il sistema resta pulito e si puo' tenere tracci&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>L1q1d</name></author>	</entry>

	<entry>
		<id>http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;diff=2460&amp;oldid=prev</id>
		<title>L1q1d il 09:54, 12 set 2006</title>
		<link rel="alternate" type="text/html" href="http://www.slacky.eu/wikislack/index.php?title=Safeinstall&amp;diff=2460&amp;oldid=prev"/>
				<updated>2006-09-12T09:54:21Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Nuova pagina&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= Descrizione =&lt;br /&gt;
SafeInstall sostituisce &amp;quot;make install&amp;quot;, ma anziche' installare il software crea un pacchetto .tgz per Slackware, che puo' essere installato con &amp;quot;installpkg&amp;quot; e rimosso con &amp;quot;removepkg&amp;quot;. In questo modo il sistema resta pulito e si puo' tenere tracci&lt;br /&gt;
= Readme (italiano) =&lt;br /&gt;
Compilare un programma per linux da sorgente e' semplice: il piu' delle&lt;br /&gt;
volte e' sufficiente dare:&lt;br /&gt;
&lt;br /&gt;
./configure make su make install&lt;br /&gt;
&lt;br /&gt;
Quest'ultimo comando installa effettivamente i file nel sistema. Raramente&lt;br /&gt;
pero' l'autore offre la possibilita' di dare &amp;quot;make uninstall&amp;quot;, quindi&lt;br /&gt;
la procedura di disinstallazione non e' affatto semplice.&lt;br /&gt;
&lt;br /&gt;
SafeInstall sostituisce &amp;quot;make install&amp;quot;, ma anziche' installare il software&lt;br /&gt;
crea un pacchetto .tgz per Slackware, che puo' essere installato con&lt;br /&gt;
&amp;quot;installpkg&amp;quot; e rimosso con &amp;quot;removepkg&amp;quot;. In questo modo il sistema resta&lt;br /&gt;
pulito e si puo' tenere traccia del software installato nel sistema.&lt;br /&gt;
&lt;br /&gt;
SafeInstall esegue il &amp;quot;make install&amp;quot; da utente normale, redirigendo&lt;br /&gt;
l'installazione in una directory temporanea della home directory&lt;br /&gt;
dell'utente, dalla quale poi crea effettivamente il pacchetto. Senza&lt;br /&gt;
permessi di root, non esiste il rischio che il &amp;quot;make install&amp;quot; sparga&lt;br /&gt;
in giro per il sistema qualche file, contribuendo cosi' alla &amp;quot;pulizia&amp;quot;&lt;br /&gt;
del sistema.&lt;br /&gt;
&lt;br /&gt;
SafeInstall necessita dei permessi di root esclusivamente per settare&lt;br /&gt;
correttamente i permessi dei file contenuti nel pacchetto.&lt;br /&gt;
&lt;br /&gt;
Prima di creare effettivamente il pacchetto, e' possibile aggiungere o&lt;br /&gt;
togliere files (per esempio eliminare locales, pagine man, etc.)&lt;br /&gt;
&lt;br /&gt;
Il pacchetto viene salvato nella home directory dell'utente, e&lt;br /&gt;
contemporaneamente vengono creati 2 file: &amp;quot;&amp;lt;nomepacchetto&amp;gt;.log&amp;quot; e&lt;br /&gt;
&amp;quot;&amp;lt;nomepacchetto&amp;gt;.err&amp;quot; contenenti i dettagli relativi all'installazione.&lt;br /&gt;
= Readme (inglese) =&lt;br /&gt;
Compiling a linux software from source is easy: most of the times you&lt;br /&gt;
just need to type:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./configure&lt;br /&gt;
make&lt;br /&gt;
su&lt;br /&gt;
make install&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The last command installs all the files in your system. Unfortunately,&lt;br /&gt;
only a few program's authors add an uninstall rule to their Makefile,&lt;br /&gt;
so removing the software isn't easy.&lt;br /&gt;
&lt;br /&gt;
SafeInstall takes the place of &amp;quot;make install&amp;quot;, but instead of installing&lt;br /&gt;
it builds a Slackware package, which can be installed with &amp;quot;installpkg&amp;quot;&lt;br /&gt;
and removed with &amp;quot;removepkg&amp;quot;. This way the system remains &amp;quot;clean&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
SafeInstall executes &amp;quot;make install&amp;quot; with normal user permissions,&lt;br /&gt;
redirecting the installation to a temporary directory in the user's&lt;br /&gt;
home, from which the package is built. Without root permissions, the&lt;br /&gt;
&amp;quot;make install&amp;quot; can't mess up the system with files installed anywhere.&lt;br /&gt;
&lt;br /&gt;
SafeInstall needs root permission just for setting package files and&lt;br /&gt;
directories permissions.&lt;br /&gt;
&lt;br /&gt;
Before creating the package you can manually modify the package content&lt;br /&gt;
(e.g. removing locales, man pages, ...).&lt;br /&gt;
&lt;br /&gt;
The package will be saved in your home directory, and at the same time&lt;br /&gt;
two files will be created:  &amp;quot;&amp;lt;packagename&amp;gt;.log&amp;quot; e &amp;quot;&amp;lt;packagename&amp;gt;.err&amp;quot;,&lt;br /&gt;
containing installation details.&lt;br /&gt;
= Script =&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
# SafeInstall v0.3 - Slackware package builder&lt;br /&gt;
# by davide aka bash 2005&lt;br /&gt;
# http://neutronstar.cjb.net&lt;br /&gt;
#&lt;br /&gt;
# DESCRIPTION&lt;br /&gt;
#&lt;br /&gt;
# Compiling a linux software from source is easy: most of the times you&lt;br /&gt;
# just need to type:&lt;br /&gt;
#&lt;br /&gt;
# ./configure&lt;br /&gt;
# make&lt;br /&gt;
# su &lt;br /&gt;
# make install&lt;br /&gt;
#&lt;br /&gt;
# The last command installs all the files in your system. Unfortunately,&lt;br /&gt;
# only a few program's authors add an uninstall rule to their Makefile,&lt;br /&gt;
# so removing the software isn't easy.&lt;br /&gt;
#&lt;br /&gt;
# SafeInstall takes the place of &amp;quot;make install&amp;quot;, but instead of installing&lt;br /&gt;
# it builds a Slackware package, which can be installed with &amp;quot;installpkg&amp;quot;&lt;br /&gt;
# and removed with &amp;quot;removepkg&amp;quot;. This way the system remains &amp;quot;clean&amp;quot;.&lt;br /&gt;
#&lt;br /&gt;
# SafeInstall executes &amp;quot;make install&amp;quot; with normal user permissions,&lt;br /&gt;
# redirecting the installation to a temporary directory in the user's&lt;br /&gt;
# home, from which the package is built. Without root permissions, the&lt;br /&gt;
# &amp;quot;make install&amp;quot; can't mess up the system with files installed anywhere.&lt;br /&gt;
#&lt;br /&gt;
# SafeInstall needs root permission just for setting package files and&lt;br /&gt;
# directories permissions.&lt;br /&gt;
#&lt;br /&gt;
# Before creating the package you can manually modify the package content&lt;br /&gt;
# (e.g. removing locales, man pages, ...).&lt;br /&gt;
#&lt;br /&gt;
# The package will be saved in your home directory, and at the same time&lt;br /&gt;
# two files will be created:  &amp;quot;&amp;lt;packagename&amp;gt;.log&amp;quot; e &amp;quot;&amp;lt;packagename&amp;gt;.err&amp;quot;,&lt;br /&gt;
# containing installation details.&lt;br /&gt;
#&lt;br /&gt;
# HISTORY&lt;br /&gt;
#&lt;br /&gt;
# 0.1 First public release.&lt;br /&gt;
# 0.2 Added &amp;quot;destdir&amp;quot; string grep into Makefile, for checking DESTDIR support.&lt;br /&gt;
# 0.3 Force &amp;quot;make DESTDIR= install&amp;quot; if requested.&lt;br /&gt;
#&lt;br /&gt;
# LICENCE&lt;br /&gt;
#&lt;br /&gt;
# This program is free software; you can redistribute it and/or modify&lt;br /&gt;
# it under the terms of the GNU General Public License as published by&lt;br /&gt;
# the Free Software Foundation; either version 2 of the License, or&lt;br /&gt;
# (at your option) any later version.&lt;br /&gt;
#&lt;br /&gt;
# This program is distributed in the hope that it will be useful,&lt;br /&gt;
# but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
# GNU General Public License for more details.&lt;br /&gt;
&lt;br /&gt;
OUTDIR=$HOME&lt;br /&gt;
PKG=&amp;quot;$HOME/tmppkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
CURDIR=`pwd`&lt;br /&gt;
PKGNAME=&amp;quot;`basename \&amp;quot;$CURDIR\&amp;quot;`&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -- SafeInstall v0.3 - Slackware package builder&lt;br /&gt;
echo -- by davide aka bash 2005&lt;br /&gt;
echo -- http://neutronstar.cjb.net&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- Building package: $PKGNAME.tgz&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
rm -r $PKG &amp;gt; /dev/null 2&amp;gt;&amp;amp;1&lt;br /&gt;
echo &amp;quot;-- Creating temporary directory...&amp;quot;&lt;br /&gt;
if [ -d &amp;quot;$PKG&amp;quot; ]; then&lt;br /&gt;
    echo &amp;quot;Could not delete $PKG, please delete it manually.&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
    exit&lt;br /&gt;
else&lt;br /&gt;
    mkdir $PKG&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
TESTDESTDIR=`cat Makefile | grep --ignore-case destdir`&lt;br /&gt;
if [ &amp;quot;$TESTDESTDIR&amp;quot; == &amp;quot;&amp;quot; ]; then&lt;br /&gt;
    echo &amp;quot;-- Makefile DOESN'T seem to offer DESTDIR support.&amp;quot;&lt;br /&gt;
    echo &amp;quot;-- Enter install command (e.g. \&amp;quot;make prefix=$PKG/usr install\&amp;quot;)&amp;quot;&lt;br /&gt;
    echo &amp;quot;-- or just hit ENTER to run \&amp;quot;make DESTDIR=$PKG install\&amp;quot; anyway.&amp;quot;&lt;br /&gt;
    echo &amp;quot;-- To quit now press CTRL-C.&amp;quot;&lt;br /&gt;
    read -p &amp;quot;-- &amp;quot; MAKECMD&lt;br /&gt;
    if [ &amp;quot;$MAKECMD&amp;quot; == &amp;quot;&amp;quot; ]; then&lt;br /&gt;
	make DESTDIR=$PKG install &amp;gt; $OUTDIR/$PKGNAME.log 2&amp;gt;$OUTDIR/$PKGNAME.err&lt;br /&gt;
    else&lt;br /&gt;
	echo&lt;br /&gt;
	echo &amp;quot;-- Executing \&amp;quot;$MAKECMD\&amp;quot;...&amp;quot;&lt;br /&gt;
	$MAKECMD &amp;gt; $OUTDIR/$PKGNAME.log&lt;br /&gt;
    fi&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;-- Makefile seems to offer DESTDIR support.&amp;quot;&lt;br /&gt;
    echo &amp;quot;-- Executing \&amp;quot;make DESTDIR=$PKG install\&amp;quot;...&amp;quot;&lt;br /&gt;
    make DESTDIR=$PKG install &amp;gt; $OUTDIR/$PKGNAME.log 2&amp;gt;$OUTDIR/$PKGNAME.err&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- Stripping binaries...&amp;quot;&lt;br /&gt;
find $PKG | xargs file | grep &amp;quot;executable&amp;quot; | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2&amp;gt; /dev/null&lt;br /&gt;
find $PKG | xargs file | grep &amp;quot;shared object&amp;quot; | grep ELF | cut -f1 -d : | xargs strip --strip-unneeded 2&amp;gt; /dev/null&lt;br /&gt;
find $PKG | xargs file | grep &amp;quot;current ar archive&amp;quot; | cut -f 1 -d  : | xargs strip -g 2&amp;gt; /dev/null&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- Compressing manual and info pages...&amp;quot;&lt;br /&gt;
for DIR in `find $PKG -type d -name 'man?' -print`; do cd $DIR &amp;amp;&amp;amp; gzip -9 *; done&lt;br /&gt;
for DIR in `find $PKG -type d -name 'info' -print`; do cd $DIR &amp;amp;&amp;amp; gzip -9 *; done&lt;br /&gt;
&lt;br /&gt;
cd $PKG&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- If needed, modify NOW \&amp;quot;$PKG\&amp;quot; directory content&amp;quot;&lt;br /&gt;
echo &amp;quot;-- (file and dir permissions will be set later on),&amp;quot;&lt;br /&gt;
echo -n &amp;quot;-- then hit ENTER to start creating package, or CTRL-C to quit.&amp;quot;&lt;br /&gt;
read&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- Please insert root password for setting up correct permissions.&amp;quot;&lt;br /&gt;
echo -n &amp;quot;-- &amp;quot;&lt;br /&gt;
su -c &amp;quot;chown -R root.root $PKG/* &amp;amp;&amp;amp; \&lt;br /&gt;
find $PKG -type d -name bin -exec chown -R root.bin {} \; &amp;amp;&amp;amp; \&lt;br /&gt;
/sbin/makepkg -l y -c n $OUTDIR/$PKGNAME.tgz &amp;gt; /dev/null 2&amp;gt;&amp;amp;1 &amp;amp;&amp;amp; \&lt;br /&gt;
rm -r $PKG&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;-- \&amp;quot;$OUTDIR/$PKGNAME.tgz\&amp;quot; successfully created.&amp;quot;&lt;br /&gt;
echo &amp;quot;-- Install it with \&amp;quot;installpkg $PKGNAME.tgz\&amp;quot;.&amp;quot;&lt;br /&gt;
echo &amp;quot;-- Check \&amp;quot;$PKGNAME.log\&amp;quot; and \&amp;quot;$PKGNAME.err\&amp;quot; for details.&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Data:    	03 Jun 2006&lt;br /&gt;
* Autore:    	Bash&lt;br /&gt;
* Versione:    	0.3&lt;/div&gt;</summary>
		<author><name>L1q1d</name></author>	</entry>

	</feed>