commit: ba302ca3c7f0b6eac9f280e57fcc6f75fb5981f5 Author: Michał Górny <mgorny <AT> gentoo <DOT> org> AuthorDate: Sun May 8 14:04:20 2022 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Wed May 11 16:43:42 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ba302ca3
qmake-utils.eclass: Add a function to get qmake args Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> eclass/qmake-utils.eclass | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/eclass/qmake-utils.eclass b/eclass/qmake-utils.eclass index 1f09cbd9ca77..a4be44fa65a5 100644 --- a/eclass/qmake-utils.eclass +++ b/eclass/qmake-utils.eclass @@ -60,6 +60,33 @@ qt5_get_plugindir() { echo $(qt5_get_libdir)/qt5/plugins } +# @FUNCTION: qt5_get_qmake_args +# @DESCRIPTION: +# Echoes a multi-line string containing arguments to pass to qmake. +qt5_get_qmake_args() { + cat <<-EOF + QMAKE_AR="$(tc-getAR) cqs" + QMAKE_CC="$(tc-getCC)" + QMAKE_LINK_C="$(tc-getCC)" + QMAKE_LINK_C_SHLIB="$(tc-getCC)" + QMAKE_CXX="$(tc-getCXX)" + QMAKE_LINK="$(tc-getCXX)" + QMAKE_LINK_SHLIB="$(tc-getCXX)" + QMAKE_OBJCOPY="$(tc-getOBJCOPY)" + QMAKE_RANLIB= + QMAKE_STRIP= + QMAKE_CFLAGS="${CFLAGS}" + QMAKE_CFLAGS_RELEASE= + QMAKE_CFLAGS_DEBUG= + QMAKE_CXXFLAGS="${CXXFLAGS}" + QMAKE_CXXFLAGS_RELEASE= + QMAKE_CXXFLAGS_DEBUG= + QMAKE_LFLAGS="${LDFLAGS}" + QMAKE_LFLAGS_RELEASE= + QMAKE_LFLAGS_DEBUG= + EOF +} + # @FUNCTION: eqmake5 # @USAGE: [arguments for qmake] # @DESCRIPTION: