Author Topic: Upgrading to the nightly  (Read 94753 times)

Offline abitlost

  • Squaddie
  • *
  • Posts: 3
    • View Profile
Re: Upgrading to the nightly
« Reply #75 on: May 13, 2015, 08:22:59 pm »
Thanks again for replying so quickly myk002, your fix worked perfectly! You're a star!!  ;D

Offline 7Saturn

  • Colonel
  • ****
  • Posts: 457
    • View Profile
Re: Upgrading to the nightly
« Reply #76 on: May 13, 2015, 11:01:59 pm »
Code: [Select]
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j10
so this way, you don't need to run ccmake at all, just cmake.  you can set other vars on the initial call to cmake too.  This is the one I use to get all set up on OSX:
Code: [Select]
CC=/usr/bin/clang CXX=/usr/bin/clang++ cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$HOME/bin/openxcom.inst ..
And when not entering a value after
Code: [Select]
make -j it runs awesomely fast. That kicks ass. Thanks for the hints (also to winterheart). Now I only have to find a way, to automatically generate something for the version-string, locally, and I'll be happy. =)

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: Upgrading to the nightly
« Reply #77 on: May 14, 2015, 02:37:34 am »
cmake will pick up the git revision so that should be covered too

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: Upgrading to the nightly
« Reply #78 on: May 14, 2015, 02:48:26 am »
Interesting.. make -j uses however many jobs you can, whereas -j10 would limit it to 10 jobs. I would have expected that 10 jobs would be high enough. I'll have to try it since taking forever is one of the main reasons why I don't update more often..

Offline 7Saturn

  • Colonel
  • ****
  • Posts: 457
    • View Profile
Re: Upgrading to the nightly
« Reply #79 on: May 14, 2015, 11:50:55 am »
cmake will pick up the git revision so that should be covered too
Apparently, that doesn't mean a thing, when using the cmake/ccmake-way with downloaded zip-archive. I always found it saying version "1.0". I found a way to change it, using the date and time of now, in a shell script. But it would make be much more sense, if the official nightly-version-string were to be included.
Interesting.. make -j uses however many jobs you can, whereas -j10 would limit it to 10 jobs. I would have expected that 10 jobs would be high enough. I'll have to try it since taking forever is one of the main reasons why I don't update more often..
Well, I already found if having a problem, but I'm still working on the question, if it really comes from the -j-idea. At my site it doesn't take more than two minutes, using a script that does everything, including mounting my network-drive, where the archive with vanilla- and patch-files lies. But I reverted to -j10 in order to make sure everything works smoothly.

Edit:
I just tried it this way, which lead my to version »1.0«, no nightly-notification, but the compiling felt like takeing forever...
« Last Edit: May 14, 2015, 01:25:16 pm by 7Saturn »

Offline Arthanor

  • Commander
  • *****
  • Posts: 2488
  • XCom Armoury Quartermaster
    • View Profile
