You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

128 lines
4.7 KiB

##
## vcg.spec -- OpenPKG RPM Specification
## Copyright (c) 2000-2004 The OpenPKG Project <http://www.openpkg.org/>
## Copyright (c) 2000-2004 Ralf S. Engelschall <rse@engelschall.com>
## Copyright (c) 2000-2004 Cable & Wireless <http://www.cw.com/>
##
## Permission to use, copy, modify, and distribute this software for
## any purpose with or without fee is hereby granted, provided that
## the above copyright notice and this permission notice appear in all
## copies.
##
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
## SUCH DAMAGE.
##
# package information
%define V_major 1.30
%define V_vendor %{V_major}.r3.17
%define V_opkg %{V_major}.3.17
# package information
Name: vcg
Summary: Visualization of Compiler Graphs
URL: http://rw4.cs.uni-sb.de/users/sander/html/gsvcg1.html
Vendor: Georg Sander
Packager: The OpenPKG Project
Distribution: OpenPKG [PLUS]
Group: Graphics
License: GPL
Version: %{V_opkg}
Release: 20030708
# list of sources
Source0: ftp://ftp.cs.uni-sb.de/pub/graphics/vcg/vcg.%{V_vendor}.tgz
# build information
Prefix: %{l_prefix}
BuildRoot: %{l_buildroot}
BuildPreReq: OpenPKG, openpkg >= 20030708, X11, make, gcc
PreReq: OpenPKG, openpkg >= 20030708, X11
AutoReq: no
AutoReqProv: no
%description
The VCG tool reads a textual and readable specification of a graph
and visualizes the graph. If not all positions of nodes are fixed,
the tool layouts the graph using several heuristics as reducing
the number of crossings, minimizing the size of edges, centering
of nodes. The specification language of the VCG tool is nearly
compatible to GRL, the language of the Edge tool, but contains many
extensions. The VCG tool allows folding of dynamically or statically
specified regions of the graph.
%prep
%setup -q -n vcg.%{V_major}
%build
cp preconf/globals.h src/globals.h
cp tMakefile.tpl tMakefile
x11lib=`%{l_prefix}/etc/rc --query x11_libdir`
x11inc=`%{l_prefix}/etc/rc --query x11_incdir`
%{l_shtool} subst \
-e 's;BINPATHNAME;%{l_prefix}/bin;' \
-e 's;MANPATHNAME;%{l_prefix}/man/man1;' \
-e 's;MANEXTNAME;1;' \
-e 's;VCGNAME;vcg;' \
-e 's;CFLAGSNAME;-c %{l_cflags -O};' \
-e 's;CLINKFLAGSNAME;-o;' \
-e "s;ADDINCLUDEPATHNAME;%{l_cppflags} -I${x11inc};" \
-e "s;ADDLIBPATHNAME;%{l_ldflags} -L${x11lib};" \
-e 's;ADDLIBSNAME;-lXext -lX11 -lm;' \
-e 's;CCNAME;%{l_cc};' \
-e 's;CCLINKNAME;%{l_cc};' \
-e 's;FLEXNAME;false %{l_flex};' \
-e 's;BISONNAME;false %{l_bison} -y -d;' \
-e 's;MAKENAME;%{l_make} %{l_mflags};' \
-e 's;SEDNAME;sed;' \
-e 's;TOUCHNAME;touch;' \
-e 's;MVNAME;mv;' \
-e 's;LNNAME;ln -s;' \
-e 's;RMNAME;rm -f;' \
-e 's;parsegen;false parsegen-dummy;' \
tMakefile
%{l_shtool} subst \
-e 's;<malloc\.h>;<stdlib.h>;g' \
src/*.[ch] src/preconf/*.[ch]
%{l_make} %{l_mflags} -f tMakefile
%install
rm -rf $RPM_BUILD_ROOT
%{l_shtool} mkdir -f -p -m 755 \
$RPM_BUILD_ROOT%{l_prefix}/bin \
$RPM_BUILD_ROOT%{l_prefix}/man/man1 \
$RPM_BUILD_ROOT%{l_prefix}/share/vcg
%{l_shtool} install -c -s -m 755 \
src/vcg demo/vcgdemomaker \
$RPM_BUILD_ROOT%{l_prefix}/bin/
%{l_shtool} install -c -m 644 \
man/vcg.man \
$RPM_BUILD_ROOT%{l_prefix}/man/man1/vcg.1
%{l_shtool} install -c -m 644 \
man/vcgdemomaker.man \
$RPM_BUILD_ROOT%{l_prefix}/man/man1/vcgdemomaker.1
%{l_gzip} -9 doc/visual.ps
%{l_shtool} install -c -m 644 \
doc/visual.ps.gz \
$RPM_BUILD_ROOT%{l_prefix}/share/vcg/
ln $RPM_BUILD_ROOT%{l_prefix}/bin/vcg \
$RPM_BUILD_ROOT%{l_prefix}/bin/xvcg
ln $RPM_BUILD_ROOT%{l_prefix}/man/man1/vcg.1 \
$RPM_BUILD_ROOT%{l_prefix}/man/man1/xvcg.1
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
%files -f files
%clean
rm -rf $RPM_BUILD_ROOT