Netbeans pluging installation offline - windows

I have a system which is offline and has no access to Internet.
I want to add Java Card plugin to my Netbeans. How can I add Java Card plugin on my PC (which is offline)?
I could not find .nbm file for Java card for its offline installation.
P.S. I have a 2nd system which is up and running and has Java Card plugin on its Netbeans. I thought this might help to copy files from 2nd PC to 1st PC. But I was looking to a better approach.

This following approach is a bit of a hack, but it worked for me. On a NetBeans installation which has internet access, but does not yet have Java Card installed:
Go to Tools > Plugins, and download/install the Java Card plugin. In my case installing the Java Card plugin triggered the download and installation of several other required plugins:
Specifically choose not to restart NetBeans during the plugin process.
Within your NetBeans installation directory, the installation of the Java Card plugin will have created a directory named javacard/update/download. In my case the full path of that directory is C:/NetBeans14/javacard/update/download, but yours will almost certainly be different.
Copy the content of that directory to some arbitrary empty directory on your machine without internet access.
The copied directory on your offline machine should look similar to this, with a couple of XML files and thirteen plugins with the nbm file extension:
07/30/2022 02:39 PM 1,633 additional_information.xml
07/30/2022 02:39 PM 2,619 install_later.xml
07/30/2022 02:37 PM 110,204 org-netbeans-modules-javacard-apdu-io.nbm
07/30/2022 02:37 PM 89,498 org-netbeans-modules-javacard-apdufile.nbm
07/30/2022 02:37 PM 109,226 org-netbeans-modules-javacard-common.nbm
07/30/2022 02:37 PM 110,491 org-netbeans-modules-javacard-console.nbm
07/30/2022 02:37 PM 106,018 org-netbeans-modules-javacard-filemodels.nbm
07/30/2022 02:37 PM 84,771 org-netbeans-modules-javacard-kit.nbm
07/30/2022 02:37 PM 89,855 org-netbeans-modules-javacard-platform-ui.nbm
07/30/2022 02:37 PM 426,563 org-netbeans-modules-javacard-project.nbm
07/30/2022 02:37 PM 177,235 org-netbeans-modules-javacard-ri-platform.nbm
07/30/2022 02:38 PM 131,152 org-netbeans-modules-javacard-spi.nbm
07/30/2022 02:37 PM 92,895 org-netbeans-modules-properties-based-dataobjects.nbm
07/30/2022 02:37 PM 89,160 org-netbeans-modules-simple-project-templates.nbm
07/30/2022 02:37 PM 90,796 org-netbeans-modules-swing-customizerlayout.nbm
The thirteen nbm files correspond to the thirteen plugins listed in the Verify Certificate screenshot above.
Finally, on the offline machine select Tools > Plugins > Downloaded > Add Plugins, navigate to the directory containing the copied plugins that you just created (named JavaCardPlugins in my case), select all of the nbm files for installation, select All Files from the Files of Type drop list, and click the Open button:
Once Java Card and its associated plugins have been installed, choose to restart NetBeans, and you should see that the Java Card plugin is listed under Tools > Plugins > Installed.
Notes:
It is important not to immediately restart NetBeans after installing Java Card on the machine with internet access because the nbm files to be copied to the offline machine will be deleted by NetBeans during the restart.
You may not want to mess with your existing NetBeans installation on the machine with internet access, since you would need to uninstall/reinstall Java Card. So either create a second temporary NetBeans installation solely for downloading/installing/copying the nbm files on that machine, or use an alternative machine with internet access.
You don't need to understand the purpose of the individual plugins, or the sequence in which they should be installed. Just select them all for installation at the same time and NetBeans will work out what needs to be done.
Although I have only verified this approach for Java Card, I suspect it would probably work for the offline installation of any plugin.

Related

FHIR IG Publisher templates

