gcc10_fix-1.patch 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. Submitted By: Pierre Labastie <pierre dot labastie at neuf dot fr>
  2. Date: 2020-05-21
  3. Initial Package Version: 1.1.15
  4. Upstream Status: Unknown (no development since 2011)
  5. Origin: self, adapted from opensuse
  6. Description: Fixes building with GCC 10
  7. --- jfsutils-1.1.15.old/fscklog/display.c 2005-11-22 21:43:54.000000000 +0100
  8. +++ jfsutils-1.1.15.new/fscklog/display.c 2020-05-21 18:15:13.410617620 +0200
  9. @@ -54,7 +54,7 @@
  10. * output: fsck extracted service log I/O buffer
  11. *
  12. */
  13. -char xchklog_buffer[XCHKLOG_BUFSIZE];
  14. +static char xchklog_buffer[XCHKLOG_BUFSIZE];
  15. /* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  16. *
  17. diff -ur --exclude '*.o' --exclude '*.a' jfsutils-1.1.15.old/libfs/logredo.c jfsutils-1.1.15.new/libfs/logredo.c
  18. --- jfsutils-1.1.15.old/libfs/logredo.c 2005-11-22 21:43:55.000000000 +0100
  19. +++ jfsutils-1.1.15.new/libfs/logredo.c 2020-05-21 18:19:44.927703271 +0200
  20. @@ -87,9 +87,9 @@
  21. * S T U F F F O R T H E L O G
  22. *
  23. */
  24. -struct logsuper logsup; /* log super block */
  25. -int32_t numdoblk; /* number of do blocks used */
  26. -int32_t numnodofile; /* number of nodo file blocks used */
  27. +static struct logsuper logsup; /* log super block */
  28. +static int32_t numdoblk; /* number of do blocks used */
  29. +static int32_t numnodofile; /* number of nodo file blocks used */
  30. int32_t numExtDtPg = 0; /* number of extended dtpage blocks used */
  31. /*
  32. @@ -129,7 +129,7 @@
  33. */
  34. /* buffer header table */
  35. -struct bufhdr {
  36. +static struct bufhdr {
  37. int16_t next; /* 2: next on free/lru list */
  38. int16_t prev; /* 2: previous on free/lru list */
  39. int16_t hnext; /* 2: next on hash chain */
  40. @@ -142,7 +142,7 @@
  41. } bufhdr[NBUFPOOL]; /* (24) */
  42. /* buffer table */
  43. -struct bufpool {
  44. +static struct bufpool {
  45. char bytes[PSIZE];
  46. } buffer[NBUFPOOL - 1];
  47. @@ -151,15 +151,16 @@
  48. *
  49. * log has its own 4 page buffer pool.
  50. */
  51. -uint8_t afterdata[LOGPSIZE * 2]; /* buffer to read in redopage data */
  52. +static uint8_t afterdata[LOGPSIZE * 2]; /* buffer to read in redopage data */
  53. /*
  54. * Miscellaneous
  55. */
  56. -caddr_t prog; /* Program name */
  57. -int32_t mntcnt, bufsize;
  58. -char *mntinfo;
  59. -int32_t retcode; /* return code from logredo */
  60. +static caddr_t prog; /* Program name */
  61. +extern int32_t mntcnt;
  62. +static int32_t bufsize;
  63. +static char *mntinfo;
  64. +static int32_t retcode; /* return code from logredo */
  65. int end_of_transaction = 0;
  66. /*