Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-21 Thread Bo Berglund
On Sun, 17 Jan 2016 09:09:37 +0100, Bo Berglund
 wrote:

Thanks for your comments!
After looking through them and a lot of web resources I came to the
conclusion that it is not worth the time. I decided to go with a
Lazarus installation instead and ditch the platforms that would not
allow me to install Lazarus...


-- 
Bo Berglund
Developer in Sweden


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-21 Thread Michael Schnell

On 01/21/2016 09:51 AM, Bo Berglund wrote:

  ditch the platforms that would not
allow me to install Lazarus...


It should be possible to link a project against the LCL without 
completely installing Lazarus or  using Lazarus on that platform


This does not even require cross compiling.

The project is just source coed. You can develop it on an appropriate 
platform (best as similar to the final target as possible).


Then (provided you already do have a compiler and the RTL on the target 
system, plus the required Linux Widget Set stuff) you can copy the 
source codes of your project and the LCL sources  onto the target system 
and compile via command line.


So you will generate the fully featured GUI based program.

-Michael

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-21 Thread Mattias Gaertner
On Thu, 21 Jan 2016 10:14:33 +0100
Michael Schnell  wrote:

> On 01/21/2016 09:51 AM, Bo Berglund wrote:
> >   ditch the platforms that would not
> > allow me to install Lazarus...
> 
> It should be possible to link a project against the LCL without 
> completely installing Lazarus or  using Lazarus on that platform

If you want to build GUI programs the needed external libraries of the
IDE are the same as for any LCL application.
You don't need gdb, nor a working window manager to build a GUI
application though.

Mattias

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-21 Thread Michael Van Canneyt



On Thu, 21 Jan 2016, Mattias Gaertner wrote:


On Thu, 21 Jan 2016 10:14:33 +0100
Michael Schnell  wrote:


On 01/21/2016 09:51 AM, Bo Berglund wrote:

  ditch the platforms that would not
allow me to install Lazarus...


It should be possible to link a project against the LCL without
completely installing Lazarus or  using Lazarus on that platform


If you want to build GUI programs the needed external libraries of the
IDE are the same as for any LCL application.
You don't need gdb, nor a working window manager to build a GUI
application though.


Indeed. 
I daily build GUI programs on a headless build machine, using lazbuild and FPC.


Michael.

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-18 Thread Michael Schnell

On 01/17/2016 09:09 AM, Bo Berglund wrote:

If I install only fpc is it then possible to build a GUI program from
sources without also installing Lazarus (on Linux target)?


Of course: if you create  your of GUI.

Alternatively you can also use MSE instead of Lazarus (I suppose there 
are some more fpc aware GUI libraries out there).


-Michael

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-17 Thread Graeme Geldenhuys
On 2016-01-17 08:09, Bo Berglund wrote:
> If I install only fpc is it then possible to build a GUI program from
> sources without also installing Lazarus (on Linux target)?

Of course it is - as long as you have all the dependencies installed
too, and if you application is LCL based, you obviously need the LCL
sources too.

I have done that before on a Linux build server, and recently I have
used MSEide to manage and build LCL based applications (all without
lazbuild or a Lazarus IDE executable around).

The list of source paths (for building LCL) was large, but very doable.
MSEide made this a bit easier with its support for path macros and quick
setup of unit and include path setup. But if you are going to use purely
FPC from the command line, I would create a config (text) file that
holds all the compiler parameters - one parameter per line, then compile
your project as follows:

   fpc @extrafpc.cfg myproject.lpr


Another option would be to use FPC's fpmake.pp functionality. I don't
know if Lazarus includes such a file already. Otherwise take a look at
fpGUI's sources (/src/fpmake.pp) for a working example.


Regards,
  - Graeme -

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp

--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-17 Thread Anthony Walter
At a minimum for lcl graphics form applications you need the lcl and
lazbuild installed, as well as a valid set of config files, all of which
are included with Lazarus. If you want to build just using fpc, then you'll
need to gather at least those pieces together, and the easiest way to do
that is to install Lazarus.
--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus


[Lazarus] Can I build a Lazarus GUI program only with fpc installed?

2016-01-17 Thread Bo Berglund
If I install only fpc is it then possible to build a GUI program from
sources without also installing Lazarus (on Linux target)?

Say that I have a simple GUI program that is imported in Lazarus from
Delphi7 by using the import tool in Lazarus on a Linux platform.
It builds and runs OK on that platform.

Then I have a need to compile on another linux platform (different CPU
etc) but do not want to/am able to install Lazarus there but fpc is
available. Can I transfer the sources to that platform and then build
on the command line somehow?

I have tried to find info on this on the web but what I find is very
condensed and hard to understand

The steps I thought of would be something like this:

apt-get install fpc
apt-get install (long list of dependencies for lazarus)
transfer sources (5-10 files) to ~/projects/code
cd ~/projects/code
issue command to build program

But what would that command look like?
Or is lazarus necessary to build a fpc GUI program (as opposed to a
command line program)?

I have seen talk about the fpc.conf file used to set some options, but
there is a global such file in /etc and I do not see how one must
change that for each project to build...
Whatever needed as source info should be in the project dir or on the
command line, right?

Or can a makefile be generated in the system where the program is
created and used on the target system without Lazarus?
If so, how?


-- 
Bo Berglund
Developer in Sweden


--
___
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus