Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
magic-lantern
magic-lantern
Commits
087cf951d689
Commit
590a4e2b
authored
Dec 17, 2020
by
alex@thinkpad
Browse files
QEMU install: configure_eos updated for gcc 9.x and 10.x (to be tested)
--HG-- branch : qemu
parent
1ec259ec6f8a
Changes
1
Hide whitespace changes
Inline
Side-by-side
contrib/qemu/scripts/configure_eos.sh
View file @
087cf951
...
...
@@ -21,24 +21,47 @@ fi
if
[[
$CC
==
clang
*
]]
;
then
# fixme: some warnings about format strings in conditional expressions
# still needed? could not reproduce on recent systems (tested clang 3.8, 10.x, 12.x)
#EXTRA_CFLAGS="$EXTRA_CFLAGS -Wno-format-extra-args -Wno-format-zero-length"
export
CXX
=
${
CXX
:
=clang++
}
EXTRA_CFLAGS
=
"-Wno-format-extra-args -Wno-format-zero-length"
if
[[
$CXX
!=
clang++
*
]]
;
then
echo
"Warning: not using clang++ (check CXX)"
fi
fi
if
[[
$CC
==
gcc
*
]]
;
then
# gcc 6 warns about readdir_r
export
CXX
=
${
CXX
:
=g++
}
EXTRA_CFLAGS
=
"-Wno-error=deprecated-declarations"
GCC_VERSION
=
$(
$CC
-dumpfullversion
-dumpversion
)
GPP_VERSION
=
$(
$CXX
-dumpfullversion
-dumpversion
)
GCC_MAJOR
=
${
GCC_VERSION
%%.*
}
GPP_MAJOR
=
${
GPP_VERSION
%%.*
}
if
gcc
-v
2>&1 |
grep
-q
clang
;
then
echo
"This version of gcc is actually clang..."
# no known warnings on current systems
else
if
((
$GCC_MAJOR
>=
6
))
;
then
# gcc 6 warns about readdir_r
EXTRA_CFLAGS
=
"
$EXTRA_CFLAGS
-Wno-error=deprecated-declarations"
fi
if
((
$GCC_MAJOR
>=
9
))
;
then
# gcc 9 warns about unaligned pointer in packed structures and some more
# gcc 10 also warns about stringop-overflow
EXTRA_CFLAGS
=
"
$EXTRA_CFLAGS
-Wno-error=address-of-packed-member -Wno-error=stringop-truncation -Wno-error=stringop-overflow -Wno-error=format-truncation"
fi
fi
if
[[
$CXX
!=
g++
*
]]
;
then
echo
"Warning: not using g++ (check CXX)"
fi
if
[[
"
$GCC_VERSION
"
!=
"
$GPP_VERSION
"
]]
;
then
# QEMU configure script will take care of this one
echo
"Warning: different gcc/g++ version (gcc
$GCC_VERSION
, g++
$GPP_VERSION
)"
fi
fi
echo
"Using
$CC
/
$CXX
with
$EXTRA_CFLAGS
"
echo
"Using
$CC
$GCC_VERSION
/
$CXX
$GPP_VERSION
with flags:
$EXTRA_CFLAGS
"
echo
"Options:
$GUI_FLAGS
$@
"
./configure
--target-list
=
arm-softmmu
--disable-docs
--enable-vnc
$GUI_FLAGS
\
--extra-cflags
=
"
$EXTRA_CFLAGS
"
"
$@
"
--extra-cflags
=
"
$EXTRA_CFLAGS
"
"
$@
"
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment