Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 585592 - dev-db/freetds-1.00 fails to compile: ../../include/freetds/tds.h:150:2: error: bit-field ‘__res_state’ has invalid type
Summary: dev-db/freetds-1.00 fails to compile: ../../include/freetds/tds.h:150:2: erro...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-11 14:27 UTC by Silvio
Modified: 2017-08-16 02:30 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,59.79 KB, text/x-log)
2016-06-11 14:33 UTC, Silvio
Details
freetds-1.00.1-fix_include_freetds_tds.patch (freetds-1.00.1-fix_include_freetds_tds.patch,481 bytes, patch)
2016-07-21 09:25 UTC, Joerg Neikes
Details | Diff
freetds-1.00.1-fix_src_tds_threadsafe.patch (freetds-1.00.1-fix_src_tds_threadsafe.patch,312 bytes, patch)
2016-07-21 09:26 UTC, Joerg Neikes
Details | Diff
freetds-1.00.1-r2.ebuild (freetds-1.00.1-r2.ebuild,1.25 KB, text/plain)
2016-07-21 09:27 UTC, Joerg Neikes
Details
freetds-1.00.1-r2.ebuild.patch (freetds-1.00.1-r2.ebuild.patch,707 bytes, patch)
2016-07-21 09:41 UTC, Joerg Neikes
Details | Diff
build.log (build.log,56.07 KB, text/plain)
2016-08-01 07:53 UTC, Tom
Details
freetds-1.00.13-r1.ebuild.patch (freetds-1.00.13-r1.ebuild.patch,575 bytes, patch)
2016-08-01 15:10 UTC, Joerg Neikes
Details | Diff
freetds-1.00.13-r1.ebuild (freetds-1.00.13-r1.ebuild,2.08 KB, text/plain)
2016-08-01 15:14 UTC, Joerg Neikes
Details
emerge-info.txt (emerge-info.txt,15.58 KB, text/plain)
2017-07-01 10:23 UTC, Toralf Förster
Details
dev-db:freetds-1.00.41:20170701-101023.log (dev-db:freetds-1.00.41:20170701-101023.log,56.75 KB, text/plain)
2017-07-01 10:23 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,333.11 KB, text/plain)
2017-07-01 10:23 UTC, Toralf Förster
Details
environment (environment,69.09 KB, text/plain)
2017-07-01 10:23 UTC, Toralf Förster
Details
etc.portage.tbz2 (etc.portage.tbz2,22.72 KB, application/x-bzip)
2017-07-01 10:23 UTC, Toralf Förster
Details
logs.tbz2 (logs.tbz2,19.79 KB, application/x-bzip)
2017-07-01 10:23 UTC, Toralf Förster
Details
temp.tbz2 (temp.tbz2,24.93 KB, application/x-bzip)
2017-07-01 10:23 UTC, Toralf Förster
Details
build log (build.log,58.80 KB, text/x-log)
2017-07-23 06:51 UTC, Silvio
Details
freetds-roken.patch (freetds-roken.patch,1.95 KB, patch)
2017-08-09 07:48 UTC, INODE64 Sistemas
Details | Diff
freetds-1.00.41.ebuild (freetds-1.00.41.ebuild,1.99 KB, text/plain)
2017-08-09 07:49 UTC, INODE64 Sistemas
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Silvio 2016-06-11 14:27:51 UTC
Compiling it exits with:


../../include/freetds/tds.h:150:2: error: bit-field ‘__res_state’ has invalid type
make[4]: *** [Makefile:556: threadsafe.lo] Error 1
make[4]: *** Attesa per i processi non terminati....
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c iconv.c -o iconv.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c vstrbuild.c  -fPIC -DPIC -o .libs/vstrbuild.o
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c token.c -o token.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c vstrbuild.c -o vstrbuild.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c convert.c -o convert.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c query.c -o query.o >/dev/null 2>&1
make[4]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00/work/freetds-1.00/src/tds"
make[3]: *** [Makefile:571: all-recursive] Error 1
make[3]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00/work/freetds-1.00/src/tds"
make[2]: *** [Makefile:445: all] Error 2
make[2]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00/work/freetds-1.00/src/tds"
make[1]: *** [Makefile:420: all-recursive] Error 1
make[1]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00/work/freetds-1.00/src"
make: *** [Makefile:461: all-recursive] Error 1
 * ERROR: dev-db/freetds-1.00::gentoo failed (compile phase):


