[Development] ActiveQt AxServer with CMake
Robert Knight
robertknight at gmail.com
Wed Feb 12 16:47:52 CET 2014
> Has anyone managed to create an ActiveQt server with CMake?
To clarify, is the problem with running the IDC/IDL tools or some
other step? The CMake logic we've used for this is roughly:
set(IDL_COMMANDS
COMMAND idl ${BINARY_PATH} -idl ${BINARY_PATH}.idl
COMMAND midl ${BINARY_PATH}.idl ${BINARY_PATH}.tlb
COMMAND idc ${BINARY_PATH} -tlb ${BINARY_PATH}.tlb)
add_custom_command(TARGET ${SERVER_TARGET} POST_BUILD ${IDL_COMMANDS}
COMMENT "Generating and embedding type library")
Where ${SERVER_TARGET} is the name of the executable target that is
the ActiveX server and ${BINARY_PATH}
is set to '$<TARGET_FILE:SERVER_TARGET>' - CMake automatically expands
that to the .exe path at build time.
So the target is built as normal and then idl/idc is run as a
post-build step whenever the target is rebuilt.
Regards,
Rob.
On 12 February 2014 14:24, Fricot, Daniel <daniel.fricot at barco.com> wrote:
> Hi,
>
> Has anyone managed to create an ActiveQt server with CMake? I got it working
> with qmake but we need to do this with CMake. I also tried idc manually
> after CMake but then I keep getting the error:
>
> QObject::startTimer: Timers can only be used with threads started with
> QThread
>
> IDL generation failed trying to run program myapp.exe!
>
> Thanks,
>
> Daniel
>
> This message is subject to the following terms and conditions: MAIL
> DISCLAIMER
>
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development
>
More information about the Development
mailing list