mono/mono-addins

Compilation error

cybericius opened this issue · 8 comments

Hi,

I would like to compile mono-addins as it is a requirement of Monodevelop.

It gives me the following compilation error after executing commands:

git clone https://github.com/mono/mono-addins
./autogen.sh --prefix=/usr/local
make

Have I missed something? Thank you!

make[1]: Entering directory /opt/mono-3/mono-addins/Mono.Addins.Gui' sed -e "s/@ASSEMBLY_NAME@/Mono.Addins.Gui/" -e "s/@POLICY@/0.2/" ../policy.config > policy.0.2.config /usr/local/bin/al -link:policy.0.2.config -out:policy.0.2.Mono.Addins.Gui.dll -keyfile:../mono-addins.snk ALINK: warning A99999: Path 'policy.0.2.config' in the resource name is not supported. Using just file name 'policy.0.2.config' sed -e "s/@ASSEMBLY_NAME@/Mono.Addins.Gui/" -e "s/@POLICY@/0.3/" ../policy.config > policy.0.3.config /usr/local/bin/al -link:policy.0.3.config -out:policy.0.3.Mono.Addins.Gui.dll -keyfile:../mono-addins.snk ALINK: warning A99999: Path 'policy.0.3.config' in the resource name is not supported. Using just file name 'policy.0.3.config' sed -e "s/@ASSEMBLY_NAME@/Mono.Addins.Gui/" -e "s/@POLICY@/0.4/" ../policy.config > policy.0.4.config /usr/local/bin/al -link:policy.0.4.config -out:policy.0.4.Mono.Addins.Gui.dll -keyfile:../mono-addins.snk ALINK: warning A99999: Path 'policy.0.4.config' in the resource name is not supported. Using just file name 'policy.0.4.config' sed -e "s/@ASSEMBLY_NAME@/Mono.Addins.Gui/" -e "s/@POLICY@/0.5/" ../policy.config > policy.0.5.config /usr/local/bin/al -link:policy.0.5.config -out:policy.0.5.Mono.Addins.Gui.dll -keyfile:../mono-addins.snk ALINK: warning A99999: Path 'policy.0.5.config' in the resource name is not supported. Using just file name 'policy.0.5.config' sed -e "s/@ASSEMBLY_NAME@/Mono.Addins.Gui/" -e "s/@POLICY@/0.6/" ../policy.config > policy.0.6.config /usr/local/bin/al -link:policy.0.6.config -out:policy.0.6.Mono.Addins.Gui.dll -keyfile:../mono-addins.snk ALINK: warning A99999: Path 'policy.0.6.config' in the resource name is not supported. Using just file name 'policy.0.6.config' Building Mono.Addins.Gui.csproj Mono.Addins.Gui/AddinManagerDialog.cs(187,24): error CS0506:Mono.Addins.Gui.AddinManagerDialog.Dispose()': cannot override inherited member GLib.Object.Dispose()' because it is not marked virtual, abstract or override Mono.Addins.Gui/AddinTreeWidget.cs(52,25): error CS0012: The typeGLib.IIcon' is defined in an assembly that is not referenced. Consider adding a reference to assembly gio-sharp, Version=3.0.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f' Mono.Addins.Gui/ManageSitesDialog.cs(67,24): error CS0506:Mono.Addins.Gui.ManageSitesDialog.Dispose()': cannot override inherited member GLib.Object.Dispose()' because it is not marked virtual, abstract or override Mono.Addins.Gui/NewSiteDialog.cs(46,24): error CS0506:Mono.Addins.Gui.NewSiteDialog.Dispose()': cannot override inherited member GLib.Object.Dispose()' because it is not marked virtual, abstract or override gtk-gui/generated.cs(53,11): error CS0234: The type or namespace nameSizeRequestedArgs' does not exist in the namespace Gtk'. Are you missing an assembly reference? Mono.Addins.Gui/HeaderBox.cs(98,27): error CS0115:Mono.Addins.Gui.HeaderBox.OnSizeRequested(ref Gtk.Requisition)' is marked as an override but no suitable method found to override
Mono.Addins.Gui/HeaderBox.cs(125,27): error CS0115: Mono.Addins.Gui.HeaderBox.OnExposeEvent(Gdk.EventExpose)' is marked as an override but no suitable method found to override Mono.Addins.Gui/HoverImageButton.cs(83,44): warning CS0618:Gtk.Style' is obsolete: Replaced by StyleContext' Mono.Addins.Gui/HoverImageButton.cs(150,33): error CS0115:Mono.Addins.Gui.HoverImageButton.OnExposeEvent(Gdk.EventExpose)' is marked as an override but no suitable method found to override
make[1]: *** [csproj_build] Error 1
make[1]: Leaving directory /opt/mono-3/mono-addins/Mono.Addins.Gui' make: *** [all-recursive] Error 1 root@phoenix:/opt/mono-3/mono-addins# Mono.Addins.Gui/AddinManagerDialog.cs(187,24): error CS0506:Mono.Addins.Gui.AddinManagerDialog.Dispose()': cannot override inherited member GLib.Object.Dispose()' because it is not marked virtual, abstract or override bash: syntax error near unexpected token187,24'

A lot of the errors I was getting went away when I switched the projects to .NET 4.0. Currently they are on 2.0 which is very old.

Can you clarify a bit more on how to switch to .NET 4.0 before compiling ? I have the same compilation problem.

Through your project Properties page in visual studio. Look for where it says "Target Framework"

I'm not sure if we are considering the same problem here. For me I try to compile mono-addins from source and everything is done on command line. I do not use visual studio or monodevelop at this point. But thanks nonetheless.

Hi guys: How do you run the configure from a local directory? I downloaded the zip file here, unzipped it, and tried to run ./configure but the Unix shell tells me "./configure: No such file or directory"

@wittawatj You should be able to edit the .csproj file and modify the target framework in the XML. As long as you know the MSBuild syntax, you would know where to change.

@hjchen2005 This is MONO-ADDINS, not mono; If you need mono you need to either install it through the package manager of your distro or go to the actual repository's page.

Mono-Addins does not need you to compile it separately, you just add the nuget package reference and mono compiler will automatically pull it when compiling your project

@fahadash ...unless you're compiling monodevelop on linux, which is not working at all right now (because it requires mono-addins and the versions of mono and mono-addins official arch packages have some problems and many people are making various AUR packages to correct issues with mono, mono-addins, and monodevelop) -- unless there is a way to use nuget from the command line while building monodevelop (I thought you needed the GUI to use nuget). I'm not sure why you are saying you don't need to build mono-addins to build monodevelop (building monodevelop is the original issue) -- please clarify-- you are saying you don't want people to use the git version, and that you don't want people to build it, but I'm not sure why. If people build it they are simply using their right as per the license and can help you identify problems to make mono-addins better, making your work lighter. These are people who can help you, and need your help: