how should port file confilicts/updates be solved?
![](https://secure.gravatar.com/avatar/eceb1cc66066c414b14a64b846cd6256.jpg?s=120&d=mm&r=g)
hi, the general question is, whether there already exists a common pattern, what to do, when a installation routine wants to modify an existing file of an already installed port. Simply removing the previous port wouldn't work, since the new port depends on the old one. The story: Atm I am trying to create a p5-xml-libxml port on my own, without any patches. The p5-xml-libxml port depends on the p5-xml-sax port, which contains the file: /usr/lib/perl5/site_perl/5.8.8/XML/SAX/ParserDetails.ini. During the installation of p5-xml-libxml it (imho) wants to register itself as a sax parser, but can't, sice it doesn't have write permissions to this file (i am building my ports as unprivileged user)(see attached log file). Does anyone of you have a clue, how to tackle this problem? Fyi: The ports how they are atm are at [1] and a httpup file is at [2]. bye richi [1] http://www.deri.at/~richardp/ports/ [2] http://www.deri.at/~richardp/ports/namenlos.httpup -- quoting guide: http://www.xs4all.nl/~hanb/documents/quotingguide.html
![](https://secure.gravatar.com/avatar/4e374bb9f03cbbca5d9541a8bf8ec8bf.jpg?s=120&d=mm&r=g)
Hi Richard, On Thu, Jul 12, 2007 at 13:28:05 +0200, Richard Pöttler wrote:
hi,
The story: Atm I am trying to create a p5-xml-libxml port on my own, without any patches. The p5-xml-libxml port depends on the p5-xml-sax port, which contains the file: /usr/lib/perl5/site_perl/5.8.8/XML/SAX/ParserDetails.ini. During the installation of p5-xml-libxml it (imho) wants to register itself as a sax parser, but can't, sice it doesn't have write permissions to this file (i am building my ports as unprivileged user)(see attached log file). Ports should never write to the live filesystem, even when building as root. If the standard installation routines do that, you'll have to
[...] patch it out or find another way to stop it from doing that. If an application needs to register itself in a file not owned by that port, using post-install scripts and/or asking the user to perform that action manually after installation is the only way to achieve that. HTH, Johannes -- Johannes Winkelmann mailto:jw@smts.ch Zurich, Switzerland http://jw.smts.ch
![](https://secure.gravatar.com/avatar/eceb1cc66066c414b14a64b846cd6256.jpg?s=120&d=mm&r=g)
On Thu, Jul 12, 2007 at 01:30:12PM +0200, Johannes Winkelmann wrote:
The story: Atm I am trying to create a p5-xml-libxml port on my own, without any patches. The p5-xml-libxml port depends on the p5-xml-sax port, which contains the file: /usr/lib/perl5/site_perl/5.8.8/XML/SAX/ParserDetails.ini. During the installation of p5-xml-libxml it (imho) wants to register itself as a sax parser, but can't, sice it doesn't have write permissions to this file (i am building my ports as unprivileged user)(see attached log file). Ports should never write to the live filesystem, even when building as root. If the standard installation routines do that, you'll have to
On Thu, Jul 12, 2007 at 13:28:05 +0200, Richard Pöttler wrote: patch it out or find another way to stop it from doing that.
If an application needs to register itself in a file not owned by that port, using post-install scripts and/or asking the user to perform that action manually after installation is the only way to achieve that.
Hi, Johannes, thanks for this advice. Totally forgot about post-install scripts... I managed to do the changes with such a script. bye richi -- quoting guide: http://www.xs4all.nl/~hanb/documents/quotingguide.html
participants (2)
-
Johannes Winkelmann
-
Richard Pöttler