From owner-freebsd-questions@FreeBSD.ORG Wed Jul 9 18:52:19 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DBBCFC13 for ; Wed, 9 Jul 2014 18:52:19 +0000 (UTC) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8984E2D87 for ; Wed, 9 Jul 2014 18:52:19 +0000 (UTC) Received: from r56.edvax.de (port-92-195-69-249.dynamic.qsc.de [92.195.69.249]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx01.qsc.de (Postfix) with ESMTPS id B658A3CB9E; Wed, 9 Jul 2014 20:52:16 +0200 (CEST) Received: from r56.edvax.de (localhost [127.0.0.1]) by r56.edvax.de (8.14.5/8.14.5) with SMTP id s69IqGgd001909; Wed, 9 Jul 2014 20:52:16 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Wed, 9 Jul 2014 20:52:15 +0200 From: Polytropon To: rvclayton@acm.org (R. Clayton) Subject: Re: Reconfiguring a package and other questions. Message-Id: <20140709205215.86615682.freebsd@edvax.de> In-Reply-To: <8738eaochn.fsf@UlanBator.myhome.westell.com> References: <8738eaochn.fsf@UlanBator.myhome.westell.com> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 Jul 2014 18:52:19 -0000 On Wed, 09 Jul 2014 10:03:48 -0400, R. Clayton wrote: > I'm running this > > $ uname -a > FreeBSD BanjaLuka 10.0-RELEASE FreeBSD 10.0-RELEASE #0 r260789: Fri Jan 17 > 01:46:25 UTC 2014 root@snap.freebsd.org:/usr/obj/usr/src/sys/GENERIC i386 > > $ > > and I did this (via www.freebsd.org/handbook/x-install.html) > > # pkg install xorg > > to install X. It didn't work: xstart runs the default window manager, but the > keyboard and mouse are frozen. You're probably missing HAL and DBUS. Those need to be enabled via rc.conf. Requiring those is a result of the default options from which the X package has been generated. If you _intend_ not to use them, you'll have to compile X with the required options (unset) yourself, or maybe find a package source that has those options disabled. You can also find information here: http://www.wonkity.com/~wblock/docs/html/aei.html > 1: I usually install xorg from ports, and what I do in this case (which usually > happens) is reconfigure xorg-server to disable hal. However, I don't see how > packages can be reconfigured. They can't. You have to build from source yourself. > the pkg-config man page seems to show how to > reconfigure pkg itself, not individual packages. How it possible to > reconfigure packages? It's impossible. The only alternative is to obtain packages with different options, those may or may not exist in the official repositories. There might be 3rd party repositories which make them available. > 2: How do I undo the effects of installing a metapackage like xorg? Doing the > obvious > > # whereis X > X: /usr/local/bin/X > > # pkg remove xorg > Deinstallation has been requested for the following 1 packages: > > xorg-7.7 > > Proceed with deinstalling packages [y/N]: y > [1/1] Deleting xorg-7.7... done > > # whereis X > X: /usr/local/bin/X > > # > > doesn't do what I wanted ("pkg delete -R xorg" behaves as above). Correct. The metaport does not automatically deinstall all of its components. It's possible to use a regex to remove all ports containing "xorg" (NB: make sure you're not removing "false positives"!). You can also determine which port has installed a certain file on the system, for example # pkg which `which X` This will deinstall the package responsible for the binary, but ports for libraries, input drivers and so on will be kept. It could be neccessary to remove them as well. > 3: I resorted to deleting xorg-server as a package and re-installing it as a > port with appropriate configuration. This works, but raises the question of > consistency between ports and packages. This should not be a problem in general. BUT: Related to X and its requirement for HAL and DBUS, which are also requirements of many other ports, this _could_ lead to problems when you install an application package that expects HAL being present in X _and_ running, and your configuration does not meet those requirement. In those special cases, building that port (and maybe its depencencies) could be needed. > What is the relation between the > software in ports and the software in packages? Installing from a port means that a package is created by compiling from source, and this package is then installed and registered. Installing via pkg is similar, except the package is obtained from a repository. The packages available in the official FreeBSD repositories are built from ports as well, and with the _default_ options. Regarding software registration: Both "pkg install" and "make install" cause the system database to properly register installed software and its dependencies and requirements. There is no difference. That's why using a port management program (such as portmaster or portupgrade) is not a problem. > Have I just introduced an > error (or potential for error) that will come back and bite me hard six months > after I've forgotten what I've done? Probably not, and pkg is able to resolve "conflicts" quite well. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...