# Create OS X graphic executable with ocamlc

**URL:** <https://discuss.ocaml.org/t/create-os-x-graphic-executable-with-ocamlc/5565>\
**Category:** Learning\
**Tags:** build\
**Created:** [April 19, 2020, 5:07pm UTC](https://discuss.ocaml.org/t/create-os-x-graphic-executable-with-ocamlc/5565 "2020-04-19T17:07:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fredOnGitHub](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ocaml.org/fredongithub/32/2144_2.png) [@fredOnGitHub](https://discuss.ocaml.org/u/fredOnGitHub)\
**Post date:** [April 19, 2020, 5:07pm UTC](https://discuss.ocaml.org/t/create-os-x-graphic-executable-with-ocamlc/5565/1 "2020-04-19T17:07:17Z")

</div>

Hello

I’d like to know the syntaxe for Mac to create executable with graphics

I have the graphic window with

```auto
$ utop
#require "graphics" ;;
Graphics.open_graph "";;

```

but with compile syntaxe like

```auto
% ocamlc graphics.cma test_graph.ml

```

I get

```auto
**File "test_graph.ml", line 18, characters 0-19** :
18 | Graphics.open_graph "";;

**^^^^^^^^^^^^^^^^^^^**

**Error** : Unbound module Graphics

```

How to do ?

The program is

```auto
Graphics.open_graph "";;

```
