Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 97162 | Differences between
and this patch

Collapse All | Expand All

(-)glibc-2.3.4.20041102-r1.ebuild.orig (-6 / +61 lines)
Lines 180-185 Link Here
180
		filter-flags -m32 -m64
180
		filter-flags -m32 -m64
181
	fi
181
	fi
182
182
183
	# PPC64 multilib
184
	if use ppc64 && has_multilib_profile; then
185
		# We change our CHOST, so set this right here
186
		export CC="$(tc-getCC)"
187
188
		if [ "${ABI}" = "ppc64" ]; then
189
			CTARGET="powerpc64-unknown-linux-gnu"
190
			CHOST="${CTARGET}"
191
		else
192
			# The following is required in order to change into multilib environment from non-multilib environment for ppc64.
193
			if [[ ! -e /lib32/ld.so.1 ]]; then
194
				CBUILD="powerpc64-unknown-linux-gnu"
195
				CHOST="powerpc-unknown-linux-gnu"
196
				CTARGET="powerpc-unknown-linux-gnu"
197
			else
198
				CTARGET="powerpc-unknown-linux-gnu"
199
				CHOST="${CTARGET}"
200
			fi
201
		fi
202
203
		filter-flags -m32 -m64
204
	fi
205
183
	if [ "`gcc-major-version`" -ge "3" -a "`gcc-minor-version`" -ge "4" ]; then
206
	if [ "`gcc-major-version`" -ge "3" -a "`gcc-minor-version`" -ge "4" ]; then
184
		# broken in 3.4.x
207
		# broken in 3.4.x
185
		replace-flags -march=pentium-m -mtune=pentium3
208
		replace-flags -march=pentium-m -mtune=pentium3
Lines 685-694 Link Here
685
	fi
708
	fi
686
709
687
	# Who knows if this works :)
710
	# Who knows if this works :)
688
	[[ -n ${CBUILD} ]] && myconf="${myconf} --build=${CBUILD}"
711
	if [[ -n ${CBUILD} ]]; then
712
		myconf="${myconf} --build=${CBUILD}"
713
	else
714
		myconf="${myconf} --build=${CHOST}"
715
	fi
716
689
	myconf="${myconf} --without-cvs
717
	myconf="${myconf} --without-cvs
690
			--enable-bind-now
718
			--enable-bind-now
691
			--build=${CHOST}
692
			--host=${CTARGET}
719
			--host=${CTARGET}
693
			--disable-profile
720
			--disable-profile
694
			--without-gd
721
			--without-gd
Lines 774-782 Link Here
774
				LIBDIR_x86="lib"
801
				LIBDIR_x86="lib"
775
			fi
802
			fi
776
803
804
			if use ppc64 && [ "${ABI}" = "ppc" -a "$(get_libdir)" != "lib" ]; then
805
				OLD_LIBDIR="$(get_libdir)"
806
				LIBDIR_ppc="lib"
807
			fi
808
777
			src_install
809
			src_install
778
810
779
			# Handle stupid lib32 BS
811
			# Handle stupid lib32 BS on amd64 and ppc64
780
			if use amd64 && [ "${ABI}" = "x86" -a -n "${OLD_LIBDIR}" ]; then
812
			if use amd64 && [ "${ABI}" = "x86" -a -n "${OLD_LIBDIR}" ]; then
781
				LIBDIR_x86="${OLD_LIBDIR}"
813
				LIBDIR_x86="${OLD_LIBDIR}"
782
				unset OLD_LIBDIR
814
				unset OLD_LIBDIR
Lines 800-805 Link Here
800
				done
832
				done
801
			fi
833
			fi
802
834
835
			if use ppc64 && [ "${ABI}" = "ppc" -a -n "${OLD_LIBDIR}" ]; then
836
				LIBDIR_ppc="${OLD_LIBDIR}"
837
				unset OLD_LIBDIR
838
839
				mv ${D}/lib ${D}/$(get_libdir)
840
				mv ${D}/usr/lib ${D}/usr/$(get_libdir)
841
				mkdir ${D}/lib
842
				dosym ../$(get_libdir)/ld.so.1 /lib/ld.so.1
843
				dosed "s:/lib/:/$(get_libdir)/:g" /usr/$(get_libdir)/libc.so /usr/$(get_libdir)/libpthread.so
844
845
				rm -rf ${D}/usr/$(get_libdir)/misc ${D}/usr/$(get_libdir)/locale
846
847
				for f in ${D}/usr/$(get_libdir)/*.so; do
848
					local basef=$(basename ${f})
849
					if [ -L ${f} ]; then
850
						local target=$(readlink ${f})
851
						target=${target/\/lib\//\/$(get_libdir)\/}
852
						rm ${f}
853
						dosym ${target} /usr/$(get_libdir)/${basef}
854
					fi
855
				done
856
			fi
803
		done
857
		done
804
		ABI="${OABI}"
858
		ABI="${OABI}"
805
		unset OABI
859
		unset OABI
Lines 1044-1050 Link Here
1044
		rm ${ROOT}/lib64
1098
		rm ${ROOT}/lib64
1045
		# now that lib64 is gone, nothing will run without calling ld.so
1099
		# now that lib64 is gone, nothing will run without calling ld.so
1046
		# directly. luckily the window of brokenness is almost non-existant
1100
		# directly. luckily the window of brokenness is almost non-existant
1047
		/lib/ld-linux-x86-64.so.2 /bin/mv ${ROOT}/lib ${ROOT}/lib64
1101
		use amd64 && /lib/ld-linux-x86-64.so.2 /bin/mv ${ROOT}/lib ${ROOT}/lib64
1102
		use ppc64 && /lib/ld64.so.1 /bin/mv ${ROOT}/lib ${ROOT}/lib64
1048
		# all better :)
1103
		# all better :)
1049
		ldconfig
1104
		ldconfig
1050
		ln -s lib64 ${ROOT}/lib
1105
		ln -s lib64 ${ROOT}/lib
Lines 1077-1083 Link Here
1077
	# 2005.0 is setup properly, and this is executed as part of the
1132
	# 2005.0 is setup properly, and this is executed as part of the
1078
	# 2004.3 -> 2005.0 upgrade script.
1133
	# 2004.3 -> 2005.0 upgrade script.
1079
	# It can be removed after 2004.3 has been purged from portage.
1134
	# It can be removed after 2004.3 has been purged from portage.
1080
	use amd64 && [ "$(get_libdir)" == "lib64" ] && ! has_multilib_profile && fix_lib64_symlinks
1135
	use amd64 || use ppc64 && [ "$(get_libdir)" == "lib64" ] && ! has_multilib_profile && fix_lib64_symlinks
1081
1136
1082
	# it appears that /lib/tls is sometimes not removed. See bug
1137
	# it appears that /lib/tls is sometimes not removed. See bug
1083
	# 69258 for more info.
1138
	# 69258 for more info.
Lines 1112-1118 Link Here
1112
		${ROOT}/usr/sbin/iconvconfig --prefix=${ROOT}
1167
		${ROOT}/usr/sbin/iconvconfig --prefix=${ROOT}
1113
	fi
1168
	fi
1114
1169
1115
	if [ ! -e "${ROOT}/ld.so.1" ] && use ppc64
1170
	if [ ! -e "${ROOT}/ld.so.1" ] && use ppc64 && ! has_multilib_profile
1116
	then
1171
	then
1117
		pushd ${ROOT}
1172
		pushd ${ROOT}
1118
		cd ${ROOT}/lib
1173
		cd ${ROOT}/lib

Return to bug 97162