How do I set up the delphi development environment in Ubuntu? - linux

I started developing Delphi, but I do not know how to use Delphi in Linux.

You can't use Delphi itself in Linux directly, as the Delphi IDE and compilers are all Windows-only executables. So, to run Delphi on a Linux system, you would have to run it inside of a Windows-based virtual machine running on Linux.
However, Delphi 10.2 Tokyo and later include a compiler that can create executables that run natively on Linux.

Unfortantley you cannot run Delphi in Linux. But there is an amazing alternative. It is called Lazarus! It will run on Linux, Mac or Windows. Get it at https://www.lazarus-ide.org/
I am actually surprised Lazarus isn't one of the most popular desktop development tools. If you find it useful and you are capable you should also contibute to the project. It has come a long ways in the past 10 years and with it I don't think you will need to even consider running Delphi on Linux. Lazarus with FreePascal is sufficient!

Also maXbox runs on Linux with a lot of scripts and also python for delphi.
we need Wine to run the scripting engine on debian linux.
maXbox is a script tool engine, compiler and source lib all in one exe to design and code your scripts in a shellbook! Pure Code for Object Scripting. Principle is simplicity and reduce to the max.
The App is “out of the box” (self containment) and needs no installation nor registration.
Release Notes maXbox 4.7.5.90 October 2021 mX47
Add 14 Units + 2 Tutorials
https://sourceforge.net/projects/maxbox/

Related

Can I compile and run a linux app C++ source on Windows?

