揭曉Windows 11如何做到原生支持安卓應用

{"type":"doc","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"編譯|核子可樂、燕珊"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"作者|RON AMADEO"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"雖然微軟某高管曾在6年前宣稱“Windows 10 之後不再有下一代 Windows 操作系統”,但事實顯然並非如此。當地時間6月24日,微軟舉辦"},{"type":"link","attrs":{"href":"https:\/\/www.microsoft.com\/zh-cn\/windows\/windows-11","title":"xxx","type":null},"content":[{"type":"text","text":"Window 11"}]},{"type":"text","text":"發佈會,這是微軟繼2015年推出Windows 10操作系統以來,發佈的第一個新的Windows系統大版本,並且Windows 11可謂是賺足熱度,其中最重要的更新之一便是“支持Android應用的運行”。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"與此同時,引起熱議的是,Android應用的支持究竟是如何實現的呢?是靠模擬實現還是說用到了Windows現有的Linux支持機制?關於這點,微軟在當時的主題演講中並沒有透露公佈太多細節,不過,在後來發布的開發者訪談"},{"type":"link","attrs":{"href":"https:\/\/www.youtube.com\/watch?v=egZ82QGshX8","title":"xxx","type":null},"content":[{"type":"text","text":"視頻"}]},{"type":"text","text":"中,答案開始浮現。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":"支持安卓應用的實現原理"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"事實上,新功能的官方名稱爲“Windows Subsystem for Android”,跟Windows Subsystem for Linux(WSL)有異曲同工之妙,也基本上揭示了背後的實現原理。Windows目前的Windows Subsystem for Linux,可以說是基於Hyper-V 功能的子集提供了“真正的Linux 內核”。(Hyper-V允許由第二客戶操作系統繞過主機操作系統直接訪問裸機硬件,因此資源消耗更低。)"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"而手機Android使用的正是Linux內核,於是微軟着手在WSL之上構建起一套Android框架,用於適配Windows Subsystem for Android。簡單來講,就相當於是在Hyper-V上運行x86 Android。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/4b\/fa\/4b1735b697b1f78216eb8fddf14d54fa.png","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":"center","origin":null},"content":[{"type":"text","marks":[{"type":"size","attrs":{"size":10}}],"text":"微軟WSL項目負責人Miguel Ramos在推特上稱新功能“和WSL一樣酷”。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"Windows下的Android應用在使用體驗上與原生Windows應用程序一致,同樣具有前置窗口、任務欄條目以及添加到開始菜單等功能。微軟在其演示中表示,“在底層,我們實際創建了一款代理原生應用,作爲Android App模型與Windows應用程序模型之間的橋樑。”據推測,這意味着新系統也能夠爲Android應用提供諸如開始菜單快捷方式、圖標、應用卸載列表條目,以及其他與原生Windows應用程序高度統一的體驗元素。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/ee\/69\/ee15353ab179d30b50cfee50dd4cfd69.png","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"微軟希望儘可能降低、甚至徹底消除“模擬”,但具體取決於設備型號與Android應用本身。Windows與Android分別運行在x86與Arm架構之上,Windows支持x86、而Android支持Arm。所以,如果是在Arm上運行Windows,那Android應用的支持根本不是問題;而如果使用的是x86 Windows,微軟則提供Android應用的對應x86版本。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"但如果某款Android應用只有Arm版本,那麼英特爾"},{"type":"link","attrs":{"href":"https:\/\/www.businesswire.com\/news\/home\/20210624005812\/en\/Intel-Core-Processors-and-Intel-Bridge-Technology-Unleash-Windows-11-Experience","title":"xxx","type":null},"content":[{"type":"text","text":"Bridge技術"}]},{"type":"text","text":"就能把Arm代碼轉換爲x86 CPU所支持的形式。微軟方面還特別強調,這項功能也適用於AMD CPU。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/53\/e8\/538d885a2b226daef94be1e956be8ae8.jpeg","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":"center","origin":null},"content":[{"type":"text","marks":[{"type":"size","attrs":{"size":10}}],"text":"TikTok在Windows 11上運行。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"微軟採取的方法其實也類似於其他一些操作系統的Android應用支持模式。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"其中,Chrome OS的Android應用支持功能可以算是典型案例了,畢竟Chrome OS本身運行的就是Linux內核,所以可以直接通過一套容器化Android框架實現App運行。但如果選擇的是x86 Chromebook,Chrome OS會使用Android內置的Arm-to-x86進行二進制轉換。而如果使用的是Linux桌面操作系統,則通過Anbox工具在Linux上加載Android框架,最終實現同樣的支持效果。如今,大家甚至可以在WSL上運行Anbox。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"很多人對x86 Android的最後一次體驗,可能來自2012年由英特爾發佈的Atom版x86手機,包括華碩Zenfone系列在內的相關產品都不怎麼樣。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"後來經過不斷的發展,x86 Android已經取得了很大的進步;2016年推出的Android Chrome也在操作系統層面解決了不少問題。而且在2016年之前,谷歌就一直在推動Arm架構對於x86應用程序的支持能力,其內部開發工具也早已默認支持Arm與x86二進制文件轉換。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"同樣是在2016年,谷歌做出了一項重要判斷:未來預計25%的Google Play裏的應用將完全無法支持x86,必須配合Arm轉譯工具才能實現適配。但隨着更多x86客戶開始選擇Chrome OS,這個比例可能要比預期更低一些。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":"從哪裏下載安卓應用?"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"那麼,用戶要如何給Windows 11下載安卓應用?微軟並不打算在Windows上使用Google Play生態,也無意構建自己的生態。這一次,他選擇了與亞馬遜合作,使用與Fire OS設備同平臺的Amazon Appstore。亞馬遜還就此事發布了專門的"},{"type":"link","attrs":{"href":"https:\/\/developer.amazon.com\/zh\/blogs\/appstore\/post\/a7583854-9367-4480-99c4-15f91456558c\/amazon-and-microsoft-create-new-opportunities-for-developers-and-increase-return-on-investment-in-the-amazon-appstore","title":"xxx","type":null},"content":[{"type":"text","text":"新聞稿"}]},{"type":"text","text":",表示隨後將逐步放出更多具體細節。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"我們還沒在Windows 11上看到過完整的Android App安裝流程,所以不敢斷言具體是怎麼實現的。微軟目前也只發布了幾張截圖,展示了微軟Store上列出的Amazon Appstore應用頁面。看起來,微軟應用商店是直接轉載了亞馬遜的App目錄,包括其中的評論、截圖與說明內容。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"但微軟自家的應用商店似乎沒法直接安裝Android應用,必須點擊安裝並跳轉至Amazon Appstore。對於Windows應用,這個位置的按鈕爲“獲取”,代表要安裝相應的應用程序;但對Android應用,按鈕內容不同,顯示爲“從Amazon Appstore獲取”,並帶有一個小框加箭頭圖標,提示點擊後將進行跳轉。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/ba\/42\/ba62250eefcdb5629ae305d84bd82042.jpeg","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"不過據《華爾街日報》報道,亞馬遜會爲Windows構建一款專門的Amazon Appstore客戶端,用戶需要使用相應的亞馬遜賬戶才能登錄並下載應用。微軟應用商店則只是一套統一的應用搜索界面,再無其他用處。根據推測,這意味着兩套AppStore將同時在Windows上保持運行且分別檢查更新——聽起來好像很麻煩。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"微軟工程師Miguel de Icaza則證實,Windows 11還爲不想安裝Amazon Appstore的朋友提供旁加載支持,供大家直接從F-Droid等開源商店或APKMirror等其他應用獲取渠道。這樣看起來,最後連Google Play也會擠進戰團。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"憑藉多年的默認推動與對額外架構的良好支持,x86應用程序在Google Play上已經頗具人氣。但x86在Amazon Appstore上的普及度如何?由於我們已經可以在任何Android設備上旁加載Amazon Appstore,而亞馬遜自家的Echo Fire設備則全部採用Arm架構。再考慮到大部分應用已經可以在一切架構上順暢運行,所以應該沒什麼問題。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/1a\/c2\/1a8c785411885f5420afbf4eb27a43c2.jpeg","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"如果微軟推出Surface Duo並與谷歌合作在Windows 11中推出Play商店,那就萬事大吉了。因爲一切脫離Play商店安裝的Android應用都無法訪問推送通知等Play Services API。但多年以來,亞馬遜一直在爲Fire OS構建自己的替代API及雲服務,所以如果真的沒有谷歌Play,Amazon Appstore也確實是個不錯的選擇。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"本週,微軟將通過 Windows Insider 渠道提供 Windows 11的早期預覽版本。正式版本的推送日期暫未確定,微軟官方說的是“今年晚些時候”,並且只有64位的設備才能安裝。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"附上Windows 11對設備的硬件要求\/最低配置:"}]},{"type":"image","attrs":{"src":"https:\/\/static001.infoq.cn\/resource\/image\/e4\/0d\/e445d9e75ccb6c4942e45cd1205b6a0d.png","alt":null,"title":"","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"延展閱讀:"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"https:\/\/arstechnica.com\/gadgets\/2021\/06\/microsofts-windows-subsystem-for-android-sounds-a-lot-like-chrome-os\/"}]}]}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章