2006-12-28 13:03:34 +00:00
|
|
|
Name: logtalk
|
2007-06-12 11:39:47 +01:00
|
|
|
Summary: Logtalk - Open source object-oriented logic programming language
|
2007-11-06 01:50:09 +00:00
|
|
|
Version: 2.30.7
|
2006-12-28 13:03:34 +00:00
|
|
|
Release: 1
|
|
|
|
License: Artistic License 2.0
|
|
|
|
Group: Development/Languages
|
|
|
|
Packager: Paulo Moura <pmoura@logtalk.org>
|
2007-11-06 01:50:09 +00:00
|
|
|
Source: http://logtalk.org/files/lgt2307.tar.bz2
|
2006-12-28 13:03:34 +00:00
|
|
|
BuildArchitectures: noarch
|
|
|
|
URL: http://logtalk.org/
|
|
|
|
Prefix: /usr/local
|
|
|
|
AutoReqProv: no
|
|
|
|
%description
|
2007-06-12 11:39:47 +01:00
|
|
|
Logtalk is an open source object-oriented logic programming language that can use most Prolog implementations as a back-end compiler. As a multi-paradigm language, Logtalk includes support for both prototypes and classes, protocols, component-based programming through category-based composition, event-driven programming, and multi-threading programming.
|
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%prep
|
2007-06-12 11:39:47 +01:00
|
|
|
|
2007-11-06 01:50:09 +00:00
|
|
|
%setup -n lgt2307
|
2007-06-12 11:39:47 +01:00
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%build
|
2007-06-12 11:39:47 +01:00
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%install
|
2007-06-12 11:39:47 +01:00
|
|
|
mkdir -p /usr/local/share
|
2007-11-06 01:50:09 +00:00
|
|
|
rm -rf /usr/local/share/lgt2307
|
2007-06-12 11:39:47 +01:00
|
|
|
rm -f /usr/local/share/logtalk
|
2007-11-06 01:50:09 +00:00
|
|
|
mkdir /usr/local/share/lgt2307
|
|
|
|
cp -R * /usr/local/share/lgt2307
|
|
|
|
cd /usr/local/share/lgt2307
|
|
|
|
chmod a+x scripts/cleandist.sh
|
|
|
|
scripts/cleandist.sh
|
|
|
|
cd ..
|
|
|
|
ln -sf lgt2307 logtalk
|
2007-06-12 11:39:47 +01:00
|
|
|
cd ..
|
|
|
|
mkdir -p bin
|
2006-12-28 13:03:34 +00:00
|
|
|
cd bin
|
2007-06-12 11:39:47 +01:00
|
|
|
ln -sf ../share/logtalk/integration/bplgt.sh bplgt
|
|
|
|
ln -sf ../share/logtalk/integration/ciaolgt.sh ciaolgt
|
|
|
|
ln -sf ../share/logtalk/integration/cxlgt.sh cxlgt
|
|
|
|
ln -sf ../share/logtalk/integration/eclipselgt.sh eclipselgt
|
|
|
|
ln -sf ../share/logtalk/integration/gplgt.sh gplgt
|
|
|
|
ln -sf ../share/logtalk/integration/plclgt.sh plclgt
|
2007-11-06 01:50:09 +00:00
|
|
|
ln -sf ../share/logtalk/integration/qplgt.sh qplgt
|
2007-06-12 11:39:47 +01:00
|
|
|
ln -sf ../share/logtalk/integration/sicstuslgt.sh sicstuslgt
|
|
|
|
ln -sf ../share/logtalk/integration/swilgt.sh swilgt
|
|
|
|
ln -sf ../share/logtalk/integration/xsblgt.sh xsblgt
|
2007-11-06 01:50:09 +00:00
|
|
|
ln -sf ../share/logtalk/integration/xsbmtlgt.sh xsbmtlgt
|
2007-06-12 11:39:47 +01:00
|
|
|
ln -sf ../share/logtalk/integration/yaplgt.sh yaplgt
|
|
|
|
ln -sf ../share/logtalk/scripts/cplgtdirs.sh cplgtdirs
|
|
|
|
ln -sf ../share/logtalk/xml/lgt2pdf.sh lgt2pdf
|
|
|
|
ln -sf ../share/logtalk/xml/lgt2html.sh lgt2html
|
|
|
|
ln -sf ../share/logtalk/xml/lgt2xml.sh lgt2xml
|
2007-11-06 01:50:09 +00:00
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%clean
|
2007-11-06 01:50:09 +00:00
|
|
|
cd /usr/local/share
|
|
|
|
rm -rf lgt2307
|
|
|
|
rm -f logtalk
|
|
|
|
cd ../bin
|
|
|
|
rm -f bplgt
|
|
|
|
rm -f ciaolgt
|
|
|
|
rm -f cplgtdirs
|
|
|
|
rm -f cxlgt
|
|
|
|
rm -f eclipselgt
|
|
|
|
rm -f gplgt
|
|
|
|
rm -f lgt2html
|
|
|
|
rm -f lgt2pdf
|
|
|
|
rm -f lgt2xml
|
|
|
|
rm -f plclgt
|
|
|
|
rm -f qplgt
|
|
|
|
rm -f sicstuslgt
|
|
|
|
rm -f swilgt
|
|
|
|
rm -f xsblgt
|
|
|
|
rm -f xsbmtlgt
|
|
|
|
rm -f yaplgt
|
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%files
|
2007-06-12 11:39:47 +01:00
|
|
|
%defattr(-,root,root)
|
2007-11-06 01:50:09 +00:00
|
|
|
%doc /usr/local/share/lgt2307/BIBLIOGRAPHY.bib
|
|
|
|
%doc /usr/local/share/lgt2307/CUSTOMIZE.txt
|
|
|
|
%doc /usr/local/share/lgt2307/INSTALL.txt
|
|
|
|
%doc /usr/local/share/lgt2307/LICENSE.txt
|
|
|
|
%doc /usr/local/share/lgt2307/QUICK_START.txt
|
|
|
|
%doc /usr/local/share/lgt2307/README.txt
|
|
|
|
%doc /usr/local/share/lgt2307/RELEASE_NOTES.txt
|
|
|
|
%doc /usr/local/share/lgt2307/UPGRADING.txt
|
|
|
|
/usr/local/share/lgt2307/compiler
|
|
|
|
/usr/local/share/lgt2307/configs
|
|
|
|
/usr/local/share/lgt2307/contributions
|
|
|
|
/usr/local/share/lgt2307/examples
|
|
|
|
/usr/local/share/lgt2307/integration
|
|
|
|
/usr/local/share/lgt2307/libpaths
|
|
|
|
/usr/local/share/lgt2307/library
|
|
|
|
%docdir /usr/local/share/lgt2307/manuals
|
|
|
|
/usr/local/share/lgt2307/manuals
|
|
|
|
/usr/local/share/lgt2307/scripts
|
|
|
|
/usr/local/share/lgt2307/wenv
|
|
|
|
/usr/local/share/lgt2307/xml
|
2007-06-12 11:39:47 +01:00
|
|
|
/usr/local/share/logtalk
|
2006-12-28 13:03:34 +00:00
|
|
|
/usr/local/bin/cplgtdirs
|
|
|
|
/usr/local/bin/lgt2pdf
|
|
|
|
/usr/local/bin/lgt2html
|
|
|
|
/usr/local/bin/lgt2xml
|
2007-06-12 11:39:47 +01:00
|
|
|
/usr/local/bin/bplgt
|
|
|
|
/usr/local/bin/ciaolgt
|
|
|
|
/usr/local/bin/cxlgt
|
|
|
|
/usr/local/bin/eclipselgt
|
|
|
|
/usr/local/bin/gplgt
|
|
|
|
/usr/local/bin/plclgt
|
2007-11-06 01:50:09 +00:00
|
|
|
/usr/local/bin/qplgt
|
2007-06-12 11:39:47 +01:00
|
|
|
/usr/local/bin/sicstuslgt
|
|
|
|
/usr/local/bin/swilgt
|
|
|
|
/usr/local/bin/xsblgt
|
2007-11-06 01:50:09 +00:00
|
|
|
/usr/local/bin/xsbmtlgt
|
2007-06-12 11:39:47 +01:00
|
|
|
/usr/local/bin/yaplgt
|
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%post
|
2007-06-12 11:39:47 +01:00
|
|
|
echo
|
|
|
|
echo "Installed Logtalk on \"$RPM_INSTALL_PREFIX/share\"."
|
|
|
|
echo
|
|
|
|
echo "Links to the \"cplgtdirs\", \"lgt2pdf\", \"lgt2html\", and \"lgt2xml\" scripts"
|
|
|
|
echo "have been created on \"$RPM_INSTALL_PREFIX/bin\"; you may need to add this directory"
|
|
|
|
echo "to your execution path."
|
|
|
|
echo
|
|
|
|
echo "The following integration scripts are installed for running Logtalk"
|
|
|
|
echo "with selected back-end Prolog compilers:"
|
|
|
|
echo
|
|
|
|
echo " B-Prolog: bplgt (first run must use sudo)"
|
|
|
|
echo " CIAO: ciaolgt (first run must use sudo)"
|
|
|
|
echo " CxProlog: cxlgt"
|
|
|
|
echo " ECLiPSe: eclipselgt"
|
|
|
|
echo " GNU Prolog: gplgt"
|
|
|
|
echo " K-Prolog: plclgt"
|
2007-11-06 01:50:09 +00:00
|
|
|
echo " Qu-Prolog: qplgt"
|
2007-06-12 11:39:47 +01:00
|
|
|
echo " SICStus Prolog: sicstuslgt"
|
|
|
|
echo " SWI-Prolog: swilgt"
|
|
|
|
echo " XSB: xsblgt (first run must use sudo)"
|
2007-11-06 01:50:09 +00:00
|
|
|
echo " XSB (MT): xsbmtlgt (first run must use sudo)"
|
2007-06-12 11:39:47 +01:00
|
|
|
echo " YAP: yaplgt"
|
|
|
|
echo
|
|
|
|
echo "The Prolog integration scripts can be found on \"$RPM_INSTALL_PREFIX/bin\"."
|
|
|
|
echo "Make sure that the Prolog compilers are properly installed and available"
|
|
|
|
echo "on your execution path."
|
|
|
|
echo
|
|
|
|
echo "If you get an unexpected failure when using one of the Prolog integration"
|
|
|
|
echo "scripts, consult the \"$RPM_INSTALL_PREFIX/share/logtalk/configs/NOTES.txt\" file"
|
|
|
|
echo "for compatibility notes."
|
|
|
|
echo
|
2006-12-28 13:03:34 +00:00
|
|
|
mkdir -p /etc/profile.d
|
|
|
|
echo "# Logtalk environment setup" > /etc/profile.d/logtalk.sh
|
|
|
|
echo "" >> /etc/profile.d/logtalk.sh
|
|
|
|
echo "# Logtalk installation directory:" >> /etc/profile.d/logtalk.sh
|
2007-06-12 11:39:47 +01:00
|
|
|
echo "export LOGTALKHOME=$RPM_INSTALL_PREFIX/share/logtalk" >> /etc/profile.d/logtalk.sh
|
2006-12-28 13:03:34 +00:00
|
|
|
echo "" >> /etc/profile.d/logtalk.sh
|
|
|
|
echo "# Default location for Logtalk end-user files:" >> /etc/profile.d/logtalk.sh
|
|
|
|
echo "export LOGTALKUSER=\$HOME/logtalk" >> /etc/profile.d/logtalk.sh
|
|
|
|
chmod a+x /etc/profile.d/logtalk.sh
|
|
|
|
echo "# Logtalk environment setup" > /etc/profile.d/logtalk.csh
|
|
|
|
echo "" >> /etc/profile.d/logtalk.csh
|
|
|
|
echo "# Logtalk installation directory:" >> /etc/profile.d/logtalk.csh
|
2007-06-12 11:39:47 +01:00
|
|
|
echo "setenv LOGTALKHOME $RPM_INSTALL_PREFIX/share/logtalk" >> /etc/profile.d/logtalk.csh
|
2006-12-28 13:03:34 +00:00
|
|
|
echo "" >> /etc/profile.d/logtalk.csh
|
|
|
|
echo "# Default location for Logtalk end-user files:" >> /etc/profile.d/logtalk.csh
|
|
|
|
echo "setenv LOGTALKUSER \$HOME/logtalk" >> /etc/profile.d/logtalk.csh
|
|
|
|
chmod a+x /etc/profile.d/logtalk.csh
|
|
|
|
echo "Defined the following environment variables for all users:"
|
2007-06-12 11:39:47 +01:00
|
|
|
echo
|
|
|
|
echo " Logtalk installation directory: LOGTALKHOME = $RPM_INSTALL_PREFIX/share/logtalk"
|
2006-12-28 13:03:34 +00:00
|
|
|
echo " Default Logtalk user files directory: LOGTALKUSER = \$HOME/logtalk"
|
2007-06-12 11:39:47 +01:00
|
|
|
echo
|
2006-12-28 13:03:34 +00:00
|
|
|
echo "You may need to logout and login again or start a new shell in order to"
|
|
|
|
echo "use the new environment variables."
|
2007-06-12 11:39:47 +01:00
|
|
|
echo
|
|
|
|
echo "Users may change the default value of the LOGTALKUSER environment variable"
|
|
|
|
echo "in their shell configuration files if they already use, or want to use, a "
|
|
|
|
echo "different location for the Logtalk user files directory. This directory "
|
|
|
|
echo "is created by running the \"cplgtdirs\" shell script, which must be run "
|
|
|
|
echo "once by each user before using the integration scripts."
|
|
|
|
echo
|
|
|
|
echo "Logtalk basic installation completed."
|
|
|
|
echo
|
|
|
|
|
2006-12-28 13:03:34 +00:00
|
|
|
%postun
|
2007-06-12 11:39:47 +01:00
|
|
|
rm -f /etc/profile.d/logtalk.sh 2> /dev/null
|
|
|
|
rm -f /etc/profile.d/logtalk.csh 2> /dev/null
|