ASSP out of date

Scott Haneda talklists at newgeo.com
Wed Nov 5 21:15:40 PST 2008


Thanks Bryan, see comments below:

On Nov 5, 2008, at 8:05 PM, Bryan Blackburn wrote:

> On Wed, Nov 05, 2008 at 07:08:17PM -0800, Scott Haneda said:
> [...]
>>
>> This is my first effort to make a port update file locally on my  
>> machine,
>> so be gentle :)
>
> For a first Portfile, this is a bad choice, it does nearly all steps
> manually (configure, no build, and destroot are all there in the  
> Portfile).

Can you elaborate a little on this, I am not sure I understand what  
you mean.  What would you suggest I do?  I already have ASSP running  
via hand compile, but wanted to use this as a way to possibly supply a  
working install back to the community.  Same with mrtg as well, but I  
have a feeling mrtg may be a little harder, even though I also have  
that working as well by hand compiling it and dependencies.

>> sudo port edit assp
>> Changed -> version                 1.4.3.0
>> Changed -> maintainers             scott at newgeo.com
>> Added   -> distname                ASSP_${version}-Install
>>
>> pre-patch seems to run around and look for two files, to rename
>> file rename "${worksrcpath}/ASSP Documentation.htm" ${worksrcpath}/
>> ASSPDocumentation.htm
>> file rename "${worksrcpath}/Regular Expression Tutorial.htm" $
>> {worksrcpath}/RegularExpressionutorial.htm
>>
>> Neither of them exist, and even if they did, they would have moved  
>> to the
>> docs/ directory.  Either way, I am not sure what was bad about  
>> spaces in
>> the files anyway, they are html files, and most browsers can deal  
>> with
>> that.
>
> Both appear to be in ASSP/docs though the former is now "Legacy  
> - ..."  The
> pre-patch does hit more than just HTML though, there are also perl  
> and shell
> scripts in the glob, not sure how well those will run with DOS-style  
> line
> endings; though the .sh file I looked at was *nix-style, and so is  
> at least
> one perl script.
> Not sure why the 'file rename' is being used, lots of files with  
> spaces on
> Macs.

Ahh nice catch, I did not notice the "Legacy" leading word there.  I  
will simply keep it as is and just reference the correct files.  I am  
pretty sure I can delete the bits about the spaces, as spaces in files  
should be just fine, and I would rather not change the original file  
name if possible.

>> I am not sure what this does:
>> reinplace "s%^#!.*perl%#![binaryInPath perl]%"
>
> reinplace as a regex-based sed-like replacement tool, that does it
> 'in-place' as in the result is in the same file as the source.  You  
> can
> search the guide for reinplace for the full documentation.
>
> This particular reinplace replaces perl shebang lines with the  
> result of
> [binaryInPath perl] which I actually disagree with; it should be using
> ${prefix}/bin/perl5 so make sure MacPorts' perl is used:
>
>   reinplace "s%^#!.*perl%#!${prefix}/bin/perl5%"

So the main job is to simply alter the path to perl to that of what OS  
X wants for the path?  However, you would like to force the use of the  
perl that macports installs?

I am ok with that, granted, I was hoping this would be a portable set  
of files once done, by changing to non OS X built in perl, the files  
are no longer portable to other systems.  I guess I should give up on  
that.

ASSP has a few non mandatory dependencies.  One is email::validate or  
something similar, and the other is net:LDAP or similar, I am assuming  
these are not installed.

What is the procedure for me making sure those get added. I know that  
CPAN makes it pretty trivial to get them, as I have done that before.  
I want them included in this port as well, as they are small, and  
eventually very useful.

Is the idea to include them in the portfile, and there is no option to  
not install them, or do they need to be supplied as arguments to the  
port install command?

If they are installed, it means some changes to the config file that  
is the default file for ASSP, which makes me think I may be getting in  
a little too deep on this one.

ClamAV is another optional component as well, how would I go about  
that intrgration?  I assume clamAV is part of the ports files already,  
so I just need to hook it in somehow.

>> Hopefully I have troubleshot this as best as I can, I am stuck at  
>> this
>> point, with this being my first attempt to make a port update file.  
>> Any
>> help is appreciated.
>
> Again, this definitely isn't the simplest one.  Almost seems like it  
> could
> be easier to create a new Portfile for it, start fleshing that out  
> and use
> the old one for hints on a few things.

I am willing to give it a try, I just have a feeling it may end up  
making me ask even more questions.  What is the best guide for  
starting from scratch?

Thanks.
--
Scott



More information about the macports-users mailing list