Unable to compile on Ubuntu 14.04 lazarus / 1-Linux ---------------------------------------------------------------------- Paolo_R · 2015-10-26 03:12 I've just installed FPC 2.6.2-8 on Ubuntu. I can't get testapp.pas (a FV example program) to compile. First of all, in the Options -> Directories dialog I've no idea what to put in the various options i.e. Unit directories, Include files, Libraries, Object files and Miscellaneous, as I don't know where the install program has put the various files. Second, if I try to compile testapp.pas I get an error 'Can't open include file "platform.inc"'. I don't know where this is so I commented out the line. Third, after commenting out the {$I platform.inc} line I then get the error 'Can't find unit Drivers for testapp'. SoI've fallen at the frst hurdle. Can any one enlighten me please? Paul ---------------------------------------------------------------------- Ñuño_Martínez · 2015-10-26 17:53 Quote from: Paolo_R on October 26, 2015, 04:12:48 amI've just installed FPC 2.6.2-8 on Ubuntu. I can't get testapp.pas (a FV example program) to compile. First of all, in the Options -> Directories dialog I've no idea what to put in the various options i.e. Unit directories, Include files, Libraries, Object files and Miscellaneous, as I don't know where the install program has put the various files.In most (actually almost all) cases you don't need to change that. Quote from: Paolo_R on October 26, 2015, 04:12:48 amSecond, if I try to compile testapp.pas I get an error 'Can't open include file "platform.inc"'. I don't know where this is so I commented out the line. Third, after commenting out the {$I platform.inc} line I then get the error 'Can't find unit Drivers for testapp'. Seems like you didn't installed everything you need, or that you didn't installed it correctly. I recommend you to reinstall it.  Look at the wiki to be sure you're doing it correctly. ---------------------------------------------------------------------- Paolo_R · 2015-10-26 22:50 QuoteSeems like you didn't installed everything you need, or that you didn't installed it correctly. If I use the non-IDE compiler (fpc) the program compiles so I assume everything was installed correctly. ---------------------------------------------------------------------- Ñuño_Martínez · 2015-10-29 12:05 [edit] I've understood wrongly what you wrote, so next answer isn't what you're asking.  I've have another answer below: ______________________________________________________________________ ________________ Lazarus units (LCL) aren't in same path than the RTL+FCL libraries.  May be that's why it doesn't find the stuff needed. I have a project that uses a few LCL units and I had to add the LCL path to the compiler, this way: Code: [Select]# From a makefile scritp: ## Where the LCL is. #LCLDIR = /usr/lib/lazarus/default/lcl/ #CCLDIR = /usr/lib/lazarus/default/components/lazutils/ LCLDIR = /usr/lib64/lazarus/lcl/ CCLDIR = /usr/lib64/lazarus/components/lazutils/ ##  Compiler options to add to the compilation command: LCLUNITS = -Fu$(LCLDIR) -Fu$(LCLDIR)* -Fi$(LCLDIR)include -Fu$(CCLDIR) ## So, to compile: fpc $(FLAGS) -Fu$(SRCDIR) -Fu$(SRCDIR)* $(LCLUNITS) -FU$(OBJDIR) $(SRCDIR)program.pas -o$(BINDIR)program As you see, there are different paths depending on your system and version.  For example, I had to change it in the last update. ______________________________________________________________________ _________ [edit] Here you have a better answer: If FPC is able to compile it correctly, then Lazarus IDE should be able to compile it as well. May be you're using a configuration for FPC that is different than the configuration you use for Lazarus.  Take a look to the command-line options you used to compile with FPC, and also look in the FPC configuration file (fpc.cfg, IIRC) and read documentation about options.  Then revise your project's configuration in Lazarus. Also check if you're using the same compiler in any case (i.e. you have installed FPC "by hand" then installed Lazarus). ---------------------------------------------------------------------- Paolo_R · 2015-10-29 22:26 I am not using Lazarus. When I talked about the IDE I meant the text- based UI of Free Pascal, the one that looks like Turbo Pascal. So I'm using the same compiler for both IDE and non-IDE. ---------------------------------------------------------------------- Ñuño_Martínez · 2015-10-31 11:50 You should say that from the beggining... Anyway, what was said for Lazarus works also for fpide.  You should remove the fpide configuration file (now I don't remember the name, but should be "fpide.cfg" or something) if you have problems. ---------------------------------------------------------------------- Paolo_R · 2015-11-01 01:02 Actually I never said anywhere that I was using Lazarus - you assumed that. Anyway fp.cfg is in my home directory. Removing it made no difference. A new fp.cfg was created the next time I opened the Free Pascal IDE and it contained the same contents as the previous fp.cfg ---------------------------------------------------------------------- molly · 2015-11-01 01:43 @Paolo_R: First realize that there are 3 _different_ configurations possible. You can switch configurations using menu->options->mode to switch between normal, debug and release mode. When switching modes, also all the configuration options made (and saved) belong to that mode you selected using that menu. So, please don't be surprised to see empty directories again when switching modes  Ok, as for the directories (i had to dig out an old fp-ide windows installation), my unit directory option reads: D:\WinDev\FPC271\units\i386-win32\* Although above is a Windows oriented path, i do hope it will help you recognize where exactly to look for the units installed by FPC. You could apply something similar for include paths. Since you're on linux you probably would also need something like the library directory point to your linux development environment libraries (where that is depends on your linux distro and where you installed your development libraries). Things can get complicated fast when wanting to cross-compile, but i didn't saw you mentioning that ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 01:47 hello, i have tried to compile testapp.pas from fv examples on Ubuntu 14.04   fpc 2.6.4 . Success adding this line in the fpide menu  Options/Directories/ tab Include Files : Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i /usr/share/fpcsrc/$fpcversion/packages/fv/src Friendly J.P ---------------------------------------------------------------------- molly · 2015-11-01 02:17 @Jurassic Pork i stumbled upon a 2.6.4 windows installation, and the file platform.inc was nowhere to be found. At least not in the binary distribution. I guess a small oversight ? or is it expected for end-users to also install the sources ? ---------------------------------------------------------------------- molly · 2015-11-01 02:32 Ha, i'm able to answer my own questions  FPC 3.0 RC1 includes platform.inc inside fv example directory ---------------------------------------------------------------------- Paolo_R · 2015-11-01 04:11 Quote from: Jurassic Pork on November 01, 2015, 02:47:05 amhello, i have tried to compile testapp.pas from fv examples on Ubuntu 14.04   fpc 2.6.4 . Success adding this line in the fpide menu  Options/Directories/ tab Include Files : Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i /usr/share/fpcsrc/$fpcversion/packages/fv/src Friendly J.P JP: thanks. I added that line to the Include Files directory substituting 2.6.2 and tried again to compile testapp.pas from the examples directory but I'm still getting Compile failed[/b with Total errors of 2. No indication what the errors are. I have mode as Normal and targetprocessor as 808386. One point: when I put entries into the Directories options and then Save what file are these changes written to? The fp.ini in my Home directory doesn't show any difference. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 10:16 the option is in the fp.cfg file : Quote -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\*  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\rtl  -Fi/usr/share/fpcsrc/$fpcversion/packages/fv/src  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8/32  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8  -XS Processor target ATHLON64 ( UBUNTU 64 bits ) i launch fp in the /usr/share/fpcsrc/2.6.4/ide folder in an admin terminal. Version of fp : 2.6.4 ---------------------------------------------------------------------- molly · 2015-11-01 15:16 Quote from: Paolo_R on November 01, 2015, 05:11:25 amJP: thanks. I added that line to the Include Files directory substituting 2.6.2 and tried again to compile testapp.pas from the examples directory but I'm still getting Compile failed[/b with Total errors of 2. No indication what the errors are. That's strange. The compiler message windows (F12) that should appear during compilation should at least give you an indication of what is wrong exactly. FWIW: If you select menu->options->compiler... and select the verbose tab, you can 'tick' several options. If you 'checkmark' the All option then when you compile a file/project Free Pascal will show you all the files it is trying to locate, show all warnings, hints etc. -> that is the best way to locate Free Pascal and/or toolchain related errors. It adds a fair amount of time to compilation, and produces a lot of output, but it is very helpful in case you are trying to solve a compilation related issue (besides the obvious errors located in source-code). QuoteI have mode as Normal and targetprocessor as 808386. Just for the record: it does not matter much for/under which mode you compile, you just have to make sure you configure all modes with similar using paths. Details of the chosen options can differ to reflect the chosen mode. E.g. in debug mode it is common to add debug information and/or put range checking on. Or as another example use paths to units compiled with debug information included. QuoteOne point: when I put entries into the Directories options and then Save what file are these changes written to? The fp.ini in my Home directory doesn't show any difference. As explained by JP. Your comple related settings are located inside fp.cfg. The fp.ini file just 'contains' all the desktop information like windows positions, last opened files etc. And also to just make sure: The missing include file that you experience is/was an oversight. e.g. it is a bug that is already solved in FPC 3.x. Normally (as end-user) you should usually have no need to set an include path to FPC sources. So as an alternative to JP's solution (adding the include path) you can also 'follow' the solution presented by FPC 3.x and download the platform.inc file inside and place it in the directory of the example that you are trying to compile. The platform.inc file can be downloaded here. ---------------------------------------------------------------------- Paolo_R · 2015-11-01 22:39 Quote from: Jurassic Pork on November 01, 2015, 11:16:59 amthe option is in the fp.cfg file :  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\*  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\rtl  -Fi/usr/share/fpcsrc/$fpcversion/packages/fv/src  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8/32  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8  -XS Are there different versions of fp.cfg? I have a version in my home directory. Under #IFDEF NORMAL of those options you show only Quote -Fi/usr/share/fpcsrc/$fpcversion/packages/fv/src is shown Quotei launch fp in the /usr/share/fpcsrc/2.6.4/ide folder in an admin terminal. Version of fp : 2.6.4 I have v 2.6.2 - version 2.6.4 doesn't appear to be available via Synaptic Package Manager. ---------------------------------------------------------------------- Paolo_R · 2015-11-01 22:47 Quote from: molly on November 01, 2015, 04:16:55 pm That's strange. The compiler message windows (F12) that should appear during compilation should at least give you an indication of what is wrong exactly. FWIW: If you select menu->options->compiler... and select the verbose tab, you can 'tick' several options. If you 'checkmark' the All option then when you compile a file/project Free Pascal will show you all the files it is trying to locate, show all warnings, hints etc. -> that is the best way to locate Free Pascal and/or toolchain related errors. I only get a small dialog box with messages "Failed to compile... Line number 0...Total errors 2" Do you think it's worthwhile uninstalling and reinstalling again? ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 22:56 hello, Paolo_R what is your version of Ubuntu ? oops    Ubuntu 14.04 ,  it's my version of Ubuntu and i have version 2.6.4 in synaptic. Maybe you must update your fp packages. package fpc and fpc-src : ---------------------------------------------------------------------- Paolo_R · 2015-11-01 23:14 I made a mistake in my last post re location of fp.cfg. I do have a copy in my home directory but there is also a copy in my working pascal directory (which contains the testapp.pas). This fp.cfg in the working pascal directory contains: -Fl/usr/lib/fpc/2.6.2/units/i386-linux/ -Fl/usr/lib/fpc/2.6.2/units/i386-linux/rtl -Fl/usr/lib/fpc/2.6.2/ Should I delete the fp.cfg in my home directory? ---------------------------------------------------------------------- molly · 2015-11-01 23:21 Quote from: Paolo_R on November 01, 2015, 11:47:16 pmI only get a small dialog box with messages "Failed to compile... Line number 0...Total errors 2" Of course (because i don't have same OS installed as you) i can't speak for how things should work, but under windows it is possible to use the mouse and double-click the top border in order to size the window to larger proportions. Also when compilation finished you can use the up-down keys to scroll inside the message Window. You can 'cycle' through windows using F6 and shift-F6 keys instead of using the mouse, and use F5 for 'zooming' the window. If you'd checkmarked the all options as explained then you should see on one of the first lines at the top of the message window which exact fp.cfg file was being used (location on your disk). QuoteDo you think it's worthwhile uninstalling and reinstalling again? If everything else fails then yes. Right now i believe you have to get yourself a little more familiar with FP-IDE and compilation with Free Pascal as a whole. It might perhaps be a steep learning curve, but if you hang in there during the 'dark' period you'll be up and running in no time and laugh about these encountered issues (alas always in hindsight of course :-) ) Sorry to butt into your quotes to JP QuoteAre there different versions of fp.cfg? That's always possible (and might work confusing). As explained the Show all errors option will tell you exactly which fp.cfg is being used (at top of compiler message window, scroll waaaay up o see if you got all errors option set). QuoteI have a version in my home directory. Under #IFDEF NORMAL of those options you show only i believe something might have gone lost during conversation. The suggestion made by JP entails that you fill in the paths in FP-IDE (or alternatively, copy paste them into fp.cfg, then fire up FP-IDE again to see what changed inside the compiler options inside FP-IDE). the entries JP showed that starts with: 1) -Fu should be located inside FP-IDE directory options, tab UNITS 2) -Fi should be located inside FP-IDE directory options, tab INCLUDE FILES 3) -Fl should be located inside FP-IDE directory options, tab LIBRARIES If you do it inside fp.cfg then you can copy paste, in case you do it from within FP-IDE then you need to remove the -Fx parts and only fill in the paths. Each entry goes on a separate line. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 23:28 configuration file is in the home directory : Quotejurassic@jurassic-VN433:~$ fp * Free Pascal IDE Version 1.0.12 [2014/04/20] * Compiler Version 2.6.4 * Using configuration files from: /home/jurassic/ Running "/home/jurassic/free pascal/projects/test fv/testapp " ---------------------------------------------------------------------- molly · 2015-11-01 23:33 @Jurrasic Pork: Quote-Fl/usr/lib/fpc/2.6.2/units/i386-linux/ -Fl/usr/lib/fpc/2.6.2/units/i386-linux/rtl -Fl/usr/lib/fpc/2.6.2/ Shouldn't that read -Fu ? Or does linux installation do this differently ? ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 23:45 this is what i have in my fpc.cfg file for release mode : Quote#IFDEF RELEASE  -TLinux  -Mfpc  -Sg  -CpATHLON64  -OpATHLON64  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\*  -Fu/usr/lib/fpc/$fpcversion\units\$fpctarget\rtl  -Fi/usr/share/fpcsrc/$fpcversion/packages/fv/src  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8/32  -Fl/usr/lib/gcc/x86_64-linux-gnu/4.8  -XS  -Xs  -g-  -p-  -b-  -O2 #ENDIFand the config files are where you launch fp ( default home directory from a terminal window) ---------------------------------------------------------------------- Paolo_R · 2015-11-01 23:48 Quote from: Jurassic Pork on November 01, 2015, 11:56:12 pm Ubuntu 14.04 ,  it's my version of Ubuntu and i have version 2.6.4 in synaptic. Maybe you must update your fp packages. JP - I changed the server setting from Australia (where I am) to main server and updated all packages. Synaptic is still showing version 2.6.2. If I search for fpc 2.6.4 no result is returned. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-01 23:53 fpc 2.6.4 version ubuntu 14.04 package  is only for 64 bits architecture ---------------------------------------------------------------------- Paolo_R · 2015-11-01 23:57 Molly QuoteRight now i believe you have to get yourself a little more familiar with FP-IDE and compilation with Free Pascal as a whole. I've used Turbo Pascal/Turbo Vision for a long time on DOS. It's not Free Pascal IDE that I need to be familiar with - it's the Linux installation and getting FP to work in Linux ---------------------------------------------------------------------- Paolo_R · 2015-11-01 23:59 Quote from: Jurassic Pork on November 02, 2015, 12:53:06 amfpc 2.6.4 version ubuntu 14.04 package  is only for 64 bits architecture  JP - that explains why I can't see it. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-02 00:09 maybe you can try to install this version : http://sourceforge.net/pro jects/freepascal/files/Linux/2.6.4/fpc-2.6.4.i386-linux.tar/download fpc sources : http://sourceforge.net/projects/freepascal/files/Source/ 2.6.4/fpc-2.6.4.source.tar.gz/download ---------------------------------------------------------------------- molly · 2015-11-02 00:22 Quote from: Paolo_R on November 02, 2015, 12:57:50 amI've used Turbo Pascal/Turbo Vision for a long time on DOS. It's not Free Pascal IDE that I need to be familiar with - it's the Linux installation and getting FP to work in Linux Well, not to offend but Turbo IDE <> FP-IDE. In Turbo you did not have to set some of the options (weren't even available) that are needed for Free Pascal / FP-IDE. Unfortunately, i can't 'guess' where your package manager installs all the files. The package manager should be able to tell you that. In case everything fails (and you are familiar with that as well), try to install midnight commander (which has a pretty good resemblance with old Norton Commander for DOS). It helped me tremendously with my first Linux experience. Regarding the version of FPC... it doesn't really matter much. Of course there are improvements and new features in later versions, but since you're 'exploring' with Linux, i would just stick with things until you get more familiar with things. You can always opt (at any given time) for downloading a non-package manager version (like JP suggests)  or to compile FP-IDE from source in order to update to a newer version. Regarding your fp.cfg file inside project directory. I know this is a feature of fpc command-line compiler, but i seem unable to locate something similar for FP-IDE. Simply remove fp.cfg from the project directory and use the global one from user directory. @Jurrasic Pork: Thank you for the confirmation. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-02 00:39 success story for fpc  2.6.4 i386 on Ubuntu 14.04 1 - Download fpc sources from here :  http://sourceforge.net/projects/ freepascal/files/Source/2.6.4/fpc-2.6.4.source.tar.gz/download 2 - extract the files in your home directory 3 - open a terminal window and go in fpc 2.6.4 sources folder 4 - type make and cross the fingers. 5 - if it is ok copy plateform.inc from packages/fv/src to packages/fv/examples 6 - go in the ide folder and launch fp 7 - open testapp.pas , compile and run ---------------------------------------------------------------------- Paolo_R · 2015-11-02 04:06 Quote3 - open a terminal window and go in fpc 2.6.4 sources folder JP - I have created a directory (fpc-2.6.4) into which I extracted the tar file. That directory has the following sub-directories: compiler, ide, installer, packages, rtl, tests and utils plus a Makefile and a Makefile.fpc. If I issue 'sudo make' from this directory I get: Targets all Alias for build build Build a new compiler and all packages install Install newly build files zipinstall Create zip/tar of installed files singlezipinstall Alias for zipinstall and that's it. ---------------------------------------------------------------------- Jurassic Pork · 2015-11-02 05:15 try make all ---------------------------------------------------------------------- Paolo_R · 2015-11-02 05:35 Quote from: Jurassic Pork on November 02, 2015, 06:15:02 amtry make all JP - That certainly caused a lot of activity  Has that also installed fpc 2.6.4? Or do I need to do a 'make install'? ---------------------------------------------------------------------- Paolo_R · 2015-11-02 05:44 I tried to compile testapp.pas from the from the ../packages/fv/examples directory but it failed again. The compiler is still showing 2.6.2-8. ---------------------------------------------------------------------- molly · 2015-11-02 06:01 QuoteHas that also installed fpc 2.6.4? Or do I need to do a 'make install'? The latter  Quote from: Paolo_R on November 02, 2015, 06:44:50 amI tried to compile testapp.pas from the from the ../packages/fv/examples directory but it failed again. The compiler is still showing 2.6.2-8. It might be helpful to use your package manager to remove the 'old' fpc installation. The 'problem' is that all paths/configurations now points to your old 2.6.2 installation. You should (emphasis on should) be able to manually travel to the directory where the new compiled compiler was installed and invoke fp from there manually. At least you would be able to check if things worked out correctly with compilation. The log from the make install should be able to provide you with the path where the new compiler was installed. Alternatively do a zipinstall so that everything ends up in a (for you distributable) archive ---------------------------------------------------------------------- Paolo_R · 2015-11-02 06:31 molly: OK I've completely removed all fpc 2.6.2 compiler, units etc. When I load fp (the ide) the various directories are inserted in Options->Directories using fp.cfg from /home/paul which are what I put into fp.cfg What I've now got is: Units: /usr/lib/fpc/2.6.4/units/i386-linux/ /usr/lib/fpc/2.6.4/units/i386-linux/* /usr/lib/fpc/2.6.4/units/i386-linux/rtl Include files: /usr/share/fpcsrc/2.6.4/packages/fv/src /usr/lib/fpc/2.6.4 I'm not sure about these include files. I suspect that using Fi (in fp.cfg) was incorrect. Can you advise on this? ---------------------------------------------------------------------- molly · 2015-11-02 06:55 Quote from: Paolo_R on November 02, 2015, 07:31:14 amWhat I've now got is: Units: /usr/lib/fpc/2.6.4/units/i386-linux/ /usr/lib/fpc/2.6.4/units/i386-linux/* /usr/lib/fpc/2.6.4/units/i386-linux/rtl If that is where the .ppu files are actually located then that looks fine to me. QuoteInclude files: /usr/share/fpcsrc/2.6.4/packages/fv/src /usr/lib/fpc/2.6.4 I'm not sure about these include files. I suspect that using Fi (in fp.cfg) was incorrect. Can you advise on this? Yes, the use of -Fi in front of the path when using the configuration windows of FP-IDE is (as you suspected) wrong. FP-IDE's configuration dialogs (at least those that ask for providing paths) only expects paths to be inserted, each path on a separate line. As long as you don;t plan on compiling the compiler and platform related units (again, and with wanting to use FP-IDe for that), i would get rid of providing these currently shown include paths all- together. Instead (and if you still have the FPC-2.6.4 source on your disk located), copy the platform.inc file from fpc-sources, inside the directory where the FV example (of your fpc installation) is located. (it is the same solution used as upcoming FPC 3.x release) I'm more anxious to know if you are at least able to compile a simple helloworld program without any errors, and then check f you are able to compile an example that depends on one of the units that makes use of your configured paths. ---------------------------------------------------------------------- Paolo_R · 2015-11-02 07:25 molly: you mentioned earlier about a make install log. Where would I find this? whereis fpc gives /usr/local/bin/fpc /usr/local/lib/fpc If I type 'fpc' I get 'Error: ppc386 can't be executed, error message: Failed to execute "ppc386". err 7' I still cannot compile testapp.pas ---------------------------------------------------------------------- molly · 2015-11-02 07:51 Quote from: Paolo_R on November 02, 2015, 08:25:52 ammolly: you mentioned earlier about a make install log. Where would I find this? whereis fpc gives /usr/local/bin/fpc /usr/local/lib/fpc Ouch. And sorry for that. When you typed make install + enter a lot of output was produced (i hope), that _was_ the log. In order to make the log permanent store on disk you should have invoked make install with something like a solution mentioned here (never mind the bsd platform or other software being 'make install"-ed) QuoteIf I type 'fpc' I get 'Error: ppc386 can't be executed, error message: Failed to execute "ppc386". err 7' Oh dear... did you perhaps forgot to mention (or i overlooked) that you are running a 64-bit version of linux ? If so, then i'm affraid i run into troubles helping you solve that in an effective manner (i simply lack the experience creating/using 32-bit compiler on a 64-bit distro). If not, then i have no clue as of why ppc386 gives you an error. QuoteI still cannot compile testapp.pas Yes, unfortunately that much was clear. Sorry for that. fwiw: in case it would have been me into this situation, i would start from scratch again. - let package manager install fpc 2.6.2 - download fpc 2.6.4 sources and follow JP's instructions Add perhaps additional extra steps to produce the correct compiler for your chosen target -> look how others perhaps solved it, maybe a wiki article mentioning the problem encountered and providing a solution. and see where that would bring me. But it might perhaps be more helpful if a real linux user could give you a hand here. ---------------------------------------------------------------------- Paolo_R · 2015-11-02 08:30 Quote from: molly on November 02, 2015, 08:51:48 am Oh dear... did you perhaps forgot to mention (or i overlooked) that you are running a 64-bit version of linux ? If so, then i'm affraid i run into troubles helping you solve that in an effective manner (i simply lack the experience creating/using 32-bit compiler on a 64-bit distro). If not, then i have no clue as of why ppc386 gives you an error. In fact I'm running 32-bit Ubuntu and I assumed that fpc-2.6.4 was also 32-bit Quotefwiw: in case it would have been me into this situation, i would start from scratch again. - let package manager install fpc 2.6.2 - download fpc 2.6.4 sources and follow JP's instructions I think I might well do that. Anyway thanks for your help (and JP as well). ---------------------------------------------------------------------- molly · 2015-11-02 09:14 Quote from: Paolo_R on November 02, 2015, 09:30:42 amIn fact I'm running 32-bit Ubuntu and I assumed that fpc-2.6.4 was also 32-bit Well, that's the point  since you've downloaded the sources of FPC 2.6.4 and compiled them yourself, the make script should 'detect' your platform and automatically create and install the compiler that's suitable for your system. The makefile interprets environment settings on your system to detect the correct parameters for compilation/installation. It is also possible to provide additional parameters to the make-script, for example to create a special cross-compiler for a specific target. My current understanding of your situation is that something went wrong with detecting your system correctly and that the wrong compiler (or none at all) was created. I'll keep trying to search on that error, but the first hits i encountered that mentioned that error was in situations where people tried to create a 32-bit FPC compiler on a 64-bit system. Hence my asking for verification. Nevertheless i do apologize for getting you into this current situation. You could always opt for letting synaptic install fpc 2.6.2 for you, try to configure it properly with the correct paths (just give it another try/attempt now that you're a little wiser) and copy the missing include file. Hopefully someone else might be able to tap in and give you/us an extra hand. ---------------------------------------------------------------------- Paolo_R · 2015-11-02 09:35 molly: QuoteNevertheless i do apologize for getting you into this current situation. Don't worry about it. I'll figure it out - eventually