[Qt-creator] QtCreator support for Unreal Engine 4

Sander Smid sander.smid at gmail.com
Sat Mar 3 09:57:41 CET 2018


Thanks Tobias for your reply.

So I've been looking into what QtCreator already provides, what steps are
already done on the UE4 side of things and what is missing to get proper
integration. What UE4 currently provides is a qmake project file (.pro) and
a few project include files (.pri) which mainly list all the project source
and header files. The UE4.pro file does contain some description of targets
but not all of them are picked up when the user configures the project
file. All of the settings that actually deal with defines (UE4Defines.pri)
seem stubbed and don't contain actual build defines. Probably because it is
required by qmake but simply doesn't have a purpose as UE4 uses its own
build system.

The current UE4 documentation recommends each user needs to create a
UE4.pro.user file in which the qmake build and clean steps are removed and
(manually) replaced with a make command. This is all described in an array
of "ProjectExplorer.Project.Target" structures in the UE4.pro.user that
define the build and run settings. As a quick test I moved that part over
to a UE4.pro.shared file as that file is intended to be shared.
Unfortunately QtCreator prompts me to configure the project so I assume
this isn't supported.
The alternative would be to generate the UE4.pro.user file in a similar way
the .pro file is generated (I should have all the information at that the
moment the .pro and .pri files are being generated) however I got the
impression that is not the recommended way to go about this.

This bring me to the following set of questions:

   1. Fixing the qmake build steps:
   - Each user currently needs to define their kits (which makes sense as
      it includes build target locations) but after generating them not all the
      targets as described in UE4.pro are not all available. Can you what steps
      are missing here?
      - Can you see any reason why the qmake project files are not working?
      I know this is a broad question so feel free to skip this.
      - Is there any other place than the .pro.user files where QtCreator
      stored information about project configurations that might be
relevant (e.g
      ~/.config)?
   2. Use qmake project as a shell for code navigation and focus on getting
   build and run configurations working with make:
   - I'm thinking to generate a set of "ProjectExplorer.Project.Target"
      structures that call 'make' to build the projects. I think I can generate
      the structure for a UE4.pro.user but that conflicts with the kit
      generation/configure step. Is there any other place where I can
store this
      structure so it is available to all users? And is this a sane
approach? I'm
      a bit worried about some of the Ids in there (e.g. ProjectExplorer.
      ProjectConfiguration.Id and EnvironmentId) will bite me once I got
      the UE4.pro.user file generated. Any ideas on that?

For reference I attached the generated .pro and .pri files which might help
filling in the blanks where my explanation (with very limited experience
with qmake) might fall short.

Cheers!
.san


On Sat, Mar 3, 2018 at 9:50 AM, Sander Smid <sander.smid at gmail.com> wrote:

