Im working on minix 3.2.1 . I just put a :
printf("hi");
command in do_mkdir -> open.c ,in many lines , so when i use mkdir 'name' command in shell it prints hi.
I put this printf inside :
mined /usr/src/servers/vfs/open.c in do_mkdir function
and i compile it with :
cd /usr/src/
make hdboot
and then i reboot. But it just make file, it wont print hi.
I tried compile with make install too.. but nothing.
I think its problem with compiling. Any idea?
Keep in mind that make hdboot is a command that you can use when you're in the usr/src/realeasetools directory. Therefore it's possible that your mistake is simply this. If however that's not the case, then there's a possibility that you're missing some tools. Apart from make install try to update your minix. ( I think the command is make update, not sure though)
Related
I want to create a fat library in mac. So I foll this. I copied the content of makefile into an edit text and renamed it to Makefile.mak. I opened the terminal in where the makefile is located and types "make" in the terminal and hit enter. I am getting an error that "Makefile is not found". What would be the reason for this? Where I made a mistake?
Please help me.
Thanks
Your makefile is incorrectly named. You need to rename your Makefile.mak back to 'makefile'; that's what the make command is looking for.
make looks for files with name GNUmakefile, makefile or Makefile. If you change your file's name to one of these, you can run it without a problem. If you still want to use that name, you must run the make with -f flag. Running command should be like this:
$make -f <file_name>
In your case:
$make -f Makefile.mak
I'm using #angular/compiler-cli to build my ng2 app in aot mode. When I input 'ngc -p tsconfig-aot.json' in my bash window, I get 'bash: ngc: command not found'. However, when I use 'node_modules/.bin/ngc -p tsconfig-aot.json' instead, it works. I googled for serval times but didn't get any usfull information. Can any give me a hand? Thx!
Seems like you need to put ngc in your path:
echo $PATH
Do you see ngc in binary in your path?
If not:
PATH=$PATH:/path/to/ngc
To make it permanent add to .bash_profile
export PATH=$PATH:/path/to/ngc
I've tried to change the slash to 'backslash' on windows and it worked for me:
node_modules\\.bin\ngc
If you don't want to set it globally, you can specify an absolut path in your angular-project, just make sure that you delete this part of the path when you don't use it anymore.
ngc is in node_modules/.bin, so depending on where you want to use ngc you can export the path like this:
PATH=$PATH:../../../node_modules/.bin
To run commands located into the node_modules folder of your project, without installing them globally (operation that will make the ngc command work in any system folder), you can use this command:
ngx ncc <options>
Basically ngx is a shortcut that executes any command located in node_modules bin folder.
I am trying to create my own homebrew formula using brew create and brew edit .
As part of the install for this project I need to change into a sub directory and build things there, for example
cd sub/dir/place
make -f makefile otherMakeTarget
I tried adding to my formula.rb
system "cd", "sub/dir/place/"
system "make", "etc"
But it doesn't seem to do the cd correctly. The logfile 01.cd shows the cd and the argument on two separate lines, I'm not sure if that's the problem.
Calling system creates a subshell and any modifications to the working directory go away when that call completes.
You could try using chdir:
Dir.chdir('sub/dir/place')
Another way to do it is to use a chdir block.
chdir "vendor" do
system "make", "install"
end
Ok so I've been trying to run some things from the command line and I'm having a 'permission denied' problem and then when I 'sudo ./(file.c' I get a 'command not found'. It's weird because other .c files in the same directory work ok.
I've downloaded and installed Xcode and command line tools. Also, I have #include some other things that are also in the same directory.
When I echo $PATH I'm getting this output:
/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
Thanks for any help that could be provided!
You're running sudo ./file.c but file.c looks like the name of a source code file which would usually not be executable. Probably the problem you're having is that you're trying to run something which cannot be run. If you really want to force the computer to run it, you can do chmod +x file.c before trying to run it. But if it is indeed C source code, it won't do anything useful.
Last week, when I am trying to install gcc_select on my macbook, I went through several commands,I did remember I just cd to a certain directory and made some modifications using the root. Everything seems fine, however, I found that when I open the terminal and trying to compile a program by using gcc or g++, it keeps saying that the "command not found".I have to manually to type the :" export PATH=$PATH:/Developer/usr/bin" in order to make the gcc or g++ command run.
My question is , is there anyone please tell me how to permanently change that, so that I don't need to type the same command again and again.
Append
export PATH=$PATH:/Developer/usr/bin
in the .profile file in your home directory. If it does not exit, create it. Better way would be the one user57368 gave in the comment though.