为什么在安装deb文件时文件丢失



我从源代码为Apache2构建了一个deb文件,而且我能够在我用来编译的机器上成功安装和运行。但是,当我将deb文件复制(SCP(到另一台机器并安装时,新安装的系统中缺少apache2的日志目录(/CloudS/Packages/apache2-cs/var/log/(。在这两种情况下,

使用命令dpkg-i file_name.deb 安装

有人能说出原因是什么吗?我该如何解决?

编译器:

root@compiler:/build/result# cd /CloudS/Packages/apache2-cs/
root@compiler:/CloudS/Packages/apache2-cs# ls
usr  var

另一台机器:

root@ubuntu-1cpu-1gb-de-fra1:~# ls /CloudS/Packages/apache2-cs/
usr
root@ubuntu-1cpu-1gb-de-fra1:~#

正如您所看到的,在另一台机器上安装相同的deb文件时,"var"目录丢失了。我使用以下配置来构建deb文件

./configure --enable-layout=Debian --prefix=/CloudS/Packages/apache2-cs --sysconfdir=/etc/apache2-cs --enable-rewrite=shared --enable-speling=shared --with-pcre --with-include-apr --with-include-aprutils --enable-load-all-modules --with-suexec-caller=cloudS-www --with-suexec-logfile=/var/log/apache2-cs/suexec.log --with-suexec-bin=/usr/lib/apache2-cs/suexec --with-suexec-docroot=/var/www --with-suexec-userdir=public_html --with-suexec-uidmin=100 --enable-suexec=shared --with-program-name=apache2-cs --enable-logio
make clean
make 
checkinstall --install=no --pakdir=/build/result/ 

checkinstall只检查make的作用,make不创建任何日志文件。您可以使用checkinstall--include选项强制在生成的包中添加路径。详见其手册页。

最新更新