my emerge --info:

Portage 2.3.0_rc1 (python 2.7.11-final-0, default/linux/amd64/13.0/desktop/plasma, gcc-5.3.0, glibc-2.23-r2, 4.6.0-gentoo x86_64)
=================================================================
System uname: Linux-4.6.0-gentoo-x86_64-Intel-R-_Core-TM-_i7-4710HQ_CPU_@_2.50GHz-with-gentoo-2.2
KiB Mem:    16314464 total,   3711012 free
KiB Swap:   17825788 total,  17825788 free
sh bash 4.3_p42-r2
ld ld di GNU (Gentoo 2.25.1 p1.1) 2.25.1
distcc 3.2rc1 x86_64-pc-linux-gnu [disabled]
ccache version 3.2.5 [disabled]
app-shells/bash:          4.3_p42-r2::gentoo
dev-java/java-config:     2.2.0-r3::gentoo
dev-lang/perl:            5.24.0-r1::gentoo
dev-lang/python:          2.7.11-r2::gentoo, 3.4.4::gentoo, 3.5.1-r3::gentoo
dev-util/ccache:          3.2.5::gentoo
dev-util/cmake:           3.5.2-r1::gentoo
dev-util/pkgconfig:       0.29.1::gentoo
sys-apps/baselayout:      2.2::gentoo
sys-apps/openrc:          0.21::gentoo
sys-apps/sandbox:         2.10-r2::gentoo
sys-devel/autoconf:       2.13::gentoo, 2.69-r2::gentoo
sys-devel/automake:       1.11.6-r2::gentoo, 1.13.4-r1::gentoo, 1.14.1-r1::gentoo, 1.15-r2::gentoo
sys-devel/binutils:       2.25.1-r1::gentoo
sys-devel/gcc:            4.9.3::gentoo, 5.3.0::gentoo
sys-devel/gcc-config:     1.8-r1::gentoo
sys-devel/libtool:        2.4.6-r2::gentoo
sys-devel/make:           4.2-r2::gentoo
sys-kernel/linux-headers: 4.6::gentoo (virtual/os-headers)
sys-libs/glibc:           2.23-r2::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.europe.gentoo.org/gentoo-portage
    priority: -1000

manual
    location: /usr/portage/local/manual
    masters: gentoo
    priority: 0

bibletime
    location: /var/lib/layman/bibletime
    masters: gentoo
    priority: 1

amielke-overlay
    location: /var/lib/layman/amielke-overlay
    masters: gentoo
    priority: 50

belak
    location: /var/lib/layman/belak
    masters: gentoo
    priority: 50

betagarden
    location: /var/lib/layman/betagarden
    masters: gentoo
    priority: 50

gamerlay
    location: /var/lib/layman/gamerlay
    masters: gentoo
    priority: 50

luman
    location: /var/lib/layman/luman
    masters: gentoo
    priority: 50

maekke
    location: /var/lib/layman/maekke
    masters: gentoo
    priority: 50

maggu2810-overlay
    location: /var/lib/layman/maggu2810-overlay
    masters: gentoo
    priority: 50

nikai
    location: /var/lib/layman/nikai
    masters: gentoo
    priority: 50

pentoo
    location: /var/lib/layman/pentoo
    masters: gentoo
    priority: 50

pinkbyte
    location: /var/lib/layman/pinkbyte
    masters: gentoo
    priority: 50

sunrise
    location: /var/lib/layman/sunrise
    masters: gentoo
    priority: 50

voyageur
    location: /var/lib/layman/voyageur
    masters: gentoo
    priority: 50

