make pkg_install suite reusable, please

Charlie Kester corky1951 at comcast.net
Fri Apr 9 19:05:50 UTC 2010


On Fri 09 Apr 2010 at 07:36:17 PDT Alexander Churanov wrote:
>2010/4/9 Leinier Cruz Salfran <salfrancl.listas at gmail.com>
>
>> i want to ask you one thing: can you make the 'pkg_install' suite
>> reusable .. means install 'libinstall.a' as a shared object in order
>> to make it reusable by others devs
>>
>
>Hi Leinier,
>
>I'd like to add my 50 cents. From my point of view, the true UNIX way is
>re-using whole programs. This provides unbelievable isolation and
>correctness. If you don't want to fork myriads of processes each second,
>then, it's, probably, better to ask for pipe mode of pkg_* tools. For
>example, aspell works that way. You start a process, write commands and
>queries and read results.

+1

It was a watershed moment in my programming career when I realized that
the bubbles on those DFD charts we used to use for structured design
could be whole processes and not just functions in a single, monolithic
program.  

Suddenly everything the structured design folks were saying about
re-use, encapsulation, loose coupling, module cohesion, etc. made a lot
more sense when viewed from the perspective of simple Unix utilities
communicating with plain text via pipes. 

We should encourage that approach as a default, and only put things into
binary libraries when forced to by performance considerations.


More information about the freebsd-hackers mailing list