I have been trying to install nachos 4.0 (c++ version), but on running the "make" command, I get the following error:
gcc -E -I../userprog -I../threads start.cc > _/strt.s
mips-xgcc/as -mips2 -o _/start.o /strt.s
make[1]: execvp: mips-xgcc/as: Permission denied
make[1]: * [/start.o] Error 127
make: * [all] Error 2
I also tried giving all the permissions to the mentioned folder (mips-xgcc), but to no avail.
Also I had doubts regarding running user-processes. There is a sample code in the test folder, which performs matrix multiplication. To run this program one needs to convert the binary which is .coff format to .noff format (where .coff is the format of any a.out file in linux). My doubt is that since the example code contains statements which are peculiar to the MIPS architecture (e.g: Exit(C[Dim-1][Dim-1]) in "matmult.c"), how can we first compile the program as normal gcc and then use coff2noff to convert it into ".noff" format.
Is it possible that user-level process doesn't run because of the error mentioned in "1."
Any help would be appreciated.
Thank You
Related
I bought an M1 Silicon with Monterey back in January and --- after a three+ month pause -- am trying again to get Rcpp running so I can install RStan. Following these instructions in response to (I'd like to just comment on this other issue, but being new to posting on Stack Overflow it tells me that I cannot and what I am about to post is certainly NOT an answer):
Configuring compilers on Mac M1 (Big Sur, Monterey) for Rcpp and other tools
While step 3 (installing gfortran) looks to go well, when I ask about gfortran things seem less hopeful:
-bash: gfortran: command not found
Or maybe this is not how to ask if all went well with the installation?
No matter, I charge on to step 4 installing from openmp-13.0.0-darwin21-Release.tar.gz based on:
Apple clang version 13.1.6 (clang-1316.0.21.2.3)
Target: arm64-apple-darwin21.4.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
I confirm that I have the files where expected, then create the .R directory and the Makevars file (in nano) then try to run the R and get ....
+ #endif
+ }
+ ')
/Users/lizzie/.R/Makevars:6: *** missing separator. Stop.
Error in Rcpp::sourceCpp(code = "\n#include <RcppArmadillo.h>\n#ifdef _OPENMP\n# include <omp.h>\n#endif\n\n// [[Rcpp::depends(RcppArmadillo)]]\n// [[Rcpp::export]]\nvoid omp_test()\n{\n#ifdef _OPENMP\n Rprintf(\"OpenMP threads available: %d\\n\", omp_get_max_threads());\n#else\n Rprintf(\"OpenMP not supported\\n\");\n#endif\n}\n") :
Error 1 occurred building shared library.
WARNING: The tools required to build C++ code for R were not found.
Please install Command Line Tools for XCode (or equivalent).
Any thoughts or ideas much appreciated. Again, I am new to posting to StackOverflow so apologize as I am sure I am doing this wrong.
I am trying to use scan-build to do static analysis for my project.
When I run the scan-build with single .cpp or .c file , it reports the bugs correctly.
But when I use with cmake/make , it always says No Bugs found.
Commands used:
scan-build --use-cc /usr/bin/gcc --use-c++ /usr/bin/c++ --keep-cc cmake -DCMAKE_C_COMPILER=/usr/bin/gcc -DCMAKE_CXX_COMPILER=/usr/bin/c++
scan-build -V -v -v --use-cc /usr/bin/gcc --use-c++ /usr/bin/c++ --keep-cc --force-analyze-debug-code -analyze-headers -stats --status-bugs --use-analyzer=/llvm-project/build/bin/clang-15 --analyzer-target --keep-going -enable-checker all checkers separated by comma -o reports path
Actual Output:
scan-build: Analysis run complete.
scan-build: Removing directory '/tmp/scan-build-' because it contains no reports.
scan-build: No bugs found.
Expected Output:
scan-build bugs with html reports
Single file output:
11: warning: Division by zero [core.DivideZero]
return 5/(x-x); // warn
~^~~~~~
1 warning generated.
scan-build: Analysis run complete.
scan-build: 1 bug found.
scan-build: Run 'scan-view /tmp/scan-build-' to examine bug reports.
I have tried all the other options mentioned in this forum, but nothing worked for me.
Tried below also,
export CCC_CC=clang
export CCC_CXX=clang++
Would be very helpful if someone provide exact options that can work and generate bugs with gcc/make.
On "./configure" of an open source project I get:
user agent OS = Linux
./configure: line 13957: syntax error near unexpected token 0.9.3'
./configure: line 13957: GOBJECT_INTROSPECTION_CHECK(0.9.3)'
make: *** [config.status] Error 2
Ubuntu 12.04 package "gobject-introspection" and "libgirepository1.0-dev" are present. Removing the GOBJECT_INTROSPECTION_CHECK line allows configure to complete, but the project fails a dependency later.
How can I get past this configure step cleanly? Googling for this issue shows bugs filed against numerous OS projects for this same blocking issue, but the usual answer is "install gobject-introspection".
As the OP discovered on his own he had to install the gobject-introspection package to get the m4 macros that were being used.
The error message has the raw macro in it, as configure scripts are generated from configure.in/configure.ac files via m4/etc the fact that the raw macro is in the output file indicates that the macro did not get translated at generation time.
The gobject-introspection m4 files were apparently installed after autogen.sh (or equivalent) was run to generate the configure script. Re-running the autogen.sh script should regenerate the configure script and run the macro correctly.
I am new to the R programming language and am having basic issues with it. I want to untar a file, but it has not been able to work for me.
Here is the code that I enter:
untar("CD_data.tar", exdir="data")
It then returns the following error message:
/bin/sh: /usr/bin/gnutar: No such file or directory
Warning message:
In untar("CD_data.tar", exdir = "data") :
‘/usr/bin/gnutar -xf 'CD_data.tar' -C 'data'’ returned error code 127
Please help! Thanks!
R on OS X 10.9 (Mavericks) seems to set a wrong TAR environment variable.
You can fix this by adding the following to your .Rprofile (or executing it manually):
Sys.setenv(TAR = '/usr/bin/tar')
Alternatively, you can provide the tar path as an argument when calling untar.
My 2 cents is that you are using a mac and have not installed tar. You are getting value 127 because the command is not found within your $PATH and it's not a built-in command (which is usually the case if you were in unix...
In other words you need to install tar.
Or run it in linux.
I am trying to install frama-c in cygwin and get the following errors but I can't interpret them. Can you help me interpreting them or give me a link to where I get the information?
Preparing Wp-Coq Sources
Uncaught exception: Util.UserError("_", _)
Makefile:49: recipe for target `depend' failed
make[1]: *** [depend] Error 2
src/wp/Makefile:285: recipe for target `.make-wpcoqs' failed
make: *** [.make-wpcoqs] Error 2
note that coqc and ocaml are both the latest version
Are you using Coq 8.4 by any chance? I had something very similar happen to me, and my issue was the lack of the option -coqlib <your Coq installation directory> when Coq is not installed in the standard directory in the PATH. There used to be a specific error message in Coq 8.3, but it seems to have disappeared in Coq 8.4.
If you can find the line in the Makefile which runs the coqdep command, and replace it with something like coqdep -coqlib ~/coq84pl1 (replacing ~/coq84pl1 with your Coq installation directory), it could work. But you would also need to add this flag to other Coq-related commands as well (coqc, for instance) or other issues might come up later.