Compile and Execute QxORM qxBlog example - c++

I'm actually in a project in which I use Qt and I need to use an ORM. I found QxORM. In the process of getting started with this ORM, I need to be able to compile and execute the qxBlog example provided with it. I have thoroughly followed
the QxORM installation tutorial : http://www.qxorm.com/qxorm_en/tutorial_3.html
the qxBlog example test tutorial http://www.qxorm.com/qxorm_en/tutorial_1.html
But when I execute the project (qxBlog) with QtCreator, I get this error
C:\Users\HP\dev\libraries\qxorm\QxOrm_1.4.2\test\qxBlog\include\precompiled.h:4: erreur : C1083: Cannot open include file: 'QxOrm.h': No such file or directory
Following this error, I compiled the QxORM library with all its dependencies to get the qxormd.dll and put either in bin or lib folder (that I created) but it didn't work.
Can anyone help me with this issue?
Thanks in advance!
I have changed the "#include " line in precompiled.h to "#include <../../include/QxOrm.h>" (relative path to QxOrm.h file) but I still get a similar error because of the includes in that file (QxOrm.h).
C:\Users\HP\dev\libraries\qxorm\QxOrm_1.4.2\include\QxOrm.h:58: erreur : C1083: Cannot open include file: 'QxPrecompiled.h': No such file or directory
I don't want to put the QxORM library in the same folder as the project. How can I successfully include Qxorm.h with all its dependencies without putting the entire library in the same folder as my project ?
Thanks in advance !
Thanks for you answer. I have added an include path in my .pro file. I get no such previous errors. Nevertheless, I get this error
"LNK1104: cannot open file 'QxOrmd.lib'"
Can anyone help me with this?
Thanks in advance.

I found an answer to my question with #drescherjm help.
All I had to do was to add an include path to my .pro file. I did it by adding the following line :
INCLUDEPATH += ../../../QxOrm/include/

Related

How to add own c++ header file in electron?

I'm new to electron and want to call c++ dll, that works fine. I now want to know how to add my own header file in electron. I tried root dictionary and some other deeper place, but only got:
fatal error C1083: cannot open file: “MyDriver.h”: No such file or directory [c:\Users\75803\Documents\GitHub\native_addon\node_modules\hello\build\hello.vcxproj
Any help will be appreciate!
OP worked this out by himself.
Solution is to put the custom header file in the folder
iojs-(yoour electron version)/src

How to place header and ui file in different folders using autouic in cmake

According to the documentation, regarding autouic:
If a preprocessor #include directive is found which matches ui_.h, and a .ui file exists, then uic will be executed to generate the appropriate file.
But what if the .ui file is in another folder? I currently get the following error when trying to build:
AUTOUIC : error : process for ui_module.h failed:
File 'C:/app/source/headers/module.ui' is not valid
The ui file is actually located here:
C:/app/source/forms/module.ui
I've tried to add the C:/app/source/forms/ to the include_directories()-macro without success. Any ideas?
Issue mentioned in this answer is now resolved.
This worked in CMake v3.9.0-rc6:
set(CMAKE_AUTOUIC_SEARCH_PATHS your/folder/here)
See documentation of AUTOUIC_SEARCH_PATHS.
Update
A search path, CMAKE_AUTOUIC_SEARCH_PATHS, has been added to CMake
version 3.9.
After further investigation, it seems like it's not possible to do. There is an open issue in their tracking system, but it is so far not implemented:
Add Search path for AUTOUIC

compiler error - opencv2/highgui.hpp: No such file or directory

I am a "very" beginner of OpenCV. I just downloaded it for my Windows and extracted.
I have read this post: http://opencv-srf.blogspot.ro/2011/09/capturing-images-videos.html about how to read webcam and I copied and pasted the code in a C++ file I created in "include" folder of OpenCV extracted archive.
When I try to run the program I get this error: Error in: /opencv/build/include/opencv2/highgui/highgui.hpp - opencv2/highgui.hpp: No such file or directory.
What should I do?
Thank you all!
EDIT
I opened: "/opencv/build/include/opencv2/highgui/highgui.hpp" and I can see that it includes this path "opencv2/highgui.hpp". If I change it to "../highgui.hpp" it works but I get other errors like this for other files... What should I do?
The problem is that you are not supposed to create your "cpp" file in the OpenCV "include" directory. You need to create it in a separate directory and then add OpenCV "include" as additional include directory for the compilation step.
The way to achieve this depends on your C++ development environment. If you are using Visual Studio, then you need to open project property pages, go to "C/C++ -> General" and add the path to OpenCV "include" directory to "Additional Include Directories". In case of some other compiler/IDE, you can find out how to do this by reading the corresponding documentation.

fatal error C1083 : Cannot open include file: 'mexutils.h': No such file or directory

I would like to compile a c++ file as a mex file in MATLAB namely: "mexLasso.cpp".
These are the steps I take and I get the following error. What is the problem?
1. Put the files "mexLasso.cpp" and "mexutils.h" in a folder.
2. Set the compiler:
mex -setup C++
I recieve:
MEX configured to use 'Microsoft Visual C++ 2013 Professional' for C++ language compilation.
3. Run the command:
mex C:\...\mexLasso.cpp
I recieve the following error:
Error using mex
mexLasso.cpp
C:\...\mexLasso.cpp(33) : fatal error C1083: Cannot
open include file: 'mexutils.h': No such file or directory
Can somebody help us what we are missing?
From the mex command line tool reference, there is an argument for adding include paths:
-Ipathname Adds pathname to the list of folders to search for #include files.
Do not add a space between I and pathname.
Like this:
mex -v -IC:\path\to\mexutils_h\ mexLasso.cpp
Note that with -I you are not specifying the header, you are specifying a path containing one or more header files.
Thanks for your comments. I think the besy way to solve my problem is to install SPAMS in my machine and successfully compile it. I have posted the steps I take in this post :
How to install SPAMS toolbox in Matlab 2014b under windows 8.1
Can I have your opinion there. Sorry for duplicated message, only for relevancy and importance of the discussed topic.
Many thanks.

Error running Opencv sample code

I am starting with OpenCV on my new laptop, but there are some errors. I followed all the steps mentioned in the OpenCV tutorials in doc directory. But the sample code just does not work. This is the error:
">c:\users\ankit\documents\visual studio 2010\projects\test\test\test.cpp(7):
fatal error C1083: Cannot open include file: 'opencv2/imgproc/imgproc.hpp':
No such file or directory
1>
1>Build FAILED."
I am working on Win7 64 bit machine. I have already included Additional directories and libraries in Property Page. Still it gives me this error. Help.
You obviously entered a wrong include directory. Navigate to included directory and make sure that it contains file opencv2/imgproc/imgproc.hpp.
Update:
Here's error doc. See all the causes.
Update #2:
About your new issue.