Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Trac Trac
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Issues 246
    • Issues 246
    • List
    • Boards
    • Service Desk
    • Milestones
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
  • Wiki
    • Wiki
  • Activity
  • Create a new issue
  • Issue Boards
Collapse sidebar
  • Legacy
  • TracTrac
  • Issues
  • #26272
Closed (moved) (moved)
Open
Created Jun 02, 2018 by teor@teor

gcc 7 fails on -Wunused-const-variable for Zstd headers

When using gcc 7 on macOS:

$ gcc-7 --version
gcc-7 (Homebrew GCC 7.3.0) 7.3.0

I see the following errors:

In file included from ../src/common/compress_zstd.c:29:0:
/usr/local/Cellar/zstd/1.3.4//include/zstd.h:593:29: error: 'ZSTD_defaultCMem' defined but not used [-Werror=unused-const-variable=]
 static ZSTD_customMem const ZSTD_defaultCMem = { NULL, NULL, NULL };  /**< this constant defers to stdlib's functions */
                             ^~~~~~~~~~~~~~~~
/usr/local/Cellar/zstd/1.3.4//include/zstd.h:404:21: error: 'ZSTD_skippableHeaderSize' defined but not used [-Werror=unused-const-variable=]
 static const size_t ZSTD_skippableHeaderSize = 8;  /* magic number + skippable frame length */
                     ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/Cellar/zstd/1.3.4//include/zstd.h:403:21: error: 'ZSTD_frameHeaderSize_max' defined but not used [-Werror=unused-const-variable=]
 static const size_t ZSTD_frameHeaderSize_max = ZSTD_FRAMEHEADERSIZE_MAX;
                     ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/Cellar/zstd/1.3.4//include/zstd.h:402:21: error: 'ZSTD_frameHeaderSize_min' defined but not used [-Werror=unused-const-variable=]
 static const size_t ZSTD_frameHeaderSize_min = ZSTD_FRAMEHEADERSIZE_MIN;
                     ^~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/Cellar/zstd/1.3.4//include/zstd.h:401:21: error: 'ZSTD_frameHeaderSize_prefix' defined but not used [-Werror=unused-const-variable=]
 static const size_t ZSTD_frameHeaderSize_prefix = ZSTD_FRAMEHEADERSIZE_PREFIX;
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking