2012-08-09 18 views
5

में libqxt संकलित करना मेरे पास libqxt का नवीनतम (git) संस्करण है। मैं ./configure चलाने के लिए और है कि बस ठीक काम करता है, इस त्रुटि के साथ विफल तो बनाना:मैक ओएसएक्स

linking ../../lib/QxtWidgets.framework/QxtWidgets 
ld: warning: directory not found for option '-L/usr/local/pgsql/lib' 
ld: warning: directory not found for option '-L/tmp/qt-stuff-85167/source/qt-everywhere-opensource-src-4.8.1/Desktop/Qt/4.8.1/gcc/lib' 
ld: warning: directory not found for option '-F/tmp/qt-stuff-85167/source/qt-everywhere-opensource-src-4.8.1/Desktop/Qt/4.8.1/gcc/lib' 
Undefined symbols for architecture x86_64: 
    "_CGSGetWindowProperty", referenced from: 
     QxtWindowSystem::windowTitle(long) in qxtwindowsystem_mac.o 
ld: symbol(s) not found for architecture x86_64 
collect2: ld returned 1 exit status 
make[1]: *** [../../lib/QxtWidgets.framework/QxtWidgets] Error 1 
make: *** [sub-src-widgets-install_subtargets] Error 2 

अगर यह मायने रखती है, मैं OSX माउंटेन शेर उपयोग कर रहा हूँ।

धन्यवाद!

उत्तर

4

ऐसा लगता है कि क्यूएक्स कुछ निजी मैक ओएस एक्स एपीआई का उपयोग कर रहा है जिसे माउंटेन शेर में हटा दिया गया था। CGSGetWindowProperty को मैक ओएस एक्स के पिछले संस्करणों में दस्तावेज नहीं किया गया था, इसलिए मुझे लगता है कि इसे किसी भी तरह से उपयोग करने के लिए विश्वसनीय नहीं था।

+1

हाँ, यही वह भी था जो मैं सोच रहा था ... क्या आपको लगता है कि इस के आसपास जाने का कोई तरीका है, या यहां तक ​​कि हेडर/lib कहीं और ढूंढें? यदि हां, तो कहाँ? – sfw

4

एक हैकी फिक्स के रूप में आप केवल CGSGetWindowProperty प्रॉपर्टी कॉल को हटा सकते हैं - Qxt संकलित होगा, लेकिन निश्चित रूप से QxtWindowSystem::windowTitle सही तरीके से काम नहीं करेगा।

diff --git a/src/widgets/mac/qxtwindowsystem_mac.cpp b/src/widgets/mac/qxtwindowsystem_mac.cpp 
index 63cab38..de4a89c 100644 
--- a/src/widgets/mac/qxtwindowsystem_mac.cpp 
+++ b/src/widgets/mac/qxtwindowsystem_mac.cpp 
@@ -89,11 +89,7 @@ QString QxtWindowSystem::windowTitle(WId window) 
    // most of CoreGraphics private definitions ask for CGSValue as key but since 
    // converting strings to/from CGSValue was dropped in 10.5, I use CFString, which 
    // apparently also works. 
- err = CGSGetWindowProperty(connection, window, (CGSValue)CFSTR("kCGSWindowTitle"), &windowTitle); 
- if (err != noErr) return QString(); 
- 
- // this is UTF8 encoded 
- return QCFString::toQString((CFStringRef)windowTitle); 
+ return QString(); 
} 

QRect QxtWindowSystem::windowGeometry(WId window) 

भविष्य के संदर्भ के लिए आप this issue in libqxt repository पर निगरानी रख सकते हैं।

+0

हाय, यदि संभव हो, तो क्या आप इस प्रश्न का उत्तर दे सकते हैं: http://stackoverflow.com/questions/28708747/error-trying-to-install-qxt-for-sending-email? मैंने ठीक किया मैंने कहा, मुझे 'इंस्टॉल करें' चरण के दौरान त्रुटि मिली .. – SexyBeast