After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 744616 - Recently added -Werror causes many problems when compiling with clang
Recently added -Werror causes many problems when compiling with clang
Status: RESOLVED FIXED
Product: easytag
Classification: Other
Component: general
master
Other FreeBSD
: Normal normal
: 2.2
Assigned To: EasyTAG maintainer(s)
EasyTAG maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2015-02-16 18:41 UTC by Ting-Wei Lan
Modified: 2015-02-16 19:21 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ting-Wei Lan 2015-02-16 18:41:01 UTC
Here is the list of error obtained by running `gmake -k':


nautilus-extension/nautilus-easytag.c:271:1: error: unused function 'nautilus_easytag_get_instance_private' [-Werror,-Wunused-function]
G_DEFINE_DYNAMIC_TYPE_EXTENDED (NautilusEasytag,
^
/home/lantw44/gnome/devinstall/include/glib-2.0/gobject/gtypemodule.h:185:24: note: expanded from macro 'G_DEFINE_DYNAMIC_TYPE_EXTENDED'
static inline gpointer \
                       ^
<scratch space>:187:1: note: expanded from here
nautilus_easytag_get_instance_private
^
1 error generated.

src/browser.c:110:20: error: unused variable 'BOX_SPACING' [-Werror,-Wunused-const-variable]
static const guint BOX_SPACING = 6;
                   ^
1 error generated.

src/misc.c:40:20: error: unused variable 'BOX_SPACING' [-Werror,-Wunused-const-variable]
static const guint BOX_SPACING = 6;
                   ^
1 error generated.

src/scan_dialog.c:91:20: error: unused variable 'BOX_SPACING' [-Werror,-Wunused-const-variable]
static const guint BOX_SPACING = 6;
                   ^
1 error generated.

src/tags/libapetag/info_mac.c:116:13: error: cast from 'unsigned int *' to 'struct macHeader *' increases required alignment from 4 to 8
      [-Werror,-Wcast-align]
    header= (struct macHeader *) HeaderData;
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

src/tags/flac_tag.c:656:38: error: implicit conversion from enumeration type 'FLAC__StreamMetadata_Picture_Type' to different enumeration type
      'EtPictureType' [-Werror,-Wenum-conversion]
            pic = et_picture_new (p->type, (const gchar *)p->description,
                  ~~~~~~~~~~~~~~  ~~~^~~~
src/tags/flac_tag.c:1051:57: error: implicit conversion from enumeration type 'EtPictureType' to different enumeration type
      'FLAC__StreamMetadata_Picture_Type' [-Werror,-Wenum-conversion]
                picture_block->data.picture.type = pic->type;
                                                 ~ ~~~~~^~~~

src/tags/id3_tag.c:1027:61: error: cast from 'gchar *' (aka 'char *') to 'unicode_t *' (aka 'unsigned short *') increases required alignment from 1 to 2
      [-Werror,-Wcast-align]
                num_chars = ID3Field_GetUNICODE_1(id3_field,(unicode_t *)string,ID3V2_MAX_STRING_LEN,0);
                                                            ^~~~~~~~~~~~~~~~~~~
src/tags/id3_tag.c:1203:47: error: cast from 'gchar *' (aka 'char *') to 'const unicode_t *' (aka 'const unsigned short *') increases required alignment
      from 1 to 2 [-Werror,-Wcast-align]
                ID3Field_SetUNICODE(id3_field,(const unicode_t*)string_converted);
                                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/tags/id3_tag.c:1299:66: error: cast from 'gchar *' (aka 'char *') to 'unicode_t *' (aka 'unsigned short *') increases required alignment from 1 to 2
      [-Werror,-Wcast-align]
                num_chars = ID3Field_GetUNICODE_1(id3_field_text,(unicode_t *)string,ID3V2_MAX_STRING_LEN,0);
                                                                 ^~~~~~~~~~~~~~~~~~~
3 errors generated.


The following error occur when opus or opusfile is not installed.

src/file_list.c:243:13: error: enumeration value 'OPUS_TAG' not explicitly handled in switch [-Werror,-Wswitch-enum]
    switch (description->TagType)
            ^
src/file_list.c:339:13: error: enumeration value 'OPUS_FILE' not explicitly handled in switch [-Werror,-Wswitch-enum]
    switch (description->FileType)
            ^
2 errors generated.

src/file.c:1120:13: error: enumeration value 'OPUS_FILE' not explicitly handled in switch [-Werror,-Wswitch-enum]
    switch (description->FileType)
            ^
src/file.c:1306:13: error: enumeration value 'OPUS_TAG' not explicitly handled in switch [-Werror,-Wswitch-enum]
    switch (description->TagType)
            ^
src/file.c:1742:13: error: enumeration value 'OPUS_TAG' not explicitly handled in switch [-Werror,-Wswitch-enum]
    switch (description->TagType)
            ^
3 errors generated.
Comment 1 David King 2015-02-16 19:21:03 UTC
You should probably enable -disable-Werror, which I just added support for in master with commit 83b4a66ad564f0eba58edcb0c2a742b556781d7f.