Author Topic: Merging... [Trunk no longer broken]  (Read 1565 times)

daniel.santos

  • Guest
Merging... [Trunk no longer broken]
« on: 25 September 2009, 18:45:43 »
Sorry, if you need the trunk, explicitly specify revision 234 (I think is the correct revision).  Merging has been exceedingly due to sourceforge's very crappy servers!  It's been SO slow!  It's faster now, but now I have all of these:

svn: Attempt to add tree conflict that already exists
svn: Error reading spooled REPORT request response

Because it lost the connection to the server last time.  I've had to re-do them twice now and it's really pissing me off.  I'm going to see if there's a way to fix this without reverting the affected directories and re-doing the whole goddam merge!
« Last Edit: 28 September 2009, 02:26:28 by daniel.santos »

daniel.santos

  • Guest
Re: Merging...
« Reply #1 on: 27 September 2009, 23:36:36 »
Ok, I've completed the actual "merge" part for the trunk, but I'm afraid it didn't go very well.  For whatever reason, the merge wanted to go back a long way.   don't think I did a very good job, as a whole, with this merge.  I think that what I should have done was to just run svn merge --record-only and used kdiff3 to merge each file myself.  The result appears that I have accidentally introduced changes that were later reverted, and I'm sorry.  I'm going to try to make sure that I get all of these corrected, but just keep an eye out for anything like this as you work with the code.  Either way, I'm cleaning it up now an I always learn from my mistakes (especially the painful ones!).

And speaking of pain, because I wanted to get this out of the way, I have moved glest_map_editor and glest_game to map_editor and game, respectively.  As soon as I get it building again, I'll commit and post to this thread again.

And now I want to note a few things, some changes that I've reverted because I disagree with them.  You guys have done some amazing work while I was absent!  At the same time, some stuff went to "hell in a hand basket" as it were, with regard to conventions (we've discussed a lot of this before).  This is largely my fault, not just for not being able to be there for a long time, but for not having thoroughly documented project conventions before.  I have to say that having spent a *lot* of time last year trying to get the code formatted to a certain standard added to my frustration to find a lot of it changed to something else.

Enough of my griping though, these are the issues. :)  As always, if somebody disagrees with the technical accuracy or efficacy of any of these points, PLEASE speak your mind!  I am certainly not perfect and have learned much from working with you guys already!!  ;D  I realize that I am fairly OCD about code formatting, and that's probably mostly just because I spent so much time trying to re-format it before. :)  (But I don't actually have OCD.  I do have CDO, though.  It's a lot like OCD, but just with the letters in alphabetical order, as they aught to be.)

  • Never inline constructors that seem simple (e.g., GameSettings default ctor) when it has a lot of data members.  The reason for this is even though the source code is very brief, the generate code has to have constructors for each data member.  If these constructors are in turn inlined (like std::string) then the size continues to grow, making these very bad candidates for inline.  Remember also that with compilers, like gcc, that do not yet have support for cross-object optimizations (a.k.a., "whole program optimizations") that if the compiler refused to inline something (which it can) it will create a static copy of that function in each object file where it refuses to inline it, thus continuing to bloat the app even further.
  • In general, try to keep in mind the lack of cross-object optimizations on gcc.  I saw one function that silnarm outlined that I don't blame you for (it was kinda big and if it isn't really high-use, then sure, out-line it), but others that would lead to slower code on gcc.
  • I noticed that the tinyxml sources were included in the tree.  Please never add sources to an external project that's supposed to be a dependency, unless we decide that we *really* want to do that, and the only reason I can think of is because we want to alter their code.  The proper way to do this is to modify the Jamfile, configure.ac, etc. so that any needed include directories are included (-Ixxx CPPFLAGS) and the libraries are linked in (-Lxxx and -lxxx added to LDFLAGS).  I'm not highly skilled with the m4 language and I tend to wait for others to do this part, but hard-coding these values (as they work on your system) into Jamrules is better than including their sources in our tree.

I'll be adding to the above list as I go. =)

daniel.santos

  • Guest
