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"

Compile Unreal with gcc and system STL for linux

I am trying to compile Unreal with gcc and system STL(not the unreal provided STL i.e UNREAL STL). I only have to support for Linux:

 1. Can anyone suggest a version of gcc and c++ version to use.
 2. Will unreal run smoothly if I use system STL instead of UNREAL STL.
 3. Will this configuration also work on windows 10.
Product Version: UE 4.15
Tags:
more ▼

asked Jul 21 '17 at 11:05 PM in Linux

avatar image

RajZoox
61 1 9 8

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

1 answer: sort voted first

Could you tell a bit more what is the problem are you trying to solve?

BTW, there's no "Unreal STL", you are perhaps referring to libc++ bundled with the engine. You can switch to default libstdc++ by setting an environment variable UE4_LINUX_USE_LIBCXX to 0. However before doing that - what is the problem that is causing you to consider that?

Compiling with gcc is harder. UBT still contains remnants of gcc support, but we have not attempted it in quite a while. However, I have heard of licensees who were able to compile the engine with gcc, albeit with rather extensive changes to the code base.

more ▼

answered Jul 21 '17 at 11:25 PM

avatar image

RCL STAFF
2.7k 59 6 88

avatar image RajZoox Jul 21 '17 at 11:36 PM

I have a code base which I am trying to port to linux from windows and in the process I am finding it hard to compile it to linux.

We have few pre-compiled libs with no access to source code. These libs expose their public interface in terms of default libstdc++(i.e parameters are passed as std::string). When compiling unreal on linux with clang and unreal bundled stl, I get linking errors. So, this is the reason I want to compile unreal with gcc and default STL.

avatar image RCL STAFF Jul 22 '17 at 12:00 AM

Try just switching from libc++ to libstdc++. clang and gcc are largely compatible so it is unlikely that you will run into further linking errors.

Keep in mind that bundling libstdc++ is risky and you need to consult a lawyer if you decide to bundle it. If you don't bundle it with the resulting binary, you need to make sure that the users will not run it on a system where an incompatible version of libstdc++ is installed.

(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