Questions tagged [fpc]

FPC (Free Pascal Compiler) is a 32/64-bit multi-architecture Object Pascal compiler with both Turbo Pascal, Apple Pascal and Delphi dialects.

FPC (Free Pascal Compiler) is a 16/32/64-bit multi-architecture Object Pascal compiler with both Turbo Pascal, Apple Pascal and Delphi dialects.

Free Pascal is the compiler core under the Lazarus RAD project, which provides a portable Delphi-like IDE and RAD. Lazarus has its own tag on Stackoverflow.

However Free Pascal is used directly for server/web/control apps too.

Free Pascal currently supports x86/x86_64, powerpc/powerpc64, sparc and assorted ARMs, and most popular OSes.

8086 (16-bit x86), m68k and Mips are in advanced stages of preparation in the development branch.

164 questions
6
votes
1 answer

Free Pascal for Android on MIPS

Trying to port a Delphi library to Android. Free Pascal has Android/ARM support - a prebuilt compiler for Windows is available. However, Android NDK now supports MIPS and x86 as well. What's the status of support for those in FPC? For now, my…
Seva Alekseyev
  • 59,826
  • 25
  • 160
  • 281
5
votes
3 answers

Reading a file in FreePascal

I have a text file with specified structure, namely (for each line): char, space, char, space, double value, endline. For instance q w 1.23 e r 4.56 t y 7.89 What is the proper way to "extract" those values in Free Pascal?
Clueless
  • 605
  • 3
  • 10
  • 19
5
votes
1 answer

Installing package without IDE on Lazarus from command line

I am trying to automate installing of my package to IDE from the command line using (this) article. When using IDE the package is installed correctly and my components appear on Lazarus palette. To verify the article steps, after installation with…
AlexeyDaryin
  • 903
  • 6
  • 15
5
votes
1 answer

FPC : RTTI on records

This is my first time on this site. Usually, I have no problem to found replies in the old posts but I don't success with my actual problem. I would like to know how use RTTI functions to know at running time the properties/members of a record under…
5
votes
1 answer

Best way for read and write a text file

I am using the latest version of Lazarus IDE and I have a Memo1 on my TForm1. I have to load a text file in Memo1 and then edit every line of the Memo (I use Memo1.Lines.Strings[i] := ...). At the end I must save the edited memo at a particular…
Alberto Miola
  • 4,643
  • 8
  • 35
  • 49
5
votes
1 answer

Problem with WM_COMMAND on Lazarus/FPC

I have form with MainMenu and I want to intercept when the user selects a command item from a menu. This works in Delphi: type TForm1 = class(TForm) ... // Memo and MainMenu created protected procedure WMCommand(var Info: TWMCommand);…
Michał Niklas
  • 53,067
  • 18
  • 70
  • 114
5
votes
3 answers

GUI Only By Using FPC

I want to know how I can develop GUI applications(32 Bits) without using Delphi language(Object Pascsl), only by using FPC with Lazarus installed(Pascal). Thanks.
Nathan Campos
  • 28,769
  • 59
  • 194
  • 300
5
votes
1 answer

Installation of R fpc package

I'm having a particularly hard time trying to get the 'fpc' package in R to install on Ubuntu 13.04. The code I've written contains a line like: install.packages('fpc') ; library(fpc) which gives the output: Error in contrib.url(repos, type) : …
astromax
  • 6,001
  • 10
  • 36
  • 47
4
votes
1 answer

How do I use CreateFile to access a physical disk?

I asked on the Lazarus programming forum how to open a physical disk. I want to allow the user to select physical disks from their system when they click a "Select Disk" button. There are some examples here at Stack Overflow that are similar but not…
Gizmo_the_Great
  • 979
  • 13
  • 28
4
votes
1 answer

Execute code in the context of the main thread (Lazarus)

I have to execute some code in the context of the main thread. I am using Lazarus + FPC. I receive an event from a thread inside a DLL (shared library if on linux) and my callback function gets called. Note that this function is not a member of any…
Runner
  • 6,073
  • 26
  • 38
4
votes
2 answers

Passing arguments to write within a procedure

How can I pass arguments from my procedure to a call of write called inside ? Something quite like that: procedure smth (args: alltypes); begin write(args); end;
Imobilis
  • 1,475
  • 8
  • 29
4
votes
2 answers

How can create https server using synapse in lazarus

I am trying to create https server in lazarus using synapse but I am failing. I want to mys server receive data from other https clients. I am sending requests with my browser using https://localhost:1500 and mys server is receiving signals. But…
Imants Gulbis
  • 87
  • 1
  • 8
4
votes
2 answers

Multithreaded bubblesort. Works fine with delphi 7 but not with Lazarus? Compiler bug?

First of all I would like to show you my code: unit BSort; {==============================================================================} {$mode…
Babubabu
  • 69
  • 4
4
votes
1 answer

Linking FPC .o files into Delphi

How can I link a FPC .o from a library to a Delphi executable. When I try to link the following code I get a bunch of unsatisfied forward or external declarations. library project1; {$mode objfpc}{$H+} uses Classes { you can add units after…
user3060326
  • 187
  • 2
  • 16
3
votes
1 answer

iAd with Firemonkey?

I would like to know how (if?) I can put an iAd into an App created using Firemonkey. I have only been able to find one answer to this (in months of regular searching), which directed the poster to Apple's iAd documentation. I know how to use iAd in…
Maggie
  • 31
  • 1
1
2
3
10 11