File: avoid_date_cpp_macro.diff

package info (click to toggle)
oolite 1.84-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 124,644 kB
  • ctags: 3,975
  • sloc: objc: 132,132; ansic: 3,138; sh: 559; perl: 359; makefile: 276; php: 5
file content (27 lines) | stat: -rw-r--r-- 1,203 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Description: avoid __DATE__ C pre-processor macro for build reproducibility
 The version string should be sufficient for the intended purpose as I
 understand it.
 .
 See
 https://wiki.debian.org/ReproducibleBuilds/About#Why_do_we_want_reproducible_builds.
 and https://wiki.debian.org/ReproducibleBuilds/TimestampsProposal.
Author: Nicolas Boulenguez <nicolas@debian.org>

--- a/src/SDL/MyOpenGLView.m
+++ b/src/SDL/MyOpenGLView.m
@@ -196,13 +196,9 @@
 
 	[OOSound setUp];
 
-	// Generate the window caption, containing the version number and the date the executable was compiled.
-	static char windowCaption[128];
+	// Generate the window caption, containing the version number.
 	NSString *versionString = [NSString stringWithFormat:@"Oolite v%@", [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleVersion"]];
-
-	strcpy (windowCaption, [versionString UTF8String]);
-	strcat (windowCaption, " - "__DATE__);
-	SDL_WM_SetCaption (windowCaption, "Oolite");	// Set window title.
+	SDL_WM_SetCaption ([versionString UTF8String], "Oolite");	// Set window title.
 
 #if OOLITE_WINDOWS
 	// needed for enabling system window manager events, which is needed for handling window movement messages