Files
OpenSceneGraph/dist/RedHatRPM/makespec
Don BURNS e0adca775b Reinstated Norman Vine's TARGET_BASENAME variable in the makefiles and
added prefixes and suffixes to libs and plugins.  ALl this to accomodate
cygwin...

Also added INST_SYS_PREFIX and INST_SHARE_PREFIX for installation, as well
as "standardizing" the install locations for the various platforms.
2002-04-03 17:42:12 +00:00

89 lines
1.4 KiB
Bash
Executable File

#!/bin/sh
list_install_files()
{
for d in \
${OSGHOME}/bin\
${OSGHOME}/lib\
${OSGHOME}/include
do
dd=`basename $d`
for f in `ls -1 $d`
do
echo cp -rf \
/usr/src/redhat/BUILD/osg-"$OSGVERSION"/$dd/$f /usr/$dd/$f
done
done
}
list_attr_files()
{
for d in \
${OSGHOME}/bin\
${OSGHOME}/lib
do
dd=`basename $d`
for f in $d/*
do
ff=`basename $f`
echo "%attr(755, root, root) /usr/$dd/$ff"
done
done
for f in ${OSGHOME}/include/osg/*
do
ff=`basename $f`
echo "%attr(444, root, root) /usr/include/osg/$ff"
done
}
[ -z "$OSGHOME" ] && (echo Please define OSGHOME; exit 1)
OSGVERSION=`./version`
OSGRELEASE=1
##[ -z "$OSGVERSION" ] && (echo Please define OSGVERSION; exit 1)
##[ -z "$OSGRELEASE" ] && (echo Please define OSGRELEASE; exit 1)
cat <<-LEOF > osg.spec
Summary: Open Scene Graph
Name: osg
Version: $OSGVERSION
Release: $OSGRELEASE
Copyright: GLPL
Group: Graphics
Source: osg-$OSGVERSION.tar.gz
URL: http://www.openscenegraph.org
Packager: `awk -f - /etc/passwd <<-EOF
BEGIN { FS=":"}
{
if( \\$1 == "$LOGNAME" )
print \\$5
}
EOF`
%description
Open Scene Graph is an open-source scene graph API.
%prep
%setup
%build
%install
`list_install_files`
# ---------------------
# FILES Sections
%files
`list_attr_files`
LEOF