Dimensione: 4028
Commento:
|
Dimensione: 3665
Commento: corretto link
|
Le cancellazioni sono segnalate in questo modo. | Le aggiunte sono segnalate in questo modo. |
Linea 6: | Linea 6: |
= Introduzione = | |
Linea 7: | Linea 8: |
This document describes how to install debug packages on Ubuntu, which will aid in providing information for bugs. | Questo documento descrive come installare pacchetti per eseguire il '''''debug''''' in Ubuntu. |
Linea 9: | Linea 10: |
== Ubuntu 7.04 «Feisty Fawn» == | |
Linea 10: | Linea 12: |
== Edgy Eft 6.10 == Use this section only if you are using Ubuntu Edgy 6.10. See the following section if you are using a prior version. 1. Add the following line to `/etc/apt/sources.list`: {{{deb http://people.ubuntu.com/~pitti/ddebs edgy main universe |
Questo passo descrive quanto detto in precedenza per «Edgy Eft» anche per «Feisty Fawn», aggiungere la seguente linea al file `/etc/apt/sources.list`: {{{ deb http://people.ubuntu.com/~pitti/ddebs feisty main universe |
Linea 18: | Linea 16: |
2. Import Martin's public key to your keyring: {{{ |
== Ubuntu 7.10 «Gutsy Gibbon» == Come già esposto in precedenza, aggiungere la seguente linea in `/etc/apt/sources.list`: {{{ deb http://people.ubuntu.com/~pitti/ddebs gutsy main universe }}} == Ubuntu 6.10 «Edgy Eft» == Usare questa sezione solo se si possiede '''Ubuntu 6.10''' «'''Edgy Eft'''». Anche in caso di versioni precedenti seguire quanto segue: Aggiungere la seguente linea in `/etc/apt/sources.list`: {{{ deb http://people.ubuntu.com/~pitti/ddebs edgy main universe }}} Importare la chiave pubblica di Martin sul sistema: {{{ |
Linea 23: | Linea 36: |
3. Then run {{{ |
Per aggiornare la lista dei pacchetti, digitare: {{{ |
Linea 27: | Linea 39: |
to update your package list. | |
Linea 29: | Linea 40: |
4. The debug symbol packages have the '-dbgsym' suffix attached, so to install the debug symbols for the package 'yelp', you run: {{{ |
I simboli dei pacchetti del debug hanno allegato il suffisso `-dbgsym`, così per installare i simboli di debug per il pacchetto ''yelp'', digitare: {{{ |
Linea 34: | Linea 44: |
a. Now you make a ["Backtrace"]. a. You can also run ["Valgrind"], if the program crashes with a "Segmentation fault" or "Bus error". a. Optionally, you may be asked to produce an ["Strace"]. |
a. Adesso è stato realizzato un [wiki:Ubuntu/Backtrace Backtrace]; a. eseguire [:Programmazione/Valgrind:Valgrind], se il programma crasha a causa di ''Segmentation fault'' o ''Bus error''; a. a scelta, potrebbe venir chiesta una wiki:Ubuntu/Strace. |
Linea 39: | Linea 49: |
=== References === | == Versioni di Ubuntu precedenti == |
Linea 41: | Linea 51: |
* Announcement: https://lists.ubuntu.com/archives/ubuntu-devel-announce/2006-September/000195.html | Questa sezione riguarda le versioni che precedono '''Ubuntu 6.10''' «'''Edgy Eft'''». |
Linea 43: | Linea 53: |
||<tablestyle="text-align: justify; width:100%; " style="border:none;" 5%>[[Immagine(Icone/Piccole/note.png,,center)]] ||<style="padding:0.5em; border:none;"> ''Se si vuole creare un pacchetto, assicurarsi di avere la linea deb-src in `/etc/apt/sources.list`''|| | |
Linea 44: | Linea 55: |
== Feisty Fawn 7.04 == | Controllare se il pacchetto è disponibile per la versione di debugging. Generalmente, i pacchetti di debug saranno identificati con il suffisso `-dbg`. |
Linea 46: | Linea 57: |
The steps described above for Edgy also work for Feisty, just add the following line to `/etc/apt/sources.list`: | Se non è disponibile, è possibile crearne uno in questo modo: |
Linea 48: | Linea 59: |
{{{deb http://people.ubuntu.com/~pitti/ddebs feisty main universe }}} == Gutsy Gibbon 7.10 == The steps described above for Edgy also work for Gutsy, just add the following line to '/etc/apt/sources.list' : {{{deb http://people.ubuntu.com/~pitti/ddebs gutsy main universe }}} == Prior Ubuntu versions == Use this section if you are using an Ubuntu version prior to Edgy 6.10. 1. Check if the package has a debugging version available. In general, debugging packages will be named with a `-dbg` suffix 1. If not, you can generally* build one this way: Something to keep in mind: if you would like to create a build you're going to need to have the relevant deb-src lines in your /etc/apt/sources.list a. Install the development scripts: {{{ |
installare lo script seguente: {{{ |
Linea 71: | Linea 63: |
a. Find out to which package your program belongs to: {{{ |
scoprire quale pacchetto appartiene al proprio programma: {{{ |
Linea 76: | Linea 67: |
a. Install the build-time dependencies for the package: {{{ |
installare le dipendenze:{{{ |
Linea 80: | Linea 70: |
a. Build .debs for debugging: {{{ |
creare `.deb` per il debugging:{{{ |
Linea 85: | Linea 75: |
a. Install the needed .debs (they will be in the current working directory if the build succeeded): {{{ |
installare i necessari `.deb` (si troveranno nella cartella di lavoro, in caso di successo nella creazione): {{{ |
Linea 90: | Linea 80: |
* Most packages support the build of debugging version in this way. If this process doesn't work for a package, please open a bug against it. == The Xorg server == The X server will by default trap its own crashes and dump a stack trace in /var/log/Xorg.0.log. However, this stack trace is modified by the signal handler itself. To get a "normal" crash, which will trigger a core dump (and ''apport'' reporting), add this to your /etc/X11/xorg.conf: {{{ |
== Xorg server == Il server X server è in grado di gestire i ''crash'' creando uno "scarico" (''dump'') lasciando la traccia in `/var/log/Xorg.0.log`. Questa traccia è modificata dallo stesso segnale responsabile. Per ottenere un "normale" crash, cioè che crei un ''core dump'' (e un resoconto tramite '''apport'''), aggiungere nel file `/etc/X11/xorg.conf` la seguente opzione: {{{ |
Linea 103: | Linea 88: |
== Info for the BugSquad == | = Ulteriori risorse = |
Linea 105: | Linea 90: |
If you're trying to `apport-retrace` a crash report from a bug that didn't happen on the same Ubuntu release as the one you're running, do the following: | * [https://wiki.ubuntu.com/DebuggingProgramCrash Documento originale] |
Linea 107: | Linea 92: |
Say that you're running `feisty` and the crash happened on `edgy`: 0. This will create a minimal `edgy` system. {{{ sudo mkdir -p /chroots/edgy sudo debootstrap edgy /chroots/edgy/}}} 0. Now you change into this minimal `edgy` system. {{{ sudo chroot /chroot/edgy}}} 0. edit `/etc/apt/sources/list` and all the repositories you need, especially Martin's ddeb repository. 0. {{{ apt-get update; apt-get install gdb apport}}} 0. use `apport-retrace` as you're used to. |
* Annunci: https://lists.ubuntu.com/archives/ubuntu-devel-announce/2006-September/000195.html |
Linea 120: | Linea 94: |
CategoryNuoviDocumenti |
Indice:BRTableOfContents |
Introduzione
Questo documento descrive come installare pacchetti per eseguire il debug in Ubuntu.
Ubuntu 7.04 «Feisty Fawn»
Questo passo descrive quanto detto in precedenza per «Edgy Eft» anche per «Feisty Fawn», aggiungere la seguente linea al file /etc/apt/sources.list:
deb http://people.ubuntu.com/~pitti/ddebs feisty main universe
Ubuntu 7.10 «Gutsy Gibbon»
Come già esposto in precedenza, aggiungere la seguente linea in /etc/apt/sources.list:
deb http://people.ubuntu.com/~pitti/ddebs gutsy main universe
Ubuntu 6.10 «Edgy Eft»
Usare questa sezione solo se si possiede Ubuntu 6.10 «Edgy Eft».
Anche in caso di versioni precedenti seguire quanto segue:
Aggiungere la seguente linea in /etc/apt/sources.list:
deb http://people.ubuntu.com/~pitti/ddebs edgy main universe
Importare la chiave pubblica di Martin sul sistema:
wget -q "http://keyserver.ubuntu.com:11371/pks/lookup?op=get&search=0x0DE7276D5E0577F2" -O- | sudo apt-key add -
Per aggiornare la lista dei pacchetti, digitare:
sudo apt-get update
I simboli dei pacchetti del debug hanno allegato il suffisso -dbgsym, così per installare i simboli di debug per il pacchetto yelp, digitare:
sudo apt-get install yelp-dbgsym
- Adesso è stato realizzato un [wiki:Ubuntu/Backtrace Backtrace];
eseguire [:Programmazione/Valgrind:Valgrind], se il programma crasha a causa di Segmentation fault o Bus error;
- a scelta, potrebbe venir chiesta una wiki:Ubuntu/Strace.
Versioni di Ubuntu precedenti
Questa sezione riguarda le versioni che precedono Ubuntu 6.10 «Edgy Eft».
Se si vuole creare un pacchetto, assicurarsi di avere la linea deb-src in /etc/apt/sources.list |
Controllare se il pacchetto è disponibile per la versione di debugging. Generalmente, i pacchetti di debug saranno identificati con il suffisso -dbg.
Se non è disponibile, è possibile crearne uno in questo modo:
installare lo script seguente:
sudo apt-get install devscripts fakeroot
scoprire quale pacchetto appartiene al proprio programma:
dpkg --search <program>
installare le dipendenze:
sudo apt-get build-dep <package>
creare .deb per il debugging:
export DEB_BUILD_OPTIONS="debug nostrip noopt" fakeroot apt-get source -b <package>
installare i necessari .deb (si troveranno nella cartella di lavoro, in caso di successo nella creazione):
sudo debi <package>*.changes
Xorg server
Il server X server è in grado di gestire i crash creando uno "scarico" (dump) lasciando la traccia in /var/log/Xorg.0.log. Questa traccia è modificata dallo stesso segnale responsabile. Per ottenere un "normale" crash, cioè che crei un core dump (e un resoconto tramite apport), aggiungere nel file /etc/X11/xorg.conf la seguente opzione:
Section "ServerFlags" Option "NoTrapSignals" "true" EndSection
Ulteriori risorse
[https://wiki.ubuntu.com/DebuggingProgramCrash Documento originale]
Annunci: https://lists.ubuntu.com/archives/ubuntu-devel-announce/2006-September/000195.html