Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 9 Apr 2010 11:51:50 -0700
From:      Charlie Kester <corky1951@comcast.net>
To:        freebsd-hackers@freebsd.org
Subject:   Re: make pkg_install suite reusable, please
Message-ID:  <20100409185150.GC61756@comcast.net>
In-Reply-To: <q2x3cb459ed1004090736t5a67f315geca1c199a5061e7d@mail.gmail.com>
References:  <x2ta2585ef1004090716vf74893dfo9d5412455294c64d@mail.gmail.com> <q2x3cb459ed1004090736t5a67f315geca1c199a5061e7d@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri 09 Apr 2010 at 07:36:17 PDT Alexander Churanov wrote:
>2010/4/9 Leinier Cruz Salfran <salfrancl.listas@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.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100409185150.GC61756>