I have source code for a linux application. It seems I can compile it on windows with CygWin. My question is, after compilation, can I run it on Windows?
Depends totally on what APIs you use. If you stick to C standard library things, like <stdio.h>, <stdlib.h>, etc. then yes, you can just compile and run on either OS. Or for C++ apps, there is the Standard C++ Library, which any OS / development environment should provide.
If you use any OS-specific APIs, then of course it will not be compatible with another OS. There are libraries however, like APR that try to abstract out the OS-specific bits.
From a casual glance at the code you've linked to, it appears to not use any OS-specific APIs. However:
Note that this code requires the Gnu Scientific Library, http://www.gnu.org/software/gsl/
you'll need to get that library installed as well.
The simple answer is yes; if you can compile a Linux application with Cygwin, then the compiled application will run on windows. Cygwin provides windows implementations of many unix system functions and libraries.
Cygwin/mingw(http://www.mingw.org/) should have most of the tools you need to build the binary. Once the build succeeds, you can run the binary (only) on windows.

How portable is JavaFX 2?

I am thinking of kicking off a JavaFX project on my 64-bit Windows 7 machine. What I am doing is designing a full-screen console application. It's not interactive aside from a barcode scanner.
I'm designing this for what I think would be an Ubuntu laptop or some other Linux variation, although a different Windows OS is a possibility too (as well as 32 bit). From what I understand Java FX version 2.x has made great advancements in portability from its predecessor, but I wanted to ask the community here what their experience was in deploying JavaFX apps.
Have you had success using them on a variety of different architectures? What are some problems you have encountered?
Checkout EstiMate for an example of an all-in-one jar which is runnable via double click.
https://bitbucket.org/atill/estimate/downloads
It requires Java7u10 installed. I plan to make a proper installer for it later on, using the javafx maven plugin. https://github.com/zonski/javafx-maven-plugin. I haven't tested it on Linux or Mac but it does work across winXP 32bit and 64bit windows7.
As long as your barcode scanner works the same on ubuntu as on win and you are not using any external libraries, you won't notice the difference between those systems from your app.
I found installing oracle JRE on ubuntu the most difficult task. (with JRE_HOME, etc.) Even on Archlinux was easier than ubuntu.
Nevertheless, once the JRE is set, your app will run even on Raspberry Pi (which is ARM not x86)
Remember about file system differences between systems.

Which Linux distribution for VMWare Workstation Guest?

I've been fighting a whole day with UNIX utilities - so sorry if I appear confused! I'm describing my painful and (so far) fruitless process a little because maybe someone may correct me, or maybe describing the process might be helpful to someone later on. If you want to skip this, the question is bolded below.
So I'm trying to convert a Linux program developed using kdevelop. I'm trying to make it run on Windows 7. (This is the SHoUT Speech Took mentioned here, developed by Marijn Huijbregts).
I've wasted half a day trying to install kdevelop on Windows, only to understand that kdevelop can't run on Windows and that I've been installing KDE all that time :( (If kdevelop CAN run on Windows, information would be highly appreciated).
OK, so following the advice in SO's Best environment to port C/C++ code from Linux to Windows, I installed MinGW32 only to find out that SHoUT's makefile contains targets such as aclocal, autoheader etc. - I've come face to face with the hitherto unknown GNU Build System.
I'm now in the middle of installing GnuWin32 using GetGnuWin32. This is taking hours. And I suspect that once it finishes, I'll stumble on something else.
A day of pain - and still not one code line compiled :((.
So, I'm thinking about an alternative approach: Install Linux and run kdevelop as a cross-compiler to compile to Windows. As this is a console application, MAYBE it'll be easier.
So, finally, my question:
If I want to install Linux guest in VMWare Workstation (8, running on Windows 7 host), I understand I need a "distribution". I understand there's a ton of distributions, some free, some paid.
Which distribution should I choose which would run kdevelop and be as simple as possible? I just want to ##$$ing compile, and I can't stand one more day like this...
Avi
Edit:
I've tried compiling the code using VS - very tedious. Many differences between Linuix/GCC and windows/MSVC. Moreover, this is code deveoped by someone else, and I'm not even sure that the program sovles the business needs. So I've decided on the following process:
Configure Linux and run the software on Linux.
Validate that program solves business rule. If not - Abort.
Try cross oompiling on Linux. If running on Windows, verify by comparing outputs to those obtained on Linux. If good - Done.
Try compiling on Windows using ported Windows versions of the GNU Build tools. Use understanding and values obtained from building on the Linux target. If good - Done. Else
Abend and try another solution to the business problem, or try the MS tools (again using understanding and values obtained from building on the Linux target).
Many distributions are possible. Mandriva is KDE based.
But you can also install a Debian distribution, and install KDE in it.
I suggest to contact the ShOUT project community.
You should not cross-compile. MinGW can come handy but it is not required. What you need is to port the code and its dependencies to Windows, and there is nothing wrong if you use Visual Studio, for example.
I am using Ubuntu on VirtualBox OSE and through it use kdevelop and it runs seamlessly. Alternatively you can try kubuntu.
Why VirtualBox OSE - Free, Mature
It is easier to compile with MinGW on Windows than cross compile on Linux.
Build system... It could be quite easy to write Your own. Much easier than actual porting of C++ code. Could be even easier than using GNU Build System.
Please DON'T install Linux! It will take you another half a day and another questions asked here if you're doing it for the first time.
Just install VirtualBox and grab some VirtualBox image from some site. Kubuntu should be working fine with your KDE stuff: http://virtualboxes.org/images/kubuntu/
It will get you a running KDE Linux in just 5 minutes.

How can I compile my Windows program into a single Linux binary that runs with Wine?

Just today i checked my ubuntu with installing wine in it ,
Delphi 3 to 7 worked perfectly (Rad studios did not work because they use .net scraps).
But all of the application i made worked perfectly!!!!!
And i heard that it also works well in mac with WineBottler
Is it possible to create a header linux executable and put my vcl application and requird wine stuff into it and distribute as a single executable (.bin)
there is(was) a solution for Linux from Borland, called Kylix. Kylix is based on some older Qt-stuff.
But I would give FreePascal/Lazarus a try, it's pretty cool! and the compiler compiles for many different platforms.
I guess this is what winelib is for. However I have never tried it. (Wasn't Kylix Delphi + winelib compiled for Linux?)
Since Wine is now stable (reached the 1.0 version some time ago), it could make sense to ask the user to install it using its Linux packages manager. It's very fast and easy. So Wine will be always up to date, according to the distribution used.
Then it's very easy to install any Windows program with Wine.
Since Delphi executables are mostly self-contained (if you don't use the BDE or some external database libraries), your clients will install your Delphi application alla "Windows" way, that is, by running a Setup program from Wine.
And it will work fine, as is.
Using WineLib is not a good idea, even not advised by Wine developers, as far as I remember. At least for closed-source software: in one or two years, perhaps you won't release another version of your program, but Wine and WineLib will have evolved a lot... If you use Wine as an external package, your client can be sure there will be some end user enhancements.
If your software is purely Open Source, then using WineLib could make sense. But even the WineLib headers can evolved, so perhaps your source won't evolve at the same speed...

NSIS support for Linux and Solaris

Does NSIS support Linux and Solaris? I read somewhere that we can compile nsis script on Linux but cant execute the .exe generated on any other platforms but Windows. Can somebody put more light in this?
No.
See the NSIS feature list for more information ...
Portable Compiler
The NSIS compiler can be compiled for POSIX platforms like
Linux and *BSD. Generated installer
will still run on Windows only, but
this way they can be generated without
Windows or WINE.
You can compile installers on POSIX and Windows systems, but it always produces a Win32 PE file that only runs on Windows (And maybe under WINE on *nix)
Check the NSIS manual for more info
The installer systems for Windows and Linux are completely different.
Whereas Windows' only contribution to a software management system is one registry entry pointing to the uninstaller, Linux has a full working software management system. There are apt, yum, pacman and many more out there, which are supporting many more features and possibilities including automatic execution of scripts and pulling in/installing dependencies. If you have a cross platform application you wanna share, you're either stuck with creating a tar-ball, or you learn how to build deb/rpm etc. packages.
Linux and Windows are not binary compatible, so you can't do that.
But, most of the windows binary installer could able to install at WINE

Resources