gdb: fix cross build for ppc* w/ gcc10
The generators sim/ppc built for the host architecture also have multiple defined symbols which is why CFLAGS_FOR_HOST needs the -fcommon flag as well. There are also warnings like returning the address of a stack variable which require -Wno-error to make gdb cross compile for ppc*. With these minimal changes in the template the sim/ppc issues are just ignored and should probably be fixed instead.
This commit is contained in:
parent
e6de0e58cb
commit
335308e075
1 changed files with 4 additions and 3 deletions
|
@ -25,8 +25,8 @@ if [ "${CROSS_BUILD}" ]; then
|
|||
CFLAGS="-I${XBPS_CROSS_BASE}/${py3_inc}"
|
||||
CXXFLAGS="-I${XBPS_CROSS_BASE}/${py3_inc}"
|
||||
fi
|
||||
CFLAGS+=" -fcommon"
|
||||
CXXFLAGS+=" -fcommon"
|
||||
CFLAGS+=" -fcommon -Wno-error"
|
||||
CXXFLAGS+=" -fcommon -Wno-error"
|
||||
# Package build options
|
||||
build_options="gdbserver static python"
|
||||
desc_option_gdbserver="Enable support for building GDB server"
|
||||
|
@ -41,7 +41,8 @@ post_extract() {
|
|||
}
|
||||
do_configure() {
|
||||
cd ${wrksrc}/build
|
||||
../configure ${configure_args/with-sysroot/with-build-sysroot}
|
||||
../configure ${configure_args/with-sysroot/with-build-sysroot} \
|
||||
CFLAGS_FOR_BUILD="${CFLAGS_FOR_BUILD} -fcommon"
|
||||
export gl_cv_func_gettimeofday_clobber=no
|
||||
export gl_cv_func_working_strerror=yes
|
||||
export gl_cv_func_strerror_0_works=yes
|
||||
|
|
Loading…
Reference in a new issue