--- loncom/build/lpml_parse.pl 2011/03/25 22:55:06 1.57 +++ loncom/build/lpml_parse.pl 2020/10/07 19:55:39 1.62 @@ -12,7 +12,7 @@ # The LearningOnline Network with CAPA # lpml_parse.pl - Linux Packaging Markup Language parser # -# $Id: lpml_parse.pl,v 1.57 2011/03/25 22:55:06 raeburn Exp $ +# $Id: lpml_parse.pl,v 1.62 2020/10/07 19:55:39 raeburn Exp $ # # Written by Scott Harrison, codeharrison@yahoo.com # @@ -1230,6 +1230,7 @@ sub format_file { my @tokeninfo=@_; $file=''; $source=''; $target=''; $categoryname=''; $description=''; $note=''; $build=''; $status=''; $dependencies=''; $installscript=''; + $buildlink = ''; my $text=&trim($parser->get_text('/file')); my $buildtest; $file_count++; @@ -1323,25 +1324,57 @@ END } return $result; } - my $bflag='-b1'; - $bflag='-b3' if $dependencies or $buildlink; - return <get_text('/buildlink')); if ($text) { $parser->get_tag('/buildlink'); $buildlink=$sourceroot.'/'.$text; + } else { + $buildlink=''; } return ''; } @@ -1662,12 +1696,13 @@ sub format_status { # ------------------------------------------------- Format dependencies section sub format_dependencies { my @tokeninfo=@_; - #$dependencies=''; my $text=&trim($parser->get_text('/dependencies')); if ($text) { $parser->get_tag('/dependencies'); $dependencies=join(';',((map {s/^\s*//;s/\s$//;$_} split(/\;/,$text)),$dependencies)); $dependencies=~s/;$//; + } else { + $dependencies=''; } return ''; }