[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: How to add qt script tools support in cmake?
From:       dmitry chernov <diman4ik.chernov () gmail ! com>
Date:       2011-06-24 13:06:12
Message-ID: BANLkTi=OeLnuT91c6gwTvF5JcKCUxaM9+g () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Thank you, but this doesn't work for me. ))

On Fri, Jun 24, 2011 at 4:45 PM, Luis Gustavo Spern Barreto <
gustavosbarreto@gmail.com> wrote:

> Hello.
> Add these variables to the include_directories() and
> target_link_libraries():
>
> include_directories(${QT_....} ${QT_QTSCRIPTTOOLS_INCLUDE_DIR})
> target_link_libraries(${QT_....} ${QT_QTSCRIPTTOOLS_LIBRARY})
>
> If you need Qt script:
> ${QT_QTSCRIPT_INCLUDE_DIR}
> ${QT_QTSCRIPT_LIBRARY}
>
> Luis Gustavo Spern Barreto,
> http://www.gustavobarreto.net
> +55 53 9144.4318
>
>
>
> 2011/6/24 dmitry chernov <diman4ik.chernov@gmail.com>:
> > For me it builds only after adding this:
> > include_directories(file /usr/include/QtScriptTools) and changing this:
> > TARGET_LINK_LIBRARIES( context2d ${QT_LIBRARIES}
> > /usr/lib/libQtScriptTools.so )
> >
> > So0mething is broken or smth. I've got rather old system Fedora11...
> >
> > On Fri, Jun 24, 2011 at 7:58 AM, dmitry chernov <
> diman4ik.chernov@gmail.com>
> > wrote:
> >>
> >> Thank you, Filip.
> >> But it still says that : error: QScriptEngineDebugger: No such file or
> >> directory.
> >>
> >> On Tue, Jun 21, 2011 at 2:49 PM, Filip Brcic <brcha@gna.org> wrote:
> >>>
> >>> On =D1=83=D1=82=D0=BE=D1=80=D0=B0=D0=BA, 21. =D1=98=D1=83=D0=BD 2011.=
 8.35.41 dmitry chernov wrote:
> >>> > Do anybody have proper CMakeLists.txt to build qt's example
> Context2D?
> >>> > I
> >>> > had to add -DQT_NO_SCRIPTTOOLS. When I build this example with .pro
> >>> > file
> >>> > it builds ok. So I want to know how to add qt script tools support =
in
> >>> > cmake
> >>>
> >>> Here's the CMakeLists.txt that works:
> >>>
> >>> project(context2d)
> >>>
> >>> find_package(Qt4 COMPONENTS QtCore QtGui QtScript QtScriptTools
> REQUIRED)
> >>> include(${QT_USE_FILE})
> >>>
> >>> SET(context2d_SRCS
> >>>    main.cpp
> >>>    context2d.cpp
> >>>    domimage.cpp
> >>>     environment.cpp
> >>>    qcontext2dcanvas.cpp
> >>>    window.cpp
> >>> )
> >>>
> >>> SET(context2d_HEADERS
> >>>    context2d.h
> >>>    domimage.h
> >>>    environment.h
> >>>    qcontext2dcanvas.h
> >>>    window.h
> >>> )
> >>>
> >>> QT4_WRAP_CPP( context2d_HEADERS_MOC ${context2d_HEADERS} )
> >>>
> >>> SET(context2d_RESOURCES context2d.qrc)
> >>>
> >>> QT4_ADD_RESOURCES(context2d_RESOURCES_RCC ${context2d_RESOURCES})
> >>>
> >>> ADD_DEFINITIONS(${QT_DEFINITIONS})
> >>>
> >>> ADD_EXECUTABLE(context2d ${context2d_SRCS}
> >>>                          ${context2d_RESOURCES_RCC}
> >>>                         ${context2d_HEADERS_MOC} )
> >>>
> >>> TARGET_LINK_LIBRARIES(context2d ${QT_LIBRARIES})
> >>>
> >>> It seams this example needs both QtScript and QtScriptTools (as is
> >>> written in
> >>> the .pro file).
> >>>
> >>> Best regards,
> >>> Filip
> >>>
> >>> --
> >>> Filip Brcic <brcha@gna.org>
> >>> WWWeb: http://brcha.com
> >>> Jabber  : brcha@kdetalk.net
> >>> GPG 0x2537C379
> >>> Fingerprint: 287D 5F24 50AA A36C 977F AC9A F1FD C7EB 2537 C379
> >>>
> >>>
> >>> >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to
> >>> >> unsubscribe <<
> >>>
> >>
> >
> >
> >
> >>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to
> unsubscribe
> >>> <<
> >
> >
>
> >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to
> unsubscribe <<
>

[Attachment #5 (text/html)]

Thank you, but this doesn&#39;t work for me. ))<br><br><div class="gmail_quote">On \
Fri, Jun 24, 2011 at 4:45 PM, Luis Gustavo Spern Barreto <span dir="ltr">&lt;<a \
href="mailto:gustavosbarreto@gmail.com">gustavosbarreto@gmail.com</a>&gt;</span> \
wrote:<br> <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, \
204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hello.<br> Add these \
variables to the include_directories() and target_link_libraries():<br> <br>
include_directories(${QT_....} ${QT_QTSCRIPTTOOLS_INCLUDE_DIR})<br>
target_link_libraries(${QT_....} ${QT_QTSCRIPTTOOLS_LIBRARY})<br>
<br>
If you need Qt script:<br>
${QT_QTSCRIPT_INCLUDE_DIR}<br>
${QT_QTSCRIPT_LIBRARY}<br>
<br>
Luis Gustavo Spern Barreto,<br>
<a href="http://www.gustavobarreto.net" \
target="_blank">http://www.gustavobarreto.net</a><br> +55 53 9144.4318<br>
<br>
<br>
<br>
2011/6/24 dmitry chernov &lt;<a \
href="mailto:diman4ik.chernov@gmail.com">diman4ik.chernov@gmail.com</a>&gt;:<br> \
<div><div></div><div class="h5">&gt; For me it builds only after adding this:<br> \
&gt; include_directories(file /usr/include/QtScriptTools) and changing this:<br> &gt; \
TARGET_LINK_LIBRARIES( context2d ${QT_LIBRARIES}<br> &gt; \
/usr/lib/libQtScriptTools.so )<br> &gt;<br>
&gt; So0mething is broken or smth. I&#39;ve got rather old system Fedora11...<br>
&gt;<br>
&gt; On Fri, Jun 24, 2011 at 7:58 AM, dmitry chernov &lt;<a \
href="mailto:diman4ik.chernov@gmail.com">diman4ik.chernov@gmail.com</a>&gt;<br> &gt; \
wrote:<br> &gt;&gt;<br>
&gt;&gt; Thank you, Filip.<br>
&gt;&gt; But it still says that : error: QScriptEngineDebugger: No such file or<br>
&gt;&gt; directory.<br>
&gt;&gt;<br>
&gt;&gt; On Tue, Jun 21, 2011 at 2:49 PM, Filip Brcic &lt;<a \
href="mailto:brcha@gna.org">brcha@gna.org</a>&gt; wrote:<br> &gt;&gt;&gt;<br>
&gt;&gt;&gt; On уторак, 21. јун 2011. 8.35.41 dmitry chernov wrote:<br>
&gt;&gt;&gt; &gt; Do anybody have proper CMakeLists.txt to build qt&#39;s example \
Context2D?<br> &gt;&gt;&gt; &gt; I<br>
&gt;&gt;&gt; &gt; had to add -DQT_NO_SCRIPTTOOLS. When I build this example with \
.pro<br> &gt;&gt;&gt; &gt; file<br>
&gt;&gt;&gt; &gt; it builds ok. So I want to know how to add qt script tools support \
in<br> &gt;&gt;&gt; &gt; cmake<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Here&#39;s the CMakeLists.txt that works:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; project(context2d)<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; find_package(Qt4 COMPONENTS QtCore QtGui QtScript QtScriptTools \
REQUIRED)<br> &gt;&gt;&gt; include(${QT_USE_FILE})<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; SET(context2d_SRCS<br>
&gt;&gt;&gt;      main.cpp<br>
&gt;&gt;&gt;      context2d.cpp<br>
&gt;&gt;&gt;      domimage.cpp<br>
&gt;&gt;&gt;       environment.cpp<br>
&gt;&gt;&gt;      qcontext2dcanvas.cpp<br>
&gt;&gt;&gt;      window.cpp<br>
&gt;&gt;&gt; )<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; SET(context2d_HEADERS<br>
&gt;&gt;&gt;      context2d.h<br>
&gt;&gt;&gt;      domimage.h<br>
&gt;&gt;&gt;      environment.h<br>
&gt;&gt;&gt;      qcontext2dcanvas.h<br>
&gt;&gt;&gt;      window.h<br>
&gt;&gt;&gt; )<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; QT4_WRAP_CPP( context2d_HEADERS_MOC ${context2d_HEADERS} )<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; SET(context2d_RESOURCES context2d.qrc)<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; QT4_ADD_RESOURCES(context2d_RESOURCES_RCC ${context2d_RESOURCES})<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; ADD_DEFINITIONS(${QT_DEFINITIONS})<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; ADD_EXECUTABLE(context2d ${context2d_SRCS}<br>
&gt;&gt;&gt;                                       ${context2d_RESOURCES_RCC}<br>
&gt;&gt;&gt;                                     ${context2d_HEADERS_MOC} )<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; TARGET_LINK_LIBRARIES(context2d ${QT_LIBRARIES})<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; It seams this example needs both QtScript and QtScriptTools (as is<br>
&gt;&gt;&gt; written in<br>
&gt;&gt;&gt; the .pro file).<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Best regards,<br>
&gt;&gt;&gt; Filip<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; --<br>
&gt;&gt;&gt; Filip Brcic &lt;<a href="mailto:brcha@gna.org">brcha@gna.org</a>&gt;<br>
&gt;&gt;&gt; WWWeb: <a href="http://brcha.com" \
target="_blank">http://brcha.com</a><br> &gt;&gt;&gt; Jabber   : <a \
href="mailto:brcha@kdetalk.net">brcha@kdetalk.net</a><br> &gt;&gt;&gt; GPG \
0x2537C379<br> &gt;&gt;&gt; Fingerprint: 287D 5F24 50AA A36C 977F AC9A F1FD C7EB 2537 \
C379<br> &gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; &gt;&gt; Visit <a \
href="http://mail.kde.org/mailman/listinfo/kde-devel#unsub" \
target="_blank">http://mail.kde.org/mailman/listinfo/kde-devel#unsub</a> to<br> \
&gt;&gt;&gt; &gt;&gt; unsubscribe &lt;&lt;<br> &gt;&gt;&gt;<br>
&gt;&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;&gt;&gt; Visit <a href="http://mail.kde.org/mailman/listinfo/kde-devel#unsub" \
target="_blank">http://mail.kde.org/mailman/listinfo/kde-devel#unsub</a> to \
unsubscribe<br> &gt;&gt;&gt; &lt;&lt;<br>
&gt;<br>
&gt;<br>
<br>
&gt;&gt; Visit <a href="http://mail.kde.org/mailman/listinfo/kde-devel#unsub" \
target="_blank">http://mail.kde.org/mailman/listinfo/kde-devel#unsub</a> to \
unsubscribe &lt;&lt;<br> </div></div></blockquote></div><br>



>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic