[devel] Fwd: [RFC] More core integration

Alexey Tourbin =?iso-8859-1?q?at_=CE=C1_altlinux=2Eru?=
Чт Янв 20 12:38:07 MSK 2005


Здравствуйте.
В стандартную поставку перла новой версии (5.10) хотят интегрировать
ещё добрую дюжину новых CPAN модулей.  То есть то, что я от perl-base и
perl-devel отпиливаю, они туда ещё больше подбрасывают.

Идеалы покомпонентной (design by contract), асинхронной разработки
программного обеспечения попираются нынче не каждом шагу.  У кого-нибудь
есть желание пойти туда и громко поругаться?


----- Forwarded message from "Jos I. Boumans" <kane на xs4all net> -----

Date: Wed, 19 Jan 2005 14:25:32 +0100
From: "Jos I. Boumans" <kane на xs4all net>
Subject: [RFC] More core integration
To: Perl 5 Porters <perl5-porters на perl org>
Message-Id: <983D8E42-6A1D-11D9-AC55-000A956B0E06 на xs4all net>
X-Mailer: Apple Mail (2.619)

Hi,

As outlined in another thread, I'm currently creating a patchset to add 
CPANPLUS to the core. This has a few consequences however, which would 
necessitate (or prefer) the adoptation of a few other modules. Some of 
them we knew about already, others are here for discussion. I hope this 
will make a fairly conclusive list, so we can keep the overview.

Here's a list of which ones, and the rationale behind them and what 
would happen if we don't:

* Module::CoreList [NEW]
	An 'obvious' choice; Apart from the fact that currently perl core doesn't
 	list what modules are shipped with it in a comprehensible format, this is
	also the one tool (due to lack of more elaborate CPAN index files) which
	modules are part of core perl (especially for older versions of perl).
	By not adding it, CPANPLUS is unable to detect whether a module in an older
	version of perl is actually part of core or not, which is essential for
	dependency resolving and the building of distributions[1].
	It has no dependencies other than Test::More and has shown to pass it's
	tests quite well:
		http://testers.cpan.org/show/Module-CoreList.html

* Module::Build
	An obvious choice; the 'other' CPAN installer. CPANPLUS currently assumes
	Module::Build to be available (it bundles M::B for its CPAN release).
	Would be wise to include this one, as about 10% of CPAN uses this as its
	installer now.
	By not integrating it, we miss out on the tests for CPANPLUS to deal with
	M::B related distributions, but that could be made a 'skiptest', at least
	for now.
	All its dependencies are core perl. It recommends a few non-core modules
	however, including Archive::Tar.

* IPC::Run
	Essential to be able to shell out on all platforms IPC::Open3 is not
	supported on (most notably Win32 and cygwin) to reliably get exit 
	codes
	from the shell and capture the output of the command.
	By not integrating it, CPANPLUS can not function on Win32 and cygwin and
	other platforms not supporting IPC::Open3, which will cause regression
	tests to fail.
	It currently has a bug in its test suite (not the code!) that makes it
	fail on darwin, but a patch for that is already available:
		http://testers.cpan.org/show/IPC-Run.html

	It depends on IO::Tty (which has no more dependencies itself), but IO::Tty
	will not work on Win32 due to lack of header files (works on cygwin ok):
		http://testers.cpan.org/show/IO-Tty.html

	On Win32, for older versions of Socket.pm (only relevant on older perls)
	it depends on Win32::Process. Since we are talking about integrating with
	5.9, this should not be an issue.

