hzzc1987 / jnaerator

Automatically exported from code.google.com/p/jnaerator
0 stars 0 forks source link

rev 435 broken on linux (patch) #20

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Initialization of the default include path is broken on linux, since an
unmodifieable list is created for the default include path. At startime
modifications fail.

patch:
Index: sources/com/ochafik/lang/jnaerator/JNAeratorConfigUtils.java
===================================================================
--- sources/com/ochafik/lang/jnaerator/JNAeratorConfigUtils.java    (revision 435)
+++ sources/com/ochafik/lang/jnaerator/JNAeratorConfigUtils.java    (working copy)
@@ -97,9 +97,11 @@
            list.add(".");
            DEFAULT_INCLUDE_PATH = Collections.unmodifiableList(list);
        } else {
-           DEFAULT_INCLUDE_PATH = Arrays.asList(".");
+           DEFAULT_INCLUDE_PATH = new ArrayList<String>();
+           DEFAULT_INCLUDE_PATH.add(".");
        }
        if (SystemUtils.isUnix()) {
+           DEFAULT_INCLUDE_PATH = new ArrayList<String>();
            DEFAULT_INCLUDE_PATH.add("/usr/include");

Original issue reported on code.google.com by everf...@gmail.com on 13 Jun 2009 at 8:21

GoogleCodeExporter commented 8 years ago
Hi everflux,

Thanks a lot for the report !
I've just checked-in / uploaded a fix.
Could you confirm it works ?

Regards

Original comment by olivier.chafik@gmail.com on 13 Jun 2009 at 9:22

GoogleCodeExporter commented 8 years ago
Thanks for your quick response and fix, works for me now.

Original comment by everf...@gmail.com on 13 Jun 2009 at 9:59