x

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"

How can I add a ThirdParty library so that it compiles when I compile my game?

I want to implement an existing library in my game. However, the tricky part is I also want to compile it when I compile my game. This way I can modify the source from a single instance of Visual Studio.

I tried the module approach, but I just have to modify too much of the core library files before it even compiles. I've been snooping inside the ThirdParty library of the engine and found batch files for (for example) libPNG ((UE4_BuildThirdPartyLib), which will compile the library as the engine gets compiled (AutomationScripts are run during Visual Studio compile. right?)

Is there something similar, or a different approach, for me to add my existing library to the build-process of my game, without having to first compile .lib files, make them into a plugin?

Product Version: Not Selected
Tags:
more ▼

asked May 17 '14 at 11:42 PM in C++ Programming

avatar image

LennardF1989
235 17 19 22

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

Did you see this ? UE3 Wiki - Linking Static Libraries Using The Build System ?

I followed that, digged a bit into my Build.cs and found it worked really well.

If afterwards you still have issues , please specify which part and I'll try to help.
There is also already a ton of similar questions in this AnswerHub , i.e. here

more ▼

answered May 20 '14 at 02:50 AM

avatar image

Chrys
301 21 27 42

avatar image lostcosmonaut Apr 19 '16 at 07:42 PM

This person isn't asking about linking static libraries but including the source code so they can be built.

(comments are locked)
10|2000 characters needed characters left

I ended up creating a separate project which compiles and places the libs in the appropriate places, then defined a Build.cs file with Type set to External.

I then modified my includepaths of my game project and pointed it at the source directory of the library. You can now debug the library and step through the code. Only recompilation has to be done using the other project.

more ▼

answered May 21 '14 at 04:58 PM

avatar image

LennardF1989
235 17 19 22

avatar image darkZ Feb 21 '16 at 06:54 PM

Is it possible to share what project settings were for your external library ? I can't seem to link a debug library with my UE4 code even when I compile it in DebugGame mode. It only seems to accept a Release version of my external library for linking. This prevents me from stepping through the code of the external library...

avatar image lostcosmonaut Apr 19 '16 at 07:53 PM

Was this to get unreal to cross compile to all platforms?

(comments are locked)
10|2000 characters needed characters left
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