FATAL ERRORS with compilation after installing Aspose.Cells library for C++ - c++

Can someone please help me with my issue with Aspose.Cells library for C++?
I was writing my first C++ programme using Aspose.Cells library. Everything seemed smooth except that the following error was produced after I built the file:
Error before I launch is:
"Error exist in a required project.Continue launch?"
Error after running the code is:
"**fatal error: boost/config/compiler/gcc.hpp: No such file or directory**".**
If I commented out the line #<include Aspose.Cells.h>, the file can run with no errors.
I tried to solve the error by installing Boost library for C++ from zip file "boost_1_73_0", as I think Aspose depends on Boost to run. However, I couldn't link to Boost successfully as there doesn't seem to be a "include" folder and "lib" folder for me to add into project properties.
My questions are:
Will installing Boost solve my problem?
If yes, how can I install Boost library successful?
The following is my code in C++. Thanks a Lot in advance!
#include <iostream>
#include <Aspose.Cells.h>
using namespace std;
int main() {
cout << "!!!I am little red!!!" << endl;
return 0;
}
Regards
Hillary
UPDATE: I have successfully installed and linked Boot library now but I have got three warning message upon building: "Ignoring #pragma warning [-wunknown-pragmas]" , are these warning messages serious?
I also ran into another fatal error: unicode/uloc.h:No such file or directory. How can I correctly link up to unilib-master/Unicode library?

Yes, installing Boost helps.
If Aspose only requires header-only libraries from Boost, then you don't have to do much. The "include" path you're looking for is just the folder where you extracted the zip. The actual library headers are under boost/ in that folder, which are then found by the compiler.
If you need the shared libraries, you will need to build them. Follow the steps here Getting Started On Windows

Related

Fatal Error: comdef.h: No such file or directory

I installed Aspose.Cells and tried to write a simple C++ file that includes Aspose.Cells.h. I soon realized that I had to install two other external libraries, boost and icu4c as without these libraries my compiler would throw errors saying some h or hpp files can not be found.
My problem is: even after I installed these libraries, I still couldn’t compile my code, as I received a new error saying “Fatal ERROR: comdef.h: No such file or directory.”
And the error persisted even after I installed the latest version for SDK for Win 10.
My simple file can run if I remove the line "#include Aspose.Cells.h" .
Can someone please enlighten me as to how to solve this error?
Also I noticed there is a folder called “Publish” under “include” folder for Aspose.Cells. This folder is besides boost and icu. Could this mean Publish is the third external library to be installed? But I couldn’t find any library called Public on the web. Pls see the screenshot below.
directory of include folder that comes with the installed Aspose.Cells package
Thanks a lot!
My code is as follows:
#include <iostream>
#include <Aspose.Cells.h>
using namespace std;
int main() {
cout << "hello!!!" << endl;
return 0;
}
Regards
Hillary

LINK : fatal error LNK1181: cannot open input file 'opencv_world341d.lib'

I have found two similar questions this and this .
But they both use opencv, and opencv indeed provide the corresponding lib. I don't use opencv, and my project is very simple, just hello world.I have changed project default configuration like this
except for these configurations, others all take defaults
I just want to test my project configuration,that works find for win32 debug and release. But not work for x64 debug and release, they all tell me LINK : fatal error LNK1104: cannot open file 'opencv_world341d.lib'
I indeed know my project does not use any opencv lib, but why they tell me I need to use opencv_world341d.lib
my code
#include<iostream>
using namespace std;
int main()
{
cout << "hello world" << endl;
}
Thanks for everyone who comments on the question. I have solved the problem, although this problem not relevant to OpenCV to much, but I think the solution to the problem may be helpful to others. When I build project, visual studio 2019 tell me cannot link opencv_world341d.lib, so I go to Project->Properties->Linker->Input->Additional Dependencies , and I found opencv_world341d.lib. So I need to remove it, but it's readonly. From this we know visual studio using settings file (Microsoft.cpp..users.props) to control global settings including Global search path. These files are located at $(USERPROFILE)\appdata\local\microsoft\msbuild\v4.0 directory. Then I reedit Microsoft.cpp.<Platform>.users.props, delete opencv_world341d.lib, reboot visual studio, problem solved.

Linking native WebRTC application with Visual Studio

