commonmark / cmark

CommonMark parsing and rendering library and program in C
Other
1.6k stars 534 forks source link

Building cmark for iOS #15

Closed RuiAAPeres closed 9 years ago

RuiAAPeres commented 9 years ago

I followed the steps to create a libcmark.0.18.1.dylib, but when added to the project I get a:

building for iOS Simulator, but linking against dylib built for MacOSX file

How can I make the dylib to iOS?

jgm commented 9 years ago

This might require some cmake tweaks.

Did you tell cmake you wanted to build an XCode project?

There's an ios toolchain here which you could try: https://code.google.com/p/ios-cmake/wiki/HowTo

RuiAAPeres commented 9 years ago

@jgm would it be possible to simply import the c files + headers and work with that?

jgm commented 9 years ago

Sure. Note, though, that you'll need a few generated headers which you can find in build/src after a regular build.

+++ Rui Peres [Mar 17 15 12:31 ]:

@jgm would it be possible to simply import the c files + headers and work with that?


Reply to this email directly or view it on GitHub: https://github.com/jgm/cmark/issues/15#issuecomment-82556271

RuiAAPeres commented 9 years ago

@jgm one quick question (I wasn't able to find an example), how would you go about to generate the AST from the markdown using your lib?

jgm commented 9 years ago

parse_document is the function that does that. See the man page cmark.3.

+++ Rui Peres [Mar 18 15 03:31 ]:

@jgm one quick question (I wasn't able to find an example), how would you go about to generate the AST from the markdown using your lib?


Reply to this email directly or view it on GitHub: https://github.com/jgm/cmark/issues/15#issuecomment-82885442