Date: Tue, 17 Jan 2006 00:01:17 +0100 From: Ondra Knezour <knezour@weboutsourcing.cz> To: freebsd-emulation@freebsd.org Subject: Using Linux shared libraries Message-ID: <43CC25BD.3070100@weboutsourcing.cz>
next in thread | raw e-mail | index | archive | help
Dear all, I have some comercial Linux application, which I'm able to run on FreeBSD using linux emulation. However, there are two linux shared libraries for Firebird database and I'm looking for some way how to use them. Not too successfully yet. Tried to brand them as linux binaries as first step, but this solution wasn't successfull, as expected. Later I found some discussion confirming my expectation, that this mixing of bsd and linux binaries is simply impossible. Then I tried to make plugin wrapper using www/linuxpluginwrapper port with make dummy.c TARGET_PLUGIN=target_plugin_path mv dummy.c debug/dummy_plugin_name.c add plugin to Makefile and debug/Makefile.inc make target_plugin install for both plugin files. I got two requested files installed, created symlink to them form Firebird UDF directory, but I haven't any succes to run Firebird server with them. Server is randomly not responding, dying silently, sometimes with ERR10 - No child process (watched with truss). My questions: Is there some usefull reading about using linux plugins for bsd applications? Is there any how-to for linuxpluginwrapper or usefull discussion thread? I looked at some port which use this plugin, but I don't feel myself fully understanding this tool, especially how to found which additional files should be specified in plugin_nameOBJ variable in Makefile. Which way is sugested for watching calls and responses between executed binary and shared library? I use truss -fae, but there must be something more usefull for this situation. GDB will probably do what I expect, but if there is wide consensus about debugging this scenario, I want to know which one it is. Another way may be possible - decompile linux file and compile it on FreeBSD. I have some asm-like decompiled files for mentioned libraries, but assembler isn't my best friend, so I want to ask, if this way may be successfull and if can, which method and tools can lead to success. Versions used: FreeBSD server 6.0-SECURITY FreeBSD 6.0-SECURITY #0: Mon Dec 19 23:46:33 UTC 2005 root@builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC i386 Firebird TCP/IP server version FB-V1.5.2.4731 Firebird 1.5 Some additional sources: modified LPW Makefile http://gw.weboutsourcing.cz/fb/Makefile modified LPW debug/Makefile.inc http://gw.weboutsourcing.cz/fb/Makefile.inc dummy.c files generated for libraries http://gw.weboutsourcing.cz/fb/dummy_udfs_00.c http://gw.weboutsourcing.cz/fb/dummy_udfs_01.c some disassembled sources http://gw.weboutsourcing.cz/fb/udfs_00res.zip http://gw.weboutsourcing.cz/fb/udfs_00dis.zip Thanks for your time -- Best Regards Ondra Knezour
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?43CC25BD.3070100>