yarik-overlay
    location: /var/lib/layman/yarik-overlay
    masters: gentoo
    priority: 50

zugaina
    location: /var/lib/layman/zugaina
    masters: gentoo
    priority: 50

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=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 /usr/share/maven-bin-3.3/conf"
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 /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=native -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync 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://mirror.ovh.net/gentoo-distfiles/ http://ftp.heanet.ie/pub/gentoo/ http://mirror.ovh.net/gentoo-distfiles/ http://www.die.unipd.it/pub/Linux/distributions/gentoo-sources/ rsync://rsync3.it.gentoo.org/gentoo-sources/ ftp://ftp.unina.it/pub/linux/distributions/gentoo/"
LANG="it_IT.UTF-8"
LC_ALL="it_IT.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j9"
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="/var/tmp"
USE="3ds 64bit X a52 aac aacplus aacs aalib acl acpi ads aften aiglx akode alias alsa amd64 amr ao apache apm apng asyncns audiofile autoreplace autotrace avahi avi bash-completion berkdb bidi bitmap-fonts bluetooth bluray bmp branding browserplugin bzip bzip2 cairo caps cdaudio cdda cddb cdr cli clucene connectionstatus consolekit contactnotes cracklib crypt cuda cups cvd cvs cxx dbus declarative designer dia dialup dirac djvu dri dtmf dts dv dvb dvd dvdr dvdread dvi dxva2 dynamicplugin ebook efi emboss encode ethereal exif faac faad fam farstream fat fdk ffmpeg firefox flac fluidsynth fontconfig foomaticdb fortran freetds frei0r fribidi g726 g729 gbm gdbm geolocation gif gimp git glamor glib glitz gme gnome-keyring gphoto2 gpm gps gpu groupwise gstreamer gtk gtk3 h323 highlight history hvm i8x0 iconv icu ieee1394 ilbc imagemagick innodb ios iphone ipv6 irc ithreads jack java javascript jingle jpeg jpeg2k kate kde kdenlive kdepim kipi kontact kqemu lame laptop lcms ldap libass libkms libnotify lm_sensors lucene m4a mad mbrola mdb mdnsresponder-compat mercurial midi mime minizip mmx mmxext mng modules moonlight mozilla mp3 mp4 mpeg mpeg2 mplayer msn mssql multilib musepack musicbrainz ncurses netmeeting nls nowlistening npt1 nptl nptlonly nsplugin ntfs nvidia odbc ogg openal openexr opengl openipmi openmp opus orc pam pango pcmcia pcre pda pdf perl phonon pkcs11 plasma pmu png policykit portaudio postgres postproc ppds pulseaudio python python3 qemu qml qt3support qt4 qt5 quicktime rar raw rdesktop rdp readline reiserfs reports rtsp samba sametime sane scanner sdl sdl-image seccomp semantic-desktop session shout sip sipim skype smartcard smp sms soprano soundtouch speex spell sqlite sse sse2 sse3 ssh ssl startup-notification subtitles subversion svg tcpd texteffect texteffects theora tidy tiff timidity tk tordns touchpad translator truetype truetype-fonts twolame type1-fonts udev udisks unicode upower usb utempter uxa v4l v4l2 vaapi vcd vcdx vdpau video virtualbox vnc vorbis vpx wav wavpack webkit webpresence webrtc-aec wicd widevine widgets wifi wiimote win32codecs win64 winbind winetriks winpopup wlm wma wma-fixed wmf wxwidgets wxwindows x264 xattr xcb xcomposite xen xetex xine xinerama xml xmp xscreensaver xv xvid xvmc yahoo zeroconf zlib" ABI_X86="64 32" ALSA_CARDS="snd_hda_intel" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="*" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 sse3 ssse3 sse4_1 sse4_2 avx avx2 fma3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="keyboard mouse evdev joystick synaptics wacom" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="it en it_IT" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_4" RUBY_TARGETS="ruby20 ruby21 ruby22" SANE_BACKENDS="*" USERLAND="GNU" VIDEO_CARDS="nvidia intel i965 nv vesa nouveau v4l v4l2 modesetting fbdev" 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"
Unset:  CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Silvio 2016-06-11 14:33:12 UTC
Created attachment 437166 [details]
build.log
Comment 3 Michael 'veremitz' Everitt 2016-06-12 05:15:45 UTC
Copying Hans for reference.
Comment 4 Hans de Graaff gentoo-dev Security 2016-06-12 06:17:43 UTC
I don't see that problem but I noticed there is now a 1.00.1 so I added that. Can you test and report back if this version fixes this?
Comment 5 Silvio 2016-06-12 21:08:39 UTC
(In reply to Hans de Graaff from comment #4)
> I don't see that problem but I noticed there is now a 1.00.1 so I added
> that. Can you test and report back if this version fixes this?

It fails too, exiting in the same way:


In file included from threadsafe.c:65:0:
/usr/include/roken.h:145:0: note: this is the location of the previous definition
 #define strlcat rk_strlcat
 ^
In file included from threadsafe.c:73:0:
../../include/freetds/tds.h:150:2: warning: function declaration isn’t a prototype [-Wstrict-prototypes]
  TDS_USMALLINT _res:10;
  ^
../../include/freetds/tds.h:150:2: error: bit-field ‘__res_state’ has invalid type
make[4]: *** [Makefile:556: threadsafe.lo] Error 1
Comment 6 Hans de Graaff gentoo-dev Security 2016-06-13 18:55:45 UTC
To set expectations: this package is maintainer-needed. Since I was the last to touch the package I was happy to provide the additional version bump, but I won't do further investigations. Please report the error upstream instead.
Comment 7 Joerg Neikes 2016-07-21 09:25:52 UTC
Created attachment 441296 [details, diff]
freetds-1.00.1-fix_include_freetds_tds.patch
Comment 8 Joerg Neikes 2016-07-21 09:26:22 UTC
Created attachment 441298 [details, diff]
freetds-1.00.1-fix_src_tds_threadsafe.patch
Comment 9 Joerg Neikes 2016-07-21 09:27:02 UTC
Created attachment 441300 [details]
freetds-1.00.1-r2.ebuild
Comment 10 Joerg Neikes 2016-07-21 09:41:45 UTC
Created attachment 441302 [details, diff]
freetds-1.00.1-r2.ebuild.patch
Comment 11 Tom 2016-07-22 09:38:17 UTC
taking advantage of the situation 
We Can update Freetds to newest version 
I check this patches and compile now all look fine

https://github.com/esalamandra/eS-overlay/blob/master/dev-db/freetds/freetds-1.00.11.ebuild
Comment 12 Pacho Ramos gentoo-dev 2016-07-24 12:42:03 UTC
Is anyone willing to proxy maintain this?
https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers
Comment 13 Oleh 2016-07-25 15:56:06 UTC
meanwhile, any gentoo dev could push this fixed ebuild. This 2 patches fixes the problem.
Comment 14 Tom 2016-08-01 07:53:26 UTC
Created attachment 442178 [details]
build.log
Comment 15 Tom 2016-08-01 07:55:16 UTC
Comment on attachment 442178 [details]
build.log

Now in portage is new version dev-db/freetds-1.00.13 problem look come back ?
Comment 16 Joerg Neikes 2016-08-01 15:10:16 UTC
Created attachment 442198 [details, diff]
freetds-1.00.13-r1.ebuild.patch

Fixed patch for freetds-1.00.13.ebuild.
Comment 17 Joerg Neikes 2016-08-01 15:14:28 UTC
Created attachment 442200 [details]
freetds-1.00.13-r1.ebuild

Fixed freetds-1.00.13-r1.ebuild . Works now for me again.
Comment 18 Michael Orlitzky gentoo-dev 2016-08-01 15:48:03 UTC
I committed the new version of freetds, but I'm not a heavy user of the package. I'm hesitant to commit these patches without understanding what they fix and how they fix it.

Does this compilation failure only happen on a specific platform? With newer versions of gcc? Has anyone reported it as a bug against upstream?
Comment 19 Oleh 2016-08-03 08:53:01 UTC
one of this patches is also applied by freebsd's freetds port. Maybe it's taken from there, however it's unclear what this patch supposed to fix. What version of gcc used? i'm unable to reproduce this, with fully rebuilt system with gcc-4.9.3 and fully rebuilt system with gcc-5.3.0.
Comment 20 Tom 2016-08-03 09:02:50 UTC
I have problem with this but I have very  eco cpu ;) old AMD E450.
I try recompile yet on my opteron systems.
But anyway maybe some CPU flag broke this
Comment 22 Tom 2016-08-03 09:39:51 UTC
GCC uses this for compatibility with M$.
Look like 2 similar definitions is in code. 
And second is that's defined to protect on stack
If I good understand
Comment 23 Oleh 2016-08-17 10:02:57 UTC
ok. but it's not reproducible when you have completely rebuilt system. according to emerge --info of reporter, 2 versions of gcc used. Quite possible that freetds failing due to the fact a part of a system is built with older (or with newer) gcc.
I suggest to run emerge -e @system with a certain gcc set, then try building freetds. If failed again, then it's an indication of a bug.
Comment 24 Tom 2016-08-17 11:12:06 UTC
For me emerge -e @system not worked
Comment 25 Pacho Ramos gentoo-dev 2016-08-17 12:38:13 UTC
Did you try to get that patch upstreamed?
Comment 26 Pacho Ramos gentoo-dev 2017-06-06 12:12:45 UTC
please retry with =dev-db/freetds-1.00.41
Comment 27 Martin Cyr 2017-06-24 15:18:57 UTC
1.0.41 still fails here.