This http://ots.nccn.org/documentation/site/StructureDefinition-order-template.xml.html
was generated on Apr 2017 and I have been some updates top the schema. I am new to this process and did some reading and saw this tool org.hl7.fhir.igpublisher that would create the new HTML for me. I download the JAR file and run the command but I am getting this error >Exception in thread "main" java.lang.Error: unknown version 1.9.0
java.exe -jar C:\Project\IGPublisher\org.hl7.fhir.igpublisher.jar -ig "C:\Project\IGPublisher\Publish\ig.json" -watch
FHIR Implementation Guide Publisher (v3.6.0-a77f48d9, gen-code v3.6.0 / 2) # Wednesday, October 17, 2018 1:28:34 PM
Detected Java version: 1.8.0_191 from C:\Program Files\Java\jre1.8.0_191 on amd64 (64bit). 1797MB available
[C:\Project\IGPublisher] -ig C:\Project\IGPublisher\Publish\ig.json -watch
Package Cache: C:\Users\mcdevitt\.fhir\packages
Load Configuration from C:\Project\IGPublisher\Publish\ig.json (00.0020sec)
Root directory: C:\Project\IGPublisher\Publish (00.0106sec)
Terminology Cache is at C:\Project\IGPublisher\Publish\txCache. 243 files in cache (00.0147sec)
Contacting Build Server... (00.0148sec)
... done (01.0177sec)
Exception in thread "main" java.lang.Error: unknown version 1.9.0
at org.hl7.fhir.igtools.publisher.Publisher.getMasterSource(Publisher.java:1460)
at org.hl7.fhir.igtools.publisher.Publisher.loadCorePackage(Publisher.java:1426)
at org.hl7.fhir.igtools.publisher.Publisher.initializeFromJson(Publisher.java:1088)
at org.hl7.fhir.igtools.publisher.Publisher.initialize(Publisher.java:946)
at org.hl7.fhir.igtools.publisher.Publisher.execute(Publisher.java:525)
at org.hl7.fhir.igtools.publisher.Publisher.main(Publisher.java:4927)
Press any key to continue . . .
please take this up on https://chat.fhir.org/#narrow/stream/99-IG-creation (which you have)

Windows using hidden file rather than directory in paths...Why?

I (and my colleague) are having this problem with 32-bit applications on a 64-bit Windows 7 OS. We have also found the same problems when we invoke a 64-bit application and pass a path as described below as a parameter in cmd.exe.
Given the path "C:\dir1\dir2\file1.txt", we have some 32-bit applications that don't appear to be able to consistently resolve that path and find the file if there is a hidden file of a particular naming structure causing it to lose it's way.
For example, given the directory/file structure:
\dir1
\dir2
\file1.txt
\.dir2Blah
Of importance is that the "hidden" file's name starts with the same characters as those which indicate a directory at that same level of the hierarchy. What comes after that in the hidden file's name is irrelevant. It could be called ".dir2Whatever".
The problem is that more often than not (but not consistently always) some 32-bit applications we use can't find the file1.txt file. We're told it can't be found or it doesn't exist, etc. in the application. Using Process Monitor, we found the reason appears to be that while the path being asked for is C:\dir1\dir2\file1.txt, the path being evaluated by the the Windows system is C:\dir1\.dir2Blah\file1.txt.
We have found that some 32-bit applications appear to be able to work fine with those (what I would call) erroneous paths and successfully find the files in question but others do not.
As I said above, we have also found we can reproduce the problem with 64-bit applications if we try to open the file through a cmd.exe prompt; for example, "textpad.exe \dir1\dir2\file1.txt".
We've "googled" this problem for 2 days because we're completely stumped and cannot believe that no one else has ever encountered this if it's so "easy" to reproduce. My colleague and I are both able to cause the failure; not consistently, but file access will fail more than half the time when we set up the structure I described.
I've included a picture of Process Monitor showing this failure in two applications but succeeding in a third...here.
Can anyone tell me what is going on? First, why is it changing the path to use that hidden file rather than the directory name provided? And, more importantly, how can we make it stop ;-)?
Cheers,
jtm
Added later:
Here's the "dir /x" output for a directory where I'm having this problem.
24/05/2017 12:17 PM <DIR> .
24/05/2017 12:17 PM <DIR> ..
24/05/2017 12:17 PM 12 BLAHTS~1 .blahtst
23/05/2017 03:06 PM 104 JSHINT~1 .jshintrc
24/05/2017 12:16 PM <DIR> blah
24/05/2017 12:16 PM 0 blank.txt
24/05/2017 12:15 PM 6,624 INDEX~1.HTM index.html
24/05/2017 10:48 AM <DIR> js
It also indicates how we stumbled on the problem. I have an html file that is trying to load a JavaScript file under the /js directory, but there is also a .jshintrc file at the same level and my old Apache server can't find the files to serve them. If I remove the .jshintrc file, I can get around this, but this project isn't one I created and I'm leery of just removing things willy nilly.

