Announcement

Collapse
No announcement yet.

4.7 SQLiteSupport - Bug?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    4.7 SQLiteSupport - Bug?

    I'm trying to use the SQLiteSupport module.
    I added as a dependency module for my game module. I'm able to use it in my code, but when I compile my game I get this error:

    Code:
    error C1083: Cannot open include file: 'SQLiteSupportPrivatePCH.h': No such file or directory	Engine\Source\Runtime\SQLiteSupport\Public\SQLiteDatabaseConnection.h
    What is happening is that SQLiteDatabaseConnection.h is in the module's Public folder and is including SQLiteSupportPrivatePCH.h that is in the module's Private folder. So in build time it's not found.
    I tried by adding the following code to SQLiteSupport.Build.cs

    Code:
    PrivateIncludePaths.Add("Runtime/SQLiteSupport/Private");
    But still, it won't find the header.

    I had to change SQLiteDatabaseConnection.h from:
    Code:
    #include "SQLiteSupportPrivatePCH.h"
    to:

    Code:
    #include "Runtime/SQLiteSupport/Private/SQLiteSupportPrivate.PCH"
    and managed to compile my project that way.

    But it's odd. Why is Epic trying to import the private header without adding the private include path to the module Build.cs?
    Why it's not working by adding the private include path?

    What I'm doing wrong?

    #2
    I am able to exactly reproduce this behavior, albeit with a different workaround. Since the SQLiteSupportPrivatePCH.h header has only a single line (#include "SQLiteSupport.h"), I think you can safely replace all instances of the former with the latter. That being said, this shouldn't be required. Can we get an official word on if this is a bug?

    Comment


      #3
      I should note that although I am able to compile, I still get the following linker error:
      Code:
      LINK : fatal error LNK1181: cannot open input file 'C:\Program Files\Epic Games\4.7\Engine\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-SQLiteSupport.lib'
      Indeed the mentioned library does not exist, but I have no idea what is supposed to create it, or when. Help here would also be appreciated.

      Comment


        #4
        I think you should add the head file dir to the head file search path.

        Comment


          #5
          Originally posted by Captian View Post
          I think you should add the head file dir to the head file search path.
          I tried using "PrivateIncludePaths.Add("Runtime/SQLiteSupport/Private")" to SQLiteSupport.Build.cs but it didn't work.

          Anyway now I'm gettinng the same linker error as sirrus233. This linker error appeared with 4.7.1 hotfix (worked well with 4.7.0). It's really strange because once I get the linker error I recompile again and it works perfectly. If I change any code and compile again the error comes up.
          I'm rebuilding the engine, lets see if that creates the lib.
          Last edited by Sveitar; 03-03-2015, 05:14 PM.

          Comment


            #6
            I'm pretty sure the linker error going away after a recompile is due to a screw up in Visual Studio's dependency resolution for the build. The code shows no changes, so VS doesn't even try to recompile or link anything. Doing a clean build (or as you said, making a change and building) consistently produces the linker error.

            Comment


              #7
              Thanks guys for spotting this! I've posted my answer here https://answers.unrealengine.com/que...#answer-185268. If you have more questions please move the discussion there.

              Thanks,
              Jarek

              Comment


                #8
                We hope this plugin can help you.

                HiSQLite3 (SQLite3 For UE4)
                Our email: yehaike@foxmail.com or841660657@qq.com
                UE4 C++ Plugins:
                1. "iLocalPlayer4UE4": Side-by-Side Stereo 3D implementing; Asymmetric projection(or named asymmetric view frustum) implementing.
                2. "QRCode Generator For UE4": This plugin is used to generate QRCode (Two Dimensional Code) in real time in UE4 Game.
                3. "LevelController": This UE4 C++ plugin lets you could transform UE4 Levels(Maps) at Runtime in Realtime.

                Comment

                Working...
                X