[Xorp-users] Building Xorp SVN on Linux Debian sparc fails

Jose Manuel dos Santos Calhariz jose.spam at netvisao.pt
Sun Mar 7 10:07:14 PST 2010


On Sat, Mar 06, 2010 at 12:14:00AM -0800, Ben Greear wrote:
> On 03/05/2010 07:29 PM, Jose Manuel dos Santos Calhariz wrote:
>>
>> I am trying to compile Xorp SVN on a sparc machine running Debian.
>> But it fails with:
>>
>> g++ -o obj/sparc64-unknown-linux-gnu/libproto/packet.os -c -O1 -g3 -Werror -W -Wall -Wwrite-strings -Wcast-qual -Wpointer-arith -Wcast-align -Woverloaded-virtual -ftemplate-depth-25 -pipe -fPIC -DXRL_PF=120 -D_FORTIFY_SOURCE=0 -DBOOST_DISABLE_THREADS -I/usr/local/include -Iobj/sparc64-unknown-linux-gnu -I. -I. libproto/packet.cccc1plus: warnings being treated as errors
>> libproto/packet.cc: In static member function 'static ArpHeader&  ArpHeader::assign(uint8_t*)':
>> libproto/packet.cc:238: error: cast from 'uint8_t*' to 'ArpHeader*' increases required alignment of target type
>> libproto/packet.cc: In static member function 'static const ArpHeader&  ArpHeader::assign(const std::vector<unsigned char, std::allocator<unsigned char>  >&)':
>> libproto/packet.cc:248: error: cast from 'const unsigned char*' to 'const ArpHeader*' increases required alignment of target type
>> scons: *** [obj/sparc64-unknown-linux-gnu/libproto/packet.os] Error 1
>> scons: building terminated because of errors.
>
> Here's a patch against my tree (and will probably apply somewhat clean to official SVN)
> that might fix your problem.

Thank you.  It applied without problems to the official SVN and
compiles.  Now the compilation stops on another error.  

g++ -o obj/sparc64-unknown-linux-gnu/fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.os -c -O1 -g3 -Werror -W -Wall -Wwrite-strings -Wcast-qual -Wpointer-arith -Wcast-align -Woverloaded-virtual -ftemplate-depth-25 -pipe -fPIC -DXRL_PF=120 -D_FORTIFY_SOURCE=0 -DBOOST_DISABLE_THREADS -I/usr/local/include -Iobj/sparc64-unknown-linux-gnu -I. -I. fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc
cc1plus: warnings being treated as errors
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc: In static member function 'static int IfConfigGetNetlinkSocket::parse_buffer_netlink_socket(IfConfig&, IfTree&, const std::vector<unsigned char, std::allocator<unsigned char> >&)':
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc:87: error: cast from 'char*' to 'nlmsghdr*' increases required alignment of target type
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc: In function 'void nlm_newlink_to_fea_cfg(IfTree&, const ifinfomsg*, int)':
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc:269: error: cast from 'char*' to 'rtattr*' increases required alignment of target type
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc: In function 'void nlm_dellink_to_fea_cfg(IfTree&, const ifinfomsg*, int)':
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc:533: error: cast from 'char*' to 'rtattr*' increases required alignment of target type
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc: In function 'void nlm_newdeladdr_to_fea_cfg(IfTree&, const ifaddrmsg*, int, bool)':
fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.cc:598: error: cast from 'char*' to 'rtattr*' increases required alignment of target type
scons: *** [obj/sparc64-unknown-linux-gnu/fea/data_plane/ifconfig/ifconfig_parse_netlink_socket.os] Error 1
scons: building terminated because of errors.



>
> Compile tested only..seems VRRP is the only user, and it is broken anyway, so I don't
> have a good way to actually test the code...
>
> You can find my tree at:
> http://www.candelatech.com/oss/xorp-ct.html

I am pulling your tree rigth now.  It's interesting your approach for
xorp and resources.

>
> If this works for you, I'll commit it, unless someone sees problems with it.
>
> Thanks,
> Ben
>
>

     José Calhariz

-- 
--

Entre no negócio sabendo o quanto quer ganhar; quando chegar lá, caia fora

--Max Gunther
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: Digital signature
Url : http://mailman.ICSI.Berkeley.EDU/pipermail/xorp-users/attachments/20100307/85a8c05c/attachment.bin 


More information about the Xorp-users mailing list