Re: Upgrading to the nightly
« Reply #80 on: May 14, 2015, 04:01:58 pm »
Apparently, that doesn't mean a thing, when using the cmake/ccmake-way with downloaded zip-archive. I always found it saying version "1.0". I found a way to change it, using the date and time of now, in a shell script. But it would make be much more sense, if the official nightly-version-string were to be included.
If you download the zip-archive instead of using git to get the code, then you cmake/ccmake has no way of getting the git commit. If you use the steps outlined on the wiki with git, then you will have a git repo from which to compile which will give you a hash (the version number looks like 1.0g######).

It also allows you to pull new features into the code even though Warboy/Supsuper did not want to pull them in the main repo, or checkout an older version if you want to run a mod that hasn't updated to the latest nighly yet. But it's a bit more advanced than downloading the zip file.

Quote
Well, I already found if having a problem, but I'm still working on the question, if it really comes from the -j-idea. At my site it doesn't take more than two minutes, using a script that does everything, including mounting my network-drive, where the archive with vanilla- and patch-files lies. But I reverted to -j10 in order to make sure everything works smoothly.

Edit:
I just tried it this way, which lead my to version »1.0«, no nightly-notification, but the compiling felt like takeing forever...

I first tried the way you just linked, but it did not work for some reason.. While trying to fix it we outlined upon this way with cmake/ccmake. The computer I have at home is a crappy little notebook, so that might be why it's so slow ;) OpenXCom is pretty much the pinnacle of what I can play on this, which is fine by me since it's also the pinnacle of gaming!

Offline 7Saturn

  • Colonel
  • ****
  • Posts: 457
    • View Profile
Re: Upgrading to the nightly
« Reply #81 on: May 14, 2015, 04:59:35 pm »
I'm beginning to understand a few things. I first tried it like this, failing. Just now, I tried it by using the line
Code: [Select]
git clone https://github.com/SupSuper/OpenXcom.gitinstead of the one in the link, and it runs just right, giving me the hash. I believe, I will change my skripts, now. =) Just one question: Is there any way, to get a versioning like on the download-page (see screen shot).

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: Upgrading to the nightly
« Reply #82 on: May 14, 2015, 05:57:17 pm »
I'm beginning to understand a few things. I first tried it like this, failing. Just now, I tried it by using the line
Code: [Select]
git clone https://github.com/SupSuper/OpenXcom.gitinstead of the one in the link, and it runs just right, giving me the hash. I believe, I will change my skripts, now. =) Just one question: Is there any way, to get a versioning like on the download-page (see screen shot).
I added a note to the wiki page about setting up your ssh key so the git clone git@ form will work, and I added a note that if you don't have a github account, you should use the git clone https://github.com/SupSuper/OpenXcom.git form you used.

You can always set the version string to whatever you like by compiling with -DOPENXCOM_VERSION_GIT=whateveryouwant, but I don't think you can set it when using cmake to build.  you can modify the CMakeLists.txt file to make it configurable, but for now it sets it internally according to the git revision and doesn't read anything custom from the config or commandline.  you might be able to get around it by sticking it in your custom CXXFLAGS or something, though.

Offline 7Saturn

  • Colonel
  • ****
  • Posts: 457
    • View Profile
Re: Upgrading to the nightly
« Reply #83 on: May 14, 2015, 06:26:30 pm »
I'm using the steamroller tactics: Automatically changing the
Code: [Select]
#define OPENXCOM_VERSION_SHORT "1.0"line to
Code: [Select]
#define OPENXCOM_VERSION_SHORT "1.0 Nightly <Dateandtime>"by use of a short perl-command in the script. ;D

Offline winterheart

  • Colonel
  • ****
  • Posts: 180
  • Fellow Squaddie
    • View Profile
Re: Upgrading to the nightly
« Reply #84 on: May 14, 2015, 07:47:21 pm »
I'm using the steamroller tactics: Automatically changing the
Code: [Select]
#define OPENXCOM_VERSION_SHORT "1.0"line to
Code: [Select]
#define OPENXCOM_VERSION_SHORT "1.0 Nightly <Dateandtime>"by use of a short perl-command in the script. ;D
Pffft.

Code: [Select]
make CXX_DEFINES="-DOPENXCOM_VERSION_GIT=\\\"\ Super\ Awesome\ Edition\\\""

Now you have real CMake powah.

NB: Backslashes required for escaping symbols like space, \ and "

Online Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3348
    • View Profile
Re: Upgrading to the nightly
« Reply #85 on: May 17, 2015, 05:45:42 pm »
myk002 could you add info about your changes to https://ufopaedia.org?

Offline myk002

  • Colonel
  • ****
  • Posts: 227
    • View Profile
Re: Upgrading to the nightly
« Reply #86 on: May 17, 2015, 07:13:42 pm »
in progress.  right now i'm /reading/ all the current openxcom UFOpedia articles before I go making changes.

Offline Tarvis

  • Colonel
  • ****
  • Posts: 111
    • View Profile
Re: Upgrading to the nightly
« Reply #87 on: May 31, 2015, 06:53:23 am »
I guess it's a bit late now, but would it be better for OpenXcom to look for UFO's files in the 'XCOM' folder instead? This would make OpenXcom work right out of the box by installing it into the directory of the Steam version, for example, without having to rename it. Of course it's still trivial.

Perhaps it could check either one?

Offline pilot00

  • Colonel
  • ****
  • Posts: 487
  • Back in the day it was gameplay not a feature....
    • View Profile
Re: Upgrading to the nightly
« Reply #88 on: May 31, 2015, 02:50:42 pm »
Question: Are the Universal patch files necessary to overright or are they included in the nightly?

Offline 7Saturn

  • Colonel
  • ****
  • Posts: 457
    • View Profile
Re: Upgrading to the nightly
« Reply #89 on: May 31, 2015, 03:29:55 pm »
As they patch the vanilla files, they are completely separate, as the vanilla files are never included.