So my goal is to build a native WebRTC application using the WebRTC C++ api.
I compiled webrtc for use with Visual Studio (2015) using the following guide:
https://github.com/ipop-project/ipop-project.github.io/wiki/Building-the-WebRTC-lib-for-Windows
After the build completed I tried creating a new Visual Studio console project and added the following code:
#include <iostream>
#define WEBRTC_WIN
#include <webrtc/api/peerconnection.h>
#include <webrtc/api/peerconnectionfactory.h>
#include <webrtc/api/peerconnectioninterface.h>
int main()
{
auto pcf = webrtc::CreatePeerConnectionFactory();
std::cout << "Hallo!" << std::endl;
}
Adding the build directory to the include search path works fine, however I'm unable to link the application, searching the build directories for lib-files and adding them to the linker only adds more link error as there is a whole bunch and I suspect some of them should not be linked to my application.
What is the correct way to link the application, and how do I know what .lib-files the functionality I use resides in?
I solved it!
After digging around in the build files for the examples in WebRTC I found that the following libraries should be linked:
obj\webrtc\api\libjingle_peerconnection.lib
obj\webrtc\system_wrappers\field_trial_default.lib
obj\webrtc\system_wrappers\metrics_default.lib
obj\third_party\jsoncpp\jsoncpp.lib
obj\webrtc\media\rtc_media.lib
obj\webrtc\base\rtc_base_approved.lib
obj\webrtc\webrtc_common.lib
obj\webrtc\webrtc.lib
obj\webrtc\system_wrappers\system_wrappers.lib
obj\webrtc\voice_engine\voice_engine.lib
obj\webrtc\common_audio\common_audio.lib
obj\third_party\openmax_dl\dl\openmax_dl.lib
obj\webrtc\common_audio\common_audio_sse2.lib
obj\webrtc\modules\audio_coding_module.lib
obj\webrtc\modules\cng.lib
obj\webrtc\modules\audio_encoder_interface.lib
obj\webrtc\modules\g711.lib
obj\webrtc\modules\pcm16b.lib
obj\webrtc\modules\ilbc.lib
obj\webrtc\modules\webrtc_opus.lib
obj\third_party\opus\opus.lib
obj\webrtc\modules\g722.lib
obj\webrtc\modules\isac.lib
obj\webrtc\modules\audio_decoder_interface.lib
obj\webrtc\modules\isac_common.lib
obj\webrtc\modules\red.lib
obj\webrtc\rtc_event_log.lib
obj\webrtc\rtc_event_log_proto.lib
protobuf_lite.dll.lib
obj\webrtc\modules\neteq.lib
obj\webrtc\modules\builtin_audio_decoder_factory.lib
obj\webrtc\modules\audio_decoder_factory_interface.lib
obj\webrtc\modules\rent_a_codec.lib
obj\webrtc\modules\audio_conference_mixer.lib
obj\webrtc\modules\audio_processing.lib
obj\webrtc\modules\audioproc_debug_proto.lib
obj\webrtc\modules\audio_processing_sse2.lib
obj\webrtc\modules\webrtc_utility.lib
obj\webrtc\modules\media_file.lib
obj\webrtc\base\rtc_task_queue.lib
obj\webrtc\modules\audio_device.lib
obj\webrtc\modules\bitrate_controller.lib
obj\webrtc\modules\paced_sender.lib
obj\webrtc\modules\rtp_rtcp.lib
obj\webrtc\common_video\common_video.lib
libyuv.lib
obj\third_party\libjpeg_turbo\libjpeg.lib
obj\webrtc\modules\remote_bitrate_estimator.lib
obj\webrtc\voice_engine\level_indicator.lib
obj\webrtc\modules\congestion_controller.lib
obj\webrtc\modules\video_capture_module.lib
obj\webrtc\modules\video_processing.lib
obj\webrtc\modules\video_processing_sse2.lib
obj\webrtc\modules\webrtc_video_coding.lib
obj\webrtc\modules\webrtc_h264.lib
obj\webrtc\modules\webrtc_i420.lib
obj\webrtc\modules\video_coding\utility\video_coding_utility.lib
obj\webrtc\modules\video_coding\codecs\vp8\webrtc_vp8.lib
obj\third_party\libvpx\libvpx.lib
obj\third_party\libvpx\libvpx_intrinsics_mmx.lib
obj\third_party\libvpx\libvpx_intrinsics_sse2.lib
obj\third_party\libvpx\libvpx_intrinsics_ssse3.lib
obj\third_party\libvpx\libvpx_intrinsics_sse4_1.lib
obj\third_party\libvpx\libvpx_intrinsics_avx.lib
obj\third_party\libvpx\libvpx_intrinsics_avx2.lib
obj\webrtc\modules\video_coding\codecs\vp9\webrtc_vp9.lib
obj\webrtc\p2p\rtc_p2p.lib
obj\webrtc\base\rtc_base.lib
boringssl.dll.lib
obj\third_party\usrsctp\usrsctplib.lib
obj\webrtc\modules\video_capture_module_internal_impl.lib
obj\third_party\winsdk_samples\directshow_baseclasses.lib
obj\webrtc\pc\rtc_pc.lib
obj\third_party\libsrtp\libsrtp.lib
winmm.lib
dmoguids.lib
wmcodecdspuuid.lib
amstrmid.lib
msdmo.lib
crypt32.lib
iphlpapi.lib
secur32.lib
Strmiids.lib
The document you linked to, says you need the following libraries:
boringssl.dll.lib
boringssl_asm.lib
field_trial_default.lib
jsoncpp.lib
rtc_base.lib
rtc_base_approved.lib
rtc_p2p.lib
rtc_xmllite.lib
rtc_xmpp.lib
I would link against all of them. It's unlikely to hurt.
There is a precompiled (binary) package available for Windows: here.
It contains a single lib to link, libwebrtc_full.lib

