Got rid of obsolete version number encoding.

The old version numbers were retrieved from SVN; of course this no longer works. Now no versions are retrieved on normal building. Instead, this is covered by the dist building script.
This commit is contained in:
Cas Cremers 2007-05-20 16:08:56 +02:00
parent db78b7f941
commit f56a10646f
6 changed files with 2 additions and 873 deletions

View File

@ -24,9 +24,6 @@ set (Scyther_sources
# If we are in a debug mode we want to be strict
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wall -DDEBUG")
# Determine version number
include (SVNVersion.cmake)
# Make scanner and parser
include (ScannerParser.cmake)

View File

@ -1,58 +0,0 @@
################################################################
# Name: SVNVersion.cmake
# Purpose: Determine subversion revision id for Scyther
# and write it into a macro in version.h
# Author: Cas Cremers
################################################################
# Technically, this only needs to be redone each time a file
# changes, so this is a target with dependencies on all files.
# Checkout version info
find_program (SVNVERSION_EXECUTABLE NAMES svnversion)
mark_as_advanced (SVNVERSION_EXECUTABLE)
mark_as_advanced (SVNVERSION_DYNAMIC)
set (SVNVERSION_DYNAMIC false)
if (SVNVERSION_EXECUTABLE)
# test whether svnversion gives useful info
execute_process (
COMMAND ${SVNVERSION_EXECUTABLE} --no-newline
OUTPUT_VARIABLE SVN_Result
)
mark_as_advanced (SVN_Result)
if (NOT ${SVN_Result} STREQUAL "exported")
# svnversion gives useful stuff
## write to file
#file (WRITE version.h "#define SVNVERSION \"${SVN_Result}\"\n")
set (SVNVERSION_DYNAMIC true)
endif (NOT ${SVN_Result} STREQUAL "exported")
mark_as_advanced (SVNDIR)
endif (SVNVERSION_EXECUTABLE)
# If dynamic generation is required, this means another target in the
# makefile
if (SVNVERSION_DYNAMIC)
# add a command to generate version.h
message (STATUS "Generating version.h dynamically using svnversion command")
add_custom_command (
OUTPUT version.h
# The version number depends on all the files; if they
# don't change, neither should the version number
# (although this might be incorrect when updating the
# current directory)
DEPENDS ${Scyther_sources}
DEPENDS .svn
COMMAND ./subbuild-version-information.sh
COMMENT "Generating subversion and tag version information in version.h using svnversion command"
)
else (SVNVERSION_DYNAMIC)
# Don't dynamically generate, simply empty every time
file (WRITE version.h "#define SVNVERSION \"Unknown\"\n#define TAGVERSION \"Unknown\"")
endif (SVNVERSION_DYNAMIC)
# add the version number to the sources
set_source_files_properties(version.h
PROPERTIES
GENERATED true)
set (Scyther_sources ${Scyther_sources} version.h)

View File

@ -1,789 +0,0 @@
[Project]
FileName=Scyther.dev
Name=Scyther
UnitCount=72
Type=1
Ver=1
ObjFiles=
Includes=
Libs=
PrivateResource=
ResourceIncludes=
MakeIncludes=
Compiler=
CppCompiler=
Linker=
IsCpp=0
Icon=
ExeOutput=..\gui\Scyther
ObjectOutput=
OverrideOutput=0
OverrideOutputName=Scyther.exe
HostApplication=
Folders=
CommandLine=
UseCustomMakefile=0
CustomMakefile=
IncludeVersionInfo=0
SupportXPThemes=0
CompilerSet=0
CompilerSettings=0000000000000000000000
[Unit1]
FileName=xmlout.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit2]
FileName=arachne.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit3]
FileName=arachne.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit4]
FileName=binding.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit5]
FileName=binding.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit6]
FileName=claim.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit7]
FileName=claim.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit8]
FileName=color.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit9]
FileName=color.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit10]
FileName=compiler.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit11]
FileName=compiler.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit12]
FileName=cost.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit13]
FileName=cost.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit14]
FileName=debug.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit15]
FileName=debug.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit16]
FileName=depend.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit17]
FileName=depend.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit18]
FileName=dotout.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit19]
FileName=dotout.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit20]
FileName=error.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit21]
FileName=error.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit22]
FileName=heuristic.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit23]
FileName=heuristic.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit24]
FileName=hidelevel.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit25]
FileName=hidelevel.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit26]
FileName=intruderknowledge.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit27]
FileName=intruderknowledge.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit28]
FileName=knowledge.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit29]
FileName=knowledge.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit30]
FileName=label.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit31]
FileName=label.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit32]
FileName=list.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit33]
FileName=list.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit35]
FileName=mgu.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit36]
FileName=pheading.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit37]
FileName=prune_bounds.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit38]
FileName=prune_bounds.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit39]
FileName=prune_theorems.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit40]
FileName=prune_theorems.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit41]
FileName=role.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit42]
FileName=role.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit43]
FileName=specialterm.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit44]
FileName=specialterm.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit45]
FileName=states.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit46]
FileName=states.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit48]
FileName=switches.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit49]
FileName=symbol.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit50]
FileName=symbol.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit51]
FileName=system.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit52]
FileName=system.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit53]
FileName=tac.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit54]
FileName=tac.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit55]
FileName=term.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit56]
FileName=term.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit57]
FileName=termlist.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit58]
FileName=termlist.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit59]
FileName=termmap.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit60]
FileName=termmap.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit61]
FileName=timer.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit62]
FileName=timer.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit63]
FileName=type.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit64]
FileName=type.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit65]
FileName=warshall.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit66]
FileName=warshall.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit67]
FileName=xmlout.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit68]
FileName=main.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit69]
FileName=version.h
CompileCpp=0
Folder=
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit70]
FileName=parser.h
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit71]
FileName=scanner.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[VersionInfo]
Major=0
Minor=1
Release=1
Build=1
LanguageID=1033
CharsetID=1252
CompanyName=
FileVersion=
FileDescription=Developed using the Dev-C++ IDE
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=
AutoIncBuildNr=0
[Unit34]
FileName=mgu.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit72]
FileName=parser.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit73]
FileName=scanner.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit74]
FileName=parser.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=
[Unit47]
FileName=switches.c
CompileCpp=0
Folder=Scyther
Compile=1
Link=1
Priority=1000
OverrideBuildCmd=0
BuildCmd=

View File

@ -1,19 +0,0 @@
#!/bin/sh
#
# Arguments:
#
# svnversion executable path
#
SVNVERSION=`svnversion`
TAGVERSION=`awk 'BEGIN { FS="\""; } { print $2; }' ../gui/Gui/Version.py`
echo $SVNVERSION
echo $TAGVERSION
# Fix svnversion information
echo "#define SVNVERSION \"$SVNVERSION\"" >version.h
# Fix version tag
echo "#define TAGVERSION \"$TAGVERSION\"" >>version.h

View File

@ -1247,10 +1247,7 @@ switcher (const int process, int index, int commandline)
if (switches.expert)
{
#ifdef DEBUG
printf ("Revision %s, compiled with debugging support.\n",
SVNVERSION);
#else
printf ("Revision %s\n", SVNVERSION);
printf ("Compiled with debugging support.\n");
#endif
}
printf ("Code by Cas Cremers\n");

1
src/version.h Normal file
View File

@ -0,0 +1 @@
#define TAGVERSION "unknown"