mirror of https://github.com/mpv-player/mpv
Group (system-specific) CFLAGS settings together.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@22727 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
078fda08bd
commit
148dd28490
|
@ -7188,35 +7188,6 @@ else
|
||||||
fi
|
fi
|
||||||
echores "$_crash_debug"
|
echores "$_crash_debug"
|
||||||
|
|
||||||
if darwin ; then
|
|
||||||
CFLAGS="$CFLAGS -mdynamic-no-pic -falign-loops=16 -DSYS_DARWIN -DCONFIG_DARWIN -shared-libgcc"
|
|
||||||
if [ "$_cc_major" = 3 ] && [ "$_cc_minor" -lt 1 ]; then
|
|
||||||
CFLAGS="$CFLAGS -no-cpp-precomp"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
if amigaos ; then
|
|
||||||
CFLAGS="$CFLAGS -DNEWLIB -D__USE_INLINE__ -DSYS_AMIGAOS4"
|
|
||||||
fi
|
|
||||||
if hpux ; then
|
|
||||||
# use flag for HPUX missing setenv()
|
|
||||||
CFLAGS="$CFLAGS -DHPUX"
|
|
||||||
fi
|
|
||||||
# Thread support
|
|
||||||
if linux ; then
|
|
||||||
CFLAGS="$CFLAGS -D_REENTRANT"
|
|
||||||
elif bsd ; then
|
|
||||||
# FIXME bsd needs this so maybe other OS'es
|
|
||||||
CFLAGS="$CFLAGS -D_THREAD_SAFE"
|
|
||||||
fi
|
|
||||||
# 64 bit file offsets?
|
|
||||||
if test "$_largefiles" = yes || freebsd ; then
|
|
||||||
CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
|
|
||||||
if test "$_dvdread" = yes || test "$_libdvdcss_internal" = yes ; then
|
|
||||||
# dvdread support requires this (for off64_t)
|
|
||||||
CFLAGS="$CFLAGS -D_LARGEFILE64_SOURCE"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
echocheck "compiler support for noexecstack"
|
echocheck "compiler support for noexecstack"
|
||||||
cat > $TMPC <<EOF
|
cat > $TMPC <<EOF
|
||||||
int main(void) { return 0; }
|
int main(void) { return 0; }
|
||||||
|
@ -7228,10 +7199,6 @@ else
|
||||||
echores "no"
|
echores "no"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if cc_check -Wdeclaration-after-statement ; then
|
|
||||||
CFLAGS="-Wdeclaration-after-statement $CFLAGS"
|
|
||||||
fi
|
|
||||||
|
|
||||||
echocheck "ftello()"
|
echocheck "ftello()"
|
||||||
# if we don't have ftello use the osdep/ compatibility module
|
# if we don't have ftello use the osdep/ compatibility module
|
||||||
cat > $TMPC << EOF
|
cat > $TMPC << EOF
|
||||||
|
@ -7250,13 +7217,6 @@ else
|
||||||
fi
|
fi
|
||||||
echores "$_ftello"
|
echores "$_ftello"
|
||||||
|
|
||||||
# Determine OS dependent libs
|
|
||||||
if cygwin ; then
|
|
||||||
#CFLAGS="$CFLAGS -D__CYGWIN__ -D__CYGWIN_USE_BIG_TYPES__"
|
|
||||||
# stat.st_size with BIG_TYPES is broken (not set) ::atmos
|
|
||||||
CFLAGS="$CFLAGS -D__CYGWIN__"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Dynamic linking flags
|
# Dynamic linking flags
|
||||||
# (FIXME: 'echocheck "dynamic linking"' above and modify here accordingly)
|
# (FIXME: 'echocheck "dynamic linking"' above and modify here accordingly)
|
||||||
_ld_dl_dynamic=''
|
_ld_dl_dynamic=''
|
||||||
|
@ -7413,6 +7373,46 @@ for I in $_libs_mplayer ; do
|
||||||
done
|
done
|
||||||
_libs_mplayer=$_ld_tmp
|
_libs_mplayer=$_ld_tmp
|
||||||
|
|
||||||
|
|
||||||
|
#############################################################################
|
||||||
|
if darwin ; then
|
||||||
|
CFLAGS="$CFLAGS -mdynamic-no-pic -falign-loops=16 -DSYS_DARWIN -DCONFIG_DARWIN -shared-libgcc"
|
||||||
|
if [ "$_cc_major" = 3 ] && [ "$_cc_minor" -lt 1 ]; then
|
||||||
|
CFLAGS="$CFLAGS -no-cpp-precomp"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if amigaos ; then
|
||||||
|
CFLAGS="$CFLAGS -DNEWLIB -D__USE_INLINE__ -DSYS_AMIGAOS4"
|
||||||
|
fi
|
||||||
|
if hpux ; then
|
||||||
|
# use flag for HPUX missing setenv()
|
||||||
|
CFLAGS="$CFLAGS -DHPUX"
|
||||||
|
fi
|
||||||
|
# Thread support
|
||||||
|
if linux ; then
|
||||||
|
CFLAGS="$CFLAGS -D_REENTRANT"
|
||||||
|
elif bsd ; then
|
||||||
|
# FIXME bsd needs this so maybe other OS'es
|
||||||
|
CFLAGS="$CFLAGS -D_THREAD_SAFE"
|
||||||
|
fi
|
||||||
|
if cygwin ; then
|
||||||
|
#CFLAGS="$CFLAGS -D__CYGWIN__ -D__CYGWIN_USE_BIG_TYPES__"
|
||||||
|
# stat.st_size with BIG_TYPES is broken (not set) ::atmos
|
||||||
|
CFLAGS="$CFLAGS -D__CYGWIN__"
|
||||||
|
fi
|
||||||
|
# 64 bit file offsets?
|
||||||
|
if test "$_largefiles" = yes || freebsd ; then
|
||||||
|
CFLAGS="$CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
|
||||||
|
if test "$_dvdread" = yes || test "$_libdvdcss_internal" = yes ; then
|
||||||
|
# dvdread support requires this (for off64_t)
|
||||||
|
CFLAGS="$CFLAGS -D_LARGEFILE64_SOURCE"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if cc_check -Wdeclaration-after-statement ; then
|
||||||
|
CFLAGS="-Wdeclaration-after-statement $CFLAGS"
|
||||||
|
fi
|
||||||
|
|
||||||
#############################################################################
|
#############################################################################
|
||||||
# Take care of ffmpeg dependencies
|
# Take care of ffmpeg dependencies
|
||||||
if test "$_zlib" = no ; then
|
if test "$_zlib" = no ; then
|
||||||
|
|
Loading…
Reference in New Issue