[debian-edu-commits] debian-edu/pkg-team/ 02/03: Replace __FILE__
Javier Serrano Polo
jasp00-guest at moszumanska.debian.org
Mon Aug 29 23:13:57 UTC 2016
This is an automated email from the git hooks/post-receive script.
jasp00-guest pushed a commit to branch master
in repository lmms.
commit cfd66c5351aace9b07d54b492f64557e1ad90d3a
Author: Javier Serrano Polo <javier at jasp.net>
Date: Mon Aug 29 22:40:58 2016 +0200
Replace __FILE__
---
debian/changelog | 1 +
debian/patches/no-file.patch | 304 +++++++++++++++++++++++++++++++++++++++++++
debian/patches/series | 1 +
3 files changed, 306 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 495910d..970bd1f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,7 @@ lmms (1.1.3-4) unstable; urgency=medium
* Dropped workaround for #824715, wineg++ is fixed.
* Added contributors.
* Honor CONTRIBUTORS override.
+ * Replace __FILE__ (reproducibility).
-- Javier Serrano Polo <javier at jasp.net> Wed, 08 Jun 2016 01:25:37 +0200
diff --git a/debian/patches/no-file.patch b/debian/patches/no-file.patch
new file mode 100644
index 0000000..b6e3b11
--- /dev/null
+++ b/debian/patches/no-file.patch
@@ -0,0 +1,304 @@
+Description: Replace __FILE__
+ __FILE__ records the build path, which hinders reproducible builds.
+Author: Javier Serrano Polo <javier at jasp.net>
+Bug: https://github.com/LMMS/lmms/pull/2923
+Applied-Upstream: 1.1.91
+
+Index: lmms-1.1.3/plugins/flp_import/unrtf/attr.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/attr.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/attr.c 2016-08-29 22:25:38.000000000 +0200
+@@ -383,8 +383,8 @@
+ int i;
+ int total;
+
+- CHECK_PARAM_NOT_NULL(src);
+- CHECK_PARAM_NOT_NULL(dest);
++ CHECK_PARAM_NOT_NULL(src, "attr.c");
++ CHECK_PARAM_NOT_NULL(dest, "attr.c");
+
+ total = src->tos + 1;
+
+@@ -419,7 +419,7 @@
+ {
+ int i;
+
+- CHECK_PARAM_NOT_NULL(stack);
++ CHECK_PARAM_NOT_NULL(stack, "attr.c");
+
+ i=stack->tos;
+ while (i>=0)
+Index: lmms-1.1.3/plugins/flp_import/unrtf/convert.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/convert.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/convert.c 2016-08-29 22:25:38.000000000 +0200
+@@ -704,7 +704,7 @@
+ word_dump_date (Word *w)
+ {
+ int year=0, month=0, day=0, hour=0, minute=0;
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+ while (w) {
+ char *s = word_string (w);
+ if (*s == '\\') {
+@@ -781,7 +781,7 @@
+ {
+ Word *w2;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ while (w) {
+ int num;
+@@ -850,7 +850,7 @@
+ {
+ Word *w2;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ while(w) {
+ if ((w2=w->child)) {
+@@ -879,7 +879,7 @@
+ {
+ Word *w2;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ while(w) {
+ if ((w2=w->child)) {
+@@ -911,7 +911,7 @@
+ Word *child;
+
+ #if 1 /* amaral - 0.19.2 */
+- /* CHECK_PARAM_NOT_NULL(w); */
++ /* CHECK_PARAM_NOT_NULL(w, "convert.c"); */
+ if (!w) outstring+=QString().sprintf("AUTHOR'S COMMENT: \\info command is null!\n");
+ #endif
+
+@@ -1101,7 +1101,7 @@
+ {
+ int r,g,b;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ /* Sometimes, RTF color tables begin with a semicolon,
+ * i.e. an empty color entry. This seems to indicate that color 0
+@@ -1246,7 +1246,7 @@
+ cmd_field (Word *w, int align, char has_param, int num) {
+ Word *child;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ while(w) {
+ child = w->child;
+@@ -3100,7 +3100,7 @@
+
+ enum { SMALL=0, BIG=1 };
+
+- CHECK_PARAM_NOT_NULL(s);
++ CHECK_PARAM_NOT_NULL(s, "convert.c");
+
+ state=SMALL; /* Pacify gcc, st001906 - 0.19.6 */
+ if (simulate_smallcaps) {
+@@ -3305,7 +3305,7 @@
+ int paragraph_begined=false;
+ int paragraph_align=ALIGN_LEFT;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "convert.c");
+
+ if (!coming_pars_that_are_tabular && within_table) {
+ end_table();
+@@ -3661,7 +3661,7 @@
+ void
+ word_print (Word *w, QString & _s)
+ {
+- CHECK_PARAM_NOT_NULL (w);
++ CHECK_PARAM_NOT_NULL (w, "convert.c");
+
+ outstring = "";
+ if (!inline_mode) {
+Index: lmms-1.1.3/plugins/flp_import/unrtf/error.h
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/error.h 2016-08-29 22:14:35.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/error.h 2016-08-29 22:20:37.000000000 +0200
+@@ -34,9 +34,9 @@
+ *--------------------------------------------------------------------*/
+
+
+-#define CHECK_PARAM_NOT_NULL(XX) { if ((XX)==NULL) { fprintf (stderr, "internal error: null pointer param in %s at %d\n", __FILE__, __LINE__); exit (1); }}
++#define CHECK_PARAM_NOT_NULL(XX, FF) { if ((XX)==NULL) { fprintf (stderr, "internal error: null pointer param in %s at %d\n", (FF), __LINE__); exit (1); }}
+
+-#define CHECK_MALLOC_SUCCESS(XX) { if ((XX)==NULL) { fprintf (stderr, "internal error: cannot allocate memory in %s at %d\n", __FILE__, __LINE__); exit (1); }}
++#define CHECK_MALLOC_SUCCESS(XX, FF) { if ((XX)==NULL) { fprintf (stderr, "internal error: cannot allocate memory in %s at %d\n", (FF), __LINE__); exit (1); }}
+
+
+ extern void usage(void);
+Index: lmms-1.1.3/plugins/flp_import/unrtf/output.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/output.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/output.c 2016-08-29 22:25:38.000000000 +0200
+@@ -99,7 +99,7 @@
+ void
+ op_free (OutputPersonality *op)
+ {
+- CHECK_PARAM_NOT_NULL(op);
++ CHECK_PARAM_NOT_NULL(op, "output.c");
+
+ my_free ((char*) op);
+ }
+@@ -128,7 +128,7 @@
+ static char output_buffer[2]={ 0, 0 };
+ #endif
+
+- CHECK_PARAM_NOT_NULL(op);
++ CHECK_PARAM_NOT_NULL(op, "output.c");
+
+ #if 1 /* daved - 0.20.5 */
+ if (no_remap_mode == true && ch < 256)
+@@ -231,7 +231,7 @@
+ size = ( size * 3 ) / 2;
+ int found_std_expr = false;
+
+- CHECK_PARAM_NOT_NULL(op);
++ CHECK_PARAM_NOT_NULL(op, "output.c");
+
+ /* Look for an exact match with a standard point size.
+ */
+@@ -360,7 +360,7 @@
+ {
+ int found_std_expr = false;
+
+- CHECK_PARAM_NOT_NULL(op);
++ CHECK_PARAM_NOT_NULL(op, "output.c");
+
+ /* Look for an exact match with a standard point size.
+ */
+Index: lmms-1.1.3/plugins/flp_import/unrtf/parse.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/parse.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/parse.c 2016-08-29 22:25:38.000000000 +0200
+@@ -124,7 +124,7 @@
+ {
+ int ch;
+
+- CHECK_PARAM_NOT_NULL(f);
++ CHECK_PARAM_NOT_NULL(f, "parse.c");
+
+ if (ungot_char>=0) {
+ ch = ungot_char;
+@@ -248,7 +248,7 @@
+ int has_numeric_param=false; /* if is_control_word==true */
+ int need_unget=false;
+
+- CHECK_PARAM_NOT_NULL(f);
++ CHECK_PARAM_NOT_NULL(f, "parse.c");
+
+ current_max_length = 10; /* XX */
+
+@@ -434,7 +434,7 @@
+ Word * first_word = NULL;
+ Word * new_word = NULL; /* temp */
+
+- CHECK_PARAM_NOT_NULL(f);
++ CHECK_PARAM_NOT_NULL(f, "parse.c");
+
+ do {
+ if (!read_word(f))
+Index: lmms-1.1.3/plugins/flp_import/unrtf/ur_malloc.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/ur_malloc.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/ur_malloc.c 2016-08-29 22:25:38.000000000 +0200
+@@ -86,7 +86,7 @@
+
+ void
+ my_free (char* ptr) {
+- CHECK_PARAM_NOT_NULL(ptr);
++ CHECK_PARAM_NOT_NULL(ptr, "ur_malloc.c");
+
+ free (ptr);
+ }
+@@ -120,7 +120,7 @@
+ unsigned long len;
+ char *ptr;
+
+- CHECK_PARAM_NOT_NULL(src);
++ CHECK_PARAM_NOT_NULL(src, "ur_malloc.c");
+
+ len = strlen(src);
+ ptr = my_malloc (len+1);
+Index: lmms-1.1.3/plugins/flp_import/unrtf/word.c
+===================================================================
+--- lmms-1.1.3.orig/plugins/flp_import/unrtf/word.c 2016-08-29 22:20:11.000000000 +0200
++++ lmms-1.1.3/plugins/flp_import/unrtf/word.c 2016-08-29 22:25:38.000000000 +0200
+@@ -93,7 +93,7 @@
+ char *
+ word_string (Word *w) {
+ char *str;
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "word.c");
+ if (w->hash_index) str = hash_get_string (w->hash_index);
+ else str = NULL;
+ return str;
+@@ -139,7 +139,7 @@
+ Word *prev;
+ Word *w2;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "word.c");
+
+ while (w) {
+ w2 = w->child;
+@@ -191,7 +191,7 @@
+ {
+ char *s;
+
+- CHECK_PARAM_NOT_NULL(w);
++ CHECK_PARAM_NOT_NULL(w, "word.c");
+
+ printf ("\n");
+ indent_level += 2;
+Index: lmms-1.1.3/plugins/zynaddsubfx/zynaddsubfx/src/Misc/Util.cpp
+===================================================================
+--- lmms-1.1.3.orig/plugins/zynaddsubfx/zynaddsubfx/src/Misc/Util.cpp 2016-08-29 21:00:58.000000000 +0200
++++ lmms-1.1.3/plugins/zynaddsubfx/zynaddsubfx/src/Misc/Util.cpp 2016-08-29 21:02:05.000000000 +0200
+@@ -190,8 +190,7 @@
+ return;
+ }
+ fprintf(stderr,
+- "ERROR: invalid buffer returned %s %d\n",
+- __FILE__,
++ "ERROR: invalid buffer returned src/Misc/Util.cpp %d\n",
+ __LINE__);
+ }
+
+Index: lmms-1.1.3/src/core/fft_helpers.cpp
+===================================================================
+--- lmms-1.1.3.orig/src/core/fft_helpers.cpp 2016-08-29 21:00:58.000000000 +0200
++++ lmms-1.1.3/src/core/fft_helpers.cpp 2016-08-29 21:02:05.000000000 +0200
+@@ -204,7 +204,7 @@
+
+ if ( (j_min<0)||(j_max<0) )
+ {
+- fprintf(stderr, "Error: calc13octaveband31() in %s line %d failed.\n", __FILE__, __LINE__);
++ fprintf(stderr, "Error: calc13octaveband31() in fft_helpers.cpp line %d failed.\n", __LINE__);
+ return -1;
+ }
+
+Index: lmms-1.1.3/src/core/midi/MidiAlsaSeq.cpp
+===================================================================
+--- lmms-1.1.3.orig/src/core/midi/MidiAlsaSeq.cpp 2016-08-29 21:00:58.000000000 +0200
++++ lmms-1.1.3/src/core/midi/MidiAlsaSeq.cpp 2016-08-29 21:02:05.000000000 +0200
+@@ -117,7 +117,7 @@
+ // use a pipe to detect shutdown
+ if( pipe( m_pipe ) == -1 )
+ {
+- perror( __FILE__ ": pipe" );
++ perror( "MidiAlsaSeq: pipe" );
+ }
+
+ start( QThread::IdlePriority );
diff --git a/debian/patches/series b/debian/patches/series
index d1e4810..f49af34 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -16,3 +16,4 @@ copyright-fixes.patch
sort-glob.patch
contributors.patch
honor-contributors.patch
+no-file.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-edu/pkg-team/lmms.git
More information about the debian-edu-commits
mailing list