Missing cyg*.dll when using libraries compiled with Cygwin, and errors when added

I just compiled zlib and libzip with Cygwin to use them with Code::Blocks in Windows.
My code is that:
#include <iostream>
#include <zip.h>
int main()
{
//Open the ZIP archive
int err = 0;
zip *z = zip_open("main.zip", 0, &err);
zip_close(z);
std::cout << "Hello world!" << std::endl;
return 0;
}
When I build my code, it works well, no errors and warnings.
When I launch my program, it says that I don't have cygzip-2.dll. Okay, I search it and put it in my executable folder. Then, it says that I don't have cygwin1.dll. Okay, I put it too. The same for cygz.dll and cyggcc_s-1.dll.
Oh, it works! But then, my program stops with always the same status: -1073741819.
It doesn't even tell me hello :(
I compiled it with MinGW (it did the same error on Cygwin), and I linked libz.a, libzip.a and libzip.dll.a. Where does the problem could come from?
Thanks!
EDIT: When I try to compile my program IN Cygwin, it says 'undefined reference to '_zip_open'' and 'undefined reference to '_zip_close''. Probably something is missing, but what?
Eventually, I succeeded to use my 2 libraries! I had already tried to use CMake, but failed miserably.
So today, I decided to retry it with the GUI. Firstly, I compiled zlib. I chose the zlib folder, and put the build folder in it. I configured with the option for Code::Blocks and MinGW Makefiles, and native compilers. Then, I opened the .cbp (Code::Blocks Project) in my 'build' folder, and built it.
For libzip, I did the steps except that I specified 2 variables:
ZLIB_INCLUDE_DIR = the root of zlib folder (where there are all the .h and .c) and ZLIB_LIBRARY = [the path to your build folder from zlib]\libzlib.dll
I built it from the .cbp too. And I linked all my files to my project, and it was done!

Boost compilation error with python

I'm new to the boost C++ library and I'm trying to use boost with python. Whenever I compile my simple test program I get an error:
error: pyconfig.h: No such file or dirctory
(followed by thousand more errors which I'm sure are because of this missing header).
I downloaded boost from it's website and then built the library. I still have no idea why that file is missing and how to get it. Please help!
I'm using code::blocks MinGW compiler and I have pointed code blocks to the boost folder as a search directory for headers as well as libraries.
Here's my simple program:
#include <boost/python.hpp>
using namespace boost::python;
int main()
{
Py_Initialize();
PyRun_SimpleString("from time import time,ctime\n"
"print ’Today is’,ctime(time())\n");
Py_Finalize();
return 0;
}
You apparently do not have the CPython headers in your include path. Just having boost::python is not enough, you need Python itself, too.