mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 02:49:46 +00:00
introduce LSMinimumSystemVersion for Mac package with automatic Qt-version based detection plus configure option to choose it manually
This commit is contained in:
parent
c7b4cae840
commit
d1d22a1433
@ -674,6 +674,31 @@ AC_DEFUN([LYX_USE_INCLUDED_MYTHES],[
|
||||
])
|
||||
|
||||
|
||||
dnl Usage: LYX_CHECK_MACOS_DEPLOYMENT_TARGET : select the macos deployment target
|
||||
dnl [default-auto-value])
|
||||
dnl Assign the macosx-version-min value for compiler, linker and Info.plist.
|
||||
dnl Default is dynamic - depends on used Qt library version.
|
||||
AC_DEFUN([LYX_CHECK_MACOS_DEPLOYMENT_TARGET],[
|
||||
AC_ARG_WITH(macos-deployment-target,
|
||||
[AS_HELP_STRING([--with-macos-deployment-target], [force the macos deployment target for LyX])],
|
||||
[macos_deployment_target=$withval],
|
||||
[macos_deployment_target=auto])
|
||||
if test "${macos_deployment_target}" = "auto" ; then
|
||||
macos_deployment_target="10.10"
|
||||
case "$QTLIB_VERSION" in
|
||||
6.*)
|
||||
macos_deployment_target="10.14"
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
AM_CXXFLAGS="-mmacosx-version-min=$macos_deployment_target $AM_CXXFLAGS"
|
||||
AM_LDFLAGS="-mmacosx-version-min=$macos_deployment_target $AM_LDFLAGS"
|
||||
AC_SUBST(macos_deployment_target,"${macos_deployment_target}")
|
||||
AC_MSG_CHECKING([the macos deployment target for LyX])
|
||||
AC_MSG_RESULT([$macos_deployment_target])
|
||||
])
|
||||
|
||||
|
||||
dnl Usage: LYX_WITH_DIR(dir-name,desc,dir-var-name,default-value,
|
||||
dnl [default-yes-value])
|
||||
dnl Adds a --with-'dir-name' option (described by 'desc') and puts the
|
||||
|
@ -193,6 +193,8 @@ AC_CHECK_FUNCS(chmod close _close fork getpid _getpid lockf lstat mkfifo open _o
|
||||
AC_FUNC_MKDIR
|
||||
AC_FUNC_SELECT_ARGTYPES
|
||||
|
||||
LYX_CHECK_MACOS_DEPLOYMENT_TARGET
|
||||
|
||||
LYX_CHECK_SPELL_ENGINES
|
||||
LYX_USE_INCLUDED_MYTHES
|
||||
|
||||
|
@ -146,7 +146,6 @@ usage() {
|
||||
echo " --aspell-deployment=yes|no ." default yes
|
||||
echo " --with-qt-frameworks=yes|no." default no
|
||||
echo " --qt-deployment=yes|no ....." default yes
|
||||
echo " --with-macosx-target=TARGET " default 10.4 "(Tiger)"
|
||||
echo " --with-sdkroot=SDKROOT ....." default 10.5 "(Leopard)"
|
||||
echo " --with-arch=ARCH ..........." default ppc,i386
|
||||
echo " --with-build-path=PATH ....." default \${lyx-src-dir}/../lyx-build
|
||||
@ -190,8 +189,9 @@ while [ $# -gt 0 ]; do
|
||||
QTDIR=$(echo ${1}|cut -d= -f2)
|
||||
shift
|
||||
;;
|
||||
--with-macosx-target=*)
|
||||
--with-macos-deployment-target=*)
|
||||
MACOSX_DEPLOYMENT_TARGET=$(echo ${1}|cut -d= -f2)
|
||||
LyXConfigureOptions="${LyXConfigureOptions} ${1}"
|
||||
shift
|
||||
;;
|
||||
--with-sdkroot=*)
|
||||
@ -690,8 +690,8 @@ build_lyx() {
|
||||
if [ -d "${LyxBuildDir}" ]; then rm -r "${LyxBuildDir}"; fi
|
||||
mkdir -p "${LyxBuildDir}" && cd "${LyxBuildDir}"
|
||||
|
||||
CPPFLAGS="${SDKROOT:+-isysroot ${SDKROOT}} -arch ${arch} ${MYCFLAGS}"
|
||||
LDFLAGS="${SDKROOT:+-isysroot ${SDKROOT}} -arch ${arch} ${MYLDFLAGS}"
|
||||
CPPFLAGS="${SDKROOT:+-isysroot ${SDKROOT}} -arch ${arch}"
|
||||
LDFLAGS="${SDKROOT:+-isysroot ${SDKROOT}} -arch ${arch}"
|
||||
|
||||
if [ "$configure_qt_frameworks" = "yes" ]; then
|
||||
export QT_CORE_CFLAGS="-FQtCore"
|
||||
|
@ -41,6 +41,8 @@
|
||||
<string>YES</string>
|
||||
<key>OSAScriptingDefinition</key>
|
||||
<string>LyX.sdef</string>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
<string>@macos_deployment_target@</string>
|
||||
<key>NSHighResolutionCapable</key>
|
||||
<true/>
|
||||
<key>NSPrincipalClass</key>
|
||||
|
Loading…
Reference in New Issue
Block a user