Re: [Lazarus] Lazarus project compile flags
On Fri, Jan 30, 2015 at 3:38 PM, Michael Van Canneyt wrote: > > > On Fri, 30 Jan 2015, Toan Pham wrote: > > >> Mattias, >> >> >> Autotool, cmake and pkgconfig are tools for configuring and building >> C/C++ projects. >> The tools are very helpful because they allow the developers/software >> builders to detect software dependencies, version requirements, >> and also configure software features at build-time. For example, >> let's say we want to build gtk-2, we would do the following steps: >> >> 1. Download the source code & unzip it >> 2. We want to configure it, without opengl support (just to illustrate >> this example) >> ./configure --disable-opengl >> >> 3. When we do this, auto-tool would call pkg-config (another utility), >> and see if it has libcairo version 2.1 and freefont library >> version 1.1 (for example). >> >> 4. If the dependencies are satisfied, pkg-config also tells auto-tool >> where to look for the libraries, by giving the CFLAGS and >> LFLAGS >> >> in a nutshell, that's how it works. At first, the process looks like >> there is alot of work to build a package; but in practice; >> its a standard way to build software, and it becomes very easier to >> manage when one has to build a linux distribution. >> >> Object pascal and Lazarus projects are a little bit different. I >> normally build those projects manually with lazarus. lazbuild is >> nice, but it encapsulates many features from developers. I understand >> you can use -k option to pass options to the linker etc... But >> let say, you have 200+ pascal programs and libraries, how are you build >> them effective? >> >> >> You may think lazbuild is the solution; but let's say if you are a linux >> distributor and you have to build 200+ projects and libraries >> for different architectures, lazbuild may not be enough. >> > > Why do you think so ? > > I have a fully automated build environment that uses lazbuild, guided by a > custom written program and a shell script. > It works transparantly on linux and windows. It results in an installer on > both platforms: inno setup on windows, self-extracting shell script on > linux, built from the same .iss file. > > This system compiles 40 interdependent packages/projects without human > intervention; lazbuild takes care of the dependencies, paths and compiler > options. > Moreover, different versions of packages are handled without problems. > > I see no reason why it could not handle 200+ projects. > > Using the --pcp option I can even use different lazarus setups for daily > builds and release builds. > > As far as I can see, Lazarus offers all you need. What do you think is > missing ? > > Michael. > -- > Are these ( program sources and shell script ) open to public ? If "Yes" , would you please supply link(s) to download ? Thank you very much . Mehmet Erol Sanliturk -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015 18:09:11 -0500 Toan Pham wrote: >[...] > 1. Download the source code & unzip it > 2. We want to configure it, without opengl support (just to illustrate > this example) > ./configure --disable-opengl > > 3. When we do this, auto-tool would call pkg-config (another utility), and > see if it has libcairo version 2.1 and freefont library version 1.1 (for > example). > > 4. If the dependencies are satisfied, pkg-config also tells auto-tool > where to look for the libraries, by giving the CFLAGS and LFLAGS About cflags: Not usable by fpc. About lflags: The -l parameters are auto created by the compiler. This usually leaves none or very few options. For example $(pkg-config --cflags --libs gtk+-2.0) provides no option needed by fpc. About needed libraries: Because of the above it usually works in FPC the other way round. You compile and if a library is missing you get an error message. You then install the missing library and try again. Nevertheless you are right, it would be nice if you could get the list of needed libraries without compiling. You can use a tool like auto-tool for that. Mattias -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015, Toan Pham wrote: Mattias, Autotool, cmake and pkgconfig are tools for configuring and building C/C++ projects. The tools are very helpful because they allow the developers/software builders to detect software dependencies, version requirements, and also configure software features at build-time. For example, let's say we want to build gtk-2, we would do the following steps: 1. Download the source code & unzip it 2. We want to configure it, without opengl support (just to illustrate this example) ./configure --disable-opengl 3. When we do this, auto-tool would call pkg-config (another utility), and see if it has libcairo version 2.1 and freefont library version 1.1 (for example). 4. If the dependencies are satisfied, pkg-config also tells auto-tool where to look for the libraries, by giving the CFLAGS and LFLAGS in a nutshell, that's how it works. At first, the process looks like there is alot of work to build a package; but in practice; its a standard way to build software, and it becomes very easier to manage when one has to build a linux distribution. Object pascal and Lazarus projects are a little bit different. I normally build those projects manually with lazarus. lazbuild is nice, but it encapsulates many features from developers. I understand you can use -k option to pass options to the linker etc... But let say, you have 200+ pascal programs and libraries, how are you build them effective? You may think lazbuild is the solution; but let's say if you are a linux distributor and you have to build 200+ projects and libraries for different architectures, lazbuild may not be enough. Why do you think so ? I have a fully automated build environment that uses lazbuild, guided by a custom written program and a shell script. It works transparantly on linux and windows. It results in an installer on both platforms: inno setup on windows, self-extracting shell script on linux, built from the same .iss file. This system compiles 40 interdependent packages/projects without human intervention; lazbuild takes care of the dependencies, paths and compiler options. Moreover, different versions of packages are handled without problems. I see no reason why it could not handle 200+ projects. Using the --pcp option I can even use different lazarus setups for daily builds and release builds. As far as I can see, Lazarus offers all you need. What do you think is missing ? Michael.-- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
Mattias, Autotool, cmake and pkgconfig are tools for configuring and building C/C++ projects. The tools are very helpful because they allow the developers/software builders to detect software dependencies, version requirements, and also configure software features at build-time. For example, let's say we want to build gtk-2, we would do the following steps: 1. Download the source code & unzip it 2. We want to configure it, without opengl support (just to illustrate this example) ./configure --disable-opengl 3. When we do this, auto-tool would call pkg-config (another utility), and see if it has libcairo version 2.1 and freefont library version 1.1 (for example). 4. If the dependencies are satisfied, pkg-config also tells auto-tool where to look for the libraries, by giving the CFLAGS and LFLAGS in a nutshell, that's how it works. At first, the process looks like there is alot of work to build a package; but in practice; its a standard way to build software, and it becomes very easier to manage when one has to build a linux distribution. Object pascal and Lazarus projects are a little bit different. I normally build those projects manually with lazarus. lazbuild is nice, but it encapsulates many features from developers. I understand you can use -k option to pass options to the linker etc... But let say, you have 200+ pascal programs and libraries, how are you build them effective? You may think lazbuild is the solution; but let's say if you are a linux distributor and you have to build 200+ projects and libraries for different architectures, lazbuild may not be enough. On Fri, Jan 30, 2015 at 5:22 PM, Mattias Gaertner wrote: > On Fri, 30 Jan 2015 16:42:55 -0500 > Toan Pham wrote: > > >[...] > > lazbuild does the work, but then i even want to get away from lazbuild > > dependency. > > I muck around with fpcmake but then, it too can't really create a proper > > makefile project. > > for some reasons, fpcmake failed to know where to locate the LCL gtk2 > > interface directory. > > The best way is probably to do it manually, like autoconfigure and > > pkg-config. > > I'm not sure what you mean with autoconfigure and > pkg-config do it "manually". > If you want the full features you need lazbuild. If you don't want to > use lazbuild then you have to explain what kind of project/packages > you want to build. > What exactly should be done automatically and what manually? > > > Mattias > > -- > ___ > Lazarus mailing list > Lazarus@lists.lazarus.freepascal.org > http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus > -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015 16:58:19 -0500 Toan Pham wrote: > Ideally, it would be nice to compile any fpc project using the following > command: > > fpc `fpc-config --cflags --ldflags rtl,lcl,lcl-gtk2,paszlib` project1.lpr > > fpc-config is a utility that manages configuration of all packages, and > knows where and what to pass along to the fpc compiler. What do you mean with cflags? ldflags can be passed directly to fpc with -k. rtl and paszlib are part of standard FPC. lcl and lcl-gtk2 need to be built prior to the project with separate compiler calls (e.g. using make). Many projects need more than calling the compiler to build. Your system has everything to build gtk2 applications. And you have the lcl, so you have the Lazarus sources. And you have built them, so you have lazbuild. And you want to build a Lazarus project using Lazarus packages. Why can't you use lazbuild? Mattias -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015 16:42:55 -0500 Toan Pham wrote: >[...] > lazbuild does the work, but then i even want to get away from lazbuild > dependency. > I muck around with fpcmake but then, it too can't really create a proper > makefile project. > for some reasons, fpcmake failed to know where to locate the LCL gtk2 > interface directory. > The best way is probably to do it manually, like autoconfigure and > pkg-config. I'm not sure what you mean with autoconfigure and pkg-config do it "manually". If you want the full features you need lazbuild. If you don't want to use lazbuild then you have to explain what kind of project/packages you want to build. What exactly should be done automatically and what manually? Mattias -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015, Toan Pham wrote: Ideally, it would be nice to compile any fpc project using the following command: fpc `fpc-config --cflags --ldflags rtl,lcl,lcl-gtk2,paszlib` project1.lpr fpc-config is a utility that manages configuration of all packages, and knows where and what to pass along to the fpc compiler. That is what lazbuild does ? Michael. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
Ideally, it would be nice to compile any fpc project using the following command: fpc `fpc-config --cflags --ldflags rtl,lcl,lcl-gtk2,paszlib` project1.lpr fpc-config is a utility that manages configuration of all packages, and knows where and what to pass along to the fpc compiler. On Fri, Jan 30, 2015 at 4:42 PM, Toan Pham wrote: > > Mattias, > > lazbuild does the work, but then i even want to get away from lazbuild > dependency. > I muck around with fpcmake but then, it too can't really create a proper > makefile project. > for some reasons, fpcmake failed to know where to locate the LCL gtk2 > interface directory. > The best way is probably to do it manually, like autoconfigure and > pkg-config. > Please share if you know of other ways. > > > thank you > > > > > > > On Fri, Jan 30, 2015 at 4:17 PM, Mattias Gaertner < > nc-gaert...@netcologne.de> wrote: > >> On Fri, 30 Jan 2015 12:56:12 -0500 >> Toan Pham wrote: >> >> > Hi, >> > >> > >> > When we compile an object-pascal/delphi project, we generally rely on >> > Lazarus to do the work. >> > Yet, normally Lazarus knows how a project is setup and knows link the >> > project with its run-time library. This is good, but not so good if you >> > want to compile the application without lazarus. >> > >> > >> > So, as an example, a object pascal project may have the following >> FPC_FLAGS: >> > >> > -MObjFPC -Scghi -O1 -g -gl -vewnhi -Filib/i386-linux -Fl/opt/gnome/lib >> > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux/gtk2 >> > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux >> > -Fu/usr/lib/lazarus/1.2.4/components/lazutils/lib/i386-linux >> > -Fu/usr/lib/lazarus/1.2.4/packager/units/i386-linux -Fu. >> -FUlib/i386-linux >> > -l -dLCL -dLCLgtk2 >> > >> > These directives are the equivalent of C++/C, compile and link flags. >> > Typically we call pkg-config to find out the flags when we compile a >> c/C++ >> > application. Is there a lazarus/fpc utility that is equivalent to >> > pkg-config that would allow me to find out these flags at >> compile/configure >> > time? >> > >> > I really want to be able to build a project without lazarus, and on >> > different machine machines. >> >> You can use lazbuild to build without the IDE. You can build lazbuild >> on machines without GUI libraries: >> make lazbuild >> >> >> Mattias >> >> -- >> ___ >> Lazarus mailing list >> Lazarus@lists.lazarus.freepascal.org >> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus >> > > -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
Mattias, lazbuild does the work, but then i even want to get away from lazbuild dependency. I muck around with fpcmake but then, it too can't really create a proper makefile project. for some reasons, fpcmake failed to know where to locate the LCL gtk2 interface directory. The best way is probably to do it manually, like autoconfigure and pkg-config. Please share if you know of other ways. thank you On Fri, Jan 30, 2015 at 4:17 PM, Mattias Gaertner wrote: > On Fri, 30 Jan 2015 12:56:12 -0500 > Toan Pham wrote: > > > Hi, > > > > > > When we compile an object-pascal/delphi project, we generally rely on > > Lazarus to do the work. > > Yet, normally Lazarus knows how a project is setup and knows link the > > project with its run-time library. This is good, but not so good if you > > want to compile the application without lazarus. > > > > > > So, as an example, a object pascal project may have the following > FPC_FLAGS: > > > > -MObjFPC -Scghi -O1 -g -gl -vewnhi -Filib/i386-linux -Fl/opt/gnome/lib > > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux/gtk2 > > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux > > -Fu/usr/lib/lazarus/1.2.4/components/lazutils/lib/i386-linux > > -Fu/usr/lib/lazarus/1.2.4/packager/units/i386-linux -Fu. > -FUlib/i386-linux > > -l -dLCL -dLCLgtk2 > > > > These directives are the equivalent of C++/C, compile and link flags. > > Typically we call pkg-config to find out the flags when we compile a > c/C++ > > application. Is there a lazarus/fpc utility that is equivalent to > > pkg-config that would allow me to find out these flags at > compile/configure > > time? > > > > I really want to be able to build a project without lazarus, and on > > different machine machines. > > You can use lazbuild to build without the IDE. You can build lazbuild > on machines without GUI libraries: > make lazbuild > > > Mattias > > -- > ___ > Lazarus mailing list > Lazarus@lists.lazarus.freepascal.org > http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus > -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Lazarus project compile flags
On Fri, 30 Jan 2015 12:56:12 -0500 Toan Pham wrote: > Hi, > > > When we compile an object-pascal/delphi project, we generally rely on > Lazarus to do the work. > Yet, normally Lazarus knows how a project is setup and knows link the > project with its run-time library. This is good, but not so good if you > want to compile the application without lazarus. > > > So, as an example, a object pascal project may have the following FPC_FLAGS: > > -MObjFPC -Scghi -O1 -g -gl -vewnhi -Filib/i386-linux -Fl/opt/gnome/lib > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux/gtk2 > -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux > -Fu/usr/lib/lazarus/1.2.4/components/lazutils/lib/i386-linux > -Fu/usr/lib/lazarus/1.2.4/packager/units/i386-linux -Fu. -FUlib/i386-linux > -l -dLCL -dLCLgtk2 > > These directives are the equivalent of C++/C, compile and link flags. > Typically we call pkg-config to find out the flags when we compile a c/C++ > application. Is there a lazarus/fpc utility that is equivalent to > pkg-config that would allow me to find out these flags at compile/configure > time? > > I really want to be able to build a project without lazarus, and on > different machine machines. You can use lazbuild to build without the IDE. You can build lazbuild on machines without GUI libraries: make lazbuild Mattias -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Lazarus project compile flags
Hi, When we compile an object-pascal/delphi project, we generally rely on Lazarus to do the work. Yet, normally Lazarus knows how a project is setup and knows link the project with its run-time library. This is good, but not so good if you want to compile the application without lazarus. So, as an example, a object pascal project may have the following FPC_FLAGS: -MObjFPC -Scghi -O1 -g -gl -vewnhi -Filib/i386-linux -Fl/opt/gnome/lib -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux/gtk2 -Fu/usr/lib/lazarus/1.2.4/lcl/units/i386-linux -Fu/usr/lib/lazarus/1.2.4/components/lazutils/lib/i386-linux -Fu/usr/lib/lazarus/1.2.4/packager/units/i386-linux -Fu. -FUlib/i386-linux -l -dLCL -dLCLgtk2 These directives are the equivalent of C++/C, compile and link flags. Typically we call pkg-config to find out the flags when we compile a c/C++ application. Is there a lazarus/fpc utility that is equivalent to pkg-config that would allow me to find out these flags at compile/configure time? I really want to be able to build a project without lazarus, and on different machine machines. Thank you, Toan -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] HEADS UP: FPC 3.0.1 stable branched off.
Mark Morgan Lloyd wrote: Mark Morgan Lloyd wrote: Lazarus trunk at about 47318 is OK with FPC 2.7.1 29398 on SPARC using Debian "Lenny", except that toolbar icons don't appear (bug 25470, so this is not in fact fixed or has reverted). This combination compiles natively (i.e. not as a cross-compiler) on ARM running on Qemu. Lazarus built with either "all" or "bigide" appears to run, the OS in this case was Debian "Squeeze" and toolbar icons appeared OK. On mipsel running on Qemu compiling Lazarus fails with .. (9009) Assembling codecache (3104) Compiling customcodetool.pas (3104) Compiling codetree.pas /usr/local/share/lazarus-trunk-47318/components/codetools/codetree.pas(824,1) Fatal: Internal error 2013022101 Fatal: (1018) Compilation aborted make[1]: *** [codetools.ppu] Error 1 make[1]: Leaving directory `/usr/local/share/lazarus-trunk-47318/components/codetools' make: *** [codetools] Error 2 If anybody wants more detail on this error please say, I find Qemu useful for some of the more obscure architectures but it's painfully slow. On mips running on Qemu compiling Lazarus fails with make -C packager/registration make[1]: Entering directory `/usr/local/share/lazarus-trunk-47318/packager/registration' Makefile:196: *** The Makefile doesn't support target mips-linux, please run fpcmake first. Stop. make[1]: Leaving directory `/usr/local/share/lazarus-trunk-47318/packager/registration' make: *** [registration] Error 2 Attempting to run fpcmake (with minimal investigation of the "right" way of doing things) fails with 0 1>markMLl@pye-dev-07d:/usr/local/share/lazarus-trunk-47318$ fpcmake Processing Makefile.fpc Error: Target "linux", package "rtl" not found - The combination above compiles Lazarus in both 32- and 64-bit mode on an AMC Athlon running Linux (Debian "Wheezy"), but Lazarus doesn't run. I've not investigated further. -- Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues] -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Is it posibble change cursor in source editor
Thank you, This problem in just 64 bit QT on osx on corbon is okey short way is change background color, or change color set. https://code.google.com/p/delphi-ide-theme-editor/ 2300 color themes for lazarus :) On 29.01.2015 16:59, Martin Frb wrote: Not that I know. The caret is drawn by the OS. At least on windows. Apparently GTK does not have it, and the code in the Lcl/widgetset emulates it (but has no property for color). On Mac, I do not know what happens. SynEdit can influence the shape of the caret. But the IDE has no setting to influence this, you would have to add your own change in the IDE code. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus