我从git下载了资源:
git clone git://github.com/mono/monodevelop.git
和依赖项:
cd monodevelop && git submodule init && git submodule update
我设置了单声道3.0.11(因为 “你需要单声道2.10.9或更新” 默认版本为2.10.8.1)
我添加了存储库:
cat «deb http://ubuntu.mirror.cambrium.nl/ubuntu/ lucid main» >> /etc/apt/sources.list
我安装了包:
apt-get install libglib2.0-cil gnome-sharp2 gtk-sharp2 libmono-addins-cil-dev libmono-addins-gui-cil-dev libmono-addins-msbuild-cil-dev
./配置
给我
Configuration Summary
---------------------
MonoDevelop has been configured with
prefix = /usr/local
profile = default
Packages included in the build:
main
extras/JavaBinding
extras/ValaBinding
extras/MonoDevelop.Database
extras/MonoDevelop.Debugger.Gdb
extras/PyBinding
extras/MonoDevelop.MeeGo
但是
make | grep "not resolved"
给我错误:
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:引用'glib-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:参考'pango-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:参考'atk-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:参考'gdk-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:参考'gtk-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
/usr/local/lib/mono/4.0/Microsoft.Common.targets:警告:参考'glade-sharp,Version = 2.12.0.0,Culture = neutral,PublicKeyToken = 35e10195dab3c99f'未解决
在此页面中 - http://article.gmane.org/gmane.comp.gnome.mono.monodevelop.general/14338 建议«看起来你需要安装gtk-sharp 2.12.x»
但我安装了它们:
查找/ usr / lib / mono / gac -xdev -iname“* Sharp.dll”| grep“3c99f”| grep -v“政策”
/usr/lib/mono/gac/pango-sharp/2.12.0.0__35e10195dab3c99f/pango-sharp.dll
/usr/lib/mono/gac/gconf-sharp/2.24.0.0__35e10195dab3c99f/gconf-sharp.dll
/usr/lib/mono/gac/gnome-sharp/2.24.0.0__35e10195dab3c99f/gnome-sharp.dll
/usr/lib/mono/gac/gtk-sharp/2.12.0.0__35e10195dab3c99f/gtk-sharp.dll
/usr/lib/mono/gac/atk-sharp/2.12.0.0__35e10195dab3c99f/atk-sharp.dll
/usr/lib/mono/gac/glib-sharp/2.12.0.0__35e10195dab3c99f/glib-sharp.dll
/usr/lib/mono/gac/art-sharp/2.24.0.0__35e10195dab3c99f/art-sharp.dll
/usr/lib/mono/gac/gnome-vfs-sharp/2.24.0.0__35e10195dab3c99f/gnome-vfs-sharp.dll
/usr/lib/mono/gac/glade-sharp/2.12.0.0__35e10195dab3c99f/glade-sharp.dll
/usr/lib/mono/gac/gdk-sharp/2.12.0.0__35e10195dab3c99f/gdk-sharp.dll
我也试过这个建议:
http://www.mono-project.com/Parallel_Mono_Environments#Tip:_MONO_GAC_PREFIX
并将MONO_GAC_PREFIX添加到〜/ .bashrc中
echo $ MONO_GAC_PREFIX
/ USR
但编译错误仍然存在。我该怎么做?
答案 0 :(得分:11)
这就是我的所作所为:
sudo apt-get install libglade2.0-cil-dev
sudo apt-get install gnome-sharp2
cd /usr/lib/mono/gac/
sudo gacutil -i glib-sharp/2.12.0.0__35e10195dab3c99f/glib-sharp.dll &&
sudo gacutil -i atk-sharp/2.12.0.0__35e10195dab3c99f/atk-sharp.dll &&
sudo gacutil -i gdk-sharp/2.12.0.0__35e10195dab3c99f/gdk-sharp.dll &&
sudo gacutil -i gtk-sharp/2.12.0.0__35e10195dab3c99f/gtk-sharp.dll &&
sudo gacutil -i glade-sharp/2.12.0.0__35e10195dab3c99f/glade-sharp.dll &&
sudo gacutil -i pango-sharp/2.12.0.0__35e10195dab3c99f/pango-sharp.dll &&
sudo gacutil -i gnome-sharp/2.24.0.0__35e10195dab3c99f/gnome-sharp.dll &&
sudo gacutil -i gconf-sharp/2.24.0.0__35e10195dab3c99f/gconf-sharp.dll &&
sudo gacutil -i gnome-vfs-sharp/2.24.0.0__35e10195dab3c99f/gnome-vfs-sharp.dll
显然,mono的GAC没有看到你从软件包安装的那些库。好吧,上面的命令对我有用:-D
答案 1 :(得分:0)
我今天在Ubuntu 13.04上成功编译了Monodevelop 4.1.4。我遇到了类似的问题。我从源代码编译并安装了gnome-sharp。当您运行./configure
时,请注意最后的输出。我实际上设法通过盲目地运行./configure
make
make install
而没有错误地编译它,但是没有注意到为了使dll能够工作,需要事先获得许多库。 ./configure
的最终输出将告诉您这些dll需要哪些库。
任何看似缺失的内容,从源代码构建并安装在您的计算机上。请注意版本号,因为有些库的更高版本。
答案 2 :(得分:-1)
我建议尝试删除文件〜/ .config / xbuild / pkgconfig-cache-2.xml。它缓存已安装的软件包,在某些情况下,在安装/重新安装gtk-sharp和其他软件包后会产生一些混乱。您可以查看此文件,如果您找到对不存在的旧gtk-sharp文件的引用,那么这就是您的情况。删除后,xbuild将在下次编译时重新创建该文件。
答案 3 :(得分:-2)
而不是
cat «deb http://ubuntu.mirror.cambrium.nl/ubuntu/ lucid main» >> /etc/apt/sources.list
DO
cat «deb http://ubuntu.mirror.cambrium.nl/ubuntu/ raring main» >> /etc/apt/sources.list
或可能
cat «deb http://ubuntu.mirror.cambrium.nl/ubuntu/ quantal main» >> /etc/apt/sources.list