Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index International Gentoo Users Forum italiano (Italian) Risorse italiane (documentazione e tools)
  • Search

[HOWTO] Konqueror e protocollo sysinfo:/

Forum riservato alla documentazione in italiano.

Moderator: ago

Post Reply
  • Print view
Advanced search
1 post • Page 1 of 1
Author
Message
klaimath
Apprentice
Apprentice
Posts: 213
Joined: Sun Jun 18, 2006 2:15 pm

[HOWTO] Konqueror e protocollo sysinfo:/

  • Quote

Post by klaimath » Fri Mar 23, 2007 8:32 pm

Sysinfo è un protocollo usato dalle distribuzioni SuSE per mostrare delle informazioni sul pc. Queste informazioni comprendono:

- Folder
- CPU
- Scheda Video
- Partizioni e dischi montati
- Sistema operativo in uso e versione del kernel ecc...

Vediamo un pò come installare il tutto su Gentoo.

Per prima cosa è necessario creare un paio di directory nel portage overlay

Code: Select all

sudo mkdir /locazione_del_vostro_portage/kde-misc
sudo mkdir /locazione_del_vostro_portage/kde-misc/kio_sysinfo


e copiarci dentro l'ebuild che potete trovare a questo indirizzo http://bugs.gentoo.org/show_bug.cgi?id=139837 oppure fate un bel copia e incolla di questo in un file chiamato kio-sysinfo-3.5.5.ebuild

Code: Select all

# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit kde

MY_P="kdebase3-SuSE-10.2-84.src"
S="${WORKDIR}/kdebase-SuSE"

DESCRIPTION="kio slave to display system infomation in konqueror"
HOMEPAGE="http://www.opensuse.org"
SRC_URI="http://suse.mirrors.tds.net/pub/opensuse/distribution/10.2/repo/src-oss/suse/src/${MY_P}.rpm"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~amd64"
DEPEND="virtual/libc
	|| ( kde-base/kdebase-kioslaves kde-base/kdebase )
	app-arch/rpm2targz
	>=sys-apps/hwinfo-13.0"
IUSE=""

src_unpack(){

	cd ${WORKDIR}
	rpm2targz ${DISTDIR}/${MY_P}.rpm
	tar -xzf ${WORKDIR}/${MY_P}.tar.gz || die "error unpacking kio-sysinfo"
	tar -xjf ${WORKDIR}/kdebase-SuSE-10.2.tar.bz2 || die "error unpacking kio-sysinfo"
        cd kdebase-SuSE
}


src_compile() {

	sed -i -e "s/\$(TOPSUBDIRS)/sysinfo/" Makefile.am
	sed -i -e "s/SuSE/gentoo/" sysinfo/sysinfo.cpp
	kde_src_compile 'all' || die "error compiling"
}
Ricostruite il digest con il comando

Code: Select all

sudo ebuild /locazione_del_vostro_portage/kde-misc/kio-sysinfo/kio-sysinfo-3.5.5.ebuild digest
e smascherate il pacchetto aggiungendo

Code: Select all

kde-misc/kio-sysinfo
nel file /etc/portage/package.unmask

Se tutto è andato bene lanciate un

Code: Select all

sudo emerge kio-sysinfo
e smascherate le dipendenze (nel mio caso hwinfo e sysfsutils) andando incontro a dei problemi che ora vedremo come risolvere.

Kio-sysinfo vuole una versione di hwinfo uguale o superiore alla 13.00 ma poichè la 13.0 non compila con gcc-4.1.1-r1 bisogna ricorrere alla versione 13.11 più la patch per il makefile. Tutto quel che occorre lo potete trovare qua http://bugs.gentoo.org/show_bug.cgi?id=157256

Per prima cosa create le seguenti directory

Code: Select all

sudo mkdir /locazione_del_vostro_portage/sys-apps/
sudo mkdir /locazione_del_vostro_portage/sys-apps/hwinfo
sudo mkdir /locazione_del_vostro_portage/sys-apps/hwinfo/files
e scaricate l'ebuild in sys-apps/hwinfo, fatto questo scaricate la patch nella directory sys-apps/hwinfi/files e ricostruite il digest (attenzione i server spesso sono down e può essere che occorrano due o tre tentativi per portare in fondo la ricostruzione del digest).

