Issue #8256 has been reported by akr (Akira Tanaka).

----------------------------------------
Bug #8256: dependency to include/ruby/version.h
https://bugs.ruby-lang.org/issues/8256

Author: akr (Akira Tanaka)
Status: Open
Priority: Normal
Assignee: nobu (Nobuyoshi Nakada)
Category: build
Target version: 
ruby -v: ruby 2.1.0dev (2013-04-11 trunk 40246) [x86_64-linux]


??????????????????????in-place ??? ruby ??? build ?????????????
include/ruby/version.h ??????????? make ??????? version.o ?????????????????????

以???????include/ruby/version.h ????????????
????????? version.o ????????? include/ruby/version.h ??????????????????????????????
make version.o ????????????????
  gmake: `version.o' is up to date.
??????????????????????????????????(version.o ???????????????????????)

  % echo '/**/' >> include/ruby/version.h
  % ls -l version.o include/ruby/version.h
  -rw-r--r-- 1 akr akr   1870 Apr 11 23:54 include/ruby/version.h
  -rw-r--r-- 1 akr akr 206584 Apr 11 23:45 version.o
  % make version.o
  running CONFIG_SHELL=/bin/bash /bin/bash ./configure --prefix=/home/akr/ruby/tst6 CC=/home/src/gcc/bin/gcc --disable-install-doc --with-valgrind CPPFLAGS=-DRUBY_DEBUG_ENV optflags=-O0 debugflags=-save-temps=obj -g3 warnflags=-W -Wall -Wformat=2 -Wundef -Wno-parentheses -Wno-unused-parameter -Wno-missing-field-initializers --no-create --no-recursion
  checking build system type... x86_64-unknown-linux-gnu
  ...
  checking for nroff... /usr/bin/nroff
  .ext/include/x86_64-linux/ruby/config.h unchanged
  verconf.h unchanged
  ruby library version = 2.1.0
  configure: creating ./config.status
  MAKE=gmake /bin/sh ./config.status
  config.status: creating GNUmakefile
  config.status: creating Makefile
  config.status: creating ruby-2.1.pc
  Makefile unchanged
  MAKE=gmake /bin/sh ./config.status
  config.status: creating GNUmakefile
  config.status: creating Makefile
  config.status: creating ruby-2.1.pc
  Makefile unchanged
  gmake: `version.o' is up to date.
  % ls -l version.o include/ruby/version.h
  -rw-r--r-- 1 akr akr   1870 Apr 11 23:54 include/ruby/version.h
  -rw-r--r-- 1 akr akr 206584 Apr 11 23:45 version.o

gcc ??? -MM ????????????????? include ???????????????????調?????????
以???????????? include/ruby/version.h ??????????????????version.o ???
????????????????????????????????

  version.o: version.c verconf.h include/ruby/ruby.h \
   .ext/include/x86_64-linux/ruby/config.h include/ruby/defines.h \
   include/ruby/missing.h include/ruby/intern.h include/ruby/defines.h \
   include/ruby/st.h include/ruby/subst.h version.h include/ruby/version.h \
   revision.h

??????????common.mk ???以????????????include/ruby ???? version.h ???示?????
{$(VPATH)}version.h ?????????????????????????????
?????????????????????????????? version.h ???示?? $(srcdir)/version.h ?????????????????????

  version.$(OBJEXT): {$(VPATH)}version.c $(RUBY_H_INCLUDES) \
    {$(VPATH)}version.h $(srcdir)/version.h $(srcdir)/revision.h {$(VPATH)}config.h \
    verconf.h

??????? version.h ??????????????????????? include/ruby ???????????
??????????????????????????????????????
gmake ??? VPATH ????????????????????????????????????????????????????????
??????????????????? version.h ??????????????????????????????????????????????
????????? make -p ??? make ???読????????????????調?????確????????????

  % make -p |grep '^version.o'
  ...
  version.o: version.c version.c ./include/ruby/ruby.h .ext/include/x86_64-linux/ruby/config.h ./include/ruby/defines.h ./include/ruby/intern.h ./include/ruby/missing.h ./include/ruby/st.h ./include/ruby/subst.h version.h version.h revision.h .ext/include/x86_64-linux/ruby/config.h verconf.h .ext/include/x86_64-linux/ruby/config.h ./include/ruby/missing.h

?????????? version.h ????????????????{$(VPATH)}version.h ??? $(srcdir)/version.h ??両????
version.h ???????????????????????????????????????????

??????????version.h ??????????????????????????????????????????
????????????????????????????????????????? version.h ??? rename ??????????????????????????????????????????????
????????????????????

???????????????????? verdata.h ?????????????????????
RUBY_VERSION ?????????????????????義?????????????????

???????version.h ??????????????????????????????????????調????????????????????????????????




-- 
http://bugs.ruby-lang.org/