~ubuntu-branches/debian/lenny/fpc/lenny

« back to all changes in this revision

Viewing changes to fpcsrc/packages/fcl-base/src/os2/custapp.inc

  • Committer: Bazaar Package Importer
  • Author(s): Mazen Neifer, Torsten Werner, Mazen Neifer
  • Date: 2008-05-17 17:12:11 UTC
  • mfrom: (3.1.9 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080517171211-9qi33xhd9evfa0kg
Tags: 2.2.0-dfsg1-9
[ Torsten Werner ]
* Add Mazen Neifer to Uploaders field.

[ Mazen Neifer ]
* Moved FPC sources into a version dependent directory from /usr/share/fpcsrc
  to /usr/share/fpcsrc/${FPCVERSION}. This allow installing more than on FPC
  release.
* Fixed far call issue in compiler preventing building huge binearies.
  (closes: #477743)
* Updated building dependencies, recomennded and suggested packages.
* Moved fppkg to fp-utils as it is just a helper tool and is not required by
  compiler.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
{
 
2
    This file is part of the Free Pascal run time library.
 
3
    Copyright (c) 2003 by the Free Pascal development team
 
4
 
 
5
    OS/2 version of custom app object routines.
 
6
 
 
7
    See the file COPYING.FPC, included in this distribution,
 
8
    for details about the copyright.
 
9
 
 
10
    This program is distributed in the hope that it will be useful,
 
11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
13
 
 
14
 **********************************************************************}
 
15
 
 
16
{ taken from dos unit }
 
17
 
 
18
function EnvStr (Index: longint): string;
 
19
 
 
20
var HP: PChar;
 
21
 
 
22
begin
 
23
    if (Index <= 0) or (Index > EnvC) then
 
24
        begin
 
25
            EnvStr := '';
 
26
            exit;
 
27
        end;
 
28
    HP := EnvP [Pred (Index)];
 
29
    EnvStr := StrPas (HP);
 
30
end;
 
31
 
 
32
 
 
33
procedure SysGetEnvironmentList(List : TStrings;NamesOnly : Boolean);
 
34
 
 
35
Var
 
36
  S : String;
 
37
  J,I : Integer;
 
38
 
 
39
begin
 
40
  List.Clear;
 
41
  For J := 1 to Pred (EnvC) do
 
42
    begin
 
43
    S:=EnvStr(J);
 
44
    If NamesOnly then
 
45
      begin
 
46
      I:=Pos('=',S);
 
47
      If (I>1) then
 
48
        S:=Copy(S,1,I-1);
 
49
      end;
 
50
    List.Add(S);
 
51
    end;
 
52
end;