[FFmpeg-cvslog] configure: generalise 64-bit test
Mans Rullgard
git at videolan.org
Thu Oct 25 13:26:34 CEST 2012
ffmpeg | branch: master | Mans Rullgard <mans at mansr.com> | Tue Oct 23 23:33:44 2012 +0100| [d4c99513f41272b9753e59642724717b834710a0] | committer: Mans Rullgard
configure: generalise 64-bit test
Signed-off-by: Mans Rullgard <mans at mansr.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d4c99513f41272b9753e59642724717b834710a0
---
configure | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/configure b/configure
index 37cdf1e..b1c6d45 100755
--- a/configure
+++ b/configure
@@ -2668,13 +2668,20 @@ EOF
check_host_cflags -std=c99
check_host_cflags -Wall
+check_64bit(){
+ arch32=$1
+ arch64=$2
+ expr=$3
+ check_code cc "" "int test[2*($expr) - 1]" &&
+ subarch=$arch64 || subarch=$arch32
+}
+
case "$arch" in
alpha|ia64|mips|parisc|sparc)
spic=$shared
;;
x86)
- subarch="x86_32"
- check_code cc "" "int test[(int)sizeof(char*) - 7]" && subarch="x86_64"
+ check_64bit x86_32 x86_64 'sizeof(void *) > 4'
if test "$subarch" = "x86_64"; then
spic=$shared
fi
More information about the ffmpeg-cvslog
mailing list