fatal error: QScriptEngine: No such file or directory - blackberry-10

I am working on blackberry project when i include
#include <QScriptEngine>
in my .cpp file it gives be error
fatal error: QScriptEngine: No such file or directory
can any one tell what should i include in .pro file so that i can get rid of this error .

Try replacing it with
#include <QtScript/QScriptEngine>
The qt4 include dir should be on your include path by default as long as you have CONFIG += qt somewhere in your pro file. So my guess is you just need to qualify where QScriptEngine is beneath the qt4 dir (which is inside QtScript dir).

Related

Problems to recompile a UE4 plugin

I am trying to recompile the Dialogo System plugin (https://forums.unrealengine.com/t/dialogue-system/44974) and I can't do it at all. I've tried several ways, including those suggested by the forum staff, but there's no way
This the error message I am getting:
Running C:/Program Files/Epic
Games/UE_4.26/Engine/Binaries/DotNET/UnrealBuildTool.exe Development
Win64 -Project="D:/Simulation/unreal/MyProject/MyProject.uproject"
-TargetType=Editor -Progress -NoEngineChanges -NoHotReloadFromIDE Invalidating makefile for MyProjectEditor (DialogueSystem.Build.cs
modified) #progress push 5% Parsing headers for MyProjectEditor
Running UnrealHeaderTool
"D:\Simulation\unreal\MyProject\MyProject.uproject"
"D:\Simulation\unreal\MyProject\Intermediate\Build\Win64\MyProjectEditor\Development\MyProjectEditor.uhtmanifest"
-LogCmds="loginit warning, logexit warning, logdatabase error" -Unattended -WarningsAsErrors -abslog="C:\Users\renat\AppData\Local\UnrealBuildTool\Log_UHT.txt" -installed Reflection code generated for MyProjectEditor in 4,3286771 seconds #progress pop
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTComposite_Context.cpp(1):
error: Expected BTComposite_Context.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTComposite_Question.cpp(1):
error: Expected BTComposite_Question.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTComposite_QuestionGroup.cpp(1):
error: Expected BTComposite_QuestionGroup.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTContextNode_Interface.cpp(1):
error: Expected BTContextNode_Interface.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTDialogueFunctionLibrary.cpp(1):
error: Expected BTDialogueFunctionLibrary.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTTask_CloseDialogue.cpp(1):
error: Expected BTTask_CloseDialogue.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTTask_ShowPhrases.cpp(1):
error: Expected BTTask_ShowPhrases.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\BTTask_WaitAnswer.cpp(1):
error: Expected BTTask_WaitAnswer.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\DialogueButton.cpp(1):
error: Expected DialogueButton.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\DialogueEventListener.cpp(1):
error: Expected DialogueEventListener.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\DialogueSettings.cpp(1):
error: Expected DialogueSettings.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\DialogueSystemModule.cpp(1):
error: Expected DialogueSystemModule.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Private\QuestBook.cpp(1): error: Expected QuestBook.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\BehaviorTreeEditor\QuestionCustomization.cpp(1):
error: Expected QuestionCustomization.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\BehaviorTreeEditor\ShowPhrasesCustomization.cpp(1):
error: Expected ShowPhrasesCustomization.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\QuestBookEditor\QuestBookEditor.cpp(1):
error: Expected QuestBookEditor.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\QuestBookEditor\QuestBookEditorCommands.cpp(1):
error: Expected QuestBookEditorCommands.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\QuestBookEditor\QuestBookEditorCustomization.cpp(1):
error: Expected QuestBookEditorCustomization.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\DialogueSystemEditorModule.cpp(1):
error: Expected DialogueSystemEditorModule.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\DialogueSystemStyle.cpp(1):
error: Expected DialogueSystemStyle.h to be first header included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\QuestBookAssetTypeActions.cpp(1):
error: Expected QuestBookAssetTypeActions.h to be first header
included.
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystemEditor\Private\QuestBookFactory.cpp(1):
error: Expected QuestBookFactory.h to be first header included.
Building MyProjectEditor... Using Visual Studio 2019 14.27.29111
toolchain (C:\Program Files (x86)\Microsoft Visual
Studio\2019\Community\VC\Tools\MSVC\14.27.29110) and Windows
10.0.19041.0 SDK (C:\Program Files (x86)\Windows Kits\10). Building 13 actions with 12 processes... #progress 'Compiling C++ source
code...' 0% #progress 'Compiling C++ source code...' 8% [1/13]
Default.rc2 #progress 'Compiling C++ source code...' 15% [2/13]
Default.rc2 #progress 'Compiling C++ source code...' 23% [3/13]
PCH.DialogueSystem.cpp
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Classes\BTTask_ShowPhrases.h(7):
fatal error C1083: It1s not possible to open file include: 'Widget.h':
No such file or directory
Please, some help. I really need to use this plugin to produce a demonstration of my project.
You could try what the log is suggesting and change the order of the includes. I suppose you're using a c++ project. Sometimes the order does matter.
Also check if the plugin is added in the dependecies list in the build.cs file. This file is located inside your project source folder. You will see that in the file there is already a dependecies list and you should include the plugin name in the list and build again.
BTComposite_Context.cpp(1): error: Expected BTComposite_Context.h to be first header included.
Taking this one as an example it looks like the .cpp files have been either corrupted or modified in a way. In general when you have a .cpp file you'll want it to start with the same header file as the first include. So open one of these files and see whether or not it starts with something like
#include BTComposite_Context.h
My guess since it looks to be an old plugin it probably improperly starts with something like
#include Engine/Core.h
D:\Simulation\unreal\MyProject\Plugins\UE4-DialogueSystem-master\Source\DialogueSystem\Classes\BTTask_ShowPhrases.h(7): fatal error C1083: It1s not possible to open file include: 'Widget.h': No such file or directory
This error is actually what's causing you not to be able to compile. Likely because Widget.h has been moved in a future version of UE4 compared to what it was when this plugin was made almost 7 years ago.
Try changing from #include Widget.h to #include "Components/Widget.h"
If you look at Widget.cpp in the engine source you can see this is now the correct include path that is expected.

source_sink `appl' does not exist

I have this line in a project (the project was not created by me, but it is a university project)
:- [appl], assert(max_id(333)).
when i try to compile in eclipse with the ProDT plugin it gives me this error:
source_sink `appl' does not exist
What does the line of code mean? And what about the error now?
Assuming a appl.pl file does exists in the project, most likely your current directory is not the directory of the file. Either use a full path to load the file (e.g. ['/full/path/to/appl']) or change directory first to the directory of the file (using the cd/1 predicate; e.g. cd('/some/path/'), [appl]).
To find the current directory, use the pwd/0 predicate:
?- pwd.

How are the libraries .h files included

I have successfully generated Objc .m and .h files from my simplistic Dagger-2 code.
https://gist.github.com/OscarRyz/ffd976fcae9acf87dbe1
Now I'm trying to compile those file using j2objcc but the error message says it can't find .h for the the Dagger-2 classes:
j2objcc -c -I. `find app -name *.m`
In file included from app/DaggerSearchComponent.m:10:
./app/SearchInPage_Factory.h:10:10: fatal error: 'dagger/internal/Factory.h' file not found
#include "dagger/internal/Factory.h"
^
1 error generated.
app/SearchComponent.m:11:10: fatal error: 'dagger/Component.h' file not found
#include "dagger/Component.h"
^
1 error generated.
In file included from app/SearchInPage_Factory.m:8:
./app/SearchInPage_Factory.h:10:10: fatal error: 'dagger/internal/Factory.h' file not found
#include "dagger/internal/Factory.h"
^
1 error generated.
In file included from app/SearchInPage_MembersInjector.m:9:
./app/SearchInPage_MembersInjector.h:10:10: fatal error: 'dagger/MembersInjector.h' file not found
#include "dagger/MembersInjector.h"
^
1 error generated.
app/SearchModule.m:10:10: fatal error: 'dagger/Module.h' file not found
#include "dagger/Module.h"
^
1 error generated.
In file included from app/SearchModule_ProvideHostFactory.m:8:
./app/SearchModule_ProvideHostFactory.h:10:10: fatal error: 'dagger/internal/Factory.h' file not found
#include "dagger/internal/Factory.h"
^
1 error generated.
In file included from app/SearchModule_ProvideHttpClientFactory.m:9:
./app/SearchModule_ProvideHttpClientFactory.h:10:10: fatal error: 'dagger/internal/Factory.h' file not found
#include "dagger/internal/Factory.h"
^
1 error generated.
Question: Does this means that I need to have the library source code while generating the ObjC code so the .h for those could be generated as well?
Original answer from #tabll
Dagger isn't distributed with j2objc, so you have to build it yourself. To do so (requires Maven, described in the Building J2ObjC wiki):
git clone https://github.com/google/dagger.git
cd dagger
mvn install
j2objc -d build -classpath $J2OBJC_HOME/lib/javax-inject.jar -sourcepath core/src/main/java `find core/src/main/java -name *.java`
cd build
j2objcc -c -I. `find dagger -name *.m`
ar -r libdagger.a *.o
Notes:
Specify J2OBJC_HOME either where your j2objc distribution was unzipped, or if you built j2objc, its dist directory. To test, "ls $J2OBJC_HOME/j2objc" should list the j2objc script.
These instructions generate the macosx architecture, useful when testing. The files need to be recompiled for each architecture you want to use -- the easiest way to do so is to create a static library project in Xcode, add the translated files, then include this project in your app and add it as a dependency of your app.
ar will warn that "libdagger.a(package-info.o) has no symbols", which can be ignored since it doesn't have any symbols.

mex compiler could not find include path in .h files

Hi I'm using MEX in Matlab.
The c code uses boost and a lot of headers are included.
And at first my problem is like this
>>mex readTrackletsMex.cpp
readTrackletsMex.cpp
e:\kitti\tools\devkit\matlab\tracklets.h(7) : fatal error C1083: can not open include file:“boost/serialization/nvp.hpp”: No such file or directory
This is because the include path is not specified. So I copied the headers into "/include/boost/XX" and added "-I" flag.
This time it seems that the compiler cannot find the include path in one of the header file.
>> mex -Iinclude readTrackletsMex.cpp
readTrackletsMex.cpp
include\boost/serialization/nvp.hpp(21) : fatal error C1083: can not open include file:“boost/config.hpp”: No such file or directory
Any idea on this? How do I specify a "global" include path for the compiler?
Thanks for your time.
You could try adding the include paths to the environment variables C_INCLUDE_PATH and CPLUS_INCLUDE_PATH. The other issue may be that you put in -Iinclude, and not -I/include

matlab to c++: Cannot open include file: 'mclmcrrt.h': No such file or directory

We tried to complie the m file to c++ file by matlab complier. We had the file bulit but we got the error msg as follow.
fatal error C1083: Cannot open include file: 'mclmcrrt.h': No such file or directory
Do you have any ideas about the error msg? Any suggestion will be appreciated. Thanks a lot.
Ying
This error message is caused because you need MCR dlls.
You should locate the h file in "C:\Program Files (x86)\MATLAB\MATLAB Compiler Runtime\v715\extern\include\"
and add it to your include path in C.
Check out the manual of Matlab compiler.