Oi Adilson,
Passei por uma situação contrária, onde eu tinha o .jar e o cliente
queria porque queria ter um .exe dele. Existem algumas soluções que
criam wrappers .exe para arquivos .jar executáveis, como por exemplo o
JSmooth. Dei uma olhada na documentação dele e descobri algo
interessante (
http://jsmooth.sourceforge.net/docs/jsmooth-doc.html):
---
7.1.1. How does a wrapper extract the jar file?
The jar file extraction is wrapper-specific. However, all the wrapper
provided with JSmooth as of version 0.9.3 extract it in the default
temporary directory. This is the standard behaviour expected by
Windows application.
7.1.2. What happens to the extracted jar file when the java application exits?
Whenever possible, the wrappers delete the file on exit. Note however
that this is not always possible. For example, an instance of a JVM
created using the JVM DLL does not unload cleanly. This behaviour (not
to call it a bug) is documented by Sun, and there is no known
work-around for it.
Both Windowed and Console wrapper always prefer the JVM instanciation
methods that allow them to delete the temp jar after the application
exits. Note that embedding a jar in the exe is not required, it is
always a safe choice to just leave it on the filesystem near the
executable, either in the same directory, or in a sibling or parent
directory.
Note also that deleting the files in the windows TEMP directory is not
required for Windows applications, and most application just leave
them, letting the operating system manage it. The standard behaviour
of MS Windows is to propose the user to delete the temporary files
when the disks are running low on available space.
---
No caso do .exe gerado pelo JSmooth, vc poderia rodar a aplicação .exe
em uma máquina Windows e, enquanto ela está aberta, procurar pelo .jar
original em algum diretório temporário do sistema, copiá-lo e aí sim
rodar esse .jar no Linux, ao invés de tentar rodar o .exe pelo Wine.
Não sei se esse procedimento se aplica a outros "conversores JAR2EXE",
como exe4j, etc. Quem sabe, eles adotam o mesmo procedimento? Acho que
vale a pena tentar. =)
Espero que ajude!
[]'s
Paulo
Em 30 de novembro de 2010 22:37, Mr. Adilson Bonan <arbonan(a)gmail.com> escreveu:
Ola Lista,
Olha so... to com um cenario punk para resolver...
Seguinte...
Cenario:
- O cliente tem um disco fat32 (vfat visto pelo Linux), o disco esta
montado, e o Linux como rw e funciona perfeitamente. O aplicativo WINE do
Linux tambe esta instalado e consegue executar perfeitamete uns programas
".exe" nativos do Windows. Porem, ha uma aplicacao que feita em java que
antes estava no format ".jar" e alguma "vargas dagua" ela foi
convertida
para ".exe" (ainda 'e um .jar) mas agora ta na filosofia ".exe".
- Ela funciona perfeitamente no sistema Windows quando o JRE do Windows
esta configurado corretamente. Mas agora o disco sendo do tipo fat32 (vfat
visto pelo Linux) so tem programas ".exe". Como executar essa aplicacao
".exe" usando o Wine?
Galera eu usei o comando wine aplicacao.exe, entao o wine diz que nao tem o
JRE e sugere baixar... dai eu confirmo e ele nao baixa nada... esse eh o
cenario que eu tenho...ou seja, preciso executar uma aplicacao feita em java
que antes era um ".jar" que foi convertido para ".exe". Nao consegui
instalar o JRE no wine... entao estou me batendo....
Confesso que ja vi esse cenario.. mas nao dei bola e agora to precisando
dele.... hahahah
Quer puder dar uma dica ai... acredito que vai ajudar muita gente ai.
Obrigaduuuuuuuuuu
t+
--
br-users mailing list
br-users(a)lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/br-users