So I’ve built monogame and it’s monodevelop addin from source but now i’m kinda stuck. I’ve done the following:
- Install flatpak as described here.
- Download and install monodevelop flatpak as describeds here.
Get the monogame source:
- Clone the git repo.
git clone firstname.lastname@example.org:MonoGame/MonoGame.git
- Setup the submodules.
git submodule update --init
- Install mono-complete and libopenal-dev.
sudo apt install mono-complete libopenal-dev
- Install further requirements described here.
- Create solutions.
mono Protobuild.exe --generate linux
MonoGame/MonoGame.Framework.Linux.sln in Monodevelop and build it.
Build MonoDevelop Plugin
MonoGame/IDE/MonoDevelop/MonoDevelop.MonoGame.Addin.sln in Monodevelop.
- Remove the Mono.Addins reference.
./.local/share/flatpak/app/com.xamarin.MonoDevelop/x86_64/master/<bunchofnumbers>/files/lib/monodevelop/bin/Mono.Addins.dll as a reference.
- Build it.
Now I’ve got a bunch of compiled stuff but I’m unsure how to proceed from here. I would expect to install the monodevelop plugin then use that to create a project from a template and replace any bad references with references to the compiled dlls. But there doesn’t seem to be an .mpack file anywhere, so I can’t install the plugin. Peeking at
MonoGame/Installers/default.build seems to suggest that there ought to be one.
Does anyone know what to do next?
Using those files you pointed me at I wrote a small bash script that should do the same thing as that default.build file:
mkdir Linux/tmp_run -p
mkdir Linux/tmp_run/MonoGameSDK -p
mkdir Linux/tmp_run/MonoGameSDK/Assemblies -p
cp ../IDE/MonoDevelop/MonoDevelop.MonoGame_*.mpack Linux/tmp_run/Main/MonoDevelop.MonoGame.mpack
cp ../MonoGame.Framework.Content.Pipeline/MonoGame.Content.Builder.targets Linux/tmp_run/MonoGameSDK/MonoGame.Content.Builder.targets
cp ../MonoGame.Framework.Content.Pipeline/MonoGame.Common.props Linux/tmp_run/MonoGameSDK/MonoGame.Common.props
cp ../Tools/Pipeline/bin/Linux/AnyCPU/Release Linux/tmp_run/MonoGameSDK/Tools -r
cp ../MonoGame.Framework/bin/Linux/AnyCPU/Release Linux/tmp_run/MonoGameSDK/Assemblies/DesktopGL -r
cp Linux/RUN/* Linux/tmp_run
cp Linux/Main Linux/tmp_run/Main -r
mv Linux/tmp_run/uninstall.sh Linux/tmp_run/MonoGameSDK/uninstall.sh
../ThirdParty/Dependencies/makeself/./makeself.sh Linux/tmp_run monogame-sdk.run "Monogame Pipeline Installer" ./postinstall.sh
rm Linux/tmp_run -rf
Running it from the MonoGame/Installers folder results in a monogame-sdk.run file which seems to install the framework just fine. (I’ve got a MonoGameSDK symlink in /opt and monogame-pipeline-tool seems to work.)
However using non-flatpak monodevelop (installed from here) I don’t seem able to build the monodevelop addin. I seem unable to reference
MonoDevelop.Projects.MSBuild (all I have is
Mono.Addins.MSBuild which isn’t good enough).
I also tried using
nant (which apparently is available through some apt repository) but it seems to fail when building
MonoGame.Framework.Windows.sln because it misses an assembly reference to
System.Windows.Media. And just calling it in IDE/MonoDevelop doesn’t result in an mpack file either.
MonoGame from devel branch only supports MonoDevelop 6 that is not installed from flatpak. The one from that repo is MonoDevelop 5.
What about the master branch? I tried to build that one using
nant but it borks at the
build_web part with an (to me) uninformative error:
[exec] Starting resolution of packages for Web...
[exec] Resolving: https-git://github.com/OutOfOrder/MonoKickstart.git
[exec] Git repository present at ThirdParty/Kickstart/.git; leaving as source version.
[exec] Git submodule / repository already present at ThirdParty/Kickstart
[exec] Resolving: https-git://github.com/Mono-Game/MonoGame.Dependencies.git
[exec] Git repository present at ThirdParty/Dependencies/.git; leaving as source version.
[exec] Git submodule / repository already present at ThirdParty/Dependencies
[exec] Package resolution complete.
[exec] Installing http://protobuild.org/hach-que/JSIL...
[exec] HTTP GET http://protobuild.org/hach-que/JSIL/api
[exec] Unable to resolve binary package for version "master" and platform "Linux", falling back to source version
[exec] Creating and emptying /home/wieke/.config/.protobuild-tools/9a68400a153769e8def631d96873f024de794a55
[exec] Installing http://protobuild.org/hach-que/JSIL at version master
[exec] The specified global tool package is not available for this platform.
nant with the develop branch borks on
build_windows with a lot of missing reference errors (stuff like
PresentationFramework) and I’m unsure where to get these references.
(I tried building MonoDevelop but that’s not all that straightforward either and I seem unable to find a ubuntu package for MonoDevelop 6.)
Try getting the newer version of Protobuild, the one included in master branch is quite out of date.
I’m afraid that doesn’t seem to help. Got the newer version, replaced the Protobuild.exe in the repository with it and ran
nant again on the develop and master branches. (I’d mess around with it some more but I haven’t got the time this evening.)