Check-in [6fac0b6f10]
Overview
Comment:Updated to search in requested headers last rather than first, as if they were system headers
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | packages
Files: files | file ages | folders
SHA1: 6fac0b6f109c076c62dd0065535048e5c77c087f
User & Date: rkeene on 2014-11-12 09:29:42
Other Links: branch diff | manifest | tags
Context
2014-11-12
09:30
Added coreutils package check-in: cf57024dfa user: rkeene tags: packages
09:29
Updated to search in requested headers last rather than first, as if they were system headers check-in: 6fac0b6f10 user: rkeene tags: packages
08:39
Fixed issue where libraries for libcap were located in wrong place check-in: 3e742f1756 user: rkeene tags: packages
Changes

Modified build from [5526d031f2] to [6b42e787ea].

154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
			fi

			pkgfound='1'

			for pkgchange in "${pkgchanges[@]}"; do
				case "${pkgchange}" in
					CFLAGS)
						CFLAGS="${CFLAGS} -I${pkgdir}/include"
						CPPFLAGS="${CPPFLAGS} -I${pkgdir}/include"
						export CFLAGS CPPFLAGS
						;;
					LDFLAGS)
						LDFLAGS="${LDFLAGS} -L${pkgdir}/lib -Wl,-rpath,${pkgdir}/lib"
						export LDFLAGS
						;;
					PATH)







|
|







154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
			fi

			pkgfound='1'

			for pkgchange in "${pkgchanges[@]}"; do
				case "${pkgchange}" in
					CFLAGS)
						CFLAGS="${CFLAGS} -isystem ${pkgdir}/include"
						CPPFLAGS="${CPPFLAGS} -isystem ${pkgdir}/include"
						export CFLAGS CPPFLAGS
						;;
					LDFLAGS)
						LDFLAGS="${LDFLAGS} -L${pkgdir}/lib -Wl,-rpath,${pkgdir}/lib"
						export LDFLAGS
						;;
					PATH)
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251

	dynlinker="$(ls "${glibcdir}"/lib/ld-linux*.so.* | tail -n 1)"

	if [ ! -f "${dynlinker}" ]; then
		die 'glibc directory is not available (appfs running/working?)'
	fi

	gcc_default_headers="$(echo '' | ${CPP:-cpp} -v 2>&1 | sed '/^End of search list/,$ d;0,/search starts here:$/ d' | grep '/gcc/' | sed 's@^ *@-I@' | tr $'\n' ' ')"

	CC="${CC:-gcc} -nostdinc ${gcc_default_headers} -I${glibcdir}/include"

	if ! echo " ${require[*]} " | grep ' linux-headers[/@: ]' >/dev/null; then
		CC="${CC} -I${linuxheadersdir}/include"
	fi

	BUILD_CC="${CC}"
	HOST_CC="${CC}"
	LDFLAGS="${LDFLAGS} -L${glibcdir}/lib -Wl,--rpath,${glibcdir}/lib -Wl,--dynamic-linker,${dynlinker}"
	PKG_CONFIG_LIBDIR="${glibcdir}/lib/pkgconfig"
	export CC BUILD_CC HOST_CC LDFLAGS PKG_CONFIG_LIBDIR







|

|


|







232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251

	dynlinker="$(ls "${glibcdir}"/lib/ld-linux*.so.* | tail -n 1)"

	if [ ! -f "${dynlinker}" ]; then
		die 'glibc directory is not available (appfs running/working?)'
	fi

	gcc_default_headers="$(echo '' | ${CPP:-cpp} -v 2>&1 | sed '/^End of search list/,$ d;0,/search starts here:$/ d' | grep '/gcc/' | sed 's@^ *@-isystem @' | tr $'\n' ' ')"

	CC="${CC:-gcc} -nostdinc ${gcc_default_headers} -isystem ${glibcdir}/include"

	if ! echo " ${require[*]} " | grep ' linux-headers[/@: ]' >/dev/null; then
		CC="${CC} -isystem ${linuxheadersdir}/include"
	fi

	BUILD_CC="${CC}"
	HOST_CC="${CC}"
	LDFLAGS="${LDFLAGS} -L${glibcdir}/lib -Wl,--rpath,${glibcdir}/lib -Wl,--dynamic-linker,${dynlinker}"
	PKG_CONFIG_LIBDIR="${glibcdir}/lib/pkgconfig"
	export CC BUILD_CC HOST_CC LDFLAGS PKG_CONFIG_LIBDIR