I am developing an app for a system that has GTK2 as the latest GTK library installed. I'm using Anjuta and Glade's wysiwyg design interface.
I've used "project > add library" to add the library support for GTK2
and used the project tab on the left to remove support for GTK3.
When I try running my application I get the following error message:
CRITICAL **: couldn't load builder file: src/gtk_foobar.ui: required gtk+ version 3.0, current version is 2.24
This error starts coming up as soon as I remove GTK3 as one of the libraries.
I need this application to work on systems without GTK3.
Related
I'm using Fedora 27 as my Operating System, and I'm wondering if I could get the Xamarin toolset working on it to create cross platform apps with an IDE like monodevelop, VS Code or Rider.
I heard Xamarin get's new templates for Xamarin.Forms for Linux, but I can't find any recent development news about that.
Yes, as of mid-2018, it is somewhat possible to develop a Xamarin.Forms app under MonoDevelop on Linux. I successfully managed to do it.
Basically, you need to have at least two things:
A shared library project, containing all the cross-platform Xamarin.Forms code and Xaml files. For some reason, on Linux this library project have to be compiled with .NET Core toolchain and not Mono toolchain (otherwise there is some GTK issues at runtime later on). The target framework is .NET Standard 1.0 or .NET Standard 2.0, and the main dependency is the NuGet package "Xamarin.Forms".
A Mono/GTK# platform-specific project for Linux, containing all the platform specific code: initialize GTK and Xamarin.Forms.Platform.GTK backend, and start the Xamarin.Forms code. The dependencies are the NuGet package "Xamarin.Forms.Platform.GTK", references to locally installed GTK# of your linux distribution (gtk-sharp, atk-sharp, etc...), and obviously a reference to the shared library project. Note that only GTK2 is supported and not GTK3.
The shared library project may be developed with MonoDevelop, Visual Studio, or JetBrains Rider. Note that with MonoDevelop, there is no XAML designer... so this is easier to do the design stuff with Visual Studio on Windows.
The platform specific project may be developed using MonoDevelop or Rider on Linux.
Here is a picture of the project structure under MonoDevelop:
There is a "HelloWorldXamarin" library project. It uses the .NET Core toolchain targeting .NET Standard 1.0, and have a dependency to NuGet package "Xamarin.Forms"
There is a "HelloWorldXamarin_Linux" project. It uses the Mono toolchain targeting Mono/GTK# for Linux, and have dependencies to GKT# and HelloWorldXamarin library, as well as dependency to NuGet package "Xamarin.Forms.Platform.GTK". You can see the platform specific code on the right.
And a picture of the result:
So you can now develop cross-platform Xamarin.Forms GUI applications for Windows,Mac,Linux,Android,iOS...
Yes you can and how well it will work on Fedora I'm not sure, but it looks like development is still in progress for the GTK Backend on Linux. For more information, there's a Github repo here that shows how far along it is and how you can try it yourself.
Following "How to run waveform developed in REDHawk IDE in my target board ( Zedboard by Xilinx)?", a custom OS is developed using Yocto and Redhawk recipes and installed it in Zedboard. SCA application is being developed using Redhawk IDE installed in development PC. To run the same application in custom OS, a cross-toolchain is generated for that environment using "bitbake redhawk-base-image -c populate_sdk" command (source: https://www.yoctoproject.org/docs/1.6/adt-manual/adt-manual.html). Idea is to develop the application in development PC and build it with cross-toolchain. So, now what is the procedure to integrate cross toolchain with Redhawk IDE?
The Yocto Project provides some tooling for this.
There is little experience in the community with customizing the build-chain in the REDHAWK IDE; ultimately you just want to research updating the build chain in the Eclipse CDT which can you find information about on-line.
The following is provided as a possible approach (one that hasn't been tested). The current build-chain for the REDHAWK IDE is completely based on the generated build scripts that are a part of all REDHAWK projects:
"build.sh all" to build
"build.sh clean" to clean
"build.sh install" to install
You've no doubt noticed this in the console as you've worked with projects in the IDE. So as long as you modify your project to cross-compile when build.sh is getting invoked, the build portion will happen automatically within the IDE. However, it's another matter to get the IDE to understand that your project is referencing files for the embedded board's operating system, and not the native operating system. Here's a rough outline of what I think you'd need to do:
Help -> Install New Software
Under Mobile and Device Development find and install C/C++ GCC Cross Compiler Support
Window -> Preferences
C/C++ -> Build -> Settings
Under Discovery, select CDT Cross GCC Built-in Compiler Settings
Modify the command used to get the compiler specs as appropriate for the embedded platform
Create a new component, get it setup so that when build.sh is run it is cross-compiled for the embedded platform
Project -> Properties
C/C++ General -> Paths and Symbols
Select Includes tab
Select GNU C++
Modify include directories as needed for the embedded platform
C/C++ General -> Preprocessor Includes
Select Providers
Uncheck CDT GCC Built-in Compiler Settings
Check CDT Cross GCC Built-in Compiler Settings
I wanted to write c++ desktop application with fine UI, so I did it in QT Creator.
Then I decided to add some UI features, and I moved to QML(QT Quick Application).
I installed QML Desktop Components according to here instructions, used import Qt.labs.components 0.1 and it worked well.but now I have to deploy my application, and I noticed that the application runs only on Debug mode, and not on Release mode. I checked, and saw that I have just the styleplugind.dll, and not the styleplugin.dll. Shortly, I have only the debug dll, and not the release one. I installed the components again,for release, and I really got the styleplugin.dll. but when I'm running my application(I remembered adding CONFIG+=release to my .pro file),I'm getting this error:
loaded for module "Qt.labs.components": The plugin 'C:/QtSDK/Desktop/Qt/4.7.4/mingw/imports/Qt/labs/components/plugin/styleplugin.dll' uses incompatible Qt library. Expected build key "Windows mingw release full-config", got "Windows mingw debug full-config"
import Qt.labs.components 0.1
^
I don't understand why I'm getting that: I have the right .dll file, and everything seems okay.
(BTW, I'm on Windows7)
What should I do??
The problem is, as the error output states, that your styleplugin.dll is still build against an incompatible Qt build (debug, expected is release).
I want to make a executable file of my project which I made in JavaFX 2.0. Can anyone help me with this?
The JavaFX team implemented support for this in the tools bundled with the JavaFX 2.2 SDK (included in Java7 from update 6). The JavaFX packaging toolset for packaging executables is documented in self-contained application section of the JavaFX deployment guide.
See RT-19446 "Add ability to co-bundle Java + JavaFX + App into a single native executable" for more information (anybody can sign up to view the jira).
3rd party tools such as the JavaFX maven plugin or the JavaFX gradle plugin, streamline integration of building native JavaFX executables using common build systems.
The JavaFX packaging tools can also be used to natively package any Java application, not just JavaFX applications. For example, a Swing application, as demonstrated by this shell script for packaging a Swing application using JavaFX on OS X.
If you want to do the packaging for the 2.0 or 2.1 versions of JavaFX (not JavaFX 2.2+), then you should review Packaging JavaFX Applications as Native Installers.
Javafx 2+ can now easily be packaged as a native exe (with an added payload, which the current JRE), the up to date (as in the end of 2012) article is here: http://docs.oracle.com/javafx/2/deployment/self-contained-packaging.htm
Out of curiosity I created an executable on Windows (copy-pasting the netbeans build code into netbeans' build.xml) from the canvas and the hello world examples: the app is around 20k, the executable/launcher is around 80k and the added runtime is 138mb.
By the way if you have an older netbeans install (installed with a pre 1.7jdk) you may have to update it or edit its netbeans.conf fixing the "netbeans_jdkhome" path, otherwise the bundled executable's packaging may fail.
There are several tools to generate a customized exe launcher for your Java application.
I have good experience with Winrun4J: http://winrun4j.sourceforge.net/
but you will always need an installed Java/JavaFX Runtime even if you have an .exe that contains all your code.
What are your strategies for building your JavaFX application on Mac and deploying on Windows ? I am currently having issues with how to bundle up my application so that it is double clickable on both platforms. I have tried using the ant-tools, but the jar file produced complain that JavaFX 2.1 needs to be installed on my Mac (how can I place the JavaFX 2.1 DP distribution so that the double-clickable Jar knows where to find it ?)
On the Windows side, Java7u3 is installed, which "comes with" Java FX 2.0.3. I need for the application to be able to execute as a double clickable JAR file here as well.
Any suggestions as to how this is set up ? I am using Maven to build my project. The more details you can provide the better.
Since 2.1 release the only (official) way to install JavaFX on Mac is cobundle installation with Java 7u4 (opposite to developers preview versions being published in zip archives).
If JavaFX on Mac was installed this way then jar with JavaFX can be run by double-click.
On Windows same jar by double-click will ask to install "JavaFX runtime" and will start if one is present already.
N.B.: in 2.2 release Mac/Linux would start to support jnlp (WebStart) run (already supported on Windows) which may suit you even better.