public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: John MacFarlane <jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org>
To: Uwe Brauer <oub-YB6e1s5WF/He5aOfsHch1g@public.gmane.org>,
	pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: Mac 10.15 compiling using ghc
Date: Fri, 30 Apr 2021 08:31:14 -0700	[thread overview]
Message-ID: <m2im436b7h.fsf@MacBook-Pro.hsd1.ca.comcast.net> (raw)
In-Reply-To: <87wnsjewqw.fsf-YB6e1s5WF/He5aOfsHch1g@public.gmane.org>


The issue is that ghc doesn't know where to find the dependent
libraries (in this case pandoc-types).  On ubuntu you probably
had this installed in a central location.

Generally, to build Haskell code with dependencies you need to
use stack or cabal.

But see here:
https://stackoverflow.com/questions/65539773/compiling-a-haskell-script-with-external-dependencies-without-cabal

It looks like you can do:

cabal install --lib pandoc-types
ghc --make striplatex.hs

Try that.

Uwe Brauer <oub-YB6e1s5WF/He5aOfsHch1g@public.gmane.org> writes:

> Hi
>
> Under linux (Ubuntu 16.04)
>
> I run successfully 
>
>  ghc --make striplatex.hs 
> where striplatex is just
>
> ,----
> | import Text.Pandoc.JSON
> |     
> | main = toJSONFilter stripmath
> |     where stripmath (Math _ _) = Str "FORMULA"
> |           stripmath x = x
> `----
>
> That nicely replaces all my mathematical formula, just by the word
> FORMULA
>
> I tried the same under Mac 10.15. 
>
> For that I installed pandoc https://github.com/jgm/pandoc/releases/tag/2.13
>
> I install ghc using fink (that is one of the three linux like
> environments (the others are macports and homebrew).
>
> However when I run 
>
>  ghc --make striplatex.hs 
>
> I obtain 
>
> Could not find module Text.Pandoc.JSON
>
> I admit I just started using a Mac and don't know many details.
>
> Any help would be appreciated 
>
> Thanks
>
> Uwe Brauer 
>
> -- 
> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/87wnsjewqw.fsf%40mat.ucm.es.


  parent reply	other threads:[~2021-04-30 15:31 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-30 13:18 Uwe Brauer
     [not found] ` <87wnsjewqw.fsf-YB6e1s5WF/He5aOfsHch1g@public.gmane.org>
2021-04-30 15:31   ` John MacFarlane [this message]
     [not found]     ` <m2im436b7h.fsf-jF64zX8BO08an7k8zZ43ob9bIa4KchGshsV+eolpW18@public.gmane.org>
2021-04-30 15:34       ` John MacFarlane
2021-04-30 16:25         ` Uwe Brauer
     [not found]           ` <87czubeo4d.fsf-YB6e1s5WF/He5aOfsHch1g@public.gmane.org>
2021-04-30 19:03             ` John MacFarlane
     [not found]               ` <m2y2cz389c.fsf-jF64zX8BO08an7k8zZ43ob9bIa4KchGshsV+eolpW18@public.gmane.org>
2021-04-30 19:04                 ` John MacFarlane
2021-05-01 11:11                   ` Uwe Brauer
2021-05-02 17:53                   ` [some success] (was: Mac 10.15 compiling using ghc) Uwe Brauer
     [not found]                     ` <m27dkhc9a5.fsf_-_-YB6e1s5WF/He5aOfsHch1g@public.gmane.org>
2021-05-02 20:33                       ` John MacFarlane
2021-05-03  7:18                         ` [some success] Uwe Brauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2im436b7h.fsf@MacBook-Pro.hsd1.ca.comcast.net \
    --to=jgm-tvlzxgkolnx2fbvcvol8/a@public.gmane.org \
    --cc=oub-YB6e1s5WF/He5aOfsHch1g@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).