rpm: using relativ paths for desktop menu item

git-svn-id: trunk@10772 -
This commit is contained in:
mattias 2007-03-20 18:28:48 +00:00
parent 95fbdd6309
commit 94552293bc
6 changed files with 27 additions and 17 deletions

View File

@ -1,24 +1,23 @@
<?xml version="1.0"?>
<CONFIG>
<ProjectOptions>
<PathDelim Value="\"/>
<PathDelim Value="/"/>
<Version Value="5"/>
<General>
<SessionStorage Value="InProjectDir"/>
<MainUnit Value="0"/>
<IconPath Value=".\"/>
<IconPath Value="./"/>
<TargetFileExt Value=""/>
</General>
<PublishOptions>
<Version Value="2"/>
<DestinationDirectory Value="$(TestDir)\publishedproject\"/>
<IncludeFileFilter Value="*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml)"/>
<ExcludeFileFilter Value="*.(bak|ppu|ppw|o|so);*~;backup"/>
</PublishOptions>
<RunParams>
<local>
<FormatVersion Value="1"/>
<LaunchingApplication PathPlusParams="\usr\X11R6\bin\xterm -T 'Lazarus Run Output' -e $(LazarusDir)\tools\runwait.sh $(TargetCmdLine)"/>
<LaunchingApplication PathPlusParams="/usr/X11R6/bin/xterm -T 'Lazarus Run Output' -e $(LazarusDir)/tools/runwait.sh $(TargetCmdLine)"/>
</local>
</RunParams>
<RequiredPackages Count="3">
@ -58,7 +57,6 @@
</ProjectOptions>
<CompilerOptions>
<Version Value="5"/>
<PathDelim Value="\"/>
<CodeGeneration>
<Generate Value="Faster"/>
</CodeGeneration>

View File

@ -1,7 +1,7 @@
[Desktop Entry]
Name=Lazarus
Comment=Lazarus IDE
Exec=/usr/bin/startlazarus %f
Exec=startlazarus %f
Terminal=false
Type=Application
Icon=lazarus.png

View File

@ -28,8 +28,8 @@
- restoring layout: pages
- restoring layout: move form after inserting a control
- restoring layout: spiral splitter
- save TLazDockConfigNode to stream
- load TLazDockConfigNode from stream
- save TLazDockConfigNode to stream (atm only xml implemented)
- load TLazDockConfigNode from stream (atm only xml implemented)
}
unit LDockCtrl;
@ -724,6 +724,8 @@ end;
function TCustomLazControlDocker.DockAsPage(Layout: TLazDockConfigNode
): boolean;
// dock as page like in Layout
// Requirements: Parent in Layout is a ldcntPage and a parent control exists.
var
SelfNode: TLazDockConfigNode;
PageNode: TLazDockConfigNode;
@ -739,6 +741,7 @@ var
PageIndex: LongInt;
NeighbourList: TFPList;
AnchorControls: TAnchorControls;
TopFormBounds: TRect;
begin
Result:=false;
DebugLn(['TCustomLazControlDocker.DockAsPage DockerName="',DockerName,'"']);
@ -757,7 +760,7 @@ begin
exit;
end;
if PageNode.ChildCount<>1 then begin
DebugLn(['TCustomLazControlDocker.DockAsPage SelfNode.Parent.TheType<>ldcntPage DockerName="',DockerName,'"']);
DebugLn(['TCustomLazControlDocker.DockAsPage PageNode.ChildCount<>1 DockerName="',DockerName,'"']);
exit;
end;
@ -769,15 +772,18 @@ begin
NeighbourNode:=PagesNode.Childs[PageNodeIndex+1].Childs[0];
NeighbourControl:=Manager.FindControlByDockerName(NeighbourNode.Name);
if NeighbourControl=nil then begin
DebugLn(['TCustomLazControlDocker.CreateFormAndDockWithSplitter NeighbourControl not found "',NeighbourNode.Name,'"']);
DebugLn(['TCustomLazControlDocker.DockAsPage NeighbourControl not found "',NeighbourNode.Name,'"']);
exit;
end;
if NeighbourControl.Parent=nil then begin
// NeighbourControl is a single top level control
// NeighbourControl is a top level control (no parents, no neighbours)
// => create a TLazDockForm with a TLazDockPages and two TLazDockPage
TopForm:=TLazDockForm.Create(nil);
// TODO: resize TopForm
TopFormBounds:=PagesNode.Bounds;
// TODO: shrink TopFormBounds
TopForm.BoundsRect:=TopFormBounds;
Pages:=TLazDockPages.Create(nil);
Pages.DisableAlign;
try
@ -817,7 +823,7 @@ begin
Page:=Pages.Page[PageIndex];
Control.Parent:=Page;
Control.AnchorClient(0);
// TODO resize parents
// TODO enlarge parents
end else begin
// NeighbourControl is a child control, but the parent is not yet a page
// => collect all neighbour controls for a page
@ -1613,7 +1619,7 @@ var
Result:=Manager.FindControlByDockerName(ADockerName);
end;
function DockWithSpiralSpltter: boolean;
function DockWithSpiralSplitter: boolean;
begin
// TODO
Result:=false;
@ -1636,7 +1642,7 @@ var
and CreateFormAndDockWithSplitter(Layout,a) then
exit(true);
inc(SplitterCount);
if (SplitterCount=4) and DockWithSpiralSpltter then
if (SplitterCount=4) and DockWithSpiralSplitter then
exit(true);
end;
end;

View File

@ -30,6 +30,10 @@ else
svn export $SourceDir /tmp/lazarus
fi
# add ide/revision.inc
Revision=$(cat /tmp/lazarus/.svn/entries | grep committed-rev= | head -n 1 | cut -d\" -f2)
echo "const RevisionStr = '$Revision';" > /tmp/lazarus/ide/revision.inc
cd /tmp
echo "packing ..."
tar cvzf lazarus.tgz lazarus

View File

@ -15,8 +15,9 @@ if [ "x$FPCRPM" = "x" ]; then
echo ERROR: fpc rpm not installed
exit
fi
FPCRPMVersion=`echo $FPCRPM | sed -e 's/fpc-//g'`
FPCRPMVersion=$(echo $FPCRPM | sed -e 's/fpc-//g')
echo "installed fpc version: $FPCRPMVersion"
FPCSRCRPMVersion=$(echo $FPCRPMVersion | cut -d- -f1)
Date=$Year$Month$Day
LazVersion=$(./get_lazarus_version.sh)
@ -40,6 +41,7 @@ cat rpm/lazarus.spec.template | \
-e "s/LAZSOURCE/$Src/g" \
-e "s/FPCBUILDVERSION/2.0.0/g" \
-e "s/FPCVERSION/$FPCRPMVersion/g" \
-e "s/FPCSRCVERSION/$FPCSRCRPMVersion/g" \
> $SpecFile
# build rpm

View File

@ -11,7 +11,7 @@ Packager: Mattias Gaertner
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#BuildRequires:
Requires: fpc-src = FPCVERSION, fpc = FPCVERSION, gdk-pixbuf, gtk+, glibc, gdb
Requires: fpc-src = FPCSRCVERSION, fpc = FPCVERSION, gdk-pixbuf, gtk+, glibc, gdb
# NOTE: without the symlink trick for gtk1, it requires the devel packages.
Requires(post): desktop-file-utils