Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to build on FreeBSD 12.0 (post-ino64) #1105

Closed
jbeich opened this issue Jun 29, 2017 · 2 comments
Closed

Fails to build on FreeBSD 12.0 (post-ino64) #1105

jbeich opened this issue Jun 29, 2017 · 2 comments

Comments

@jbeich
Copy link

jbeich commented Jun 29, 2017

Regressed by freebsd/freebsd-src@e75ba1d5c4c7 (see sys/sys/user.h) and fixed downstream by freebsd/freebsd-ports@248a430dd138. Can you apply the fix?

CC'ing @kostikbel (patch author) and @sunpoet (package maintainer).

$ python2.7 setup.py build
[...]
psutil/arch/freebsd/proc_socks.c:139:27: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                    &kif->kf_sa_local))
                     ~~~  ^
psutil/arch/freebsd/proc_socks.c:143:27: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                    &kif->kf_sa_peer))
                     ~~~  ^
psutil/arch/freebsd/proc_socks.c:148:27: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                    &kif->kf_sa_local))
                     ~~~  ^
psutil/arch/freebsd/proc_socks.c:152:27: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                    &kif->kf_sa_peer))
                     ~~~  ^
psutil/arch/freebsd/proc_socks.c:246:48: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                                         &kif->kf_sa_local),
                                          ~~~  ^
psutil/arch/freebsd/proc_socks.c:252:48: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                                         &kif->kf_sa_peer),
                                          ~~~  ^
psutil/arch/freebsd/proc_socks.c:256:58: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                                                   &kif->kf_sa_local));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:74:37: note: expanded from macro '__bswap16'
        ((__uint16_t)(__builtin_constant_p(x) ? \
                                           ^
psutil/arch/freebsd/proc_socks.c:256:58: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                                                   &kif->kf_sa_local));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:33: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                       ^
/usr/include/x86/endian.h:66:40: note: expanded from macro '__bswap16_gen'
#define __bswap16_gen(x)        (__uint16_t)((x) << 8 | (x) >> 8)
                                              ^
psutil/arch/freebsd/proc_socks.c:256:58: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                                                   &kif->kf_sa_local));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:33: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                       ^
/usr/include/x86/endian.h:66:51: note: expanded from macro '__bswap16_gen'
#define __bswap16_gen(x)        (__uint16_t)((x) << 8 | (x) >> 8)
                                                         ^
psutil/arch/freebsd/proc_socks.c:256:58: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                                                   &kif->kf_sa_local));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:53: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                                           ^
psutil/arch/freebsd/proc_socks.c:258:58: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                                                   &kif->kf_sa_peer));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:74:37: note: expanded from macro '__bswap16'
        ((__uint16_t)(__builtin_constant_p(x) ? \
                                           ^
psutil/arch/freebsd/proc_socks.c:258:58: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                                                   &kif->kf_sa_peer));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:33: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                       ^
/usr/include/x86/endian.h:66:40: note: expanded from macro '__bswap16_gen'
#define __bswap16_gen(x)        (__uint16_t)((x) << 8 | (x) >> 8)
                                              ^
psutil/arch/freebsd/proc_socks.c:258:58: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                                                   &kif->kf_sa_peer));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:33: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                       ^
/usr/include/x86/endian.h:66:51: note: expanded from macro '__bswap16_gen'
#define __bswap16_gen(x)        (__uint16_t)((x) << 8 | (x) >> 8)
                                                         ^
psutil/arch/freebsd/proc_socks.c:258:58: error: no member named 'kf_sa_peer' in 'struct kinfo_file'
                                                   &kif->kf_sa_peer));
                                                    ~~~  ^
/usr/include/netinet/in.h:118:26: note: expanded from macro 'htons'
#define htons(x)        __htons(x)
                                ^
/usr/include/x86/endian.h:127:30: note: expanded from macro '__htons'
#define __htons(x)      __bswap16(x)
                                  ^
/usr/include/x86/endian.h:75:53: note: expanded from macro '__bswap16'
            __bswap16_gen((__uint16_t)(x)) : __bswap16_var(x)))
                                                           ^
psutil/arch/freebsd/proc_socks.c:290:51: error: no member named 'kf_sa_local' in 'struct kinfo_file'
                sun = (struct sockaddr_un *)&kif->kf_sa_local;
                                             ~~~  ^
15 errors generated.
@giampaolo
Copy link
Owner

I don't have that specific FreeBSD version to test against. Can you make a PR?

@giampaolo
Copy link
Owner

CC @kostikbel @sunpoet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants