ocaml-libusb/lib/dune

33 lines
675 B
Plaintext
Raw Permalink Normal View History

2018-07-12 15:08:54 +00:00
(library
(name libusb)
(public_name libusb)
(flags -w "-9")
(libraries ctypes)
(c_names cstub_libusb)
(c_flags (:include libusb_cflags_and_no_discarded_qualifiers))
(c_library_flags -lusb-1.0)
)
(rule
(targets libusb_cflags_and_no_discarded_qualifiers)
(deps generator/stubs/libusb_cflags)
(action
(with-stdout-to %{targets}
(progn (echo "(")
(cat %{deps})
(echo " -Wno-discarded-qualifiers")
(echo ")")
)
)
)
)
(copy_files generator/g.ml)
(copy_files generator/stubs/{t,my_types}.ml)
(rule
(targets cstub_libusb.c bindings.ml)
(deps generator/generator.exe)
(action (run %{deps}))
)