Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 06 Feb 2005 12:17:07 +0100
From:      Florent Thoumie <flz@xbsd.org>
To:        Mike Brown <mike@skew.org>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: empty dirs needed in package
Message-ID:  <4205FCB3.9000800@xbsd.org>
In-Reply-To: <200502060920.j169KvTD056755@chilled.skew.org>
References:  <200502060920.j169KvTD056755@chilled.skew.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Mike Brown a écrit :
> Hi again,
> 
> My port creates some empty directories. They won't always be empty,
> if certain features of the software are used.
> 
> I need installing from a pacakge to result in the creation of these
> directories. Apparently, 'make package' produces a package that has
> no idea that it needs to create these directories, since there is no
> way, AFAIK, to specify empty dirs in a pkg-plist.
> 
> Since there are @dirrm entries for these directories in my pkg-plist,
> doing a 'make deinstall' after a 'pkg_add' results in complaints
> that the directories don't exist.
> 
> What's the proper way to deal with this?
> 
> Do I do something special to the pkg-plist?
> Do I use a custom +MTREE_DIRS somehow when making the package?
> Do I remove the @dirrm entries and put something in a post-deinstall
> target in the Makefile instead?

	I guess using something like that will be good :

	@exec mkdir -p %D/path/to/dir

	Note that %D is needed, and will be handled as ${PREFIX} by
	pkg_create.

-- 
Florent Thoumie
flz@xbsd.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4205FCB3.9000800>