GNOME Bugzilla – Bug 597950
[PATCH] Build Banshee.sln with xbuild
Last modified: 2010-05-30 00:40:09 UTC
Created attachment 145178 [details] [review] banshee-xbuild.patch The attached patch fixes the project files to build with xbuild, and also build against gtk-sharp > 2.12 . Changes: libbanshee/libbanshee.cproj: Add "Build" and "Clean" targets, which just call make and 'make clean'. Other project files, make g*-sharp references SpecificVersion=false, this ensures that they can build with the highest ver available on the system. If this is something that is not desired, then _none_ of those references should have SpecificVersion=false, this makes sure that all the references will be 2.12, consistency is important here. For MonoPosixHelper.dll references, i added a condition: " '$(OS)' == 'Windows_NT' " This is true on win2k+ . With the new xbuild, it'll be set of "Unix" or "OSX" An alternative could be to use the $(Configuration) property. src/Dap/Banshee.Dap.Ipod/Banshee.Dap.Ipod.csproj, src/Extensions/Banshee.SqlDebugConsole/Banshee.SqlDebugConsole.csproj: Add some missing project references. ---- I have *NOT* tested this patch on windows/msbuild, as i don't have the required setup. The changes should be harmless, but ofcourse testing on windows is required. This has been tested only on linux. I haven't tried it with MD either. It should work on OSX, but hasn't been tested. This requires xbuild from mono svn/trunk or the mono-2-6/mono-2-4 branches.
Attaching an updated patch. I had missed some *-sharp references, fixed those. Also, in src/Core/Banshee.Services/Banshee.Services.csproj added Mono.Data.Sqlite as a project reference instead of a simple reference "Mono.Data.Sqlite". This matches what the makefile does. Removed Banshee.Base reference from LastFm project.
Created attachment 145327 [details] [review] banshee-xbuild-2.patch
Any update on this ? Is there something blocking this that I could help with?
Comment on attachment 145178 [details] [review] banshee-xbuild.patch Sorry for not replying earlier. The situation with .csproj files in banshee is a bit messy currently, and I'm not sure how to address it. Is this supposed to work with mono 2.4.2.3 or is mono svn required ? I think we talked about this on IRC, but I can't remember the answer ;) I'm makring the first patch as obsoleted by the second, correct me if I'm wrong.
Like i mentioned in the original report: This requires xbuild from mono svn/trunk or the mono-2-6/mono-2-4 branches. Let me know if I can be of any help in cleaning up the project files mess.
JFYI, I am eagerly trying to get this on my radar. Moving to an xbuild/msbuild/csproj only build environment is high on my list. Bertrand: I anticipate bundling xbuild from Mono svn in our tree for a while, and am more than okay with that. Ankit: thanks for the work, and I'm going to try to get this integrated ASAP.
Created attachment 153766 [details] [review] Updated patch for xbuild build This is an updated version of the patch, to work on latest git master. With this, Banshee.sln builds with xbuild from Mono 2.4.2.3, except for libbanshee.cproj. I get this error : Target libbanshee: Project "/home/lorentz/Projets/banshee/libbanshee/libbanshee.cproj" (Build target(s)): Target Build: : error : Unable to find tool at 'make' : error : Error while building /home/lorentz/Projets/banshee/libbanshee/libbanshee.cproj If I remove libbanshee from the solution, xbuild succeeds, but tells me it had 35 errors. From the log, it seems these errors are coming from missing deps on my system : ipod-sharp, boo, Gio. Also, some of the dependency logic is missing, like : use notify-sharp from system if present, if not, use in-source copy.
Comment on attachment 153766 [details] [review] Updated patch for xbuild build The patch needs to be updated for latest git master, after some changes to the .csproj files.
Apparently, most of the issues have already been fixed in git master. I committed the remaining fixes, Banshee.sln now builds with xbuild. Note that libbanshee.cproj is no longer included in Banshee.sln. On the other hand, libbanshee/libbanshee.sln references libbanshee.vcproj which is not recognised by xbuild. Closing as FIXED. commit 4b2f87adf80dc8b26f50ad385a1509d6d3b6fc93 Author: Alexander Kojevnikov <alexander@kojevnikov.com> Date: Sun May 30 10:35:04 2010 +1000 [build] Fix xbuild integration (bgo#597950) Revised version of the original patch from Ankit Jain.