../../include/freetds/tds.h:150:2: error: bit-field ‘__res_state’ has invalid type
Comment 28 Toralf Förster gentoo-dev 2017-07-01 10:23:15 UTC
same issue with dev-db/freetds-1.00.41 at the unstable amd64 chroot image 17.0-desktop-plasma_20170623-211337 at the tinderbox
Comment 29 Toralf Förster gentoo-dev 2017-07-01 10:23:19 UTC
Created attachment 478532 [details]
emerge-info.txt
Comment 30 Toralf Förster gentoo-dev 2017-07-01 10:23:22 UTC
Created attachment 478534 [details]
dev-db:freetds-1.00.41:20170701-101023.log
Comment 31 Toralf Förster gentoo-dev 2017-07-01 10:23:25 UTC
Created attachment 478536 [details]
emerge-history.txt
Comment 32 Toralf Förster gentoo-dev 2017-07-01 10:23:28 UTC
Created attachment 478538 [details]
environment
Comment 33 Toralf Förster gentoo-dev 2017-07-01 10:23:32 UTC
Created attachment 478540 [details]
etc.portage.tbz2
Comment 34 Toralf Förster gentoo-dev 2017-07-01 10:23:35 UTC
Created attachment 478542 [details]
logs.tbz2
Comment 35 Toralf Förster gentoo-dev 2017-07-01 10:23:38 UTC
Created attachment 478544 [details]
temp.tbz2
Comment 36 Silvio 2017-07-23 06:45:04 UTC
Yet error with the stable:

