I am using a system command in Perl to execute java. I have formed an array @args that have different options to execute a jar file. Something like below:
$args[0] = $rootpath."/jre/bin/java";
$args[1] = " -jar \"".$rootpath."/temp/abc.jar\"";
$args[2] = " INP=\"".$inputfilename."\"";
$args[3] = " OUT=\"".$outputfilename."\"";
system(@args);
This gives a popup window when executed which I want to suppress and want it to run in background. I want this to be suppressed in Linux also. I tried using tild but it didn't helped as below.
my $command = "@args";
$output = `$command`;
Please help in figuring this out.
I have similar post on stackoverflow
http://stackoverflow.com/questions/30885201/suppress-windows-cmd-for-system-command-in-perl?noredirect=1#comment49841195_30885201
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.