top of page
Search
sazhidyaqdeck

Error While Loading Shared Library File Too Short: A Common Problem with Shared Libraries and How to



root@1fce794aad39: /jetson-inference/build/aarch64/binroot@1fce794aad39:/jetson-inference/build/aarch64/bin# ./imagenet images/jellyfish.jpg images/test/jellyfish.jpg./imagenet: error while loading shared libraries: /usr/lib/aarch64-linux-gnu/libnvinfer.so.7: file too short




Error While Loading Shared Library File Too Short



A NetBackup Server or Enterprise Server license key is needed for installation to continue.Enter license key: : /usr/openv/netbackup/bin/admincmd/bpminlicense: error while loading shared libraries: libnsl.so.1: cannot open shared object file: No such file or directory (127)


sqlplus: error while loading shared libraries tipsOracle Database Tips by Donald BurlesonApril 26, 2015Question: I tried to install Oracle but DBCA aborted. I then tried to open SQL*plus it showing this error:sqlplus: error while loading shared libraries: libclntsh.so.11.1: cannot open shared object file: No such file or directoryHow do I fix this sqlplus: error while loading shared libraries error? Answer: Your problem was that you did not carefully following the pre-install checklist. The installer will very rarely fail, if you follow the directions. Start by reviewing the installer logs and see why it aborted.


Starting Berkeley Internet Name Domain (DNS)...Apr 17 12:18:05 localhost.localdomain bash[2273]: /usr/sbin/named-checkconf: error while loading shared libraries: /lib64/libbind9.so.90: file too shortApr 17 12:18:05 localhost.localdomain systemd[1]: named.service: control process exited, code=exited status=127Apr 17 12:18:05 localhost.localdomain systemd[1]: Failed to start Berkeley Internet Name Domain (DNS).Apr 17 12:18:05 localhost.localdomain systemd[1]: Unit named.service entered failed state.Apr 17 12:18:05 localhost.localdomain systemd[1]: named.service failed.


  • Why is this important? Posting a snippet to the news group is the quickest way to get help. Including a snippet in a bug report is the fastest way to get a bug fixed. Taking the time to construct a snippet helps you understand the API of the library you are calling and focuses your thinking. For example, the SWT team uses C and Java snippets internally to prove or disprove problems in the operating system. Often, something you think is a bug is actually caused by something elsewhere in your program. Snippets isolate problems. Code speaks louder than words. Here is a minimal stand alone SWT program to help you get started:public static void main (String [] args) Display display = new Display (); Shell shell = new Shell (display); shell.open (); while (!shell.isDisposed ()) if (!display.readAndDispatch ()) display.sleep (); display.dispose (); For a list of sample snippets, see the SWT snippets page. Q: Where do I find the SWT source? A: SWT's source can be retrieved directly from GIT as described in Using SWT from GIT. It's also included in eclipse as follows: eclipse 3.4 and newer: plugins/org.eclipse.swt....source_X.X.X..jar

  • eclipse 3.3.2 and earlier: directory plugins/org.eclipse.rcp.source..._X.X.X./src/

