Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Packaging plugin fails

I'm currently trying to package a C++ plugin I wrote. The plugins compiles fine in DebugGame_Editor, Development, and Shipping (inside VS2017) but when I click on the Package button, i got this error:

 UATHelper: Package Plugin Task (Windows):     C:\Program Files\Epic Games\UE_4.20\Engine\Source\Runtime\Core\Public\Core.h(6): warning: Monolithic headers should not be used by this module. Please change it to explicitly include the headers it needs.
 UATHelper: Package Plugin Task (Windows):     C:\Users\Stagiaire\Documents\Unreal Packages\DeltatecMedia\HostProject\Plugins\DeltatecMedia\Source\GPUResourcesSharing\Public\GPUResourcesSharing.h(14): fatal error C1083: Cannot open include file: 'Array.h': No such file or directory

I use PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs; in my module .Build.cs (As it is possible that this information is useful).

Why is there a problem? If you have any pointers, please share them.

Product Version: UE 4.20
more ▼

asked Apr 08 '19 at 10:20 AM in Packaging & Deployment

avatar image

25 3 3 6

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Ok it seems to be a little more clear now. I re-read the documentation about IWYU and I finally understand what to do.

For anyone having the same error, begin every header file with the include of CoreMinimal.h and then after that remove all the Engine.h, Core.h (and other include that trigger the error). You can change them directly by the special header you want to include. If you need to access GEngine or other globals inside Engine.h include Engine/Engine.h to make the differences between the two.

EDIT: For most header to be included, it is not just Filename.h, it is more like SubModule/Filename.h. These can be found easily by search this page. At the bottom of the page for a particular class, you can find the module and the header to use.

For example to include AActor.h it is required to include "GameFramework/Actor.h" as shown in the picture below.

alt text

I hope this will help.

api-iwyu.png (98.0 kB)
more ▼

answered Apr 09 '19 at 08:49 AM

avatar image

25 3 3 6

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question