From: Ihor Radchenko <yantar92@posteo.net>
To: Leo Butler <Leo.Butler@umanitoba.ca>
Cc: tbanelwebmin <tbanelwebmin@free.fr>,
"emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: How to use mpirun with C or C++ Org-babel?
Date: Fri, 08 Dec 2023 22:24:45 +0000 [thread overview]
Message-ID: <87msukbadu.fsf@localhost> (raw)
In-Reply-To: <87plzg7l25.fsf@t14.reltub.ca>
Leo Butler <Leo.Butler@umanitoba.ca> writes:
> I submitted an imperfect patch some time ago [1] that targeted your use
> case: allow ob-C.el to create a named binary. Unfortunately, Ihor
> dropped the issue due to lack of interest from other users.
>
> My goal was to enable something like this to work:
>
> #+begin_src cpp :includes <iostream> :results none :file ./hello-world
> std::cout << "Hello World!\n";
> #+end_src
>
> #+begin_src bash :async t
> mpirun -np 4 ./hello-world
> #+end_src
>
> As I said, the patch I wrote was not perfect, but I am happy to re-visit
> the issue. The ability to create named binaries would significantly
> increase the usability of ob-C for projects where you want to compile
> the source once and run the binary repeatedly for potentially long
> periods of time.
Note that I did not oppose the above behaviour when the result of
evaluation is just compiling to :file. The problem was with compiling to
a :file and _also_ executing it.
If you want to propose a patch that will allow compile-only, I see no
problem at all.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
next prev parent reply other threads:[~2023-12-08 22:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-07 23:10 How to use mpirun with C or C++ Org-babel? Edgar Lux
2023-12-08 10:36 ` tbanelwebmin
2023-12-08 15:47 ` Leo Butler
2023-12-08 22:24 ` Ihor Radchenko [this message]
2023-12-13 16:09 ` Leo Butler
2023-12-14 14:08 ` Ihor Radchenko
2023-12-19 22:14 ` [PATCH] ob-C.el compile-only header argument, was " Leo Butler
2023-12-22 12:20 ` Ihor Radchenko
2024-01-04 17:53 ` Leo Butler
2024-01-05 12:47 ` Ihor Radchenko
2023-12-20 18:15 ` Leo Butler
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
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87msukbadu.fsf@localhost \
--to=yantar92@posteo.net \
--cc=Leo.Butler@umanitoba.ca \
--cc=emacs-orgmode@gnu.org \
--cc=tbanelwebmin@free.fr \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).