Q: How do I build an SWT jar for my platform? A: The SWT jar can be built from the eclipse GIT repository using an Ant task: Retrieve SWT directly from GIT as described in Using SWT from GIT Load the projects org.eclipse.swt and org.eclipse.swt.WS.OS.ARCH where WS.OS.ARCH are the names of the windowing system, operating system and architecture of interest, respectively. For example, org.eclipse.swt.gtk.linux.x86. In the project org.eclipse.swt.WS.OS.ARCH, locate the file build.xml. This is an Ant script. Run Ant on the target build.jars. If you are using eclipse as your development environment, you can run Ant by selecting the file in the Navigator or Packages view, then selecting Run Ant... from the context menu. The script will create file swt.jar in the root directory of the org.eclipse.swt.WS.OS.ARCH project. When it has finished running you can Refresh this project to bring this jar into your eclipse workspace. Q: How do I build the SWT Eclipse plug-in for my platform? A: The SWT Eclipse plug-in can be built (excluding the signing of the jar) with the steps below. Retrieve SWT directly from GIT as described in Using SWT from GIT Load the projects org.eclipse.swt and org.eclipse.swt.WS.OS.ARCH where WS.OS.ARCH are the names of the windowing system, operating system and architecture of interest, respectively. For example, org.eclipse.swt.gtk.linux.x86. (optional) If you wish to compile SWT in your workspace, in the Navigator view rename the org.eclipse.swt project's .classpath_WS file to .classpath. This is useful if, for instance, you have a patch to apply to the SWT codebase before building the plug-in. Invoke the File > Export... menu item, then select the "Plug-in Development" - "Deployable Plug-ins and Fragments" wizard, and press Next. In the resulting wizard's plug-ins list, select the org.eclipse.swt.WS.OS.ARCH fragment. Specify a destination for the output. On the Options tab set the qualifier to the plug-in's desired qualifier string. This will be something like v3655 and must match the qualifier of Eclipse's SWT plug-in that is being replaced. Press Finish to export the plug-in. Important note: Once the plug-in has been exported, the intermediate files that were created in order to make the plug-in jar are not deleted. As a result, subsequent exports of the same plug-in will NOT recompile the workspace contents, and therefore will not contain any changes that have been made in the interim. For such changes to be included in a re-export of the plug-in, these intermediate files must be deleted in order to force their recompilation. The easiest way to do this is to select the org.eclipse.swt.WS.OS.ARCH project, press F5 to refresh it, and then replace its content with the released content. Q: How do I build the SWT JNI libraries for my platform? A: SWT uses JNI to interact with the native widgets in the operating system. The SWT JNI libraries must be compiled for the windowing system, operating system and hardware architecture of interest. The libraries can be built either from the code in the GIT repository or from an eclipse SDK download. In order to build the required libraries and run Eclipse, you will require a JDK (Java Development Kit) version that is supported by Eclipse. Check eclipse.org for details.


  • RendererPlatformStyle FlagDefault Internet ExplorerWindowsSWT.IEYes WebKitmacOS, Linux GTKSWT.WEBKITYes Edge (Chromium-based)WindowsSWT.EDGENo ChromiumAllSWT.CHROMIUMNo Note: As of Eclipse/SWT 4.8, Mozilla (XULRunner) renderer is no longer supported, SWT.MOZILLA flag is deprecated and has no effect. Browser instances created with style SWT.NONE will use the default platform renderer according to the table above. Default renderer does not require additional software installation. It is possible to override the default native renderer, see How do I specify the default type of native renderer that is used by the Browser?. For additional information on specific renderers see How do I explicitly use Chromium as the Browser's underlying renderer? and How do I explicitly use Edge as the Browser's underlying renderer?. Q: How do I specify the default type of native renderer that is used by the Browser? A: The default native renderers that are used for SWT.NONE-style Browsers are listed in Which platforms support the SWT Browser, and which native renderers do they use?. Default is chosen to not require additional software installation and to preserve backward-compativle behavior. A user can set a property to specify the type of native renderer to use for SWT.NONE-style Browsers. Setting this property does not affect Browsers that are created with explicit renderer styles such as SWT.WEBKIT or SWT.CHROMIUM. The property name is org.eclipse.swt.browser.DefaultType and valid values for it currently include "webkit", "ie" (since 4.3), "chromium" (since 4.17) and "edge" (since 4.19). This property must be set before the first Browser instance is created. Note: As of Eclipse/SWT 4.8, Mozilla (XULRunner) renderer is no longer supported, the value mozilla has no effect. A user can specify a comma-separated list of native renderers, in order of preference, for the org.eclipse.swt.browser.DefaultType value. Valus not applicable to a particular platform are ignored. For example, the value of edge,chromium will change the default to Edge on Windows and Chromium on other platforms. The best opportunity for a user to set this property is by launching their application with a -D VM switch (eg. add to the end of the eclipse.ini file: -Dorg.eclipse.swt.browser.DefaultType=chromium). An alternate approach that an eclipse application may use is to provide a BrowserInitializer implementation that sets this property. This implementation will be invoked when the first Browser instance is about to be created. The steps to do this are: Create a fragment with host plug-in org.eclipse.swt.

  • In this fragment create class org.eclipse.swt.browser.BrowserInitializer.

  • Implement a static initializer in this class that sets the org.eclipse.swt.browser.DefaultType property. Q: Which Internet Explorer version do Browsers on Windows use? A: All supported Windows versions provide Internet Explorer 11. An HTML document can override this behavior by including a X-UA-Compatible meta tag as described in Defining Document Compatibility. Additionally, the Browser's default compatibility mode can be overridden by setting Java property org.eclipse.swt.browser.IEVersion to a value from Browser Emulation before the first Browser instance is created. For example, adding the line -Dorg.eclipse.swt.browser.IEVersion=7000 to the end of eclipse's eclipse.ini file will revert all IE-based Browsers to use IE7 compatibility mode by default.

  • Q: What do I need to run the SWT Browser inside Eclipse on Linux? A: Default Browser renderer for Linux GTK is WebKitGTK+ 2. Generally, it will be installed as part of the GTK-based desktop environment. Particular package name depends on the distribution. For example: RHEL, Fedora: webkit2gtk3 or webkitgtk4

  • Debian, Ubuntu: libwebkit2gtk-4.0-37

  • SLES, openSUSE: libwebkit2gtk-4_0-37

  • Note: as of Eclipse/SWT 4.8, Mozilla (XULRunner) is no longer supported. Note: as of Eclipse/SWT 4.15, WebKitGTK 1.x is no longer supported. Chromium renderer is also available for Linux, see How do I explicitly use Chromium as the Browser's underlying renderer?. Q: How do I explicitly use Chromium as the Browser's underlying renderer? A: To specify that a Chromium renderer be used by a Browser instance, create it with style SWT.CHROMIUM (since 4.17) or set the Java property org.eclipse.swt.browser.DefaultType=chromium. You can get the SWT-Chromium libraries from the Eclipse SDK or from the standalone SWT Chromium support libraries section on the download page. To use the Chromium libraries from the Eclipse SDK: Install the CEF binaries in Eclipse from the p2 repo - CEF p2 repo from Make technology

  • Add the required jars to classpath of project: SWT-Chromium fragment (org.eclipse.swt.browser.chromium....jar)

  • SWT fragment (org.eclipse.swt....jar)

  • CEF binary (com.make.chromium.cef....jar)

  • To use the Chromium libraries from the standalone SWT downloads: Get CEF binaries for your platform from the p2 repo: CEF GTK binaries

  • CEF Mac binaries

  • CEF Windows binaries

  • Add the required jars to classpath of project: SWT-Chromium standalone jar (swt-chromium.jar)

  • SWT standalone jar (swt.jar)

  • CEF binary (com.make.chromium.cef....jar)

  • To launch Eclipse with Chromium as the default browser type: Install the CEF binaries in Eclipse from the p2 repo - CEF p2 repo from Make technology

  • In eclipse.ini, add -Dorg.eclipse.swt.browser.DefaultType=chromium under -vmargs.

  • Q: How do I explicitly use Edge as the Browser's underlying renderer? A: To specify that an Edge renderer be used by a Browser instance, create it with style SWT.EDGE (since 4.19) or set the Java property org.eclipse.swt.browser.DefaultType=edge. Edge rendering back-end uses the WebView2 component, which is based on, but distinct from the Edge browser itself. WebView2 has to be installed separately from one of the following sources: A stand-alone runtime installer, either web or offline (Download the WebView2 Runtime from Microsoft). This runtime will be shared between all applications on the machine and will auto-update itself independent of your application.

  • A fixed-version archive with all the necessary files (Same link as above). This is a complete, fixed set of files to be included with your application. Unlike the first option, you have complete freedom in bundling, packaging and updating it.

  • Beta, Dev or Canary version of the Edge browser ( -us/download). This option is convenient for testing, but production deployments should use the previous two options.

  • Note: Stable Edge browser installations don't provide a WebView2 component. See also Distribution of apps using WebView2 on MSDN. SWT will automatically locate installed browsers and runtimes. In case you want to use fixed-version binaries or override the automatically chosen version, set the org.eclipse.swt.browser.EdgeDir Java property to the directory containing msedgewebview2.exe. For example: java "-Dorg.eclipse.swt.browser.EdgeDir=c:\Program Files (x86)\Microsoft\Edge Beta\Application\88.0.705.29" ... WebView2 creates a user data directory to stores caches and persistent data like cookies and localStorage. All WebView2 instances in an application and all instances of the same application share this directory. The default user directory location is %LOCALAPPDATA%\\WebView2, where is defined with Display.setAppName(). This location can be overridden on a per-process basis by setting the org.eclipse.swt.browser.EdgeDataDir Java property. Q: What configuration options are avaibale for the Edge renderer? A: Several Java properties are available to fine-tune the behavior of the Edge renderer. The properties org.eclipse.swt.browser.EdgeDir and org.eclipse.swt.browser.EdgeDataDir are described in How do I explicitly use Edge as the Browser's underlying renderer. The property org.eclipse.swt.browser.EdgeArgs defines command line arguments to be passed directly to the Chromium process. For a list of available arguments (unofficial) see -command-line-switches/. For example, to disable GPU rendering use: java -Dorg.eclipse.swt.browser.EdgeArgs=--disable-gpu ... The property org.eclipse.swt.browser.EdgeLanguage is a language or language+country code that defines the browser UI language and preferred language for HTTP requests (Accept-Languages header). Example values: en, ja, en-GB, de-AT, etc. Informational property org.eclipse.swt.browser.EdgeVersion contains the version of the browser currently in use. Note: All of the properties described above must be set before the first instance of the Edge-based Browser is created. Q: What are the limitations of the Edge Browser renderer? A: Due to API differences and WebView2 implementation details, Edge renderer doesn't implement complete Browser widget API. Some features aren't available or behave differently compared to the older Internet Explorer renderer. AuthenticationListener: Unsupported. Missing upstream API.

  • StatusTextListener: Unsupported. Conceptually obsolete.

  • VisibilityWindowListener.hide: Unsupported. Conceptually obsolete.

  • ProgressListener.changed: Unsupported. Missing upstream API.

  • ProgressListener.completed: Fires for the top level document only. On Edge version 88 and later it matches the DOMContentLoaded JavaScript event, on earlier versions it matches the load JavaScript event.

  • LocationListener.changing, OpenWindowListener.open: These events may return values and have to run synchronously. Calling evaluate() and getText() from their handlers is impossible and will throw an exception.

  • LocationListener.changed: Fires for the top document only. May not fire when using setText().

  • KeyListener, MouseListener: Unsupported. Missing upstream API.

  • evaluate(String script, boolean trusted): The parameter trusted is ignored. Everything runs in the same security context scoped to a given user directory.

  • execute(String script): Execution is always asynchronous. You can't observe evaluation effects immediately after the execute() call. Use evaluate() for synchronous script evaluation.

  • getText(): Returns the live contents of HTML document as seen by the browser. This can differ from what was set with setText() due to browser processing and script execution. Note: Implemented as evaluate("return document.documentElement.outerHTML").

  • setText(): This method uses data: URLs internally (WebView2 implementation detail) and these URLs might appear in the LocationEvent.url field.

  • getCookie(), setCookie(): Unsupported. WebView doesn't have a global cookie manager.

  • setUrl(String url, String postData, String[] headers): The parameters headers and postData require Edge 88 or later (currently in Beta).

  • close(): Unsupported. Missing upstream API.

  • Unless loaded from a file:// URL, pages don't have access to other file:// URLs.

  • Pages navigated to with setText() might appear to have data: URLs in event parameters and elsewhere. (Internet Explorer uses about:blank URL in this case).

  • Q: How do I hide the Browser's scrollbars? A: The only way to influence whether scrollbars are shown in a Browser or not is for the document it's showing to specify a style such as 'overflow:auto' or 'overflow:hidden'. There are two ways to do this: If you are providing the document being shown then its body tag can specify this style like .

  • Alternatively, this style can be changed in the DOM for any document that has been loaded. The easiest way to do this is with a line like .execute("document.getElementsByTagName('body')[0].style.overflow='auto'");.

  • Q: How do I set a proxy for the Browser to use? A: Windows: All Browser instances, regardless of native renderer, automatically use Windows' global proxy settings. These settings can be changed at any time in the Windows Control Panel. OS X: All Browser instances, regardless of native renderer, automatically use OS X's global proxy settings. These settings can be changed at any time in the OS X System Preferences.

  • Linux/Solaris: Proxy information must be explicitly specified by setting values for java properties network.proxy_host and network.proxy_port (@since 3.4). These properties are checked the first time a Browser is created, and if set, will be used for all non-local HTTP, HTTPS and FTP requests in all Browser instances. A user wishing to set these values should do so by passing -D... VM arguments to the JRE at startup.

