Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^5: Extending perl with C dynamic library.

by BrowserUk (Pope)
on Aug 20, 2013 at 19:04 UTC ( #1050225=note: print w/ replies, xml ) Need Help??


in reply to Re^4: Extending perl with C dynamic library.
in thread Extending perl with C dynamic library.

Do you know what is wrong ?

Yes. Basically, you have no idea what you are doing.

You are still trying to compile a main() function into a dll.

Dlls contain and export entrypoints that *must* be dynamically linked to and called from an executable (with a main()).

You can't use Inline C to build main programs.


With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.


Comment on Re^5: Extending perl with C dynamic library.
Re^6: Extending perl with C dynamic library.
by Martin90 (Sexton) on Aug 20, 2013 at 19:52 UTC

    "You are still trying to compile a main() function into a dll."

    No.I leave windows and compile code on Linux to .C and then to executable.

    "Yes. Basically, you have no idea what you are doing."

    Well, my problem is weak understand of C programming. That's why I am looking for help on this matter ;)

    Now the only question is why it returns Segmentation fault.

      Well, my problem is weak understand of C programming. That's why I am looking for help on this matter ;)

      This is a Perl forum.


      With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority".
      In the absence of evidence, opinion is indistinguishable from prejudice.
        "This is a Perl forum."

        Right, problem solved anyway.

        Thanks @BrowserUk for your help ;)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1050225]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (17)
As of 2015-07-07 14:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (88 votes), past polls