I really need your help. I just purchased a new laptop, it has windwos 8 operating system, and I am trying to practice my c++ code, but it gives me error and doesn't output. Please help...
Here is what I get when I run simple "Hello world" program.
||=== Build: Debug in codeblocks_testing (compiler: GNU GCC Compiler) ===|
ld.exe||cannot find -lsndfile|
ld.exe||cannot find -lglew|
||=== Build failed: 2 error(s), 0 warning(s) (0 minute(s), 2 second(s)) ===|
Thanks in advance,
Related
I found a code in internet in order to read the serial number from a USB pen drive. It uses the windows API. I use MINGW, compiler on Codeblocks ide.
There are two API:
CoUninitialize();
and
CoCreateInstance(CLSID_WbemLocator, 0,
CLSCTX_INPROC_SERVER, IID_IWbemLocator, (LPVOID *) &pLoc);
that are defined on comebaseapi.h,that I included, but the compiler cannot find the reference :
||=== Build: Debug in Dongle (compiler: GNU GCC Compiler) ===|
obj\Debug\clHw.o||In function `clHw::~clHw()':|
C:\Users\jurha\Documents\codeblocksprojects\Dongle\clHw.cpp|39|undefined reference to `__imp_CoUninitialize'|
obj\Debug\clHw.o||In function `clHw::GetWbemService(IWbemServices**)':|
C:\Users\jurha\Documents\codeblocksprojects\Dongle\clHw.cpp|86|undefined reference to `__imp_CoCreateInstance'|
||error: ld returned 1 exit status|
||=== Build failed: 14 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
I found on stackoverflow that I have to link ole32.dll, but Codeblocks allow me to link only .lib, so I search for ole32.lib, I copied it and pasted in the same folder of the project and I linked it, but than it gives me the follow error:
||=== Build: Debug in Dongle (compiler: GNU GCC Compiler) ===|
ld.exe||cannot find -lOle32.Lib|
||error: ld returned 1 exit status|
||=== Build failed: 2 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
It cannot find the library.
Someone can help me
I just tried to setup freeglut in my codeblocks 20 64-bit pre-packaged mingw-gnu-compiler, following popular youtube tutorials,
I created the glut project in codeblocks, and tried to compile, it gives error
||=== Build: Debug in SnakeGame (compiler: GNU GCC Compiler) ===|
ld.exe||cannot find -lfreeglut|
||error: ld returned 1 exit status|
||=== Build failed: 2 error(s), 0 warning(s) (0 minute(s), 3 second(s)) ===|
What's wrong?
I have installed code blocks on Windows 10, before that I installed GCC Cygwin compiler.
In Settings > Toolchain executables section I set up C compiler, C++ compiler,
linker to dynamic libs to use gcc.exe, the compiler's directory is set as C:\cygwin64.
I tried to run a dummy hello world program to make sure it works but got the following error:
||=== Build: Debug in dummy2 (compiler: Cygwin GCC) ===|
\Users\abc\OneDrive\ミミクミケ ムath\dummy2\main.c"||No such file or directory|
||error: no input files|
||=== Build failed: 2 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
I used to use min gw compiler and it worked fine, but once I switched to cygwin it started to throw errors.
It looks like this part of the file directory is garbled, cant figure out why.
OneDrive\ミミクミケ ムath\
Please let me know what can be a problem here.
Cheers.
I’m new to C++, only experienced in Java so far, so please be precise with the answers.
I translate the error from German to English, so they might not match the English counterpart.
I was trying to set up the IDE Codeblocks on Ubuntu, and tried to test it with a simple Hello World program.
Trying to "Build and run" the program caused two errors in the build log:
"-------------- Build: Debug in TestProject (compiler: GNU GCC Compiler)---
g++ -Wall -std=c++11 -g -c /home/marcel/Dokumente/Dokumente/Privat/Udemy/C++/Übung/TestProject/src/Main.cpp -o obj/Debug/src/Main.o
g++ -o bin/Debug/TestProject obj/Debug/src/Main.o
g++: error: obj/Debug/src/Main.o: File or directory not found
g++: fatal error: no input files
compilation terminated.
Process terminated with status 1 (0 minute(s), 0 second(s))
2 error(s), 0 warning(s) (0 minute(s), 0 second(s))"
I tried to look it up, but most people seemed to have more problems than just these two files. None of their Solutions worked.
So far I've wasted a few days trying to fix it, so I thought I would ask here.
Recently i installed Code Blocks, done all the linking after that i build and run the program it comes out error with "Process Terminated With Status 127". i tried several ways to solve it like build-essential, g++ but still can't solve it, please help`
-------------- Run: Release Win32 in DeepNeuralNetwork (compiler: GNU GCC Compiler)---------------
Checking for existence: /media/rnd/4F3D93242E986B7F/DeepNeuralNetwork/DeepNeuralNetwork/DeepNeuralNetwork
Executing: /media/rnd/4F3D93242E986B7F/DeepNeuralNetwork/DeepNeuralNetwork/DeepNeuralNetwork (in /media/rnd/4F3D93242E986B7F/DeepNeuralNetwork/DeepNeuralNetwork/.)
Process terminated with status 127 (0 minute(s), 0 second(s))
`