-D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer  -Wdeclaration-after-statement -c -o threadsafe.lo threadsafe.c
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c config.c -o config.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c iconv.c  -fPIC -DPIC -o .libs/iconv.o
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c mem.c -o mem.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c locale.c  -fPIC -DPIC -o .libs/locale.o
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c threadsafe.c  -fPIC -DPIC -o .libs/threadsafe.o
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c locale.c -o locale.o >/dev/null 2>&1
In file included from ../../include/freetds/tds.h:55:0,
                 from threadsafe.c:73:
../../include/replacements.h:79:0: warning: "strlcpy" redefined
 #define strlcpy(d,s,l) tds_strlcpy(d,s,l)
 ^
In file included from threadsafe.c:65:0:
/usr/include/roken.h:146:0: note: this is the location of the previous definition
 #define strlcpy rk_strlcpy
 ^
In file included from ../../include/freetds/tds.h:55:0,
                 from threadsafe.c:73:
../../include/replacements.h:109:0: warning: "strlcat" redefined
 #define strlcat(d,s,l) tds_strlcat(d,s,l)
 ^
In file included from threadsafe.c:65:0:
/usr/include/roken.h:149:0: note: this is the location of the previous definition
 #define strlcat rk_strlcat
 ^
In file included from threadsafe.c:73:0:
../../include/freetds/tds.h:150:2: warning: function declaration isn’t a prototype [-Wstrict-prototypes]
  TDS_USMALLINT _res:10;
  ^