Apktools on Mac

I went downloaded the Apktools from the website and got 2 files: Apktool.txt and Apktool_2.2.2. I renamed the Apktool_2.2.2 to Apktools.jar per the instructions. I then went to terminal and this was what I did:
Last login: Fri Mar 17 12:08:55 on ttys000
Roberts-MBP:~ Robert$ cd documents
Roberts-MBP:documents Robert$ cd metronomeapp/apktool
Roberts-MBP:apktool Robert$ **java -jar apktool.jar**
Apktool v2.2.2 - a tool for reengineering Android apk files
with smali v2.1.3 and baksmali v2.1.3
Copyright 2014 Ryszard Wiśniewski <brut.alll#gmail.com>
Updated by Connor Tumbleson <connor.tumbleson#gmail.com>
usage: apktool
-advance,--advanced prints advance information.
-version,--version prints the version then exits
usage: apktool if|install-framework [options] <framework.apk>
-p,--frame-path <dir> Stores framework files into <dir>.
-t,--tag <tag> Tag frameworks using <tag>.
usage: apktool d[ecode] [options] <file_apk>
-f,--force Force delete destination directory.
-o,--output <dir> The name of folder that gets written. Default is apk.out
-p,--frame-path <dir> Uses framework files located in <dir>.
-r,--no-res Do not decode resources.
-s,--no-src Do not decode sources.
-t,--frame-tag <tag> Uses framework files tagged by <tag>.
usage: apktool b[uild] [options] <app_path>
-f,--force-all Skip changes detection and build all files.
-o,--output <dir> The name of apk that gets written. Default is dist/name.apk
-p,--frame-path <dir> Uses framework files located in <dir>.
For additional info, see: http://ibotpeaches.github.io/Apktool/
For smali/baksmali info, see: https://github.com/JesusFreke/smali
Roberts-MBP:apktool Robert$ **./apktool d metronome.apk**
-bash: ./apktool: No such file or directory
Roberts-MBP:apktool Robert$ **apktool d metronome.apk**
-bash: apktool: command not found
Roberts-MBP:apktool Robert$
You can see in the bold what I entered. On the 2nd and 3rd bold statements, I did it both ways because I found info that one of them works on windows and one on mac and since the mac one didn't work I wanted to try the windows one to see what it would say. Both the files are in the same directory with the apk file (metronome.apk) Does anyone know why this isn't working and what I can do to resolve it?
Thanks.
Robert
Try java -jar apktool.jar d metronome.apk
To elaborate, apktool.jar is not a command itself. It's a java Jar file that can be executed by the Java runtime.

Missing some spoon steps (plugins) at runtime (KarafLifecycleListener Error)

