Git Product home page Git Product logo

Comments (3)

TheFiZi avatar TheFiZi commented on August 19, 2024

I've made a bit of progress with a CFLAG recommendation I found here

[root@TURMERIC udp-broadcast-relay]# CFLAGS='-Du_char="unsigned char"'
[root@TURMERIC udp-broadcast-relay]# export CFLAGS
[root@TURMERIC udp-broadcast-relay]# make
c99 -Du_char="unsigned char"  -Wall main.c -o udp-broadcast-relay
main.c: In function ‘main’:
main.c:235:3: warning: implicit declaration of function ‘bcopy’ [-Wimplicit-function-declaration]
   bcopy((struct sockaddr_in *) &reqbuf.ifr_addr,
   ^
main.c:316:4: error: ‘u_short’ undeclared (first use in this function)
  *(u_short*)(gram + 22) = (u_short) htons(port);
    ^
main.c:316:4: note: each undeclared identifier is reported only once for each function it appears in
main.c:316:12: error: expected expression before ‘)’ token
  *(u_short*)(gram + 22) = (u_short) htons(port);
            ^
main.c:316:37: error: expected ‘;’ before ‘htons’
  *(u_short*)(gram + 22) = (u_short) htons(port);
                                     ^
main.c:347:59: error: dereferencing pointer to incomplete type
      rcv_ifindex = ((struct in_pktinfo *) CMSG_DATA(cmsg))->ipi_ifindex;
                                                           ^
main.c:374:13: error: expected expression before ‘)’ token
   *(u_short*)(gram + 20) = (u_short) rcv_addr.sin_port;
             ^
main.c:374:38: error: expected ‘;’ before ‘rcv_addr’
   *(u_short*)(gram + 20) = (u_short) rcv_addr.sin_port;
                                      ^
main.c:377:13: error: expected expression before ‘)’ token
   *(u_short*)(gram + 24) = htons(8 + len);
             ^
main.c:378:13: error: expected expression before ‘)’ token
   *(u_short*)(gram + 2) = htons(28 + len);
             ^
main.c:392:21: error: expected expression before ‘)’ token
     ntohs(*(u_short*) (gram + 22)), /* dst port */
                     ^
make: *** [udp-broadcast-relay] Error 1

from udp-broadcast-relay.

TheFiZi avatar TheFiZi commented on August 19, 2024

What ever improvements were made by this PR fixed my compilation issues.

I've cloned their repo for now and will use that until their PR is merged.

from udp-broadcast-relay.

nomeata avatar nomeata commented on August 19, 2024

That’s odd, #7 doesn’t seem to affect compilation via make at all.

from udp-broadcast-relay.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.