Bug 226389 - x11-wm/fluxbox: fix build on armv6
Summary: x11-wm/fluxbox: fix build on armv6
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: arm Any
: --- Affects Many People
Assignee: Mark Linimon
URL: http://beefy8.nyi.freebsd.org/data/he...
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-06 11:17 UTC by Mikael Urankar
Modified: 2018-03-29 06:16 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (jgh)


Attachments
patch (1.08 KB, patch)
2018-03-06 11:17 UTC, Mikael Urankar
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mikael Urankar freebsd_committer 2018-03-06 11:17:26 UTC
Created attachment 191246 [details]
patch

Hi,
fluxbox doesn't compile on arm:

/nxb-bin/usr/bin/c++ -DHAVE_CONFIG_H -I.  -I/usr/local/include/fribidi -I/usr/local/include   -include ./config.h -I./src -I./src -I./src/FbTk -I./nls -I/usr/local/include -DLIBICONV_PLUG  -I/usr/local/include -D_THREAD_SAFE -pthread  -O2 -pipe -DLIBICONV_PLUG -fno-strict-aliasing  -DLIBICONV_PLUG  -MT src/fluxbox-Ewmh.o -MD -MP -MF src/.deps/fluxbox-Ewmh.Tpo -c -o src/fluxbox-Ewmh.o `test -f 'src/Ewmh.cc' || echo './'`src/Ewmh.cc
src/Ewmh.cc:917:22: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'long' in initializer list [-Wc++11-narrowing]
    long value[2] = {screen.width(), screen.height()};
                     ^~~~~~~~~~~~~~
src/Ewmh.cc:917:22: note: insert an explicit cast to silence this issue
    long value[2] = {screen.width(), screen.height()};
                     ^~~~~~~~~~~~~~
                     static_cast<long>( )
src/Ewmh.cc:917:38: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'long' in initializer list [-Wc++11-narrowing]
    long value[2] = {screen.width(), screen.height()};
                                     ^~~~~~~~~~~~~~~
src/Ewmh.cc:917:38: note: insert an explicit cast to silence this issue
    long value[2] = {screen.width(), screen.height()};
                                     ^~~~~~~~~~~~~~~
                                     static_cast<long>( )
2 errors generated.

The attached patch fixes the build.

Thanks in advance
Comment 1 commit-hook freebsd_committer 2018-03-29 06:11:02 UTC
A commit references this bug:

Author: linimon
Date: Thu Mar 29 06:10:58 UTC 2018
New revision: 465866
URL: https://svnweb.freebsd.org/changeset/ports/465866

Log:
  Fix build on armvX.

  PR:		226389
  Submitted by:	mikael.urankar
  Approved by:	maintainer timeout (2 weeks)

Changes:
  head/x11-wm/fluxbox/files/patch-src_Ewmh.cc
Comment 2 Mark Linimon freebsd_committer freebsd_triage 2018-03-29 06:16:23 UTC
Committed, thanks.