FPC 3.0 on Centos 6.5 lazarus / 1-Linux ---------------------------------------------------------------------- BPascal · 2016-10-28 09:39 Hi. I want to install fpc (not lazarus) on a Centos 6.5 but no package for fpc is availabe using yum. [root@mail ~]# yum install fpc Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile  * base: mirror.nl.leaseweb.net  * epel: mirror.nl.leaseweb.net  * extras: centos.mirror.triple-it.nl  * remi: nl.mirror.babylon.network  * remi-php55: nl.mirror.babylon.network  * remi-safe: nl.mirror.babylon.network  * updates: centos.mirror.transip.nl Setting up Install Process No package fpc available. Error: Nothing to do How to install fpc? Thanks! ---------------------------------------------------------------------- BPascal · 2016-10-28 09:55 (solution) Download version from https://sourceforge.net/projects/freepascal/files/Linux/3.0.0/ (I've downloaded fpc-3.0.0.x86_64-linux.tar) (Using FTP I've uploaded .tar file to my Centos 6.5 server) Go to terminal and follow steps ( based on http://www.freepascal.org/docs-html/user/usersu5.html ) - Go to fpc-3.0.0.x86_64-linux.tar directory # tar -xvf fpc-3.0.0.x86_64-linux.tar - (yes to all) # cd fpc-3.0.0.x86_64-linux/ # ./install.sh That's all ---------------------------------------------------------------------- Edson · 2016-11-27 02:38 I have done: Quotetar -xvf fpc-3.0.0.x86_64-linux.tar cd fpc-3.0.0.x86_64-linux/ ./install.sh But when executing "fp" in console, I get: Quote"fp: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by fp)" Can someone give me a solution, please? I have CentOS release 6.8 - x86_64. ---------------------------------------------------------------------- Leledumbo · 2016-11-27 06:50 Quote from: Edson on November 27, 2016, 03:38:57 amCan someone give me a solution, please? I have CentOS release 6.8 - x86_64. CentOS ships with a very old glibc version (2.12, dating over 6 years ago). Googling around it seems like a common problem in CentOS where new softwares are compiled with new glibc version. You may either install glibc 2.14 or newer, alongside 2.12 (you can't remove 2.12 as other parts of the OS depend on it) or if possible (not sure which kernel version your CentOS uses), build fpc from source. ---------------------------------------------------------------------- Edson · 2016-11-27 17:16 It looks like FPC 3.0 cannot be easily installed in CentOS 6  . I have read, the best solution is to migrate to CentOS 7, but  it's not so appropriate for me. But I have tested with FPC 2.6.4 and 2.6.0, and all of then ask for GLIBC 2.14. ---------------------------------------------------------------------- Leledumbo · 2016-11-27 18:42 Quote from: Edson on November 27, 2016, 06:16:39 pmIt looks like FPC 3.0 cannot be easily installed in CentOS 6  . I have read, the best solution is to migrate to CentOS 7, but  it's not so appropriate for me. But I have tested with FPC 2.6.4 and 2.6.0, and all of then ask for GLIBC 2.14.  Well, even glibc 2.14 itself is only 1 year younger than 2.12. If you stick to old system, you will be left behind sooner or later. ---------------------------------------------------------------------- Graeme · 2016-11-27 22:34 I've got both FPC 2.6.4 and FPC 3.0.0 installed and working 100% on CentOS 6 here. The setup was done a long time ago, so can't remember the details. But I can say that it does work, and there is no need to forcefully upgrade to CentOS 7. Code: [Select]$ lsb_release -a LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core- 4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0- amd64:printing-4.0-noarch Distributor ID: CentOS Description: CentOS release 6.6 (Final) Release: 6.6 Codename: Final  $ fpc -i Free Pascal Compiler version 2.6.4 Compiler Date      : 2014/03/03 Compiler CPU Target: x86_64 Supported targets:   Linux for x86-64   FreeBSD for x86-64   Win64 for x64   Darwin for x86_64   Solaris for x86-64 (under development)   OpenBSD for x86-64 (under development)   NetBSD for x86-64 (under development) ...snip...  $ ./fpc -i Free Pascal Compiler version 3.0.0 Compiler date      : 2016/04/29 Compiler CPU target: x86_64 Supported targets (targets marked with '{*}' are under development):   Linux: Linux for x86-64   FreeBSD: FreeBSD for x86-64   Win64: Win64 for x64   Darwin: Darwin for x86_64   solaris: Solaris for x86-64 {*}   OpenBSD: OpenBSD for x86-64 {*}   NetBSD: NetBSD for x86-64 {*}   DragonFly: DragonFly for x86-64 ...snip... How do I find out what glib version I have? ---------------------------------------------------------------------- Edson · 2016-11-28 01:04 Quote from: Graeme on November 27, 2016, 11:34:11 pmHow do I find out what glib version I have? I use:  Quoteldd --version And gives in my system: (GNU libc) 2.12 ---------------------------------------------------------------------- feds · 2016-11-28 02:30 Quote from: Edson on November 28, 2016, 02:04:30 amQuote from: Graeme on November 27, 2016, 11:34:11 pmHow do I find out what glib version I have? I use:  Quoteldd --version And gives in my system: (GNU libc) 2.12 On RH/CentOS Quoteyum list glibc might give a somewhat more detailed revision info. ---------------------------------------------------------------------- Graeme · 2016-11-28 09:40 Thanks for the info... This was the first time I ever used CentOS (I set it up in a VM for development for a specific client). I'm more of a FreeBSD guy. Here is the output. I got from 'ldd' and 'yum'. Code: [Select]$ ldd --version ldd (GNU libc) 2.12 Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions.  There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper. graemeg@wisadevel ~/devel/fpcpackages/fppdf/utils $ yum list glibc Loaded plugins: fastestmirror, refresh-packagekit, security Determining fastest mirrors  * base: mirror.vorboss.net  * centosplus: mirror.vorboss.net  * contrib: mirror.vorboss.net  * extras: mirror.vorboss.net  * fasttrack: mirror.vorboss.net  * updates: mirror.vorboss.net base                                                                                 | 3.7 kB     00:00    centosplus                                                                           | 3.4 kB     00:00    centosplus/primary_db                                                                | 2.0 MB     00:00    contrib                                                                              | 2.9 kB     00:00    extras                                                                               | 3.4 kB     00:00    fasttrack                                                                            | 3.3 kB     00:00    updates                                                                              | 3.4 kB     00:00    updates/primary_db                                                                   | 3.7 MB     00:00    Installed Packages glibc.x86_64                                    2.12-1.166.el6_7.7                                  @updates Available Packages glibc.i686                                      2.12-1.192.el6                                      base    glibc.x86_64                                    2.12-1.192.el6                                      base So it seems I have GLIBC 2.12 installed. I can also add that I normally compile my own newer FPC versions - because I often require multiple FPC compiler versions, and always install them in my $HOME directory in separate "fpc-x.y.z" directories.  Looking inside the ~/devel/fpc-3.0.0/ I can see my usual build script go.sh so I definitely compiled FPC 3.0.0 using the released FPC 2.6.4 (which I probably installed from the official Free Pascal console installer). This almost always reduces the install dependencies too (Linux package managers, 99% of the time have too many restrictive dependencies associated). ---------------------------------------------------------------------- Edson · 2016-11-28 18:35 I only need FPC 3.0.0. Is there some easy way to have it in CentOS 6.8? I'm new in CentOS too, so I have no idea how to do this. ---------------------------------------------------------------------- Graeme · 2016-11-29 09:40 Quote from: Edson on November 28, 2016, 07:35:21 pmI only need FPC 3.0.0. Is there some easy way to have it in CentOS 6.8? I'm new in CentOS too, so I have no idea how to do this. I never actually tried the text mode FP IDE on CentOS 6.7 - it actually gives the same "version `GLIBC_2.14' not found" error. But then, I never use the text mode IDE for anything. The rest of the FPC 3.0.0 compiler works perfectly though. I highly recommend you try MSEide instead of the text mode IDE - if you want a very fast and feature packed IDE, with much less memory usage and 3rd party library requirements than say Lazarus IDE. You don't have to develop MSEgui based application with MSEide (I don't), but I do use MSEide for everything else (console, web and fpGUI based applications). It works very well. ---------------------------------------------------------------------- Leledumbo · 2016-11-29 09:47 Quote from: Graeme on November 29, 2016, 10:40:00 amI never actually tried the text mode FP IDE on CentOS 6.7 - it actually gives the same "version `GLIBC_2.14' not found" error. AFAIK the text mode IDE is the only thing that links to a C library indirectly for terminal handling, hence everything but the IDE works regardless of glibc version (but still depends on minimal kernel version). ---------------------------------------------------------------------- Edson · 2016-12-01 21:52 Finally (I don't know how) I have the fpc working in CentOS 6.8  : Quote[usuario@CENTOS-64 ~]$ cat /etc/redhat-release CentOS release 6.8 (Final) [usuario@CENTOS-64 ~]$ fpc prueba.pas Free Pascal Compiler version 3.0.0 [2015/11/20] for x86_64 Copyright (c) 1993-2015 by Florian Klaempfl and others Target OS: Linux for x86-64 Compiling prueba.pas Linking prueba /usr/bin/ld: warning: link.res contains output sections; did you forget -T? 3 lines compiled, 0.0 sec [usuario@CENTOS-64 ~]$ ldd --version ldd (GNU libc) 2.12 Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions.  There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper. The IDE, still give error: Quotefp: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by fp) Anyway I don't need the IDE, by now. ---------------------------------------------------------------------- Leledumbo · 2016-12-02 04:15 Quote from: Edson on December 01, 2016, 10:52:24 pmFinally (I don't know how) I have the fpc working in CentOS 6.8  : It should have worked from the start, only the IDE doesn't. ---------------------------------------------------------------------- Edson · 2016-12-02 04:46 Quote from: Leledumbo on December 02, 2016, 05:15:07 amIt should have worked from the start, only the IDE doesn't. Yes, I think the same, but for some reason it doesn't. Maybe I'm too noob in CentOS.