[JAVA 11] Can't load native DLLs. Then later install fails when calling SetupQueueCopy

Description

I have been trying to rebuild a java webstart application to a stand alone application using izpack. This standalone application can then replace the java webstart application when we switch from java 8 to java 11.
The standalone application can be build and the installation and the application works using java 8.
After I have changed the code to use java 11 I can build it. When I run the installer using jdk 11 I am running into two problems:

1) While running the installer it does detect the native elements in installer.xml, but it fails to find the included native DLLs

2) Later on when the installion has been completed it crashes with SetupQueueCopy returned with code 87: De parameter is onjuist. (The parameter is invalid).

I am unsure if these problems are related or not, but I assume so, which is why I am only creating a single issue.

I am running the installer jar in an administrator command window using
java -DDEBUG=true -DSTACKTRACE=true -DTRACE=true -jar CENSORED-installer.jar

Details:
1a) installer.xml

This seems to work:
Checking if OS constraints OsModel{arch='x86', family='windows', jre='null', name='null', version='null'} match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
OS constraints do not match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
Checking if OS constraints OsModel{arch='x64', family='windows', jre='null', name='null', version='null'} match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
OS constraints matched platform
Checking if OS constraints OsModel{arch='x86', family='windows', jre='null', name='null', version='null'} match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
OS constraints do not match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
Checking if OS constraints OsModel{arch='x64', family='windows', jre='null', name='null', version='null'} match platform=windows,version=10.0,arch=x64,symbolicName=WINDOWS_10,javaVersion=11.0.5
OS constraints matched platform

However, when you look at the attached logfile CENSORED-installer JAVA 11.log.txt you can see that it still tries to find the 32 bit DLLs and it fails to find either one.

2) When I look at the parameters we are sending to SetupQueueCopy and compare it to the windows documentation (https://docs.microsoft.com/en-us/windows/win32/api/setupapi/nf-setupapi-setupqueuecopya) I do no see anything that can be going wrong except that if I dig into the stacktrace

it is clear that we scheduled a File to be moved. If I dig a little deeper I find that what is happening is this
FileQueueMove.addTo(WinSetupFileQueue filequeue)
->
WinSetupFileQueue.addMove(File sourcefile, File targetfile)
->
addCopy(sourcefile, targetfile, false)
->
In this addCopy method we pass this style parameter:
int style = 0 /SP_COPY_IN_USE_NEEDS_REBOOT/;
as copyStyle
to addCopy(File sourcefile, File targetfile, int /* DWORD */copyStyle)

However when I check the izpack code I find
public static final int SP_COPY_IN_USE_NEEDS_REBOOT = 0x0000100;
in WinSetupAPIBase

Therefore I am assuming perhaps 0 is an invalid parameter and it should have been 0x0000100 instead ?

Additional information:
My build.gradle file has

plugins {
id 'application'
id 'edu.sc.seis.launch4j' version '2.4.6'
id 'com.bmuschko.izpack' version '3.0' <-
// CENSORED other plugins
}

sourceCompatibility = 1.11
targetCompatibility = 1.11

dependencies {
// CENSORED Lots of implementation calls

izpack 'org.codehaus.izpack:izpack-ant:5.1.3' <-
}

If have attached my installer.xml file as CENSORED-installer.xml

Environment

64 bit Windows 10

Assignee

Unassigned

Reporter

Lodewijk Gonggrijp

Impact

None

Affects versions

Priority

Medium
Configure