Hugne / tipc-rhel7

TIPC kmod for RHEL7
1 stars 3 forks source link

CentOS 7 Compilation Issue #2

Open zhoub opened 5 years ago

zhoub commented 5 years ago

Hi

I'm trying to build this module on CentOS 7, but the branch rhel7.1 seems like not happy with my local system...

[zhoub@CentOS7 tipc-rhel7-repo]$ uname -r
3.10.0-862.el7.x86_64
libtipc.c: In function ‘tipc_join’:
libtipc.c:224:2: warning: #warning "tipc_join() not supported by this kernel version" [-Wcpp]
 #warning "tipc_join() not supported by this kernel version"
  ^
libtipc.c: In function ‘tipc_leave’:
libtipc.c:235:2: warning: #warning "tipc_leave() not supported by this kernel version" [-Wcpp]
 #warning "tipc_leave() not supported by this kernel version"
  ^
libtipc.c: In function ‘tipc_link_subscr’:
libtipc.c:493:26: error: ‘TIPC_LINK_STATE’ undeclared (first use in this function)
  if (tipc_srv_subscr(sd, TIPC_LINK_STATE, 0, ~0,
                          ^
libtipc.c:493:26: note: each undeclared identifier is reported only once for each function it appears in
libtipc.c: In function ‘tipc_linkname’:
libtipc.c:520:9: error: variable ‘req’ has initializer but incomplete type
  struct tipc_sioc_ln_req req = {peer, bearerid, };
         ^
libtipc.c:520:9: warning: excess elements in struct initializer [enabled by default]
libtipc.c:520:9: warning: (near initialization for ‘req’) [enabled by default]
libtipc.c:520:9: warning: excess elements in struct initializer [enabled by default]
libtipc.c:520:9: warning: (near initialization for ‘req’) [enabled by default]
libtipc.c:520:26: error: storage size of ‘req’ isn’t known
  struct tipc_sioc_ln_req req = {peer, bearerid, };
                          ^
libtipc.c:527:17: error: ‘SIOCGETLINKNAME’ undeclared (first use in this function)
  rc = ioctl(sd, SIOCGETLINKNAME, &req);
                 ^
libtipc.c:520:26: warning: unused variable ‘req’ [-Wunused-variable]
  struct tipc_sioc_ln_req req = {peer, bearerid, };
                          ^
make[2]: *** [libtipc.o] Error 1
make[2]: Leaving directory `/home/zhoub/Downloads/tipcutils/libtipc'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/zhoub/Downloads/tipcutils'
make: *** [all] Error 2

Is there anything I could do ? Thank you very much !

Hugne commented 5 years ago

Hi. Looks like the centos kernel is too old. Actually you'd only need the kernel headers from a recent kernel to get all defs needed to build the utils.. Are you using a rhel kmod build of the tipc module?

I have not worked with tipc for several years, so i suggest that you turn to the tipc discussion mailing list.

//E

On Tue, 25 Sep 2018, 12:06 Bo Zhou, notifications@github.com wrote:

Hi

I'm trying to build this module on CentOS 7, but the branch rhel7.1 seems like not happy with my local system...

[zhoub@CentOS7 tipc-rhel7-repo]$ uname -r 3.10.0-862.el7.x86_64

libtipc.c: In function ‘tipc_join’: libtipc.c:224:2: warning: #warning "tipc_join() not supported by this kernel version" [-Wcpp]

warning "tipc_join() not supported by this kernel version"

^ libtipc.c: In function ‘tipc_leave’: libtipc.c:235:2: warning: #warning "tipc_leave() not supported by this kernel version" [-Wcpp]

warning "tipc_leave() not supported by this kernel version"

^ libtipc.c: In function ‘tipc_link_subscr’: libtipc.c:493:26: error: ‘TIPC_LINK_STATE’ undeclared (first use in this function) if (tipc_srv_subscr(sd, TIPC_LINK_STATE, 0, ~0, ^ libtipc.c:493:26: note: each undeclared identifier is reported only once for each function it appears in libtipc.c: In function ‘tipc_linkname’: libtipc.c:520:9: error: variable ‘req’ has initializer but incomplete type struct tipc_sioc_ln_req req = {peer, bearerid, }; ^ libtipc.c:520:9: warning: excess elements in struct initializer [enabled by default] libtipc.c:520:9: warning: (near initialization for ‘req’) [enabled by default] libtipc.c:520:9: warning: excess elements in struct initializer [enabled by default] libtipc.c:520:9: warning: (near initialization for ‘req’) [enabled by default] libtipc.c:520:26: error: storage size of ‘req’ isn’t known struct tipc_sioc_ln_req req = {peer, bearerid, }; ^ libtipc.c:527:17: error: ‘SIOCGETLINKNAME’ undeclared (first use in this function) rc = ioctl(sd, SIOCGETLINKNAME, &req); ^ libtipc.c:520:26: warning: unused variable ‘req’ [-Wunused-variable] struct tipc_sioc_ln_req req = {peer, bearerid, }; ^ make[2]: [libtipc.o] Error 1 make[2]: Leaving directory `/home/zhoub/Downloads/tipcutils/libtipc' make[1]: [all-recursive] Error 1 make[1]: Leaving directory `/home/zhoub/Downloads/tipcutils' make: *** [all] Error 2

Is there anything I could do ? Thank you very much !

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Hugne/tipc-rhel7/issues/2, or mute the thread https://github.com/notifications/unsubscribe-auth/AA4Tzs_EEvmSovs8HOT4d_CkdJScfWNzks5uegAJgaJpZM4W4SAz .