I've met this issue when packaging lensfun for MeeGo.
The CPU I'm using is a:
Intel(R) Core(TM)2 Duo CPU P8400 @ 2.26GHz
flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm
constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor
ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 lahf_lm tpr_shadow
vnmi flexpriority
gcc version 4.4.2 20091027 (MeeGo 4.4.2-7) (GCC)
I tried the cpuid.cpp from SVN Trunk, it couldn't compile with -fPIC, the error
is:
error: PIC register '%ebx' clobbered in 'asm'
I'm not sure if this is a gcc bug or not. But to workaround it we can patch the
asm code like this (as posted somewhere):
--- cpuid.cpp 2010-05-12 11:44:37.000000000 +0800
+++ cpuid.cpp.new 2010-05-12 11:45:31.000000000 +0800
@@ -26,10 +26,11 @@
{
#define cpuid(cmd) \
__asm volatile ( \
+ "push %%"R_BX"\n" \
"cpuid\n" \
+ "pop %%"R_BX"\n" \
: "=a" (ax), "=c" (cx), "=d" (dx) \
- : "0" (cmd) \
- : R_BX)
+ : "0" (cmd))
__SIZE_TYPE__ ax, cx, dx, tmp;
static GStaticMutex lock = G_STATIC_MUTEX_INIT;
Please consider issue a new release since the current 0.2.5 release
can't work with UFRaw as a shared lib. Thank you.
------------------------------------------------------------------------------
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees
_______________________________________________
Lensfun-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/lensfun-users