Se non volete andare sul bugzilla l'ebuild è questo (salvatelo in un file di nome hwinfo-13.11.ebuild)

Code: Select all

# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwinfo/hwinfo-13.0.ebuild,v 1.3 2006/09/29 22:40:15 robbat2 Exp $

inherit eutils

DESCRIPTION="hwinfo is the hardware detection tool used in SuSE Linux."
HOMEPAGE="http://www.suse.com"
DEBIAN_PV="3"
DEBIAN_BASE_URI=" mirror://debian/pool/main/${PN:0:1}/${PN}/"
SRC_URI="${DEBIAN_BASE_URI}/${PN}_${PV}.orig.tar.gz
		 ${DEBIAN_BASE_URI}/${PN}_${PV}-${DEBIAN_PV}.diff.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~ppc ~x86 ~amd64"
IUSE=""
RDEPEND=">=sys-fs/sysfsutils-2
		sys-apps/hal
		sys-apps/dbus"
# this package won't work on *BSD
DEPEND="${RDEPEND}
		>=sys-kernel/linux-headers-2.6.17"

src_unpack (){
	unpack ${PN}_${PV}.orig.tar.gz
	EPATCH_OPTS="-p1 -d ${S}" epatch ${DISTDIR}/${PN}_${PV}-${DEBIAN_PV}.diff.gz
	rm ${S}/debian/patches/series
	for p in ${S}/debian/patches/*; do
		EPATCH_OPTS="-p0 -d ${S}" epatch ${p}
	done
	EPATCH_OPTS="-p1 -d ${S}" epatch ${FILESDIR}/${PN}-13.11-makefile-fixes.patch
	#sed -i -e "s,^LIBS[ \t]*= -lhd,LIBS = -lhd -lsysfs," ${S}/Makefile
	#sed -i -e "s,^LIBDIR[ \t]*= /usr/lib$,LIBDIR = /usr/$(get_libdir)," ${S}/Makefile
	echo 'libs: $(LIBHD) $(LIBHD_SO)' >>${S}/Makefile
}

src_compile(){
	# build is NOT parallel safe
	emake -j1 EXTRA_FLAGS="${CFLAGS}" || die "emake failed"
}

src_install() {
	emake install DESTDIR="${D}" || die
	dodoc VERSION README COPYING ChangeLog
	doman doc/hwinfo.8
	# this is the SuSE version
	# somebody needs to port it still
	rm ${D}/etc/init.d/hwscan
}
mentre la patch (da salvare in un file di nome hwinfo-13.11-makefile-fixes.patch) è la seguente

Code: Select all

diff -urN hwinfo-13.11/Makefile.common hwinfo-13.11.new/Makefile.common
--- hwinfo-13.11/Makefile.common	2006-09-11 11:36:57.000000000 +0100
+++ hwinfo-13.11.new/Makefile.common	2007-01-22 18:43:43.000000000 +0000
@@ -22,7 +22,7 @@
 
 CC	= gcc
 LD	= ld
-CFLAGS	= $(RPM_OPT_FLAGS) -Wall -Wno-pointer-sign -pipe -g $(SHARED_FLAGS) $(EXTRA_FLAGS) -I$(TOPDIR)/src/hd
+CFLAGS	= $(RPM_OPT_FLAGS) -Wall -pipe -g $(SHARED_FLAGS) $(EXTRA_FLAGS) -I$(TOPDIR)/src/hd
 SHARED_FLAGS	= -fPIC
 
 LDFLAGS	= -Lsrc
Una volta che l'ebuild e la patch sono al loro posto (copiati/incollati o scaricati) rifate il digest

Code: Select all

sudo ebuild /locazione_del_vostro_portage/sys-apps/hwinfo/hwinfo-13.11.ebuild digest
e smascherate il pacchetto inserendo

Code: Select all

=sys-apps/hwinfo-13.11
in /etc/portage/package.unmask e

Se tutto è andato bene non vi resta che lanciare un bel

Code: Select all

sudo emerge kio-system
e se la compilazione va a buon fine godetevi il frutto del vostro lavoro aprendo konqueror e puntandolo a questo indirizzo

Code: Select all

sysinfo:/
Cya
Klaimath
Top
Post Reply
  • Print view
1 post • Page 1 of 1

Return to “Risorse italiane (documentazione e tools)”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic