Ansgar Becker wrote:
> I'm about to change something that will break
> the simplicity of compiling the D10 package.
That would suck donkey ass.. I've talked to two new people
within the last couple of days who've just installed an IDE,
downloaded the source code, and should be compiling by now.
Who knows, they might join in and help with something if
the barrier to doing so is low enough..
> The build_super.cmd needs to check the revision of
> the working copy and then set it in the sources.
Yeah, the current state of using $Revision kind of sucks.
It doesn't get updated to reflect the WC state after
an 'svn update' unless main.pas is modified, which has
left us with executables containing corrupted version
numbers on the website :-/.
> This can be done by using SubWcRev.exe from TortoiseSVN\bin
> directory. SubWcRev.exe will read
> \source\const_template.inc and save its parsed result into
> \source\const.inc so that this file contains the final
> revision number. The command line is as follows:
>
> %ProgramFiles%\TortoiseSVN\bin\SubWCRev.exe ..\..\
> ..\..\source\const_template.inc ..\..\source\const.inc -f
Whoever wrote SubWCRev really need to fix it so that it will
just replace the revision number in existing files instead of
requiring a pair of old+new files.
I can fix SubWCRev if you want, but please don't break stuff
just to satisfy the requirements of a poorly designed tool.
> The Delphi 11 project file supports pre-build commands so
> I can set the needed command in \packages\delphi11\heidisql.dproj.
Still crap IMHO.
Even if you do as stated above, you're going to have a file which
is included for compilation in the project, but which doesn't exist
before after the build phase. The IDE's default behaviour is to
remove this file from the project (after asking for confirmation from
the user) if it's touched. Crap, crap, crap.
You're also going to have a file which, when modified, will silently
be overwritten with another version when the project is built.
Mega crap.
SubWCRev seems designed for unix makefiles where a temporary file can
be created just for the purpose of compiling and then removed again
afterwards. It's just plain crap when used together with a good IDE.
> Also the build_super.cmd is capable of doing that because we're in a
> batch file. But the Delphi 10 IDE does NOT support pre-build commands.
For the .cmd file it's a fine solution.
> workaround for D10 users:
> - manually create a local copy of const_template.inc and name
> it "const.inc"
> - ignore strings like $WCREV$ in the about-box
> - manually update const.inc whenever const_template.inc was
> SVN-modified.
>
> But these 3 steps are probably too much hassle for new developers?
> Should I break simplicity for D10 users? I'm hesitating...
Rightly so IMHO.
Let's just fix SubWCRev so it works with strings, just as $Revision.
We can't make it run automatically on 'svn update' and 'svn commit'
unfortunately, so we'll still have to put it in the pre-build
commands for various IDE versions and the build .cmd. I guess
that's OK, we need to have something there anyway in order to
get the "has local modifications?" flag correctly into the source
code and the final executable.
I'll take a look at fixing SubWCRev. I think it's GPL, so we can
include the modified version in our repository under 'extra'.
Received on Wed Sep 5 13:21:55 2007