* Archive::Tar [NEW]
	To ensure that extraction of modules from CPAN can happen in a predictable
	and portable way, the best thing is to include Archive::Tar in the core as
	well. A::T is a pure perl implementation of tar, which works portably
	across all the platforms it got tested on:
		http://testers.cpan.org/show/Archive-Tar.html

	tar programs are alas not always 'standard' -- not in their options, and
	not in their output. Since CPANPLUS needs to know what files got extracted
	(and more importantly /where/), it needs to parse the output of 
	various
	tar programs to identify these files and locations. On gnu-tars (or gnu-
	compliant ones) this works without fail, but old solaris tars and various
	AIX and third party tars as found on Win32 have their own idea of specs.
	To ensure that CPANPLUS will not fail regression tests due to these flaky
	tar implementations, including Archive::Tar is the safe bet.

	Archive::Tar requires IO::String, which has no more prerequisites, 
	and a
	perfect test result:
		http://testers.cpan.org/show/IO-String.html

	Archive::Tar optionally supports compressed tarballs via IO::Zlib, which
	in turn requires Compress::Zlib or an external gzip binary. CPANPLUS
	requires IO::Zlib to work with the compressed files of CPAN.
	For the same reasons as A::T, the external binary should be avoided,
	and C::Zlib adopted. IO::Zlib itself also has good tests results, 
	both
	tested by itself and Archive::Tar:
		http://testers.cpan.org/show/IO-Zlib.html

	Compress::Zlib is self contained (meaning it bundles all the header files
	required to build) and libz is known to build on at least all the platforms
	perl builds on, but probably more. Currently, there are 2 types of 
	test
	failures reported here:
		http://testers.cpan.org/show/Compress-Zlib.html

		One on Win32 when the build dir has spaces in it, which 
		seems to be a
		test (not code!) bug.
		One on darwin/5.6.0, but since we'll bundle with 5.9, that's 
		not really
		a relevant issue.
	
	An alternative is the pure perl version of Compress::Zlib, aptly 
	named
	Compress::Zlib::Perl -- IO::Zlib would need to be patched to support it,
	but it seems otherwise a viable alternative:
		http://testers.cpan.org/show/Compress-Zlib-Perl.html

* Abstracted out modules from CPANPLUS 0.04x
	Quite a bit of code from CPANPLUS 0.04x got abstracted out into seperate
	(CPAN) modules, to promote code-reuse. This makes the CPANPLUS to be
	integrated quite a bit slimmer, but requires these abstracted out modules
	to be included as well.
	They are all pure-perl are known to work on all platforms except for the
	cases described above. Here's the list:

		* Archive::Extract
			http://testers.cpan.org/show/Archive-Extract.html
		* File::Fetch
			http://testers.cpan.org/show/File-Fetch.html
		* IPC::Cmd
			http://testers.cpan.org/show/IPC-Cmd.html
		* Log::Message
			http://testers.cpan.org/show/Log-Message.html
		* Module::Load
			http://testers.cpan.org/show/Module-Load.html	 * Module::Load::Conditional
			http://testers.cpan.org/show/Module-Load-Conditional.html		* 
Object::Accessor
			http://testers.cpan.org/show/Object-Accessor.html
		* Params::Check
			http://testers.cpan.org/show/Params-Check.html
		* Term::UI
			http://testers.cpan.org/show/Term-UI.html
		* Locale::Maketext::Simple
			http://testers.cpan.org/show/Locale-Maketext-Simple.html


All these modules should be fairly easy to integrate and they are all 
quite small in size. I'm hereby volunteering to (also) integrate the 
modules marked with [NEW], if we can agree this is the way forward :)

Note that where there's a warning about CPANPLUS not working properly, 
we're likely to get reports of failing perl builds on those systems if 
the module is
not included, as CPANPLUS' regression tests do test for these things 
(as opposed to CPAN.pm's tests)

--

Jos Boumans

	"If superman is so smart, why does he wear underpants over his 
	trousers?"

	CPANPLUS	http://cpanplus.sf.net

[1] but that's a discussion for another time; suffice to say that this our
	attempt at making 'NAPC' come true.

----- End forwarded message -----
----------- следующая часть -----------
Было удалено вложение не в текстовом формате...
Имя     : =?iso-8859-1?q?=CF=D4=D3=D5=D4=D3=D4=D7=D5=C5=D4?=
Тип     : application/pgp-signature
Размер  : 189 байтов
Описание: =?iso-8859-1?q?=CF=D4=D3=D5=D4=D3=D4=D7=D5=C5=D4?=
Url     : <http://lists.altlinux.org/pipermail/devel/attachments/20050120/f8b58a44/attachment-0001.bin>


Подробная информация о списке рассылки Devel