Bug 143260 - devel/gobject-introspection writes files in $HOME
Summary: devel/gobject-introspection writes files in $HOME
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-gnome (Nobody)
Depends on:
Reported: 2010-01-26 15:20 UTC by Olaf Seibert
Modified: 2010-11-20 15:40 UTC (History)
1 user (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Olaf Seibert 2010-01-26 15:20:06 UTC
	devel/gobject-introspection writes files in $HOME while building.
	This does not work if you compile a package as root and
	the home directory is on NFS. In any case it is bad form.


I don't know. Avoid bad Linux software?

How-To-Repeat: 	sudo portinstall devel/gobject-introspection
	(I actually discovered it while building the GIMP).


	on one machine I got "permission denied" errors. After throwing my
	hands in the air and doing a chmod 777 $HOME/.cache, it worked
	on one FreeBSD-6.0 host. On another, with 8.0, I got

libtool: link: ranlib .libs/libgirepository-everything-1.0.a
libtool: link: ( cd ".libs" && rm -f "libgirepository-everything-1.0.la" && ln -s "../libgirepository-everything-1.0.la" "libgirepository-everything-1.0.la" )
env LPATH=.libs  env PYTHONPATH=..:..:YTHONPATH UNINSTALLED_INTROSPECTION_SRCDIR=.. UNINSTALLED_INTROSPECTION_BUILDDIR=.. ../tools/g-ir-scanner -v --add-include-path=../gir --add-include-path=. -v --add-include-path=../gir --add-include-path=. --namespace=GIRepository --nsversion=2.0 --libtool="/bin/sh /usr/local/bin/libtool"  --library=girepository-1.0 --pkg=gobject-2.0 --include=GObject-2.0 --no
closure --strip-prefix=g --c-include="girepository.h" --pkg-export gobject-introspection-1.0 -I./girepository ../girepository/girepository.c ../girepository/girepository.h --output GIRepository-2.0.gir
Traceback (most recent call last):
  File "../tools/g-ir-scanner", line 38, in <module>
  File "/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7/giscanner/scannermain.py", line 277, in scanner_main
  File "/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7/giscanner/transformer.py", line 112, in register_include
  File "/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7/giscanner/transformer.py", line 137, in _parse_include
    self._cachestore.store(filename, parser)
  File "/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7/giscanner/cachestore.py", line 112, in store
    shutil.move(tmp_filename, store_filename)
  File "/usr/local/lib/python2.6/shutil.py", line 264, in move
    copy2(src, real_dst)
  File "/usr/local/lib/python2.6/shutil.py", line 100, in copy2
    copystat(src, dst)
  File "/usr/local/lib/python2.6/shutil.py", line 77, in copystat
    os.chflags(dst, st.st_flags)
OSError: [Errno 45] Operation not supported: '/home/vb/olafs/.cache/g-ir-scanner/e3b1e4a32a6f9b450523f126aea3ddb7a1e19c90'
gmake[2]: *** [GIRepository-2.0.gir] Error 1
gmake[2]: Leaving directory `/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7/gir'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.7'
gmake: *** [all] Error 2
*** Error code 1

Stop in /usr/ports/devel/gobject-introspection.
** Command failed [exit code 1]: /usr/bin/script -qa /tmp/portinstall20100126-91846-6rfiap-0 env make DEPENDS_TARGET=package
** Fix the problem and try again.
--->  Skipping 'sysutils/polkit' because a requisite port 'devel/gobject-introspection' failed (specify -k to force)
--->  Skipping 'multimedia/gstreamer' because a requisite port 'devel/gobject-introspection' failed (specify -k to force)
--->  Skipping 'multimedia/gstreamer-plugins' because a requisite port 'multimedia/gstreamer' failed (specify -k to force)
--->  Skipping 'sysutils/policykit-gnome' because a requisite port 'sysutils/polkit' failed (specify -k to force)
... more of those ...

	The directory $HOME/.cache/g-ir-scanner was not there before

	Note that I have no control over the NFS server serving $HOME.
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2010-01-26 15:20:15 UTC
Responsible Changed
From-To: freebsd-ports-bugs->gnome

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Adrian Steinmann 2010-02-20 16:30:04 UTC
A workaround is

mkdir /tmp/cache
rm -rf ${HOME}/.cache && ln -s /tmp/cache ${HOME}/.cache

so that the testdirectories end up local.

Hope this helps
Comment 3 Jeremy Messenger freebsd_committer freebsd_triage 2010-10-03 18:12:25 UTC
State Changed
From-To: open->patched

Committed a fix in MarcusCom CVS by get it put in ${WRKDIR} instead of $HOME: 

Comment 4 Koop Mast freebsd_committer freebsd_triage 2010-11-20 15:39:58 UTC
State Changed
From-To: patched->closed

Committed to FreeBSD ports, Thanks.