I am using open-source Pentaho distribution from github.com (version 6.1-SNAPSHOT).
In Spoon there are some step missing (e.g. There is no Mongodb input/output step listed) and I cant add dataservice to step (There are no errors, this option just isn't on the list).
I have reinstalled everything (removed .kettle and .pentaho directories as well as whole source and distribution) but it didn't help.
This is what I get at spoon startup:
16:05:50,304 INFO [KarafInstance]
* Karaf Instance Number: 1 at ~/pentaho-kettle/d
ist/./system/karaf//data1
Karaf Port:8801
OSGI Service Port:9050 *
Dec 23, 2015 4:05:51 PM org.apache.karaf.main.Main$KarafLockCallback
lockAquired
INFO: Lock acquired. Setting startlevel to 100
2015/12/23 16:05:53 - cfgbuilder - Warning: The configuration
parameter [org] is not supported by the default configuration builder
for scheme: sftp
Dec 23, 2015 4:05:58 PM
org.pentaho.caching.impl.PentahoCacheManagerFactory$RegistrationHandler$1
onSuccess INFO: New Caching Service registered
16:06:04,009 ERROR [KarafLifecycleListener] The Kettle Karaf Lifycycle
Listener failed to execute properly. Releasing lifecycle hold, but
some services may be unavailable.
I suspect that
ERROR [KarafLifecycleListener] The Kettle Karaf Lifycycle Listener
failed to execute properly. Releasing lifecycle hold, but some
services may be unavailable.
has something to do with it as missing plugins reside somewhere under karaf/ directory.
It was working just fine week ago.
I am using Ubuntu 15.04.
I will be grateful for any hints.
Greetings.
you are using a non stable release. this is the place where you can download the latest stable release http://sourceforge.net/projects/pentaho/
Agreed with jipipayo, For Pentaho CE version, download it from http://community.pentaho.com/ official instead of github. It is highly possible that the codes in github might be in unstable condition.
Also in case you have a missing plugin, try using the Pentaho Marketplace and download the required plugins.
Hope this helps :)

