Android FrameWork Package packagename has no installation candidate,androidpackagename
Ubuntu 下載編譯FrameWork 源碼的時候,apt-get 跑不起來,嘗試擷取根許可權 進行如下操作apt-get update apt-get
upgrade 錯誤提示依舊出現,源提示各種 404 我查看 Ubuntu 官網,看到了如下資料:
Ubuntu Night( http://ubuntu9.com ) 的Top mirror功能根據當前的網路情況和源健康情況不斷地進行更新當前可用的源的資訊,包括了Top fast/near/stable mirror,可以找到當前網路上所有可用的Ubuntu 鏡像(即源),並按照平均下載速度和地理位置進行排名。而且,當你找到最適合你的源之後,還可以直接下載它的sources.list 檔案,並可直接將它copy到/etc/apt/sources.list或者放在/etc/apt/souces.list.d目錄下,非常的方便,無須苦苦找可用源。
不同的網路狀況串連以下源的速度不同, 建議在添加前手動驗證以下源的連線速度(ping下就行),選擇最快的源可以節省大批下載時間
首先我們需要備份一下我們之前的源列表檔案,cp to 目錄可選,這裡只做參考
sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup
我的 Ubuntu 版本比較低,對此我選擇了適合自己的源(10.04)
deb http://archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ lucid-proposed main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ lucid-proposed main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
其他還有很多的源資源就不一一介紹了,接下來我們需要添加源和更新源:
sudo gedit /etc/apt/sources.list
把剛才找到的新的源全部替換掉,就是把之前的全部清掉,粘貼完後儲存
sudo apt-get update
sudo apt-get upgrade
......
Get:32 http://archive.ubuntu.com lucid-updates/restricted Sources [2,210B]
Get:33 http://archive.ubuntu.com lucid-updates/universe Sources [110kB]
Get:34 http://archive.ubuntu.com lucid-updates/multiverse Sources [5,829B]
Get:35 http://archive.ubuntu.com lucid-proposed/main Packages [236kB]
Get:36 http://archive.ubuntu.com lucid-proposed/restricted Packages [28B]
Get:37 http://archive.ubuntu.com lucid-proposed/universe Packages [5,379B]
Get:38 http://archive.ubuntu.com lucid-proposed/multiverse Packages [28B]
Get:39 http://archive.ubuntu.com lucid-proposed/main Sources [137kB]
Get:40 http://archive.ubuntu.com lucid-proposed/restricted Sources [28B]
Get:41 http://archive.ubuntu.com lucid-proposed/universe Sources [1,031B]
Get:42 http://archive.ubuntu.com lucid-proposed/multiverse Sources [28B]
Get:43 http://archive.ubuntu.com lucid-backports/main Packages [16.9kB]
Get:44 http://archive.ubuntu.com lucid-backports/restricted Packages [14B]
Get:45 http://archive.ubuntu.com lucid-backports/universe Packages [55.7kB]
Get:46 http://archive.ubuntu.com lucid-backports/multiverse Packages [1,378B]
Get:47 http://archive.ubuntu.com lucid-backports/main Sources [9,162B]
Get:48 http://archive.ubuntu.com lucid-backports/restricted Sources [14B]
Get:49 http://archive.ubuntu.com lucid-backports/universe Sources [24.5kB]
Get:50 http://archive.ubuntu.com lucid-backports/multiverse Sources [1,633B]
Fetched 14.7MB in 5min 14s (46.6kB/s)
耗時5分多,我把源給更新完了,我 Ping 了下 net 發現還行,下載速度應該很贊
下了一個 curl 包:
root@ubuntu:/etc/apt# sudo apt-get install curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
curl
0 upgraded, 1 newly installed, 0 to remove and 1177 not upgraded.
Need to get 210kB of archives.
After this operation, 324kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com lucid-security/main curl 7.19.7-1ubuntu1.11 [210kB]
Fetched 210kB in 6s (33.9kB/s)
Selecting previously deselected package curl.
(Reading database ... 114040 files and directories currently installed.)
Unpacking curl (from .../curl_7.19.7-1ubuntu1.11_i386.deb) ...
Processing triggers for man-db ...
Setting up curl (7.19.7-1ubuntu1.11) ...
root@ubuntu:/etc/apt#
Reading package lists... Done
root@ubuntu:/etc/apt#
之後繼續安裝一個下載 FrameWork 源碼的 git-core 包
root@ubuntu:/etc/apt# sudo apt-get install git-core
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
upower libupower-glib1
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
consolekit fontconfig-config gdm ifupdown indicator-applet indicator-applet-session initramfs-tools
initramfs-tools-bin libasound2 libatk1.0-0 libc-bin libc-dev-bin libc6 libc6-dev libc6-i686 libdb4.8
libdbus-glib-1-2 libdevkit-power-gobject1 libdigest-sha1-perl libdrm-nouveau1 libdrm-radeon1 liberror-perl
libfontconfig1 libglib2.0-0 libindicator0 libnih-dbus1 libnih1 libperl5.10 libplymouth2 libpopt0 libudev0
libupower-glib1 libxklavier16 mountall patch perl perl-base perl-modules plymouth udev upower upstart
Suggested packages:
uswsusp gok git-doc git-arch git-cvs git-svn git-email git-daemon-run git-gui gitk gitweb glibc-doc diffutils-doc
perl-doc libterm-readline-gnu-perl libterm-readline-perl-perl watershed
Recommended packages:
indicator-sound indicator-application indicator-me manpages-dev plymouth-theme-ubuntu-text plymouth-theme
The following packages will be REMOVED:
devicekit-power gnome-power-manager indicator-session ubuntu-desktop usplash usplash-theme-ubuntu
The following NEW packages will be installed:
git-core initramfs-tools-bin libdb4.8 libdigest-sha1-perl libdrm-nouveau1 liberror-perl libindicator0 libnih-dbus1
libnih1 libplymouth2 libupower-glib1 libxklavier16 patch plymouth upower
The following packages will be upgraded:
consolekit fontconfig-config gdm ifupdown indicator-applet indicator-applet-session initramfs-tools libasound2
libatk1.0-0 libc-bin libc-dev-bin libc6 libc6-dev libc6-i686 libdbus-glib-1-2 libdevkit-power-gobject1
libdrm-radeon1 libfontconfig1 libglib2.0-0 libperl5.10 libpopt0 libudev0 mountall perl perl-base perl-modules udev
upstart
28 upgraded, 15 newly installed, 6 to remove and 1145 not upgraded.
Need to get 32.8MB of archives.
After this operation, 5,808kB of additional disk space will be used.
Do you want to continue [Y/n]?
速度還是挺不錯的!!剩下的就是下載和處理 repo 和 python 等一些相關支援的工具和包,另外由於FrameWork 下載時間太過長,就不介紹了
主要是解決Ubuntu 低版本源不能用的問題,還在繞彎路的朋友可以看過來,不要到處看無關緊要的部落格和資料,那樣只會被各種誤導!!
有時候找官網資料是最靠譜的
還有就是,推廣一下,我的CSDN 教材,就是希望更多朋友認識我,然後一起討論開發問題,雖然平時很忙,無暇多回複各位的問題,在此表示抱歉!
教材地址:http://edu.csdn.net/course/detail/420
但那是還是依舊有很多網友默默的支援我,我表示很感謝,真的!!所有我以後的部落格或者教程會更用心的去錄製,和撰寫,謝謝各位小夥伴的支援!!