Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 82312
Collapse All | Expand All

(-)portage-2.0.51.16/bin/ebuild.sh (-4 / +11 lines)
Lines 690-695 Link Here
690
		chflags -R noschg,nouchg,nosappnd,nouappnd,nosunlnk,nouunlnk \
690
		chflags -R noschg,nouchg,nosappnd,nouappnd,nosunlnk,nouunlnk \
691
			"${BUILDDIR}"
691
			"${BUILDDIR}"
692
	fi
692
	fi
693
	
694
	if [ "$USERLAND" == "Darwin" ] && type -p chflags &>/dev/null; then
695
		chflags -R noschg,nouchg,nosappnd,nouappnd "${BUILDDIR}"
696
	fi
693
697
694
	rm -rf "${BUILDDIR}/image"
698
	rm -rf "${BUILDDIR}/image"
695
699
Lines 1063-1069 Link Here
1063
				python -c "import os,stat; print '%o' % os.stat('$1')[stat.ST_MODE]"
1067
				python -c "import os,stat; print '%o' % os.stat('$1')[stat.ST_MODE]"
1064
			}
1068
			}
1065
		else
1069
		else
1066
			if [ "${USERLAND}" == "BSD" ]; then
1070
			if [ "${USERLAND}" == "BSD" ] || [ "${USERLAND}" == "Darwin" ]; then
1067
				do_stat() {
1071
				do_stat() {
1068
					# BSD version -- Octal result
1072
					# BSD version -- Octal result
1069
					$(type -p stat) -f '%p' "$1"
1073
					$(type -p stat) -f '%p' "$1"
Lines 1091-1102 Link Here
1091
	done
1095
	done
1092
1096
1093
	find "${D}/" -group portage | while read file; do
1097
	find "${D}/" -group portage | while read file; do
1094
		ewarn "file $file was installed with group portage!"
1095
		s=$(stat_perms "$file")
1098
		s=$(stat_perms "$file")
1096
		[ "$USERLAND" == "BSD" ] && chgrp wheel "$file"
1099
		if [ "$USERLAND" == "BSD" ] || [ "$USERLAND" == "Darwin" ];then
1097
		[ "$USERLAND" != "BSD" ] && chgrp root "$file"
1100
			chgrp wheel "$file"
1101
		else
1102
			chgrp root "$file"
1103
		fi
1098
		chmod "$s" "$file"
1104
		chmod "$s" "$file"
1099
	done
1105
	done
1106
	ewarn "files were installed with group portage!"
1100
1107
1101
	unset -f stat_perms
1108
	unset -f stat_perms
1102
1109
(-)portage-2.0.51.16/bin/emerge-webrsync (-1 / +1 lines)
Lines 68-74 Link Here
68
	attempts=$(( attempts + 1 ))
68
	attempts=$(( attempts + 1 ))
69
69
70
	#this too, sucks.  it works in the interim though.
70
	#this too, sucks.  it works in the interim though.
71
	if [ "$USERLAND" == "BSD" ] ; then
71
	if [ "$USERLAND" == "BSD" ] || [ "$USERLAND" == "Darwin" ] ; then
72
		daysbefore=$(expr $(date +"%s") - 86400 \* $attempts)
72
		daysbefore=$(expr $(date +"%s") - 86400 \* $attempts)
73
		day=$(date -r $daysbefore +"%d")
73
		day=$(date -r $daysbefore +"%d")
74
		month=$(date -r $daysbefore +"%m")
74
		month=$(date -r $daysbefore +"%m")
(-)portage-2.0.51.16/bin/etc-update (+2 lines)
Lines 14-19 Link Here
14
14
15
if [ $(/usr/lib/portage/bin/portageq envvar USERLAND) = BSD ] ; then
15
if [ $(/usr/lib/portage/bin/portageq envvar USERLAND) = BSD ] ; then
16
	function sed() { gsed "$@"; }
16
	function sed() { gsed "$@"; }
17
elif [ $(/usr/lib/portage/bin/portageq envvar USERLAND) = Darwin -a -x /bin/gsed ]; then
18
	function sed() { gsed "$@"; }
17
fi
19
fi
18
20
19
function get_config() {
21
function get_config() {
(-)portage-2.0.51.16/bin/repoman (-1 / +1 lines)
Lines 347-353 Link Here
347
		print "rm -Rf [a-z]*"
347
		print "rm -Rf [a-z]*"
348
		print "cvs up"
348
		print "cvs up"
349
		print
349
		print
350
		if portage.userland=="BSD":
350
		if portage.userland=="BSD" or portage.userland=="Darwin":
351
			print "find ./ -type f -regex '.*/CVS/Root$' -print0 | xargs -0 sed \\"
351
			print "find ./ -type f -regex '.*/CVS/Root$' -print0 | xargs -0 sed \\"
352
		else:
352
		else:
353
			print "find ./ -type f -regex '.*/CVS/Root$' -print0 | xargs -0r sed \\"
353
			print "find ./ -type f -regex '.*/CVS/Root$' -print0 | xargs -0r sed \\"
(-)portage-2.0.51.16/pym/portage.py (-1 / +1 lines)
Lines 6767-6773 Link Here
6767
					# old package won't yank the file with it. (non-cfgprot related)
6767
					# old package won't yank the file with it. (non-cfgprot related)
6768
					os.utime(myrealdest,(thismtime,thismtime))
6768
					os.utime(myrealdest,(thismtime,thismtime))
6769
					zing="---"
6769
					zing="---"
6770
				if self.settings["ARCH"] == "ppc-macos" and myrealdest[-2:] == ".a":
6770
				if self.settings["USERLAND"] == "Darwin" and myrealdest[-2:] == ".a":
6771
6771
6772
					# XXX kludge, bug #58848; can be killed when portage stops relying on 
6772
					# XXX kludge, bug #58848; can be killed when portage stops relying on 
6773
					# md5+mtime, and uses refcounts
6773
					# md5+mtime, and uses refcounts
(-)portage-2.0.51.16/pym/portage_data.py (-4 / +6 lines)
Lines 14-24 Link Here
14
if ostype=="Linux":
14
if ostype=="Linux":
15
	userland="GNU"
15
	userland="GNU"
16
	os.environ["XARGS"]="xargs -r"
16
	os.environ["XARGS"]="xargs -r"
17
elif ostype in ["Darwin","FreeBSD","OpenBSD"]:
17
elif ostype == "Darwin":
18
	if ostype == "Darwin":
18
	userland="Darwin"
19
		lchown=os.chown
20
	userland="BSD"
21
	os.environ["XARGS"]="xargs"	
19
	os.environ["XARGS"]="xargs"	
20
	lchown=os.chown
21
elif ostype in ["FreeBSD","OpenBSD"]:
22
	userland="BSD"
23
	os.environ["XARGS"]="xargs"
22
else:
24
else:
23
	writemsg(red("Operating system")+" \""+ostype+"\" "+red("currently unsupported. Exiting.")+"\n")
25
	writemsg(red("Operating system")+" \""+ostype+"\" "+red("currently unsupported. Exiting.")+"\n")
24
	sys.exit(1)
26
	sys.exit(1)

Return to bug 82312