fx5 / usbdmx

Linux/Mac/Windows-Driver for DMX-Interfaces from Digital Enlightenment and FX5
http://www.fx5.de/
BSD 3-Clause "New" or "Revised" License
17 stars 14 forks source link

#ifdef __cplusplus #2

Closed fps closed 11 years ago

fps commented 11 years ago

Hi,

to make it easier to use the header from a C++ source:

diff --git a/usbdmx.h b/usbdmx.h
index 6409e25..a1e6629 100644
--- a/usbdmx.h
+++ b/usbdmx.h
@@ -1,3 +1,7 @@
+#ifdef __cplusplus
+extern "C" { 
+#endif
+
 #include <stdint.h>

 // types for library functions
@@ -56,4 +60,7 @@ DWORD OpenInterface(TDMXArray * DMXOutArray, TDMXArray * DMXInArray, unsigned ch
 DWORD CloseInterface(void);

+#ifdef __cplusplus
+}
+#endif
fx5 commented 11 years ago

Good idea. Thank you!

I'll do this next time I make a change, or feel free to open a pull request.

fps commented 11 years ago

On 01/04/2013 03:19 PM, Frank Sievertsen wrote:

Good idea. Thank you!

I'll do this next time I make a change, or feel free to open a pull request.

— Reply to this email directly or view it on GitHub https://github.com/fx5/usbdmx/issues/2#issuecomment-11884117.

Ah you mean to fork it and then issue a pull request?

Flo

Florian Paul Schmidt http://fps.io

fx5 commented 11 years ago

Patch applied. Thanks again!