Permission denied error when running simple c++ program - c++

I get this error almost everytime i try to run a simple code on CLion.
I'm not trying to save the project in c drive.
c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot open output file A__IQ_test.exe: Permission denied
collect2.exe: error: ld returned 1 exit status
CMakeFiles\A__IQ_test.dir\build.make:95: recipe for target 'A__IQ_test.exe' failed
mingw32-make.exe[3]: * [A__IQ_test.exe] Error 1
mingw32-make.exe[2]: [CMakeFiles/A__IQ_test.dir/all] Error 2
CMakeFiles\Makefile2:66: recipe for target 'CMakeFiles/A__IQ_test.dir/all' failed
mingw32-make.exe[1]: [CMakeFiles/A__IQ_test.dir/rule] Error 2
CMakeFiles\Makefile2:78: recipe for target 'CMakeFiles/A__IQ_test.dir/rule' failed
mingw32-make.exe: * [A__IQ_test] Error 2
Makefile:117: recipe for target 'A__IQ_test' failed

This usually means your program is already running. You can't replace it with a new one while it's running. Ensure you've closed your program before you try to rebuild it. If you think you've done so, there may be a bug where it is hanging — attach your debugger to find out.

Related

unable build project in STM32 AC6

While i am building a project in STM32 AC6 software, I got the message 'building finished', but i am not able to run or debug due to the missing of binaries.The error code is as follows.Please help me
arm-none-eabi-gcc: error: CreateProcess: No such file or directory
make: * [startup/startup_stm32f334x8.o] Error 1
startup/subdir.mk:18: recipe for target 'startup/startup_stm32f334x8.o' failed
make: * Waiting for unfinished jobs....
make: *** [src/syscalls.o] Error 1
src/subdir.mk:24: recipe for target 'src/syscalls.o' failed
check that your project path does not contain any signs "-" or spaces " ", it is mostly the raison.

Using Clang to get function definitions

I would like use clang to get the functions names from a cpp file.
I found some tutorials but always I received this error when I executed 'make':
/usr/bin/ld: error: ../../lib/libLLVMSelectionDAG.a: ELF section name out of range
collect2: error: ld returned 1 exit status
tools/lto/CMakeFiles/LTO.dir/build.make:269: recipe for target 'lib/libLTO.so.7.0.0svn' failed
make[2]: * [lib/libLTO.so.7.0.0svn] Error 1
CMakeFiles/Makefile2:18957: recipe for target 'tools/lto/CMakeFiles/LTO.dir/all' failed
make[1]: * [tools/lto/CMakeFiles/LTO.dir/all] Error 2
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2
Any idea of how can I solve this problem or any tutorial?
Thanks in advance.
I solved the problem increasing the /dev/sda1 size and removing the file ../../lib/libLLVMSelectionDAG.a
After that I only executed 'make' and It worked.

Emscripten cpuid.h

Edit: Im trying to generate LLVM from a c++ project, not build the LLVM system itself.
I'm trying to build LLVM through emscripten, but I need the header 'cpuid.h'.
/home/emsdk-portable/emscripten/1.37.21/build/project/main.cpp:35:10: fatal error: 'cpuid.h' file not found
#include <cpuid.h>
^~~~~~~~~
1 error generated.
ERROR:root:compiler frontend failed to generate LLVM bitcode, halting
CMakeFiles/project.dir/build.make:86: recipe for target 'CMakeFiles/project.dir/main.cpp.o' failed
make[2]: *** [CMakeFiles/project.dir/main.cpp.o] Error 1
CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/project.dir/all' failed
make[1]: *** [CMakeFiles/project.dir/all] Error 2
Makefile:116: recipe for target 'all' failed
make: *** [all] Error 2
According to this github cpuid.h should exist (Shouldn't it?) with the included clang, but neither I nor the program itself is finding it for the include.
Fastcomp is the default backend and as such I thought cpuid.h should be locateable by whatever my program is.
Any ideas on finding/fixing the problems? Thanks

open cv install not working properly

when i am doing make in /opencv/build directory it is working upto some extent after that it is showing this kind of error what should i do
Linking CXX executable ../../bin/opencv_test_core
CMakeFiles/opencv_test_core.dir/test/ocl/test_arithm.cpp.o: file not
recognized:
File truncated collect2: error: ld returned 1 exit status modules/core
/CMakeFiles/opencv_test_core.dir/build.make:824: recipe for target 'bin/opencv_test_core' failed make[2]: * [bin/opencv_test_core]
Error 1 CMakeFiles/Makefile2:1421: recipe for target
'modules/core/CMakeFiles/opencv_test_core.dir/all' failed make[1]: *
[modules/core/CMakeFiles/opencv_test_core.dir/all] Error 2
Makefile:147: recipe for target 'all' failed make: *** [all] Error 2
Your problem is most likely here:
CMakeFiles/opencv_test_core.dir/test/ocl/test_arithm.cpp.o: file not recognized: File truncated
Delete the object (.o) file and rerun. The make call was probably interrupted before which caused the object file to be truncated.

Install external C++ libraries into Clion for a C++ project under Windows 7

I am new to Clion and C++ and your help is highly appreciated!!
My goal was to download a library to solve Ordinary Differential Equations.
The zip file was downloaded from http://headmyshoulder.github.io/odeint-v2/downloads.html
and unzipped in D:\myProjects\odeint. I use Windows 7 and MinGW.
The library can't be used as shown in the following image.
Here are the error reports.
D:\myProjects\main.cpp:3:51: fatal error: odeint/include/boost/numeric/odeint.hpp: No such file or directory
compilation terminated.
CMakeFiles\myProjects.dir\build.make:61: recipe for target 'CMakeFiles/myProjects.dir/main.cpp.obj' failed
mingw32-make.exe[3]: *** [CMakeFiles/myProjects.dir/main.cpp.obj] Error 1
CMakeFiles\Makefile2:66: recipe for target 'CMakeFiles/myProjects.dir/all' failed
mingw32-make.exe[2]: *** [CMakeFiles/myProjects.dir/all] Error 2
mingw32-make.exe[1]: *** [CMakeFiles/myProjects.dir/rule] Error 2
CMakeFiles\Makefile2:78: recipe for target 'CMakeFiles/myProjects.dir/rule' failed
mingw32-make.exe: *** [myProjects] Error 2
Makefile:117: recipe for target 'myProjects' failed