%bcond check 1 Name: perl-Chemistry-File-SLN Version: 0.11 Release: %autorelease Summary: SLN linear notation parser/writer License: GPL-1.0-or-later OR Artistic-1.0-Perl URL: https://metacpan.org/dist/Chemistry-File-SLN Source0: https://cpan.metacpan.org/authors/id/I/IT/ITUB/Chemistry-File-SLN-%{version}.tar.gz BuildRequires: make BuildRequires: perl-generators BuildRequires: perl-interpreter BuildRequires: perl(ExtUtils::MakeMaker) %if %{with check} BuildRequires: perl(Chemistry::Bond::Find) BuildRequires: perl(Chemistry::Canonicalize) BuildRequires: perl(Chemistry::Mol) BuildRequires: perl(Chemistry::Ring) BuildRequires: perl(Parse::Yapp::Driver) BuildRequires: perl(Test::More) BuildRequires: perl(Test::Pod) %endif BuildArch: noarch %description This module parses a SLN (Sybyl Line Notation) string. This is a File I/O driver for the PerlMol project. http://www.perlmol.org/. It registers the 'sln' format with Chemistry::Mol, and recognizes filenames ending in '.sln'. Optional attributes for atoms, bonds, and molecules are stored as $atom->attr("sln/attr"), $bond->attr("sln/attr"), and $mol->attr("sln/attr"), respectively. Boolean attributes are stored with a value of 'TRUE'. That's the way boolean attributes are recognized when writing, so that they can be written in the shortened form. %prep %autosetup -p1 -n Chemistry-File-SLN-%{version} %build perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" \ NO_PACKLIST=1 NO_PERLLOCAL=1 %make_build %install %make_install find %{buildroot} -type f -name '*.bs' -empty -delete %{_fixperms} '%{buildroot}'/* %if %{with check} %check make test %endif %files %doc README %dir %{perl_vendorlib}/Chemistry %dir %{perl_vendorlib}/Chemistry/File %dir %{perl_vendorlib}/Chemistry/File/SLN %{perl_vendorlib}/Chemistry/File/SLN.pm %{perl_vendorlib}/Chemistry/File/SLN/Parser.pm %{_mandir}/man3/Chemistry::File::SLN.3pm.* %changelog %autochangelog