Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 05-30-2012, 04:50 AM   #1
Registered: May 2012
Posts: 31

Rep: Reputation: Disabled
make error

I have written a simple kernel module with only init and exit modules.
When I fire make command I get the following error:

make -C /usr/src/linux-2.6.32 SUBDIRS=/home/LDD/LDD_Practice modules
make[1]: Entering directory `/usr/src/linux-2.6.32'

/bin/sh: cannot create /home/LDD/LDD_Practice/.tmp_versions/ldd1.mod: Permission denied

make[2]: *** [/home/LDD/LDD_Practice/ldd1.o] Error 2
make[1]: *** [_module_/home/LDD/LDD_Practice] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.32'
make: *** [default] Error 2

What might be the cause of it and how to resolve it?
FYI I have the root permissions.
Old 05-30-2012, 04:57 PM   #2
Senior Member
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: CentOS 6 (pre-systemd)
Posts: 2,838

Rep: Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755Reputation: 755
Running as root means you can change the permissions, it doesn't bypass them. You shoud run make as the owner of the directory not as root. Otherwise any files you create will not be owned by the directory owner which will cause problems.

This may help:
1 members found this post helpful.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Make file error code 1 make: *** [AIQ7] Error 1 raju39k Linux - Newbie 2 04-09-2012 02:22 PM
RH9 make menuconfig error: make[1]: *** [lxdialog] Error 1 rrochele Linux - Kernel 3 02-07-2007 04:39 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:16 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration