Stas Sergeev <s...@list.ru> wrote:
>29.06.2013 01:10, Mateusz Viste пишет:
>> In fact, I don't think embedding slirp is a good thing anymore.
>Yes but we need to be realistic.
>We can embed slirp and clearly state that this is a temporary
>solution until someone (of qemu) not to push the package out
>of it. :)

That sounds quite reasonable. Altough I am a bit scared - yesterday I managed 
to compile slirt as a standalone .a library, the problem is that it uses plenty 
of global stuff and functions named exactly as in dosemu, so my linker was 
complaining a lot (and after integration it either made dosemu immediately 
segfault or simply networking wasn't working). That's the main reason why I 
brought the dosemu.slirp idea - to be safe, and avoid the risk of breaking 
dosemu with some nasty border effects.. But maybe is there any another (safer) 
way to embed an executable than a static .a file..? A way that would allow to 
expose only specific functions to the linker?

>I see. :)
>Well if your code just works, then we can mark it as a
>temporary solution too... Trying to get everything right
>from the start, will lead us no where.
>But I would still encourage you to take a look into this:
>https://github.com/mwilliamson/vde/blob/master/vde-2/include/libvdeplug.h
>and this:
>http://git.qemu.org/?p=qemu.git;a=blob;f=net/vde.c;h=2a619fbc813b3e2fe8b508f347348a6d115ab381;hb=HEAD
>to see how (seemingly) simple it is.

I am not sur this code is relevant to us - from what I understand it is for 
connecting to a vde switch, not to the vdeslirp thing.

Anyway, a better bet would probably be to try to integrate libslirp from qemu, 
since they seem to be the most active ones nowadays and all cool kids downtown 
are shamelessly copying from them. But again, after some quick tries I didn't 
succeeded to take it out of qemu (it is quite deeply embedded now, and uses 
calls to qemu-specific code). And I simply lack spare time (and knowledge) to 
play with these things.

This is where my librouter solution is nice - it is a standalone library that 
presents a single socket to the application, without requiring any integration. 
And since dosemu already supports tap interfaces, making it support my 
librouter was trivial (I actually spent more time fighting with git than 
implementing librouter inside qemu) :D

Mateusz
-- 
Sent from mobile mail.

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Dosemu-devel mailing list
Dosemu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dosemu-devel

Reply via email to