Q: Why does the SWT_AWT bridge not work for me on OS X, even after updating Java or the OS? A: Prior to Eclipse 3.6, both the Carbon and Cocoa versions of the SWT only supported embedding the SWT in an AWT Frame. In Cocoa SWT 3.6 and later, embedding works in either direction. If you have the right environment, next, make sure you are starting your application with the argument '-XstartOnFirstThread'. This is necessary even if you will be using Swing or the AWT. Next, make sure your code is calling each toolkit on the correct thread. Code that calls into the SWT must be running on the main thread, and code that calls the AWT or Swing must be called from a thread other than the SWT thread, using either java.awt.EventQueue.invokeLater() or javax.swing.SwingUtilities.invokeLater(). NOTE: This is true on ALL PLATFORMS, not just Mac OS X, but your application is almost guaranteed to hang or be very unstable if you don't follow this rule on the Mac. Q: Why is the Print menu item disabled in Eclipse on GTK (Linux, UNIX)? A: GTK+ began supporting printing in version 2.10. To print in Eclipse, you need to have Eclipse version 3.3 or later, and at least GTK+ 2.10.0. To determine what GTK+ version you are running, type: rpm -q gtk2. Prior to Eclipse 3.3, printing was not implemented on GTK; however you can use the External Tools support in Eclipse to print files using lpr or some other printing utility. See here for the steps to set this up. Q: Why do I get the error "org.eclipse.swt.SWTException: Invalid thread access"? A: In SWT, by definition the thread that creates the Display is a UI-thread. This thread is responsible for reading and dispatching events from the operating system event queue, and invoking listeners in response to these events. Listener code is executed in the UI-thread. This makes an SWT application generally quite responsive, behaving like most other operating system programs. However, any long operation, when executed by a listener, will run in the UI-thread and prevent it from reading and dispatching events, thus hanging the application. If a listener has a large amount of work to perform, instead of performing that work in the UI-thread, it can fork a separate thread so the UI-thread can continue dispatching events. If the other thread needs to execute code that accesses an SWT object, such as changing the string in a label, there is a concurrency issue. At the very least, some kind of synchronization is necessary to prevent the operating system or SWT from crashing, hanging or behaving unpredictably. 2ff7e9595c


1 view0 comments

Recent Posts

See All

Comments


bottom of page