A quesiton about "Warning: Object directory not changed from original" when executing "make" command

Nan Xiao nan at chinadtrace.org
Wed Jul 27 03:38:43 UTC 2016

Hi all,

I am writing a simple FreeBSD kernel module. But after rebooting machine (I am not sure whether this is the reason), 
I find the "make" command can't work, and it always prompts the following words:  

# make
Warning: Object directory not changed from original /root/hello

even though I delete and upload a new file, this issue still exists.

After referring this post (https://www.mail-archive.com/freebsd-hackers@freebsd.org/msg10678.html), I try "make obj"
command, then the "make" works: 

# make obj
/usr/obj/root/hello created for /root/hello
# make
@ -> /usr/src/sys
machine -> /usr/src/sys/amd64/include
x86 -> /usr/src/sys/x86/include

I can't figure out the root cause behind it:  
(1) Why does make complain "Warning: Object directory not changed from original /root/hello" although I have updated file?
(2) Why "make obj" can save "make"?

Thanks very much in advance!

Best Regards
Nan Xiao (肖楠)
Skype: xiaonan19830818
Jabber/XMPP: nanxiao at xmpp.ru.net 
Telegram: nanxiao
Personal website (Chinese): http://nanxiao.me/ 
Personal website (English): http://nanxiao.me/en 
Chinese DTrace website: http://chinadtrace.org/

More information about the freebsd-questions mailing list