Rolf Sponsel wrote:
> I've built pfil-2.1.11 on a SPARCstation 5 running Solaris 7 
> (SPARC/32bit) and noticed that gcc 3.2.2 complains about assigning an 
> integer to a pointer without a cast.
...
> gcc   -I.. -I. -D_KERNEL -DSUNDDI -DSOLARIS2=7 -DPFILDEBUG -c pkt.c -o pkt.o
> pkt.c: In function `pfil_makearpreq':
> pkt.c:246: warning: assignment makes pointer from integer without a cast

See thread "pfil-2.1.10, Solaris 7 failure" from May 11, 2006.
There is no ire_lookup() in Solaris 7, and ire_ftable_lookup() has one
argument less than in Solaris 8 and higher. Try (NOT YET TESTED BY ME!):

*** SunOS/pkt.c.ORI     Wed May 24 08:06:48 2006
--- SunOS/pkt.c Mon Jul 17 09:19:54 2006
***************
*** 242,247 ****
--- 242,250 ----
  #if SOLARIS2 >= 8
        sif = ire_ftable_lookup(addr, 0, 0, IRE_INTERFACE, NULL, NULL, 0, 0,
                                MATCH_IRE_TYPE);
+ #elif SOLARIS2 == 7
+       sif = ire_ftable_lookup(addr, 0, 0, IRE_INTERFACE, NULL, NULL, 0,
+                               MATCH_IRE_TYPE);
  #else
        sif = ire_lookup(src);
  #endif
***************
*** 268,274 ****
  #if SOLARIS2 >= 8
        src.s_addr = ipif->ipif_lcl_addr;
  #else
!       src = ipif->ipif_local_addr;
  #endif
  
        MI_BCOPY(&src, n, a->areq_sender_addr_offset, 4);
--- 271,277 ----
  #if SOLARIS2 >= 8
        src.s_addr = ipif->ipif_lcl_addr;
  #else
!       src.s_addr = ipif->ipif_local_addr;
  #endif
  
        MI_BCOPY(&src, n, a->areq_sender_addr_offset, 4);

Reply via email to