=====================================================================
配置:
lenovo
product: Intel(R) Core(TM) i5-3470 CPU @ 3.20GHz
64 bits
8G内存
OS:Ubuntu 12.04.1 LTS (GNU/Linux 3.2.0-29-generic x86_64)
======================================================================
公司搭建了一些编译服务器,这些服务器平常事不连接外网,只限于局域网内,时常有安装新软件的需求。去Ubuntu packages 下载下来后使用dpkg -i 安装,但是有时候需要一些依赖,容易出错,于是在source.list中添加本。
1.创建本地包目录:
mkdir -p /var/cache/apt/localdeb
2.添加source.list precise就是ubuntu 12.04的版本
mv sources.list sources.list.net
vim sources.list.local
#use local deb
#ln -s sources.list.net sources.list
#use initnet
#ln -s sources.list.local sources.list
deb file:///var/cache/apt/localdeb precise main
ln -s sources.list.local sources.list
/etc/apt# apt-get install gitweb
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package gitweb is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
git
E: Package 'gitweb' has no installation candidate