mpicxx: Command not found - linux

I am very new to linux. I am trying to build lammps open source software with user defined modules that require to build mpi executable on opensuse leap 15.1.
lammps - https://lammps.sandia.gov/doc/Build_make.html
It showed an error: mpicxx xommand not found.
after searching i did "sudo zypper in gcc-c++" and tried again.
same error
so I did "export PATH=$PATH:/usr/lib64/mpi/gcc/openmpi/bin"
and make mpi was successful and it built lmp_mpi executable but when i tried to run with lmp_mpi it showed following error:
error while loading shared libraries: libmpi_cxx.so.1: cannot open shared object file: No such file
so I wrote "export PATH=$PATH:/usr/lib64/mpi/gcc/openmpi/bin" in my bashrc file and ran again make mpi and tried again same error is shown.
I tried by installing mpich2 with yast same error is shown.
Then I tried by installing openmpi as shown here http://edu.itp.phys.ethz.ch/hs12/programming_techniques/openmpi.pdf
When I tried to build mpi again same error "mpicxx: Command not found error" and also when I open terminal following lines are written already.
bash: /home/surya/.bashrc: line 1: syntax error near unexpected token newline'
bash: /home/surya/.bashrc: line 1:export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/opt/openmpi/lib >'
Someone please help me I have been trying this for long time.
Thanks for the suggestions.

Related

How to resolve error in debugging a program in totalview?

I installed TotalView on Ubuntu. For the begining I just tried to debug a very simple Hello Word program in but I got the following error:
"Fatal Error: Can't set up library cache directory -- cannot debug this target. Do you want to run the TotalView Diagnostic Tool?"
I don't know what is the library cache directory. Any idea about the library cache directory in ubuntu can be helpful.

Can Execute Commands in Terminal But Not from Text File

I'm running code using Ubuntu on a WSL. Every time I edit some C files I need to execute a makefile and run an installer to ensure that the changes are reflected in the python package that I am using. The set of commands I need to execute is
make clean
make
cd python
python setup.py install --user
This works perfectly when I execute them in the terminal. In order to make my life easier, I decided to put these commands in a text file Compile.txt to be executed whenever I need to compile the relevant files. I found this question and tried to replicate its solution. However, whenever I type ./Compile.txt into the terminal I get the error
'. Stop. No rule to make target 'clean
gcc -o .o
gcc: fatal error: no input files
compilation terminated.
make: *** [<builtin>: .o] Error 1
./Compile.txt: line 7: cd: $'python\r': No such file or directory
python: can't open file 'setup.py': [Errno 2] No such file or directory
Can anyone explain what I've done wrong? I apologise for any misuse of terminology as I'm still quite new to Linux.
Thanks in advance.

Getting 'Permission Denied' error trying to generate Doxygen documentation

I am trying to run the doxygen command (I'm using Windows 10 with Cygwin and the packages Doxygen, Graphviz and the g++ compiler installed with it) and, at the end of the execution, I get the following error:
Error: Could not open "/cygdrive/c/Users/alexl/Desktop/src/DOC/html/graph_legend.png" for writing: Permission denied
error: Problems running dot: exit code=1, command='dot', arguments='"/cygdrive/c/Users/alexl/Desktop/src/DOC/html/graph_legend.png" -Tpng -o "/cygdrive/c/Users/alexl/Desktop/src/DOC/html/graph_legend.png"'
I also get sixteen other warnings with the following structure:
Warning: Cannot open file <filename>.png for writing
I've been searching for hours why this may occurr. I've tried running command prompt as an administrator, but the error still persists. Any help would be greatly appreciated.

Error at Remote Debugging in Eclipse

I am trying to debug an application remotely in Eclipse. When I start debugging, the application is deployed and the gdbserver is started on the target. This seems to work automatically without any mistakes, but then following error occurs:
'Launching helloworld Build(GNU)' has encountered a problem.
Could not determine GDB version using command: /usr/bin/gdb --version
When I expand <<Details in Eclipse this is shown:
Could not determine GDB version using command: /usr/bin/gdb --version
Fatal Python error: Py_Initialize: Unable to get the locale encoding
ImportError: No module named 'encodings'
In a console on the target /usr/bin/gdb --version is showing me the version and when I open a Python shell I can import encodings without errors.
Does anybody know where this error comes from? I wasn't sure about how to tag this question since I have no clue in which area the solution will be.
What I tried so far:
In Eclipse/Debug Configurations: Commands to execute before application: Several export commands to Python.
Same in /etc/profile.
bitbake -e python | grep "^PACKAGES=" : Inserted every python package into my image recipe via IMAGE_INSTALL_append.
[...]

MiXiM building no such file or directory error

I failed to build the MiXiM on Ubuntu 14.04.3 and OMNet 4.6, the error message is: ”fatal error: Mac80211Pkt_m.h: No such file or directory”. From the manual of OMNet it can be found that the file Mac80211Pkt_m.h should be generated automatically by the compiler during the building process, but it was shown by the error message that the file was not generated automatically. I am confused about the problem, how can I solve this? Can anyone help me? Thanks!
I faced the same error message. Here is how I bypassed the problem:
Extract "mixim-2.3.tar.gz" (tar xvzf mixim-2.3.tar.gz)
Change into the directory just extracted (cd mixim-2.3)
Execute "make makefiles"
Start the build by "make"
Import the just built project using the omnet++ IDE

Resources