<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://jogamp.org/bugzilla/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.2"
          urlbase="https://jogamp.org/bugzilla/"
          
          maintainer="sgothel@jausoft.com"
>

    <bug>
          <bug_id>1271</bug_id>
          
          <creation_ts>2015-11-22 13:44:04 +0100</creation_ts>
          <short_desc>Load the native libraries from the memory instead of using temporary files</short_desc>
          <delta_ts>2019-03-29 14:19:17 +0100</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>3</classification_id>
          <classification>JogAmp</classification>
          <product>Gluegen</product>
          <component>core</component>
          <version>2.4.0</version>
          <rep_platform>All</rep_platform>
          <op_sys>all</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P4</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Julien Gouesse">gouessej</reporter>
          <assigned_to name="Sven Gothel">sgothel</assigned_to>
          <cc>gouessej</cc>
          
          <cf_type>FEATURE</cf_type>
          <cf_scm_refs></cf_scm_refs>
          <cf_workaround>---</cf_workaround>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>5491</commentid>
    <comment_count>0</comment_count>
    <who name="Julien Gouesse">gouessej</who>
    <bug_when>2015-11-22 13:44:04 +0100</bug_when>
    <thetext>The automated native library loading currently requires to extract the native libraries into a kind of temporary cache on the file system. It uses a small binary file to detect whether a directory is &quot;executable&quot;. However, some virus scanners detect this binary file as a virus, some others detect the extracted libraries as possible viruses. Moreover, GlueGen fails to find a location to build this temporary cache in constrained environments or a valid location might become unusable when there isn&apos;t enough available space.

Java and the Windows API don&apos;t support the native library loading when the library isn&apos;t in the file system but it&apos;s possible to load a DLL from the memory:
https://github.com/fancycode/MemoryModule

Actually, a JIT compiler can do something similar.

I suggest to copy the native libraries into the memory and to load them from it instead of extracting them into the file system first.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>5562</commentid>
    <comment_count>1</comment_count>
    <who name="Julien Gouesse">gouessej</who>
    <bug_when>2016-02-29 17:46:12 +0100</bug_when>
    <thetext>It&apos;s too much ambitious. Such a mechanism would be difficult to maintain. However, a more simple solution would be more suitable, for example a property to define the location of the cache.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>