Chapter 37 Further Reading
Official Documentation
- Free Pascal Process Unit — Documentation for TProcess, used to launch external programs and capture their output.
-
https://www.freepascal.org/docs-html/fcl/process/index.html
-
Free Pascal DynLibs Unit — Documentation for dynamic library loading (LoadLibrary, GetProcAddress, UnloadLibrary).
-
https://www.freepascal.org/docs-html/rtl/dynlibs/index.html
-
Free Pascal Programmer's Guide: Conditional Compilation — Complete reference for {$IFDEF}, {$IFNDEF}, {$IF}, and platform/CPU detection directives.
-
https://www.freepascal.org/docs-html/prog/progch1.html
-
Lazarus Wiki: Executing External Programs — Community guide with advanced TProcess usage patterns.
- https://wiki.lazarus-ide.org/Executing_External_Programs
Platform References
- XDG Base Directory Specification — The Linux standard for application data, configuration, and cache directories.
-
https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
-
Windows App Data Locations — Microsoft documentation for application data storage conventions.
-
https://learn.microsoft.com/en-us/windows/win32/shell/knownfolderid
-
SQLite C/C++ Interface — The official SQLite C API reference, useful for building Pascal wrappers.
- https://www.sqlite.org/cintro.html
Books
-
Kerrisk, M. (2010). The Linux Programming Interface. Comprehensive reference for Linux system programming. Covers files, processes, signals, IPC, and much more. The C examples translate directly to Pascal external declarations.
-
Richter, J. (2012). Windows via C/C++. Deep dive into Windows OS programming. Covers processes, threads, memory, I/O, registry, and DLLs. Invaluable if you need to call Windows APIs from Pascal.
Connecting to Other Languages
| Concept | Pascal | Python | C | Go |
|---|---|---|---|---|
| Environment vars | GetEnvironmentVariable |
os.environ |
getenv() |
os.Getenv() |
| Run process | TProcess |
subprocess |
fork/exec |
os/exec |
| File search | FindFirst/FindNext |
glob / os.listdir |
opendir/readdir |
filepath.Walk |
| Platform detection | {$IFDEF} |
sys.platform |
#ifdef |
runtime.GOOS |
| Call C library | external 'lib' |
ctypes |
Native | cgo |
| Registry (Win) | TRegistry |
winreg |
RegOpenKeyEx |
golang.org/x/sys/windows/registry |
Pascal's approach is closest to C: direct external function calls with no runtime overhead.