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

(-)rox.eclass (-20 / +20 lines)
Lines 45-59 Link Here
45
45
46
46
47
rox_src_compile() {
47
rox_src_compile() {
48
	cd ${APPNAME}
48
	cd "${APPNAME}"
49
	#Some packages need to be compiled.
49
	#Some packages need to be compiled.
50
	chmod 755 ./AppRun
50
	chmod 755 ./AppRun
51
	if [ -d "src/" ]; then
51
	if [ -d src/ ]; then
52
		./AppRun --compile || die "Failed to compile the package"
52
		./AppRun --compile || die "Failed to compile the package"
53
		if [ -n ${KEEP_SRC} ]; then
53
		if [ -n "${KEEP_SRC}" ]; then
54
			( cd src
54
			cd src
55
			make clean
55
			make clean
56
			)
56
			cd ..
57
		else
57
		else
58
			rm -rf src
58
			rm -rf src
59
		fi
59
		fi
Lines 63-70 Link Here
63
}
63
}
64
64
65
rox_src_install() {
65
rox_src_install() {
66
	if [ -d ${APPNAME}/Help/ ]; then
66
	if [ -d "${APPNAME}/Help/" ]; then
67
		for i in ${APPNAME}/Help/*; do
67
		for i in "${APPNAME}"/Help/*; do
68
			dodoc "${i}"
68
			dodoc "${i}"
69
		done
69
		done
70
	fi
70
	fi
Lines 73-94 Link Here
73
73
74
	#set correct permissions on files, in case they are wrong
74
	#set correct permissions on files, in case they are wrong
75
	#include all subdirectories in search, just in case
75
	#include all subdirectories in search, just in case
76
	find ${D}/usr/lib/rox/${APPNAME} -name 'AppRun' | xargs chmod 755 >/dev/null 2>&1
76
	find "${D}/usr/lib/rox/${APPNAME}" -name 'AppRun' -print0 | xargs -0 chmod 755 >/dev/null 2>&1
77
	find ${D}/usr/lib/rox/${APPNAME} -name 'AppletRun' | xargs chmod 755 >/dev/null 2>&1
77
	find "${D}/usr/lib/rox/${APPNAME}" -name 'AppletRun' -print0 | xargs -0 chmod 755 >/dev/null 2>&1
78
78
79
	# set permissions for programs where we have libdir script
79
	# set permissions for programs where we have libdir script
80
	if [ -f ${D}/usr/lib/rox/${APPNAME}/libdir ]; then
80
	if [ -f "${D}/usr/lib/rox/${APPNAME}/libdir" ]; then
81
		chmod 755 ${D}/usr/lib/rox/${APPNAME}/libdir
81
		chmod 755 "${D}/usr/lib/rox/${APPNAME}/libdir"
82
	fi
82
	fi
83
83
84
	# set permissions for programs where we have rox_run script (all who using rox-clib )
84
	# set permissions for programs where we have rox_run script (all who using rox-clib )
85
	if [ -f ${D}/usr/lib/rox/${APPNAME}/rox_run ]; then
85
	if [ -f "${D}/usr/lib/rox/${APPNAME}/rox_run" ]; then
86
	    chmod 755 ${D}/usr/lib/rox/${APPNAME}/rox_run
86
	    chmod 755 "${D}/usr/lib/rox/${APPNAME}/rox_run"
87
	fi
87
	fi
88
88
89
	# some programs have choice_install script
89
	# some programs have choice_install script
90
	if [ -f ${D}/usr/lib/rox/${APPNAME}/choice_install ]; then
90
	if [ -f "${D}/usr/lib/rox/${APPNAME}/choice_install" ]; then
91
	    chmod 755 ${D}/usr/lib/rox/${APPNAME}/choice_install
91
	    chmod 755 "${D}/usr/lib/rox/${APPNAME}/choice_install"
92
	fi
92
	fi
93
93
94
	# set permissions on all binares files for compiled programs per arch
94
	# set permissions on all binares files for compiled programs per arch
Lines 98-116 Link Here
98
		i?86) ARCH=ix86 ;;
98
		i?86) ARCH=ix86 ;;
99
	    esac
99
	    esac
100
	    PLATFORM="`uname -s`-${ARCH}"
100
	    PLATFORM="`uname -s`-${ARCH}"
101
	    chmod -R 755 ${D}/usr/lib/rox/${APPNAME}/${PLATFORM}
101
	    chmod -R 755 "${D}/usr/lib/rox/${APPNAME}/${PLATFORM}"
102
	fi
102
	fi
103
103
104
	#create a script in bin to run the application from command line
104
	#create a script in bin to run the application from command line
105
	dodir /usr/bin/
105
	dodir /usr/bin/
106
	cat >${D}/usr/bin/${APPNAME} <<EOF
106
	cat >"${D}/usr/bin/${APPNAME}" <<EOF
107
#!/bin/sh
107
#!/bin/sh
108
exec /usr/lib/rox/${APPNAME}/AppRun "\$@"
108
exec "/usr/lib/rox/${APPNAME}/AppRun" "\$@"
109
EOF
109
EOF
110
	chmod 755 ${D}/usr/bin/${APPNAME}
110
	chmod 755 "${D}/usr/bin/${APPNAME}"
111
111
112
	#now compile any and all python files
112
	#now compile any and all python files
113
	python_mod_optimize ${D}/usr/lib/rox/${APPNAME} >/dev/null 2>&1
113
	python_mod_optimize "${D}/usr/lib/rox/${APPNAME}" >/dev/null 2>&1
114
}
114
}
115
115
116
rox_pkg_postinst() {
116
rox_pkg_postinst() {

Return to bug 136406