../../include/freetds/tds.h:150:2: error: bit-field ‘__res_state’ has invalid type
make[4]: *** [Makefile:556: threadsafe.lo] Error 1
make[4]: *** Attesa per i processi non terminati....
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c token.c -o token.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c iconv.c -o iconv.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c convert.c -o convert.o >/dev/null 2>&1
libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../../include -I../../include -DUNIXODBC -DHAVE_UNISTD_H -DHAVE_PWD_H -DHAVE_SYS_TYPES_H -DHAVE_LONG_LONG -DSIZEOF_LONG_INT=8 -I/usr/include -D_REENTRANT -D_THREAD_SAFE -DDEBUG=1 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wpointer-arith -pthread -march=native -O2 -pipe -fomit-frame-pointer -Wdeclaration-after-statement -c query.c -o query.o >/dev/null 2>&1
make[4]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00.41/work/freetds-1.00.41/src/tds"
make[3]: *** [Makefile:571: all-recursive] Error 1
make[3]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00.41/work/freetds-1.00.41/src/tds"
make[2]: *** [Makefile:445: all] Error 2
make[2]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00.41/work/freetds-1.00.41/src/tds"
make[1]: *** [Makefile:420: all-recursive] Error 1
make[1]: uscita dalla directory "/var/tmp/portage/dev-db/freetds-1.00.41/work/freetds-1.00.41/src"
make: *** [Makefile:461: all-recursive] Error 1
Comment 37 Silvio 2017-07-23 06:46:15 UTC
dev-db/freetds-1.00.41

is marked "stable". Better to change till resolved.
Comment 38 Silvio 2017-07-23 06:51:18 UTC
Created attachment 486490 [details]
build log
Comment 39 INODE64 Sistemas 2017-08-09 07:47:27 UTC
I test from 1.0.41 to 1.0.51 and same result

I solved the problem, When It compiled with app-crypt/heimdal, it shows this error.
Comment 40 INODE64 Sistemas 2017-08-09 07:48:52 UTC
Created attachment 488380 [details, diff]
freetds-roken.patch

Path to remove include roken.h, it never used.
Comment 41 INODE64 Sistemas 2017-08-09 07:49:14 UTC
Created attachment 488382 [details]
freetds-1.00.41.ebuild
Comment 43 Michael Orlitzky gentoo-dev 2017-08-11 19:16:12 UTC
(In reply to INODE64 Sistemas from comment #39)
> I test from 1.0.41 to 1.0.51 and same result
> 
> I solved the problem, When It compiled with app-crypt/heimdal, it shows this
> error.

Aha! I can finally reproduce this, thank you!

This is fixed in freetds-1.00.53, but freetds.org is down at the moment so I can't push out the new version. (I grabbed the tarball from a mirror but no idea if the hash is correct.) Once the site is back up, I'll commit the new version and it should fix this problem.
Comment 44 Michael Orlitzky gentoo-dev 2017-08-12 21:01:50 UTC
Ok, v1.00.53 is in the tree and this should finally be fixed. Please try it if you were experiencing this problem.
Comment 45 Michael Orlitzky gentoo-dev 2017-08-16 02:30:02 UTC
No news is good news?