* [Caml-list] OASIS help - libraries with mixed C/C++ part
@ 2013-10-05 10:13 Michał Kurcewicz
2013-10-05 13:58 ` Philippe Veber
2013-10-06 3:19 ` ygrek
0 siblings, 2 replies; 3+ messages in thread
From: Michał Kurcewicz @ 2013-10-05 10:13 UTC (permalink / raw)
To: caml-list
[-- Attachment #1: Type: text/plain, Size: 581 bytes --]
Hello,
I am migrating some old code from OCamlMakefile to a oasis/ocamlbuild based
build process. While the migration is generally straightforward, I have
encountered some problems with a library where the C part includes mixed
C/C++ code. Putting the C++ files into CSources: in _oasis does not seem to
work, the files are not even copied over to the _build directory, changing
the file extensions and adding some options (-x c++) also does not solve
the problem. What is recommended way to build libraries that include a
mixed C/C++ part using OASIS/ocamlbuild?
Regards,
--mk
[-- Attachment #2: Type: text/html, Size: 734 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Caml-list] OASIS help - libraries with mixed C/C++ part
2013-10-05 10:13 [Caml-list] OASIS help - libraries with mixed C/C++ part Michał Kurcewicz
@ 2013-10-05 13:58 ` Philippe Veber
2013-10-06 3:19 ` ygrek
1 sibling, 0 replies; 3+ messages in thread
From: Philippe Veber @ 2013-10-05 13:58 UTC (permalink / raw)
To: Michał Kurcewicz; +Cc: caml users
[-- Attachment #1: Type: text/plain, Size: 1177 bytes --]
Hi Michal,
for an example you can have a look at a binding [1] of the Irrlicht 3d
engine (for the record my fork [2] currently has a small addition) or a
binding [3] I started (but never got very far) of the Ogre3D library. The
latter shows how to put the C++ files in a subdirectory, which was not that
easy to obtain.
HTH,
Philippe.
[1] https://github.com/antegallya/OCaml-Irrlicht
[2] https://github.com/pveber/OCaml-Irrlicht
[3] https://github.com/pveber/ogrillon
2013/10/5 Michał Kurcewicz <michal.kurcewicz@gmail.com>
>
> Hello,
>
> I am migrating some old code from OCamlMakefile to a oasis/ocamlbuild
> based build process. While the migration is generally straightforward, I
> have encountered some problems with a library where the C part includes
> mixed C/C++ code. Putting the C++ files into CSources: in _oasis does not
> seem to work, the files are not even copied over to the _build directory,
> changing the file extensions and adding some options (-x c++) also does not
> solve the problem. What is recommended way to build libraries that include
> a mixed C/C++ part using OASIS/ocamlbuild?
>
> Regards,
>
> --mk
>
[-- Attachment #2: Type: text/html, Size: 1741 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Caml-list] OASIS help - libraries with mixed C/C++ part
2013-10-05 10:13 [Caml-list] OASIS help - libraries with mixed C/C++ part Michał Kurcewicz
2013-10-05 13:58 ` Philippe Veber
@ 2013-10-06 3:19 ` ygrek
1 sibling, 0 replies; 3+ messages in thread
From: ygrek @ 2013-10-06 3:19 UTC (permalink / raw)
To: caml-list
On Sat, 5 Oct 2013 12:13:28 +0200
Michał Kurcewicz <michal.kurcewicz@gmail.com> wrote:
> Hello,
>
> I am migrating some old code from OCamlMakefile to a oasis/ocamlbuild based
> build process. While the migration is generally straightforward, I have
> encountered some problems with a library where the C part includes mixed
> C/C++ code. Putting the C++ files into CSources: in _oasis does not seem to
> work, the files are not even copied over to the _build directory, changing
> the file extensions and adding some options (-x c++) also does not solve
> the problem. What is recommended way to build libraries that include a
> mixed C/C++ part using OASIS/ocamlbuild?
One also needs to link with stdc++
The following should work
CCopt: -g -x c++ -O2 -Wextra -Wstrict-overflow=5 -fno-strict-aliasing -Wfatal-errors
CClib: -lstdc++
--
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-10-06 3:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-05 10:13 [Caml-list] OASIS help - libraries with mixed C/C++ part Michał Kurcewicz
2013-10-05 13:58 ` Philippe Veber
2013-10-06 3:19 ` ygrek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox