Package: kali
Version: 3.1-17
Severity: important
Tags: patch
User: [email protected]
Usertags: 2.27

kali 3.1-17 fails to build with glibc 2.27 (2.27-0experimental0 from
experimental):

| cc -DXFORM -Wdate-time -D_FORTIFY_SOURCE=2 -D_FILE_OFFSET_BITS=64 -g -O2 
-fdebug-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat 
-Werror=format-security -Wall   -Wdate-time -D_FORTIFY_SOURCE=2 
-D_FILE_OFFSET_BITS=64  -c -o kali.o kali.c
| kali.c: In function 'handleRedraw':
| kali.c:124:3: warning: implicit declaration of function 'reshapeviewport' 
[-Wimplicit-function-declaration]
|    reshapeviewport();
|    ^~~~~~~~~~~~~~~
| kali.c:131:3: warning: implicit declaration of function 'swapbuffers'; did 
you mean 'setbuffer'? [-Wimplicit-function-declaration]
|    swapbuffers();
|    ^~~~~~~~~~~
|    setbuffer
| kali.c: In function 'doRedraw':
| kali.c:148:5: warning: implicit declaration of function 'user_event_cb' 
[-Wimplicit-function-declaration]
|      user_event_cb(&newev, NULL);
|      ^~~~~~~~~~~~~
| kali.c: In function 'handleKeyboard':
| kali.c:273:13: warning: implicit declaration of function 'StartLoadProc'; did 
you mean 'LoadProc'? [-Wimplicit-function-declaration]
|    case '<': StartLoadProc(NULL, 0); break;
|              ^~~~~~~~~~~~~
|              LoadProc
| kali.c:275:13: warning: implicit declaration of function 'StartSaveProc'; did 
you mean 'SaveProc'? [-Wimplicit-function-declaration]
|    case '>': StartSaveProc(NULL, 0); break;
|              ^~~~~~~~~~~~~
|              SaveProc
| kali.c:277:13: warning: implicit declaration of function 'set_mode'; did you 
mean 'memmove'? [-Wimplicit-function-declaration]
|    case 'z': set_mode(KALIZOOM); break;
|              ^~~~~~~~
|              memmove
| kali.c: In function 'user_event_cb':
| kali.c:333:10: warning: variable 'y' set but not used 
[-Wunused-but-set-variable]
|    int x, y, how = 0, button;
|           ^
| kali.c:333:7: warning: variable 'x' set but not used 
[-Wunused-but-set-variable]
|    int x, y, how = 0, button;
|        ^
| kali.c: In function 'main':
| kali.c:465:3: warning: implicit declaration of function 'foreground'; did you 
mean 'XNForeground'? [-Wimplicit-function-declaration]
|    foreground();
|    ^~~~~~~~~~
|    XNForeground
| kali.c:474:3: warning: implicit declaration of function 'forms_init'; did you 
mean 'flps_init'? [-Wimplicit-function-declaration]
|    forms_init(&pwin);
|    ^~~~~~~~~~
|    flps_init
| kali.c:475:3: warning: implicit declaration of function 'winset'; did you 
mean 'winopen'? [-Wimplicit-function-declaration]
|    winset(win);
|    ^~~~~~
|    winopen
| kali.c:476:10: warning: implicit declaration of function 'load_a_file' 
[-Wimplicit-function-declaration]
|    if (f) load_a_file(f);
|           ^~~~~~~~~~~
| kali.c: In function 'DrawCurrent':
| kali.c:61:21: warning: implicit declaration of function 'cpack' 
[-Wimplicit-function-declaration]
|  #define SET_COLOR   cpack
|                      ^
| kali.c:573:3: note: in expansion of macro 'SET_COLOR'
|    SET_COLOR(BACKCOLOR);
|    ^~~~~~~~~
| kali.c:574:3: warning: implicit declaration of function 'clear'; did you mean 
'GXclear'? [-Wimplicit-function-declaration]
|    clear();
|    ^~~~~
|    GXclear
| kali.c: In function 'MakeWindow':
| kali.c:636:3: warning: implicit declaration of function 'GXinit'; did you 
mean 'lrint'? [-Wimplicit-function-declaration]
|    GXinit(&GXDraw, fl_display, 0);
|    ^~~~~~
|    lrint
| kali.c:639:3: warning: implicit declaration of function 'RGBmode' 
[-Wimplicit-function-declaration]
|    RGBmode();
|    ^~~~~~~
| kali.c:641:3: warning: implicit declaration of function 'winconstraints'; did 
you mean 'XK_containsas'? [-Wimplicit-function-declaration]
|    winconstraints();
|    ^~~~~~~~~~~~~~
|    XK_containsas
| kali.c:643:3: warning: implicit declaration of function 'doublebuffer'; did 
you mean 'XStoreBuffer'? [-Wimplicit-function-declaration]
|    doublebuffer();
|    ^~~~~~~~~~~~
|    XStoreBuffer
| kali.c:644:3: warning: implicit declaration of function 'gconfig' 
[-Wimplicit-function-declaration]
|    gconfig();
|    ^~~~~~~
| kali.c: In function 'AdjustWindowRectangle':
| kali.c:652:3: warning: implicit declaration of function 'getsize'; did you 
mean 'getline'? [-Wimplicit-function-declaration]
|    getsize(&x,&y);
|    ^~~~~~~
|    getline
| kali.c: In function 'closest':
| kali.c:662:18: error: 'HUGE' undeclared (first use in this function)
|    float dist,min=HUGE;
|                   ^~~~
| kali.c:662:18: note: each undeclared identifier is reported only once for 
each function it appears in
| kali.c: In function 'PrintLine':
| kali.c:674:12: warning: format '%x' expects argument of type 'unsigned int', 
but argument 2 has type 'LINE * {aka struct s_line *}' [-Wformat=]
|    printf("%x ",l);
|            ~^
| kali.c:676:15: warning: format '%x' expects argument of type 'unsigned int', 
but argument 3 has type 'LINE * {aka struct s_line *}' [-Wformat=]
|    printf("%d %x \n",l->id,l->next);
|               ~^           ~~~~~~~
| kali.c: In function 'DefineSymWindow':
| kali.c:749:11: warning: unused variable 'y' [-Wunused-variable]
|    float x,y;
|            ^
| kali.c:749:9: warning: unused variable 'x' [-Wunused-variable]
|    float x,y;
|          ^
| kali.c: In function 'user_event_cb':
| kali.c:396:1: warning: control reaches end of non-void function 
[-Wreturn-type]
|  }
|  ^
| kali.c: In function 'LoadProc':
| kali.c:724:3: warning: ignoring return value of 'fscanf', declared with 
attribute warn_unused_result [-Wunused-result]
|    fscanf(pat,"%d\n",&sym_index);
|    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| kali.c:725:3: warning: ignoring return value of 'fscanf', declared with 
attribute warn_unused_result [-Wunused-result]
|    fscanf(pat,"%f %f\n",&dummy,&dummy);
|    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| kali.c:727:3: warning: ignoring return value of 'fscanf', declared with 
attribute warn_unused_result [-Wunused-result]
|    fscanf(pat,"%f %f\n",
|    ^~~~~~~~~~~~~~~~~~~~~
|    &(sym->v1.x),&(sym->v1.y));
|    ~~~~~~~~~~~~~~~~~~~~~~~~~~
| kali.c:729:3: warning: ignoring return value of 'fscanf', declared with 
attribute warn_unused_result [-Wunused-result]
|    fscanf(pat,"%f %f\n",
|    ^~~~~~~~~~~~~~~~~~~~~
|    &(sym->v2.x),&(sym->v2.y));
|    ~~~~~~~~~~~~~~~~~~~~~~~~~~
| kali.c:731:3: warning: ignoring return value of 'fscanf', declared with 
attribute warn_unused_result [-Wunused-result]
|    fscanf(pat,"%f \n",
|    ^~~~~~~~~~~~~~~~~~~
|    &zoom);
|    ~~~~~~
| At top level:
| kali.c:169:13: warning: 'modechars' defined but not used [-Wunused-variable]
|  static char modechars[] = "?dcptmza/rD";  /* draw, cut, pick, transform,
|              ^~~~~~~~~
| <builtin>: recipe for target 'kali.o' failed
| make[2]: *** [kali.o] Error 1
| make[2]: Leaving directory '/<<PKGBUILDDIR>>'
| dh_auto_build: make -j1 FORMSINCL= FORMSLIB=-lforms "COPTS=-Wdate-time 
-D_FORTIFY_SOURCE=2 -D_FILE_OFFSET_BITS=64 -g -O2 
-fdebug-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat 
-Werror=format-security -Wall" "LDFLAGS=-Wl,-z,relro -Wl,-z,now" returned exit 
code 2
| debian/rules:12: recipe for target 'override_dh_auto_build' failed
| make[1]: *** [override_dh_auto_build] Error 2
| make[1]: Leaving directory '/<<PKGBUILDDIR>>'
| debian/rules:9: recipe for target 'build-arch' failed
| make: *** [build-arch] Error 2
| dpkg-buildpackage: error: debian/rules build-arch subprocess returned exit 
status 2

A full build log is available there:
http://aws-logs.debian.net/2018/02/07/glibc-exp/kali_3.1-17_unstable_glibc-exp.log

Starting with glibc 2.27, support for SVID error handling has been
removed, including the corresponding HUGE constant. This causes this
package to FTBFS. The attached patch fixes that by using HUGE_VAL
instead. Note that HUGE_VAL actually corresponds to infinity, but that
looks the right value to use there.
diff -Nru kali-3.1/debian/patches/huge.patch kali-3.1/debian/patches/huge.patch
--- kali-3.1/debian/patches/huge.patch  1970-01-01 01:00:00.000000000 +0100
+++ kali-3.1/debian/patches/huge.patch  2018-02-24 12:01:24.000000000 +0100
@@ -0,0 +1,11 @@
+--- kali-3.1.orig/kali.c
++++ kali-3.1/kali.c
+@@ -659,7 +659,7 @@ void AdjustWindowRectangle(RECTANGLE *r)
+ /* Find closest center of symmetry to new motif point */
+ int closest(POINT *new_pt, POINT *pts, int maxpts) {
+   int i,min_i;
+-  float dist,min=HUGE;
++  float dist,min=HUGE_VAL;
+  
+   for (i=0; i<maxpts; i++)
+     {
diff -Nru kali-3.1/debian/patches/series kali-3.1/debian/patches/series
--- kali-3.1/debian/patches/series      2014-01-27 08:48:48.000000000 +0100
+++ kali-3.1/debian/patches/series      2018-02-24 12:01:24.000000000 +0100
@@ -8,3 +8,4 @@
 ldflags.patch
 arg-parse-crash.patch
 print-symtab-bounds.patch
+huge.patch

Reply via email to