]> rtime.felk.cvut.cz Git - opencv.git/commitdiff
fix GCC compile error when -fPIC is specified
authorvp153 <vp153@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Fri, 12 Mar 2010 15:46:28 +0000 (15:46 +0000)
committervp153 <vp153@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Fri, 12 Mar 2010 15:46:28 +0000 (15:46 +0000)
git-svn-id: https://code.ros.org/svn/opencv/trunk@2802 73c94f0f-984f-4a5f-82bc-2d8db8d8ee08

opencv/src/cxcore/cxsystem.cpp

index e9aeb255714cde2b7c36dd7a00d5a6d8a8c6740e..8fbc0ebd464fac71a7dfe5dcbf15028b6962c2e7 100644 (file)
@@ -86,11 +86,13 @@ struct HWFeatures
     #elif defined __GNUC__ && (defined __i386__ || defined __x86_64__)
         asm volatile
         (
+         "pushl %%ebx\n"
          "movl $1,%%eax\n"
          ".byte 0x0f; .byte 0xa2\n"
+         "popl %%ebx\n"
          : "=a"(cpuid_data[0]), "=c" (cpuid_data[2]), "=d" (cpuid_data[3])
          :
-         : "%ebx", "%esi", "%edi"
+         : "%esi", "%edi"
          );
     #endif