Re: Merging...
« Reply #2 on: 28 September 2009, 02:20:02 »
I have rolled back my attempts to merge 0.2.13 into the trunk.  I will do it again with "svn merge --record-only" and then manually merging differences with kdiff3, so I don't have to mess with 10 million changes back to revision 187 *puke*

EDIT: F**K!!  The server died on commit.  I'm trying again:
svn: Commit failed (details follow):
svn: CHECKOUT of '/svnroot/glestae/!svn/ver/258/trunk/source/shared_lib/sources/graphics/particle.cpp': SSL handshake failed: Secure connection truncated (https://glestae.svn.sourceforge.net)
svn: Your commit message was left in a temporary file:
svn:    '/home/daniel/proj/gae/main/svn-commit.tmp'

EDIT: whew, it didn't die that time :(
« Last Edit: 28 September 2009, 02:26:17 by daniel.santos »

Yggdrasil

  • Local Moderator
  • Ornithopter
  • ********
  • Posts: 408
    • View Profile
Re: Merging...
« Reply #3 on: 28 September 2009, 11:29:50 »
I'm confused. Is the merge finished? Is trunk compilable (after one messes around with tinyxml)?
EDIT: ok, got it building but i can't run it:
Code: [Select]
$ ./glestadv
Exception: Can't open propertyMap file: data/lang/english.lng
language files are in gae/data/lang and there is no english.lng.

I noticed that the tinyxml sources were included in the tree.  Please never add sources to an external project that's supposed to be a dependency, unless we decide that we *really* want to do that, and the only reason I can think of is because we want to alter their code.  The proper way to do this is to modify the Jamfile, configure.ac, etc. so that any needed include directories are included (-Ixxx CPPFLAGS) and the libraries are linked in (-Lxxx and -lxxx added to LDFLAGS).  I'm not highly skilled with the m4 language and I tend to wait for others to do this part, but hard-coding these values (as they work on your system) into Jamrules is better than including their sources in our tree.
The problem is: tinyxml has no install routine and the last release package also has no way to build libraries on linux. It only builds a test program. There's a scons buildfile in cvs to build libraries. And it's unmaintained for years. See:
https://forum.megaglest.org/index.php?topic=4471.msg28907#msg28907
« Last Edit: 28 September 2009, 11:56:43 by Yggdrasil »

daniel.santos

  • Guest
Re: Merging... [Trunk no longer broken]
« Reply #4 on: 28 September 2009, 16:57:00 »
The problem is: tinyxml has no install routine and the last release package also has no way to build libraries on linux. It only builds a test program. There's a scons buildfile in cvs to build libraries. And it's unmaintained for years. See:
https://forum.megaglest.org/index.php?topic=4471.msg28907#msg28907
Crap!  Sorry then, I didn't realize that.  On Gentoo, there's a package that sticks the header in /usr/include and a shared object file in /usr/lib/tinyxml.so.  Maybe somebody should pick up maintainence of that library as it's really useful!  I would like a .a (for static linkage) personally.  Sorry, I'll go read up on this topic you posted later today!

As for the language thing, that's because the data is for the newer language code that isn't merged yet because I reverted everything.  For now, you can make a symlink to fix the problem:
Code: [Select]
#first cd to wherever you checked out the trunk
mkdir -p data/game/data/lang
cd data/game/data/lang
ln -s ../../gae/data/lang/en.lng english.lng

EDIT: If you're on windows, you'll have to create the directory data/game/data/lang and copy the file  data/game/gae/data/lang/en.lng to data/game/data/lang/english.lng (all relative to the project root)

This wont be a problem after I re-do the merge.  Instead of the old .ini file setting where it specifies a language file, you'll have a new .ini setting that specifies locale in a standard ISO 639 fashion

language[_territory][@script][.encoding]

Examples:
enGeneric English
en_USUS English
esSpanish
gl.iso885915Generic Galician (no territory specified) using ISO 8859-15 encoding
etc..
« Last Edit: 28 September 2009, 16:58:40 by daniel.santos »

 

anything