Cannot get cabal to find the mpi library for haskell-mpi on Windows [closed]

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.
Closed 11 years ago.
PROBLEM IS SOLVED!
Follow the instructions Dons posted here
Open your environment variables (My Computer -> Properties (in the context menu) -> Advanced)
Add to or make a new environment variable C_INCLUDE_PATH so it points to MPI's include directory. In my case, /c/program files/mpich2/include.
Add to or make a new environment variable LIBRARY_PATH so it points to MPI's lib directory. In my case, /c/program files/mpich2/lib
Hide libmpi.a somehow. If need be, you can fix this later. It is a hack but you cannot build haskell-mpi without doing it because ld will fail. I renamed it to _libmpi.a
Now haskell-mpi should build on windows. Anticipating more trouble down the line, but it built, and it solved my problem.
I am wanting to use haskell-mpi on a lab machine at one of my university labs to do my final project for my parallel computing class, but I am running into trouble trying to get haskell-mpi to build against MPICH2.
haskell-mpi is pretty much completely undocumented, and digging through their git repository has helped me program some example programs on it but has done nothing to help me set it up on Windows. On my personal linux system, I had no trouble setting up and running haskell-mpi against MPICH2.
The problem is probably in one of cabal, the way MPICH2 is installed, or with haskell-mpi's cabal configuration, hence the choice of tags.
I am open to experimenting here for the sake of troubleshooting, and adding more information as needed, but eventually I will no longer have access to these machines.
I have administrator rights in the lab where I will be running this, so if the problem is with the MPICH2 installation itself, I could indeed reinstall it.
cabal fails as follows when I try to install haskell-mpi:
Resolving dependencies...
Configuring haskell-mpi-1.0.0...
cabal: Missing dependency on a foreign library:
* Missing C library: mpi
This problem can usually be solved by installing the system package that
provides this library (you may need the "-dev" version). If the library is
already installed but in a non-standard location then you can use the flags
--extra-include-dirs= and --extra-lib-dirs= to specify where it is.
cabal: Error: some packages failed to install:
haskell-mpi-1.0.0 failed during the configure step. The exception was:
ExitFailure 1
Here are what I tried giving for --extra-lib-dirs and --extra-include-dirs:
--extra-lib-dirs="C:\Program Files\MPICH2\lib"
--extra-include-dirs="C:\Program Files\MPICH2\include"
I've tried reordering where I put those flags, escaping the backlashes, using the short path PROGRA~1 and various permutations of these. So I don't think this is going to help. I need to know what the mpi dependency actually means and figure out how I will satisfy it so that this library can actually build. Here is what lives in the two aforementioned folders at this moment:
Libs:
Volume in drive C has no label.
Volume Serial Number is 5406-5C5C
Directory of C:\Program Files\MPICH2\lib
04/22/2011 01:20 PM <DIR> .
04/22/2011 01:20 PM <DIR> ..
01/31/2011 03:59 PM 515,704 cxx.lib
01/31/2011 04:23 PM 137,434 fmpich2.lib
01/31/2011 04:25 PM 410,982 fmpich2g.lib
01/31/2011 04:29 PM 162,690 fmpich2s.lib
01/31/2011 04:53 PM 0 libfmpich2g.a
01/31/2011 04:53 PM 0 libmpi.a
01/31/2011 04:53 PM 215,528 libmpicxx.a
01/31/2011 04:16 PM 10,618 mpe.lib
01/31/2011 04:46 PM 135,434 mpi.lib
9 File(s) 1,588,390 bytes
2 Dir(s) 221,505,835,008 bytes free
Include:
Volume in drive C has no label.
Volume Serial Number is 5406-5C5C
Directory of C:\Program Files\MPICH2\include
02/01/2011 05:38 PM <DIR> .
02/01/2011 05:38 PM <DIR> ..
11/17/2009 09:46 PM 4,857 clog_commset.h
11/02/2007 05:50 PM 696 clog_const.h
01/31/2011 03:50 PM 731 clog_inttypes.h
11/17/2009 09:46 PM 1,353 clog_uuid.h
10/21/2010 01:20 PM 355 mpe.h
11/17/2009 09:46 PM 11,102 mpe_log.h
11/02/2007 05:50 PM 1,833 mpe_logf.h
11/17/2009 09:46 PM 1,322 mpe_misc.h
01/31/2011 03:50 PM 57,128 mpi.h
01/31/2011 04:23 PM 3,251 mpi.mod
01/31/2011 03:50 PM 97,267 mpicxx.h
01/31/2011 03:51 PM 19,051 mpif.h
01/31/2011 03:50 PM 16,765 mpio.h
01/31/2011 04:23 PM 13,668 mpi_base.mod
01/31/2011 04:23 PM 30,866 mpi_constants.mod
01/31/2011 04:23 PM 7,802 mpi_sizeofs.mod
16 File(s) 268,047 bytes
2 Dir(s) 221,505,830,912 bytes free
Is there anything here that might be recognizably missing?
I am quite stumped at this point. Just about any suggestion would be helpful.
Sincerely, Barend.
PS: This should probably be tagged "haskell-mpi", but I'm not allowed to make new tags. I guess nobody else is really using it yet.
EDIT: Following Dons' suggestion,
I installed MingGW and MSYS. After running mingw-get update, I used mingw32-get to retrieve libtools, mingw32-utils, and mingw32-binutils. I set the following environment variables for the whole system using the Windows configuration GUI:
LIBRARY_PATH="C:\Program Files\MPICH2\lib"
C_INCLUDE_PATH="C:\Program Files\MPICH2\include"
echo $LIBRARY_PATH and echo %LIBRARY_PATH% now both work as expected, no surprises there. The environment variables are set. Making progress.
cabal install haskell-mpi still produces the same output it did before.
Played with ld for a long time, huge red herring...
I had to hide libmpi.a from ld to get it to work, but haskell-mpi now builds!
Putting step by step details at the top.
I need to know what the mpi dependency actually means
The line extra-libraries: mpi means that Cabal will add -lmpi to the ld linker options. In addition, tools that process headers will search in the include paths.
So, how do we help GHC and binutils find that library?
According to the wiki, assuming you have mingw or msys,
If you need to link to C-software, define an environment variable C_INCLUDE_PATH that lists the directories where the header files can be found. For linking the libraries you need to define an environment variable LIBRARY_PATH as well, listing the directories where .a and .lib files can be found.
So try setting the paths to include the path to the headers and libraries.

Resources