I had a problem with OS shared in a project on Linux with Lazarus, I found the solution in:
a>After running the above guidelines my application started to work, however I can not run it through the lazarus (compila normal, but does not open and does not display error message), being able to run only through the terminal.
I think the problem is related to OS calling, because when I take this call off, the application works normally.
I use version 1.2.6 of Lazarus and Linux Debian 32 bits.