サポート #4032
ソースからインストールした時のヘッダのタイムスタンプ
100%
Description
ソースからビルドしてインストールするとインストールされたヘッダのタイムスタンプはインストールした時のタイムスタンプになるようです。
そのためOpenRTMをインストールすると、実際には変更がなくてもOpenRTMに変更があったとみなされ、OpenRTMに依存するソフトウェアをビルドするとすべてコンパイルし直しになってしまいます。
インストール時にファイルのタイムスタンプを維持するようにはできないでしょうか。
Associated revisions
[compat,build] Adding -C/-p option to header install command. refs #4032
[compat,build] Adding -C/-p option to header install command. refs #4032
[compat,build] Adding -C/-p option to header install command. refs #4032
[compat,build] Adding -C/-p option to header install command. refs #4032
[compat,build] Adding -C/-p option to header install command. refs #4032
merged changes from trunk/OpenRTM-aist r3017, 3019, 3025-3026, 3028, 3030, 3032-3033 during 2017-08:
[compat,->RELENG_1_2] Support for 'stretch' has been added. refs #4164
[compat,->RELENG_1_2] Support for 'stretch' has been added. refs #4165
[compat,document,->RELENG_1_2] Doxyfile has been updated with the setting of doxygen 1.8.3.
[compat,build,->RELENG_1_2] Adding C/-p option to header install command. refs #4032>RELENG_1_2] Adding
[compat,build,C/-p option to header install command. refs #4032>RELENG_1_2] Output tag file name has been added to doxyfile. refs #3969
[compat,document,
[compat,document,->RELENG_1_2] Conf file generation in Makefile.am has been modified. refs #4173
[compat,document,->RELENG_1_2] Deleting unnecessary comment and tag files. refs #4173
merged changes from trunk/OpenRTM-aist r3017, 3019, 3025-3026, 3028, 3030, 3032-3033 during 2017-08:
[compat,->RELENG_1_2] Support for 'stretch' has been added. refs #4164
[compat,->RELENG_1_2] Support for 'stretch' has been added. refs #4165
[compat,document,->RELENG_1_2] Doxyfile has been updated with the setting of doxygen 1.8.3.
[compat,build,->RELENG_1_2] Adding C/-p option to header install command. refs #4032>RELENG_1_2] Adding
[compat,build,C/-p option to header install command. refs #4032>RELENG_1_2] Output tag file name has been added to doxyfile. refs #3969
[compat,document,
[compat,document,->RELENG_1_2] Conf file generation in Makefile.am has been modified. refs #4173
[compat,document,->RELENG_1_2] Deleting unnecessary comment and tag files. refs #4173
History
#1 Updated by n-ando almost 6 years ago
- Status changed from 新規 to 解決
- Target version set to RELEASE_1_2_0
- % Done changed from 0 to 100
install-sh/install コマンド実行時に、-Cオプションまたは-pオプションを追加する必要がある。
- install-sh: autoconf/autoreconf が生成するinstallコマンドの代替
- install: システムに標準で含まれるコマンド
タイプスタンプを保持するためのオプションとして -Cと-pがある。
-C ファイルをコピーします。コピー先ファイルがすでに存在しかつ内容が
同一である場合には、ターゲットの修正時刻を変更しません。-p 修正時刻を保存します。 -C (比較してコピー) オプションが指定された
場合のようにコピーを行いますが、ターゲットファイルが存在しないも
しくは内容が異なる場合、ファイルの修正時刻を保存します。
-Cの場合は、コピー先にファイルがない場合、インストールした時間のタイムスタンプでファイルがコピーされるので、十分でない。
オプションとしては-pの方がふさわしいが、install-shには-pは実装されておらず、-pを常に指定することはできない。
したがって、installコマンドの有無を調べ、存在すれば-pオプションを使用、出なければ-Cを使用するようにconfigure.acを変更した。
dnl Adding -C/-p option to header install command
install_exists=`which install`
if test "x$install_exists" = "x" ; then
AC_SUBST([INSTALL_HEADER], ['${INSTALL} -c -C -m 644'])
else
AC_SUBST([INSTALL_HEADER], ['${INSTALL} -c -p -m 644'])
fi
以上で、元のヘッダのタイムスタンプが保持された。
#2 Updated by kanehiro almost 6 years ago
ありがとうございます。
trunkへの修正適用のようですが、RELENG_1_1等には反映されない感じでしょうか。
#3 Updated by n-ando almost 6 years ago
RELENG_1_1でお使いになりたいのでしたら、そちらも変更しておきます。
#4 Updated by kanehiro almost 6 years ago
1.2がリリースされるまではRELENG_1_1を使うつもりですので、そちらにも反映して頂けますと助かります。
#5 Updated by n-ando almost 6 years ago
承知しました。いま、検証中ですので、問題なければbranches/RELENG_1_1にコミットします。
#6 Updated by n-ando almost 6 years ago
- Status changed from 解決 to 終了
RELENG_1_1,trunkともにコミットしました。これにて終了といたします。
[compat,build] Adding -C/-p option to header install command. refs #4032