> Thanks Tobias for your reply.
>
> So I've been looking into what QtCreator already provides, what steps are
> already done on the UE4 side of things and what is missing to get proper
> integration. What UE4 currently provides is a qmake project file (.pro) and
> a few project include files (.pri) which mainly list all the project source
> and header files. The UE4.pro file does contain some description of targets
> but not all of them are picked up when the user configures the project
> file. All of the settings that actually deal with defines (UE4Defines.pri)
> seem stubbed and don't contain actual build defines. Probably because it is
> required by qmake but simply doesn't have a purpose as UE4 uses its own
> build system.
>
> The current UE4 documentation recommends each user needs to create a
> UE4.pro.user file in which the qmake build and clean steps are removed and
> (manually) replaced with a make command. This is all described in an array
> of "ProjectExplorer.Project.Target" structures in the UE4.pro.user that
> define the build and run settings. As a quick test I moved that part over
> to a UE4.pro.shared file as that file is intended to be shared.
> Unfortunately QtCreator prompts me to configure the project so I assume
> this isn't supported.
> The alternative would be to generate the UE4.pro.user file in a similar
> way the .pro file is generated (I should have all the information at that
> the moment the .pro and .pri files are being generated) however I got the
> impression that is not the recommended way to go about this.
>
> This bring me to the following set of questions:
>
>    1. Fixing the qmake build steps:
>    - Each user currently needs to define their kits (which makes sense as
>       it includes build target locations) but after generating them not all the
>       targets as described in UE4.pro are not all available. Can you what steps
>       are missing here?
>       - Can you see any reason why the qmake project files are not
>       working? I know this is a broad question so feel free to skip this.
>       - Is there any other place than the .pro.user files where QtCreator
>       stored information about project configurations that might be relevant (e.g
>       ~/.config)?
>    2. Use qmake project as a shell for code navigation and focus on
>    getting build and run configurations working with make:
>    - I'm thinking to generate a set of "ProjectExplorer.Project.Target"
>       structures that call 'make' to build the projects. I think I can generate
>       the structure for a UE4.pro.user but that conflicts with the kit
>       generation/configure step. Is there any other place where I can store this
>       structure so it is available to all users? And is this a sane approach? I'm
>       a bit worried about some of the Ids in there (e.g. ProjectExplorer.
>       ProjectConfiguration.Id and EnvironmentId) will bite me once I got
>       the UE4.pro.user file generated. Any ideas on that?
>
> For reference I attached the generated .pro and .pri files which might
> help filling in the blanks where my explanation (with very limited
> experience with qmake) might fall short.
>
> Cheers!
> .san
>
>
>
> On Thu, Feb 15, 2018 at 12:15 PM, Tobias Hunger <Tobias.Hunger at qt.io>
> wrote:
>
>> Hi Sander,
>>
>> > I was wondering if QtCreator could see some improvements in supporting
>> > third-party builds systems and/or integration with bigger projects.
>> Unreal
>> > Engine 4 is one of the biggest game engines and, when you agree with
>> > their terms, you get access to the full source code. This helped quite a
>> > bit in supporting other platforms.
>>
>> I have no plans at this time to support Unreal Engine. Contributions are
>> of course welcome, but I don't think this is something that we should offer
>> in the core Qt Creator. It would be a wonderful 3rd party plugin though.
>>
>> > One of the weaker points with this engine is that for each platform you
>> require
>> > to adapt to a another IDE or build process. Unreal uses their own build
>> system,
>> > which can generate projectfiles/-solutions for various other build
>> systems
>> > (e.g. CMake) and IDEs. If QtCreator could integrate better with UE4
>> there
>> > would be a single IDE that works on all platforms.
>>
>> Sure, Creator is a great IDE and if Unreal sees value in having a nice
>> cross-platform IDE, then they are free to contribute or fork or do whatever
>> the license allows:-) I do not see why the Qt Project should do that work
>> though.
>>
>> > The official UE4 docs[1] already mention QtCreator
>>
>> Nice! I was not aware of that.
>>
>> > but if you take the time
>> > to look at the steps the integration is very weak. Changing a build
>> target,
>> > variant or platform means changing the builds steps by hand. This is one
>> > of the reasons people often recommend CodeLite for development on
>> > Linux because that IDE allows you to switch target and variant by using
>> > the drop down menus just like you would on Visual Studio.
>>
>> According to the documentation you link you should be able to switch
>> between debug/release via creator's UI just as well, once you did the
>> initial setup.
>>
>> > Is if there is willingness to add UE4 support in QtCreator
>>
>> I am willing to answer questions on build system integration into
>> Creator, but I do not plan to work on this myself.
>>
>> > or are there ways to improve the current integration?
>>
>> Nothing obvious. Maybe another supported build system would work better
>> than the half-baked .pro-file they ask you to load? I do not have UE around
>> to test, so I don't know.
>>
>> Best Regards,
>> Tobias
>>
>> --
>> Tobias Hunger, Senior Software Engineer | The Qt Company
>> The Qt Company GmbH, Rudower Chaussee 13, D-12489 Berlin
>> Geschäftsführer: Mika Pälsi, Juha Varelius, Mika Harjuaho. Sitz der
>> Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB
>> 144331 B
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20180303/4c2d5082/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: UE4-projectfiles.zip
Type: application/zip
Size: 169067 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20180303/4c2d5082/attachment.zip>


More information about the Qt-creator mailing list