| View previous topic :: View next topic |
| Author |
Message |
Iran
Level: 49
Position: Registered User
Joined: 08 Sep 2010
Posts: 84
Kel: 95 [ Donate ]
Online Status: Offline
|
Posted: Wed Sep 08, 2010 4:44 pm Post subject: Compiling OpenRA on Ubuntu |
|
|
First off, grab the source with Git:
| Code: | $ git clone git://github.com/chrisforbes/OpenRA.git
$ cd OpenRA |
If you don't have git installed, you can install it with:
| Code: | | $ sudo apt-get install git-core |
To compile OpenRA on Ubuntu you need the following dependencies (as tested on Ubuntu 10.04):
- mono-gmcs
- libmono-corlib1.0-cil
- libmono-winforms2.0-cil
- libopenal1
- libsdl1.2-dev
- libfreetype6 or libfreetype6-dev
To install these dependencies type:
| Code: | | $ sudo apt-get install mono-gmcs freetype libmono-corlib1.0-cil libmono-winforms2.0-cil libopenal1 libsdl1.2-dev |
Next you need to install the assemblies of these third party libraries into the global assembly cache that the Mono compiler uses. You can either run the following script or run these command individually (the 'gacutil' program can't handle multiple files at once):
| Code: |
#!/bin/sh
gacutil -i thirdparty/Tao/Tao.Cg.dll
gacutil -i thirdparty/Tao/Tao.OpenGl.dll
gacutil -i thirdparty/Tao/Tao.OpenAl.dll
gacutil -i thirdparty/Tao/Tao.Sdl.dll
gacutil -i thirdparty/Tao/Tao.FreeType.dll
gacutil -i thirdparty/WindowsBase.dll
|
Note: You'll need to run the script as an administrator ("root"). If you run these command one per one, it is recommended that you use the 'sudo' application to obtain root privilege.
Alternatively, you can copy the dll’s into the same directory as OpenRa.Game.exe.
Once you have copied the following 'MIX' file packages into the appropriate directories (mods/*/packages), you're ready to compile (aka "build"):
For the Red Alert mod:
- allies.mix
- expand2.mix
- hires1.mix
- redalert.mix
- scores.mix
- sounds.mix
- conquer.mix
- general.mix
- interior.mix
- russian.mix
- snow.mix
- temperat.mix
For the Command & Conquer mod:
- cclocal.mix
- conquer.mix
- desert.mix
- general.mix
- sounds.mix
- speech.mix
- temperat.mix
- tempicnh.mix
- updatec.mix
- winter.mix
The size should be around ~20 MB if you download a stripped (no audio and videos) version of these files. You can download these for C&C here and for RA here.
If you want to use the complete, non-strippedl MIX files, you'll need to install the game and then copy these files over from the installed directory plus the game CDs. You can download all the CD (and expansions) ISOs legally:
Command & Conquer Full Game
Red Alert Full game
Note that both games' installers are 16-bit so they don't run under a 64-bit operating system, the C&C download link contains a modified 32-bit installer. To install RA1, use the Red Alert Setup Manager v0.98.
When you're done copying the MIX files to the correct folder, you'll only need to type
and pray that it works. To actually play the game you'll need the following dependencies:
- libglfw2
- libmono-* (Note: you dont need all of them, but it works with all of them)
- libopenal1
- mono-runtime
Note that the project is in alpha phase and we don't have a complete list of possible errors and fixes for them. Please check the FAQ listed on this forum before asking for help on our forum and/or IRC channel.
Last edited by Iran on Tue Oct 05, 2010 10:47 pm; edited 1 time in total |
|
| Back to top |
|
 |
Iran
Level: 49
Position: Registered User
Joined: 08 Sep 2010
Posts: 84
Kel: 95 [ Donate ]
Online Status: Offline
|
Posted: Wed Sep 29, 2010 7:26 pm |
|
|
| ignore this |
|
| Back to top |
|
 |
relipse
Level: 46
Position: Registered User
Joined: 29 Oct 2010
Posts: 2
Kel: 3 [ Donate ]
Online Status: Offline
|
Posted: Fri Oct 29, 2010 3:58 am Post subject: compiling on ubuntu -- update |
|
|
Well i tworked, I had to Go to System -> Preferences -> Appearances -> Visual Effects -> None to get i tto work and i'm using ubuntu 10.10
just as an update, tey are no longer using /chrisforbes/ the new git is:
git clone git://github.com/OpenRA/OpenRA.git |
|
| Back to top |
|
 |
Pierre Monteux
Level: 45
Position: Registered User
Joined: 11 Dec 2010
Posts: 1
Kel: 1 [ Donate ]
Online Status: Offline
|
Posted: Sun Dec 12, 2010 5:35 am |
|
|
I was unable to build on anything but the latest version of Ubuntu 10.10.
Also the gacutil script is out of date. What worked for me was to manually register every dll in the third party folder.
And mono-devel should be added to the compile dependency list. |
|
| Back to top |
|
 |
krn_78
Level: 44
Position: Registered User
Joined: 15 Jan 2011
Posts: 1
Kel: 3 [ Donate ]
Online Status: Offline
|
Posted: Sat Jan 15, 2011 4:31 pm Post subject: Re: compiling on ubuntu -- update |
|
|
In Ubuntu 10.10 openRA is available in Ubuntu Software Center
| relipse wrote (View Post): | | Go to System -> Preferences -> Appearances -> Visual Effects -> None |
Your suggestion helped me with my problem. Loader worked fine, and after choosing any mod, there was a message on console:
Unhandled Exception: System.InvalidOperationException: No valid techniques
at OpenRA.Renderer.Cg.Shader..ctor (OpenRA.Renderer.Cg.GraphicsDevice dev, System.String name) [0x00000] in <filename unknown>:0
at OpenRA.Renderer.Cg.GraphicsDevice.CreateShader (System.String name) [0x00000] in <filename unknown>:0
at OpenRA.Graphics.Renderer..ctor () [0x00000] in <filename unknown>:0
at OpenRA.Game.Initialize (OpenRA.Arguments args) [0x00000] in <filename unknown>:0
at OpenRA.Program.Run (System.String[] args) [0x00000] in <filename unknown>:0
at OpenRA.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
Thanks to you, it's ok now. |
|
| Back to top |
|
 |
Iran
Level: 49
Position: Registered User
Joined: 08 Sep 2010
Posts: 84
Kel: 95 [ Donate ]
Online Status: Offline
|
Posted: Wed Jan 19, 2011 8:16 pm |
|
|
| This tutorial is very likely outdated |
|
| Back to top |
|
 |
riderr3
Level: 45
/ff10_Tidus2.gif)
Position: Registered User
Joined: 26 Feb 2011
Posts: 98
Kel: 106 [ Donate ]
Online Status: Offline
|
Posted: Wed Mar 02, 2011 10:17 am |
|
|
error log from console terminal:
| Code: | CSC OpenRA.FileFormats.dll
CSC OpenRA.Game.exe
CSC OpenRA.Renderer.Cg.dll
CSC OpenRA.Renderer.Gl.dll
CSC OpenRA.Renderer.Null.dll
CSC mods/ra/OpenRA.Mods.RA.dll
OpenRA.Mods.RA/Widgets/Delegates/MusicPlayerDelegate.cs(33,29): warning CS0168: The variable `installed' is declared but never used
Compilation succeeded - 1 warning(s)
CSC mods/cnc/OpenRA.Mods.Cnc.dll
resgen2 OpenRA.Editor/MapSelect.resx OpenRA.Editor.MapSelect.resources 1> /dev/null
/bin/sh: resgen2: not found
make: *** [OpenRA.Editor.MapSelect.resources] Error 127 |
seems I can not compile the editor or what? |
|
| Back to top |
|
 |
ddd
Level: 50

Position: Registered User
Joined: 23 Oct 2010
Posts: 177
Kel: 181 [ Donate ]
Online Status: Offline
|
|
| Back to top |
|
 |
arjun
Level: 39
Position: Registered User
Joined: 11 Jul 2011
Posts: 1
Kel: 1 [ Donate ]
Online Status: Offline
|
Posted: Mon Jul 11, 2011 2:06 am Post subject: How I fixed it |
|
|
I followed all the instructions as above, except for the gacutil commands. Instead, following the instructions at https://github.com/OpenRA/OpenRA/blob/2ffc66416be72b30de90a7c4a067afdac4c2fd63/INSTALL I just copied all the files from thirdparty/*.dll and thirdparty/Tao/* to the OpenRA root directory.
When running openra, I got an exception.
Unhandled Exception: System.InvalidOperationException: GL Error: 1282
at OpenRA.Renderer.Glsl.GraphicsDevice.CheckGlError () [0x00000] in <filename unknown>:0
at OpenRA.Renderer.Glsl.Shader..ctor (OpenRA.Renderer.Glsl.GraphicsDevice dev, System.String type) [0x00000] in <filename unknown>:0
at OpenRA.Renderer.Glsl.GraphicsDevice.CreateShader (System.String name) [0x00000] in <filename unknown>:0
at OpenRA.Graphics.Renderer..ctor () [0x00000] in <filename unknown>:0
This is apparently due to my using an onboard intel graphics card (82945G). There is a code fix here http://bugs.open-ra.org/issues/883
You can download the patch file and apply it using
git apply <filename.patch>
or you can just click on the file to see the changes (it's about 5 lines of code), directly edit the OpenRA.Renderer.Gl/Shader.cs file and make the required changes. |
|
| Back to top |
|
 |
mainstream
Level: 32
Position: Registered User
Joined: 30 Jan 2012
Posts: 3
Kel: 4 [ Donate ]
Online Status: Offline
|
Posted: Wed Feb 01, 2012 2:57 pm |
|
|
| Why would you wanna compile it when .deb's are available? |
|
| Back to top |
|
 |
Cmd. Matt
Level: 45

Position: Registered User
Joined: 01 May 2012
Posts: 515
Kel: 513 [ Donate ]
Online Status: Offline
|
Posted: Tue May 29, 2012 5:53 am |
|
|
| mainstream wrote (View Post): | | Why would you wanna compile it when .deb's are available? |
If you want to work with the source code.
Have a look at http://archive.getdeb.net/getdeb/ubuntu/pool/games/o/openra/openra_20120504-1~getdeb1.dsc to see the dependencies for Ubuntu:
| Code: | | Build-Depends: debhelper (>= 8.0.0), mono-gmcs, cli-common-dev (>= 0.8), libgl1-mesa-dev, libsdl1.2-dev, libsdl-gfx1.2-dev, libsdl-image1.2-dev, libsdl-mixer1.2-dev, libsdl-net1.2-dev, libsdl-ttf2.0-dev, libsmpeg-dev, libopenal-dev, libalut-dev |
|
|
| Back to top |
|
 |
tacozmeister
Level: 31
Position: Registered User
Joined: 26 Jun 2012
Posts: 126
Kel: 128 [ Donate ]
Online Status: Offline
|
Posted: Mon Jul 16, 2012 7:46 pm |
|
|
I think we should also add here where to find "settings.yaml" because I can't find it >_> And I wanna enable the Cg-Renderer for every time I start.
Also, you can find the main game folder at . |
|
| Back to top |
|
 |
Cmd. Matt
Level: 45

Position: Registered User
Joined: 01 May 2012
Posts: 515
Kel: 513 [ Donate ]
Online Status: Offline
|
Posted: Tue Jul 17, 2012 7:39 am |
|
|
You find it at ~/.openra/settings.yaml
The .mix files should belong to ~/.openra/Content/$MOD |
|
| Back to top |
|
 |
tacozmeister
Level: 31
Position: Registered User
Joined: 26 Jun 2012
Posts: 126
Kel: 128 [ Donate ]
Online Status: Offline
|
Posted: Tue Jul 17, 2012 7:03 pm |
|
|
Oh, you have to view hidden files by pressing Ctrl-H. There's the file I was looking for thanks |
|
| Back to top |
|
 |
tacozmeister
Level: 31
Position: Registered User
Joined: 26 Jun 2012
Posts: 126
Kel: 128 [ Donate ]
Online Status: Offline
|
Posted: Fri Jul 27, 2012 3:08 pm |
|
|
| Hmm, how does one install extra mods (for example, mine) on Ubuntu? I tried simply dragging and dropping my mod into /usr/share/openra/mods/, but it says I do not have sufficient permission. But whenever I run "sudo nautilus" and DO put the file in there, the game will not even read the file when I open it up. I'm 100% positive it isn't just my mod, because it works fine on Windows and all that jazz. |
|
| Back to top |
|
 |
|