Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Jul 2016 14:29:54 -0700
From:      Mark Millard <markmi@dsl-only.net>
To:        freebsd-arm <freebsd-arm@freebsd.org>, FreeBSD PowerPC ML <freebsd-ppc@freebsd.org>, FreeBSD Current <freebsd-current@freebsd.org>, freebsd-stable@freebsd.org
Subject:   Re: amd64 -> armv6 [and powerpc64] -r302331 -> -r302412 re-cross-build (update): got "sh: ./make_keys: Exec format error" again for init_ketry.h in ncursesw
Message-ID:  <E1B209F5-A3BA-4A81-A47A-DE1080B294D9@dsl-only.net>
In-Reply-To: <0394F424-484D-43B3-9C7D-8C6A8E8709F0@dsl-only.net>
References:  <0394F424-484D-43B3-9C7D-8C6A8E8709F0@dsl-only.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2016-Jul-8, at 12:23 AM, Mark Millard <markmi@dsl-only.net> wrote =
--but with a few []'d notes added:

> [Before the below cross build/update attempt I updated my amd64 from =
-r302331 -> -r302412.]
>=20
> Summary: It appears that WITHOUT_META_MODE=3D still needs to be forced =
for cross compiles at least sometimes in order to avoid "Exec format =
error". man src.conf only mentions WITHOUT_META_MODE=3D in one place:
>=20
>>     WITH_DIRDEPS_BUILD
> . . .
>>             WITH_META_MODE (unless WITHOUT_META_MODE is set =
explicitly)
> . . .
>>             This must be set in the environment, make command line, =
or
>>             /etc/src-env.conf, not /etc/src.conf.
>=20
>=20
> In attempting to update my cross build (amd64 -> armv6 [or powerpc64]) =
from -r302331 to -r302412 it failed with [armv6 example]:
>=20
>> --- init_keytry.h ---
>> sh: ./make_keys: Exec format error
>> *** [init_keytry.h] Error code 126
>>=20
>> make[4]: stopped in /usr/src/lib/ncurses/ncursesw
>> .ERROR_TARGET=3D'init_keytry.h'
>> =
.ERROR_META_FILE=3D'/usr/obj/clang/arm.armv6/usr/src/lib/ncurses/ncursesw/=
init_keytry.h.meta'
>> .MAKE.LEVEL=3D'4'
>> MAKEFILE=3D''
>> .MAKE.MODE=3D'meta missing-filemon=3Dyes missing-meta=3Dyes =
silent=3Dyes verbose'
>> .CURDIR=3D'/usr/src/lib/ncurses/ncursesw'
>> .MAKE=3D'make'
>> .OBJDIR=3D'/usr/obj/clang/arm.armv6/usr/src/lib/ncurses/ncursesw'
>> .TARGETS=3D'all'
>> DESTDIR=3D'/usr/obj/clang/arm.armv6/usr/src/tmp'
>> LD_LIBRARY_PATH=3D''
>> MACHINE=3D'arm'
>> MACHINE_ARCH=3D'armv6'
>> MAKEOBJDIRPREFIX=3D'/usr/obj/clang/arm.armv6'
>> MAKESYSPATH=3D'/usr/src/share/mk'
>> MAKE_VERSION=3D'20160606'
>> =
PATH=3D'/usr/obj/clang/arm.armv6/usr/src/tmp/legacy/usr/sbin:/usr/obj/clan=
g/arm.armv6/usr/src/tmp/legacy/usr/bin:/usr/obj/clang/arm.armv6/usr/src/tm=
p/legacy/bin:/usr/obj/clang/arm.armv6/usr/src/tmp/usr/sbin:/usr/obj/clang/=
arm.armv6/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin'
>> SRCTOP=3D'/usr/src'
>> OBJTOP=3D'/usr/obj/clang/arm.armv6/usr/src'
>> .MAKE.MAKEFILES=3D'/usr/src/share/mk/sys.mk =
/usr/src/share/mk/local.sys.env.mk /usr/src/share/mk/src.sys.env.mk =
/root/src.configs/src.conf.rpi2-clang-bootstrap.amd64-host =
/usr/src/share/mk/bsd.mkopt.mk /root/src.configs/make.conf =
/usr/src/share/mk/local.sys.mk /usr/src/share/mk/src.sys.mk =
/etc/src.conf /usr/src/lib/ncurses/ncursesw/Makefile =
/usr/src/lib/ncurses/ncursesw/../ncurses/Makefile =
/usr/src/share/mk/src.opts.mk /usr/src/share/mk/bsd.own.mk =
/usr/src/share/mk/bsd.opts.mk /usr/src/share/mk/bsd.cpu.mk =
/usr/src/share/mk/bsd.compiler.mk /usr/src/share/mk/bsd.compiler.mk =
/usr/src/lib/ncurses/ncursesw/../config.mk /usr/src/share/mk/bsd.lib.mk =
/usr/src/share/mk/bsd.init.mk /usr/src/share/mk/local.init.mk =
/usr/src/share/mk/src.init.mk =
/usr/src/lib/ncurses/ncursesw/../Makefile.inc =
/usr/src/lib/ncurses/ncursesw/../../Makefile.inc =
/usr/src/share/mk/bsd.libnames.mk /usr/src/share/mk/src.libnames.mk =
/usr/src/share/mk/bsd.symver.mk /usr/src/share/mk/bsd.nls.mk =
/usr/src/share/mk/bsd.files.mk /usr/src/share/mk/bsd.incs.mk =
/usr/src/share/mk/bsd.confs.mk /usr/src/share/mk/bsd.links.mk =
/usr/src/share/mk/bsd.dep.mk /usr/src/share/mk/bsd.clang-analyze.mk =
/usr/src/share/mk/bsd.obj.mk /usr/src/share/mk/bsd.subdir.mk =
/usr/src/share/mk/bsd.sys.mk'
>> .PATH=3D'. /usr/src/lib/ncurses/ncursesw =
/usr/src/lib/ncurses/ncursesw/../ncurses =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/include =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/ncurses/base =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/ncurses/tinfo =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/ncurses/tty =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/ncurses/widechar =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/ncurses/trace =
/usr/src/lib/ncurses/ncursesw/../../../contrib/ncurses/man'
>> 1 error
>=20
> again.
>=20
> This was based on:
>=20
>> # more =
~/sys_build_scripts.amd64-host/make_rpi2_nodebug_clang_bootstrap-amd64-hos=
t.sh=20
>> kldload -n filemon && \
>> script =
~/sys_typescripts/typescript_make_rpi2_nodebug_clang_bootstrap-amd64-host-=
$(date +%Y-%m-%d:%H:%M:%S) \
>> env __MAKE_CONF=3D"/root/src.configs/make.conf" =
SRC_ENV_CONF=3D"/root/src.configs/src.conf.rpi2-clang-bootstrap.amd64-host=
" \
>> WITH_META_MODE=3Dyes \
>> MAKEOBJDIRPREFIX=3D"/usr/obj/clang" \
>> make $*
>=20
> and. . .
>=20
>> # more ~/src.configs/src.conf.rpi2-clang-bootstrap.amd64-host=20
>> TO_TYPE=3Darmv6
>> #
>> KERNCONF=3DRPI2-NODBG
>> TARGET=3Darm
>> .if ${.MAKE.LEVEL} =3D=3D 0
>> TARGET_ARCH=3D${TO_TYPE}
>> .export TARGET_ARCH
>> .endif
>> #
>> WITH_CROSS_COMPILER=3D
>> WITHOUT_SYSTEM_COMPILER=3D
>> #
>> #CPUTYPE=3Dsoft
>> WITH_LIBCPLUSPLUS=3D
>> WITH_BINUTILS_BOOTSTRAP=3D
>> WITH_CLANG_BOOTSTRAP=3D
>> WITH_CLANG=3D
>> WITH_CLANG_IS_CC=3D
>> WITH_CLANG_FULL=3D
>> WITH_CLANG_EXTRAS=3D
>> WITH_LLDB=3D
>> #
>> WITH_BOOT=3D
>> WITHOUT_LIB32=3D
>> WITHOUT_LIBSOFT=3D
>> #
>> WITHOUT_ELFTOOLCHAIN_BOOTSTRAP=3D
>> WITHOUT_GCC_BOOTSTRAP=3D
>> WITHOUT_GCC=3D
>> WITHOUT_GCC_IS_CC=3D
>> WITHOUT_GNUCXX=3D
>> #
>> NO_WERROR=3D
>> #WERROR=3D
>> MALLOC_PRODUCTION=3D
>> #
>> WITH_DEBUG_FILES=3D
>> #
>> XCFLAGS+=3D -march=3Darmv7-a -mcpu=3Dcortex-a7
>> XCXXFLAGS+=3D -march=3Darmv7-a -mcpu=3Dcortex-a7
>=20
> make.conf was empty.
>=20
> The earlier -r302331 cross build had WITH_LIBSOFT=3D in use. -r302412 =
is my first testing of WITHOUT_LIBSOFT=3D after rebuilding all ports to =
avoid libsoft. [Does not apply to the powerpc64 example.]

I should have mentioned the alternative of keeping WITH_META_MODE=3Dyes =
but doing a cleanworld before doing a separate buildworld. This is =
generally handier if one is to keep using WITH_META_MODE=3Dyes .

=3D=3D=3D
Mark Millard
markmi at dsl-only.net





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1B209F5-A3BA-4A81-A47A-DE1080B294D9>