简体   繁体   English

如何防止在 Linux 中通过 make 进行重建?

[英]How prevent rebuilding via make in Linux?

I have built package in cross enviroment (via using make command) on server.我在服务器上构建了跨环境的包(通过使用make命令)。 Package build was successful.包构建成功。 I want run make check natively on target architecture, use command to copy build directory on target machine我想在目标架构上本地运行make check ,使用命令在目标机器上复制构建目录

rsync -a -H -A -X libssh2-1.4.0 user@machine:/path/to/package/libssh2-1.4.0

Also, I sync time on server and target machine.另外,我在服务器和目标机器上同步时间。

On the target machine I execute make check .在目标机器上我执行make check But all sources are rebuilt, as if the building had not been performed before.但所有的源头都是重建的,就好像之前没有进行过建造一样。 How can I prevent this rebuilding?我怎样才能防止这种重建?

Some dependency files were newer than the target.一些依赖文件比目标文件新。 For example, stdio.h (dep file) was newer than channel.lo (target).例如,stdio.h(dep 文件)比 channel.lo(目标)更新。 Stdio.h is placed in fakeroot and copyed by me without preserving time attrs. Stdio.h 被放置在 fakeroot 中并由我复制而不保留时间属性。 After copy with preserving attrs libssh2 stopped rebuilding.使用保留属性复制后,libssh2 停止重建。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM