3

OS X Lion で Clozure CL を使って Commonqt を使いたいと思っていました。

しかし、それは機能していませんでした...

共通qt

Commonqt は、Qt の煙ライブラリへの Common Lisp バインディングです。

http://common-lisp.net/project/commonqt/

私の設定はそれです

OS X ライオン 10.7.4

Xcode 4.3.3

Clozure CL バージョン 1.8

qt 4.8.2 (git clone git://gitorious.org/qt/qt.git) "./configure && make install && make"

  • somkegen (git clone git://anongit.kde.org/smokegen) "cmake . && make install"
  • Smokeqt (git clone git://anongit.kde.org/smokeqt) "cmake . && make install"

クイックリスプ

  • local-projects commonqt (git clone git://gitorious.org/commonqt/commonqt.git) "qmake && make clean && make"

参照: http://kvardek-du.kerno.org/2011/12/setting-up-commonqt-on-osx.html

qt.asd(共通qt)

(defmethod output-files ((operation compile-op) (c cpp->so))   (values
    (loop for filename in '("libcommonqt.so" "libcommonqt.so.1"
                            "libcommonqt.so.1.0" "libcommonqt.so.1.0.0")
          collect (merge-pathnames filename (component-pathname c)))
    ;; libcommonqt.so* files are never moved to separate FASL directory
    t))

だから私は変更されました(だから - > dylib)

(defmethod output-files ((operation compile-op) (c cpp->so))   (values
    (loop for filename in '("libcommonqt.dylib" "libcommonqt.1.dylib"
                            "libcommonqt.1.0.dylib" "libcommonqt.1.0.0.dylib")
          collect (merge-pathnames filename (component-pathname c)))
    ;; libcommonqt.so* files are never moved to separate FASL directory
    t))

しかし、エラーが発生しました。例えば

ソースコード

http://pleasegodno.wordpress.com/common-lisp-tutorials/common-lisp-gui-programming-with-commonqt/2-classes-and-methods/

? (main)
MAIN
? > Error: Unable to load foreign library (LIBCOMMONQT.DYLIB-31136).
>          Error opening shared library /Users/jk/.quicklisp/local-projects/commonqt/libcommonqt.dylib : dlopen(/Users/jk/.quicklisp/local-projects/commonqt/libcommonqt.dylib, 10): no suitable image found.  Did find:
>           /Users/jk/.quicklisp/local-projects/commonqt/libcommonqt.dylib: mach-o, but wrong architecture.
> While executing: CFFI::FL-ERROR, in process listener(1).
> Type :POP to abort, :R for a list of available restarts.
> Type :? for other options.
1 > 

これは私の間違った設定ですか?または、OS X Lion で Clozure Cl を使用すると、Commonqt のソースが機能しませんか?

次に、私は何をすべきですか?

user1234192 のアドバイス: ccl -> ccl64

再試行します。

> (qt-conv:main)
2012-07-12 21:46:11.630 dx86cl64[93621:c403] *** Assertion failure in +[NSUndoManager _endTopLevelGroupings], /SourceCache/Foundation/Foundation-833.25/Misc.subproj/NSUndoManager.m:324
2012-07-12 21:46:11.631 dx86cl64[93621:c403] +[NSUndoManager(NSInternal) _endTopLevelGroupings] is only safe to invoke on the main thread.
2012-07-12 21:46:11.633 dx86cl64[93621:c403] (
    0   CoreFoundation                      0x00007fff8dc49f56 __exceptionPreprocess + 198
    1   libobjc.A.dylib                     0x00007fff9600dd5e objc_exception_throw + 43
    2   CoreFoundation                      0x00007fff8dc49d8a +[NSException raise:format:arguments:] + 106
    3   Foundation                          0x00007fff8de4671f -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 169
    4   Foundation                          0x00007fff8ddb595f +[NSUndoManager(NSPrivate) _endTopLevelGroupings] + 144
    5   AppKit                              0x00007fff8b15a0ef -[NSApplication run] + 596
    6   QtGui                               0x000000000346cc60 _ZN19QEventDispatcherMac13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE + 840
    7   QtCore                              0x0000000004122838 _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE + 394
    8   QtCore                              0x0000000004125b0b _ZN16QCoreApplication4execEv + 175
    9   libsmokeqtgui.dylib                 0x00000000043718e1 _ZN12__smokeqtgui14x_QApplication4x_84EPN5Smoke9StackItemE + 17
    10  libsmokeqtgui.dylib                 0x00000000043579d8 _ZN12__smokeqtgui18xcall_QApplicationEsPvPN5Smoke9StackItemE + 1304
    11  dx86cl64                            0x000000000001b0db SPffcall + 99
    12  ???                                 0x0000000001219328 0x0 + 18977576
)
2012-07-12 21:46:11.634 dx86cl64[93621:c403] *** Assertion failure in +[NSUndoManager _endTopLevelGroupings], /SourceCache/Foundation/Foundation-833.25/Misc.subproj/NSUndoManager.m:324
Qt has caught an exception thrown from an event handler. Throwing
exceptions from an event handler is not supported in Qt. You must
reimplement QApplication::notify() and catch all exceptions there.

Unhandled exception 10 at 0x0, context->regs at #xb029af30
Exception occurred while executing foreign code
received signal 10; faulting address: 0x0
? for help
[93621] Clozure CL kernel debugger: help
[93621] Clozure CL kernel debugger: [93621] Clozure CL kernel debugger: [93621] Clozure CL kernel debugger: Segmentation fault: 11
4

2 に答える 2

3

http://kvardek-du.kerno.org/2011/12/setting-up-commonqt-on-osx.html

Clozure cl(Lion) に成功しました

そして...あなたのエラーメッセージ..「libcommonqt.dylib:mach-o、しかし間違ったアーキテクチャ」

たぶん..あなたの ccl と libcommonqt.dylib は異なるアーキテクチャです。

ccl が x86(32bit) の場合、libcommonqt.dylib は x86 でなければなりません。

ccl が x8664(64bit) の場合、libcommonqt.dylib は x8664 でなければなりません...

64ビットをお勧めします。

私の英語はとても醜いです。ごめん.......

于 2012-07-11T17:43:18.117 に答える