Created attachment 472176 [details] build.log Build preparations: [ebuild R ] media-gfx/ufraw-0.22-r1::gentoo USE="openmp -contrast -fits -gimp -gnome -gtk -jpeg2k -timezone" 0 KiB emerge --info Portage 2.3.5 (python 3.4.6-final-0, default/linux/amd64/13.0/desktop/plasma, gcc-7.1.0, glibc-2.24-r1, 4.4.67 x86_64) ================================================================= System uname: Linux-4.4.67-x86_64-Intel-R-_Core-TM-_i5-2500K_CPU_@_3.30GHz-with-gentoo-2.3 KiB Mem: 16358300 total, 12456148 free KiB Swap: 0 total, 0 free Timestamp of repository gentoo: Tue, 09 May 2017 10:30:01 +0000 sh bash 4.4_p12 ld GNU ld (Gentoo 2.27 p1.0) 2.27 app-shells/bash: 4.4_p12::gentoo dev-lang/perl: 5.24.1-r1::gentoo dev-lang/python: 2.7.13::gentoo, 3.4.6::gentoo dev-util/cmake: 3.8.1::gentoo dev-util/pkgconfig: 0.29.2::gentoo sys-apps/baselayout: 2.3::gentoo sys-apps/openrc: 0.25::gentoo sys-apps/sandbox: 2.10-r4::gentoo sys-devel/autoconf: 2.13::gentoo, 2.69-r3::gentoo sys-devel/automake: 1.13.4-r1::gentoo, 1.15-r2::gentoo sys-devel/binutils: 2.27::gentoo sys-devel/gcc: 5.4.0-r3::gentoo, 6.3.0::gentoo, 7.1.0-r1::gentoo sys-devel/gcc-config: 1.8-r1::gentoo sys-devel/libtool: 2.4.6-r4::gentoo sys-devel/make: 4.2.1-r1::gentoo sys-kernel/linux-headers: 4.10::gentoo (virtual/os-headers) sys-libs/glibc: 2.24-r1::gentoo Repositories: gentoo location: /usr/portage sync-type: rsync sync-uri: rsync://rsync.gentoo.org/gentoo-portage priority: -1000 my location: /usr/local/my masters: gentoo priority: 0 deadbeef-overlay location: /var/lib/layman/deadbeef-overlay masters: gentoo priority: 50 mozilla location: /var/lib/layman/mozilla masters: gentoo priority: 50 scrill location: /var/lib/layman/scrill masters: gentoo priority: 50 steam-overlay location: /var/lib/layman/steam-overlay masters: gentoo priority: 50 vortex location: /var/lib/layman/vortex masters: gentoo priority: 50 ACCEPT_KEYWORDS="amd64 ~amd64" ACCEPT_LICENSE="*" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=native -mtune=native -O2 -pipe -fomit-frame-pointer" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo" CXXFLAGS="-march=native -mtune=native -O2 -pipe -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" EMERGE_DEFAULT_OPTS="--with-bdeps=y --quiet-build=n" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://distfiles.gentoo.org" LANG="ru_RU.UTF-8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" MAKEOPTS="-j5" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git" PORTAGE_TMPDIR="/tmp" USE="X a52 aac acl acpi aes aften alsa amd64 amr ass audio avx bash-completion branding bzip2 cairo cdda cdr cleartype consolekit cracklib crypt css cups cxx dbus declarative device-mapper djvu dri dts dv dvd dvdr encode exif faac faad fam fat ffmpeg firefox firmware-loader flac fontconfig gd gif glamor gpm gzip iconv icu id3tag ieee1394 imagemagick ipv6 jit jpeg kde keymap ladspa lame lash lcms libass libnotify lm_sensors lzma lzo mad matroska midi mmx mmxext mng modules mp3 mp4 mpeg mplayer mtp mudflap multilib ncurses nls nptl ntfs nvidia ogg opengl openmp opus pam pango pcre pdf phonon pie plasma png policykit popcnt ppds pppd pulseaudio qml qt3support qt4 qt5 quicktime rar raw readline scanner sdl seccomp session sse sse2 sse3 sse4_1 sse4_2 ssl ssp ssse3 startup-notification svc svg sysfs tcpd theora threads tiff toolame truetype twolame udev udisks unicode upower usb vaapi vdpau vorbis vpx wav wavpack widgets win32codecs wxwidgets x264 x265 xattr xcb xcomposite xml xorg xscreensaver xulrunner xv xvfb xvid xvmc zip zlib" ABI_X86="64" ALSA_CARDS="emu10k1" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" L10N="ru en" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="ru en" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-6" PYTHON_SINGLE_TARGET="python3_4" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby21 ruby22" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" USE_PYTHON="2.7 3.4" Unset: CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Created attachment 472648 [details, diff] compile fix for gcc7: abs() on unsigned int makes no sense calling abs() with unsigned int seems to be forbidden in gcc-7, so casting the parameters to int
(In reply to milan hodoscek from comment #1) > Created attachment 472648 [details, diff] [details, diff] > compile fix for gcc7: abs() on unsigned int makes no sense > > calling abs() with unsigned int seems to be forbidden in gcc-7, so casting > the parameters to int Thanks. This patch fixes build for both GCC-7.1.0 and Clang-4.0.0
(In reply to milan hodoscek from comment #1) > Created attachment 472648 [details, diff] [details, diff] > compile fix for gcc7: abs() on unsigned int makes no sense > > calling abs() with unsigned int seems to be forbidden in gcc-7, so casting > the parameters to int Why are you casting i and c to uint instead of just removing the call to abs()?
(In reply to Johannes Hirte from comment #3) > (In reply to milan hodoscek from comment #1) > > Created attachment 472648 [details, diff] [details, diff] [details, diff] > > compile fix for gcc7: abs() on unsigned int makes no sense > > > > calling abs() with unsigned int seems to be forbidden in gcc-7, so casting > > the parameters to int > > Why are you casting i and c to uint instead of just removing the call to > abs()? Sorry I meant, why are you casting to int instead of dropping abs() and comparing the uints?
Created attachment 474608 [details, diff] ufraw-0.22-drop_superfluous_abs.patch abs() on uint is nonsense and gcc-7.1 refuses to compile this. So just drop the call to abs() in this case.
commit d4658e180df072cdcb4102bc79b8b5b08558df60 (HEAD -> master, origin/master, origin/HEAD) Author: Alexis Ballier <aballier@gentoo.org> Date: Sun Jun 18 11:51:06 2017 +0200 media-gfx/ufraw: Fix build with gcc 7. Patch by Johannes Hirte, bug #618068 thanks