ExtUtils-Depends-0.405/000755 001750 000024 00000000000 12627070170 015760 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/Changes000644 001750 000024 00000012743 12627070101 017254 0ustar00bdmanningstaff000000 000000 Revision history for Perl extension ExtUtils::Depends. 0.405 - Remove MYMETA.* from MANIFEST file; closes autogenerated RT ticket #108554 0.404 - Depends.pm: sort deps in save_config() and get_makefile_vars(); patch submitted by Debian's reproducible build team for RT#101602 - Use / to make ::load filename, not File::Spec - perldoc -f require 0.403 - Avoid using Test::More::done_testing() for to support building out-of-the-box on older perls. 0.402 Sat Oct 18 18:06:19 EEST 2014 - Set Data::Dumper::Sortkeys = 1 in ExtUtils::Depends->save_config(); patch submitted by Niko Tyni of the Debian Perl Group; fixes RT#99260 0.401 Sat Aug 23 14:20:11 IRKT 2014 - Add README changes created by 'make dist' from the POD - Rename test modules - Test old/new schemes with .pm files - Move old/new scheme tests from middle of other stuff to end - Rename test packages to 8.3 unique 0.400 Sun Aug 10 13:58:24 CEST 2014 - In addition to the package variables $inc, $libs and @typemaps, write an 'Inline' method to ::Install::Files for easier interoperability with the Inline module. - Accompany the 'Inline' method with a 'deps' method in ::Install::Files in addition to the @deps package variable. - Make ExtUtils::Depends->load use the 'Inline' and 'deps' methods by default, falling back to the package variables if the methods are not defined. - Make the docs recommend the 'Inline' and 'deps' approach for creating ::Install::Files manually, without ExtUtils::Depends::save_config. 0.309 Sat Aug 2 15:23:03 PDT 2014 - Depends.pm: use $DLEXT instead of $SO for library filename extensions - MANIFEST: remove MYMETA.* files - use DynaLoader::mod2fname if available - Added Android support 0.308 Sun May 18 16:22:11 PDT 2014 - Fix win32 test failure in t/02_save_load.t (closes RT#95301) 0.307 Mon Apr 28 22:04:38 PDT 2014 - $Data::Dumper::Terse set to 1 broke save_config - Document API expected by ::load function 0.306 Mon Sep 28 22:04:38 PDT 2013 - Fixed typo in RT queue URL; fixes RT#88960 0.305 Mon Sep 2 14:16:58 PDT 2013 - Makefile.PL: converted to CPAN::Meta::Spec v2 - Updated license in RPM spec file; closes RT#88196 - Updated contact info and added git repo info to POD - Add comments for find_extra_libs method (closes RT#43900) - Fixed typo (closes RT#86572) 0.304 Wed Jan 26 08:48:18 CET 2011 - More robust detection of gcc toolchains on Win32 (Closes: RT#62455) (sisyphus). - Don't assume dlltool is called 'dlltool' on Win32+gcc. Ask Config.pm instead (Closes: RT#62455) (sisyphus). 0.303 Mon Nov 29 19:42:59 CET 2010 - Fix a race condition when running the tests in parallel. 0.302 Sat Jul 4 15:28:35 CEST 2009 - Create import libraries if necessary to fix linking when gcc is used on MSWin32 (Strawberry Perl, for example). 0.301 Sat Sep 6 20:11:01 CEST 2008 - On Cygwin, link directly against the DLLs of dependencies. Patch by Yaakov. - Require perl 5.6.0. 0.300 Sun Mar 30 17:35:35 CEST 2008 - On MSWin32 and cygwin, find the link libraries of dependencies and put them into LIBS. - Add tests. - Correct typos in the documentation. - In get_makefile_vars, comment out the code that put the installed libraries into @OBJECT, which caused them to get deleted on realclean. - In Makefile.PL, don't use the bogus package "MAIN". - Remove debug spew. 0.205 Sun Jan 23 13:20:14 EST 2005 - Disable the RPM-related postamble on Win32. The 'date' command on windows is interactive, and caused Makefile.PL to hang. 0.204 Sun Sep 19 23:26:23 CEST 2004 - Use capitals at the start of everything that is printed out, to unify Makefile.PL output. 0.203 Fri Mar 12 16:09:35 EST 2004 - don't output a PM pair from get_makefile_vars unless we actually have data in the pm key. 0.202 Fri Mar 5 00:26:18 EST 2004 - add long-overdue version-checking import implementation. - fixed a bad initial value bug that caused crashes if your setup did not need a call to set_libs. [Ross] - distribute the spec file. [Ross] 0.201 Thu Feb 12 15:33:47 EST 2004 - add_headers() is now deprecated. it's functionality is provided by install(), and it is already a no-op in 0.200. - remove code referring to @headers, since we don't actually keep a separate list of headers anymore. (should we?) - load() no longer returns the "header" key -- it should've been "headers", but i've simply removed all that code. 0.200 Tue Feb 10 01:21:57 EST 2004 - completely rewritten. attempted to retain backward compatibility, but some esoteric functionality is probably missing. now stores dependency lists, so that module chaining is more useful. - document just about everything. - really, really, really needs a regression test suite. 0.104 Fri Nov 21 01:34:57 EST 2003 - remove debian packaging files - add licensing terms to pod. Depends was originally part of gtk-perl, which itself bore this copyright notice. 0.103 Fri Aug 15 09:59:42 EDT 2003 - add files for maintaining debian packages. 0.102 Tue Jul 8 14:10:29 EDT 2003 - use File::Spec->file_name_is_absolute instead of non-portable m{^/}. still uses direct string manipulation on paths, but this fix lets the module function correctly under native Win32 perl. 0.101 Fri Jun 20 23:37:19 CEST 2003 - added primitive load-only testsuite. 0.1 Thu Jun 19 01:29:25 CEST 2003 - original version; created by extracting it from glib. ExtUtils-Depends-0.405/lib/000755 001750 000024 00000000000 12627070170 016526 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/Makefile.PL000644 001750 000024 00000006406 12446204413 017736 0ustar00bdmanningstaff000000 000000 #!/usr/bin/perl # We require 5.6 for sanity in general, and for 'our' in particular. use 5.006; use ExtUtils::MakeMaker; my %prereqs = ( 'File::Spec' => 0, 'Data::Dumper' => 0, 'IO::File' => 0, ); my %meta_merge = ( q(meta-spec) => { version => '2', url => 'http://search.cpan.org/perldoc?CPAN::Meta::Spec', }, author => ['Gtk2-Perl Team '], release_status => 'stable', # valid values: https://metacpan.org/module/CPAN::Meta::Spec#license license => 'perl_5', resources => { license => 'http://dev.perl.org/licenses/', homepage => 'http://gtk2-perl.sourceforge.net', x_MailingList => 'https://mail.gnome.org/mailman/listinfo/gtk-perl-list', bugtracker => { web => 'http://rt.cpan.org/Public/Dist/Display.html?Name=ExtUtils-Depends', mailto => 'bug-ExtUtils-Depends [at] rt.cpan.org', }, repository => { url => 'git://git.gnome.org/perl-ExtUtils-Depends', type => 'git', web => 'http://git.gnome.org/browse/perl-ExtUtils-Depends', }, }, prereqs => { configure => { requires => {%prereqs}, # no direct ref for 5.14 compatibility }, build => { requires => { 'Test::More' => 0, }, }, test => { recommends => { 'Test::Number::Delta' => 1.0, }, }, }, keywords => ['XS', 'XS extensions', 'dependency'], no_index => { package => 'ExtUtils::MM', }, ); WriteMakefile( dist => { $^O eq 'MSWin32' ? () : (PREOP => 'pod2text lib/ExtUtils/Depends.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;'), COMPRESS => 'gzip -9v', SUFFIX => '.gz', }, NAME => 'ExtUtils::Depends', VERSION_FROM => 'lib/ExtUtils/Depends.pm', PREREQ_PM => \%prereqs, MIN_PERL_VERSION => 5.006, #for META.yml META_MERGE => \%meta_merge, LICENSE => 'perl', ); use Cwd; sub MY::postamble { # none of this rpm stuff is useful on win32, and actually it can cause # nmake to barf. return @_ if $^O eq 'MSWin32'; my @dirs = qw{$(RPMS_DIR) $(RPMS_DIR)/BUILD $(RPMS_DIR)/RPMS $(RPMS_DIR)/SOURCES $(RPMS_DIR)/SPECS $(RPMS_DIR)/SRPMS}; my $cwd = getcwd(); chomp (my $date = `date +"%a %b %d %Y"`); my %subs = ( 'VERSION' => '$(VERSION)', 'SOURCE' => '$(DISTNAME)-$(VERSION).tar.gz', 'DATE' => $date, ); my $substitute = '$(PERL) -npe \''.join('; ', map { "s/\\\@$_\\\@/$subs{$_}/g"; } keys %subs).'\''; " realclean :: -\$(RM_F) perl-\$(DISTNAME).spec RPMS_DIR=\$(HOME)/rpms \$(RPMS_DIR)/: -mkdir @dirs SUBSTITUTE=$substitute perl-\$(DISTNAME).spec :: perl-\$(DISTNAME).spec.in \$(VERSION_FROM) Makefile \$(SUBSTITUTE) \$< > \$@ dist-rpms :: Makefile dist perl-\$(DISTNAME).spec \$(RPMS_DIR)/ cp \$(DISTNAME)-\$(VERSION).tar.gz \$(RPMS_DIR)/SOURCES/ rpmbuild -ba --define \"_topdir \$(RPMS_DIR)\" perl-\$(DISTNAME).spec dist-srpms :: Makefile dist perl-\$(DISTNAME).spec \$(RPMS_DIR)/ cp \$(DISTNAME)-\$(VERSION).tar.gz \$(RPMS_DIR)/SOURCES/ rpmbuild -bs --define \"_topdir \$(RPMS_DIR)\" perl-\$(DISTNAME).spec " } ExtUtils-Depends-0.405/MANIFEST000644 001750 000024 00000001133 12627070170 017107 0ustar00bdmanningstaff000000 000000 Changes lib/ExtUtils/Depends.pm Makefile.PL MANIFEST This list of files MANIFEST.SKIP perl-ExtUtils-Depends.spec.in README t/01_load.t t/02_save_load.t t/03_deps.t t/04_extra_libs.t t/inc/DepTest/DepTest.dll t/inc/DepTest/DepTest.lib t/inc/DepTest/Install/.keep t/inc/DepTest/libDepTest.dll.a t/inc/DepTest/PL_DepTest.dll t/inc/DepTest/PL_DepTest.lib t/inc/DepTest/PL_DepTest.so t/inc/DepTest/PL_libDepTest.dll.a t/lib/TestHelper.pm META.yml Module YAML meta-data (added by MakeMaker) META.json Module JSON meta-data (added by MakeMaker) ExtUtils-Depends-0.405/MANIFEST.SKIP000644 001750 000024 00000000125 12627070146 017657 0ustar00bdmanningstaff000000 000000 ^blib ^MAINTAINERS$ ^Makefile$ ^pm_to_blib$ ^\.git \.doap$ ^MANIFEST\.bak$ ^MYMETA.* ExtUtils-Depends-0.405/META.json000644 001750 000024 00000003607 12627070170 017407 0ustar00bdmanningstaff000000 000000 { "abstract" : "unknown", "author" : [ "Gtk2-Perl Team " ], "dynamic_config" : 1, "generated_by" : "ExtUtils::MakeMaker version 7.04, CPAN::Meta::Converter version 2.150001", "keywords" : [ "XS", "XS extensions", "dependency" ], "license" : [ "perl_5" ], "meta-spec" : { "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec", "version" : "2" }, "name" : "ExtUtils-Depends", "no_index" : { "directory" : [ "t", "inc" ], "package" : [ "ExtUtils::MM" ] }, "prereqs" : { "build" : { "requires" : { "ExtUtils::MakeMaker" : "0", "Test::More" : "0" } }, "configure" : { "requires" : { "Data::Dumper" : "0", "ExtUtils::MakeMaker" : "0", "File::Spec" : "0", "IO::File" : "0" } }, "runtime" : { "requires" : { "Data::Dumper" : "0", "File::Spec" : "0", "IO::File" : "0", "perl" : "5.006" } }, "test" : { "recommends" : { "Test::Number::Delta" : "1" } } }, "release_status" : "stable", "resources" : { "bugtracker" : { "mailto" : "bug-ExtUtils-Depends [at] rt.cpan.org", "web" : "http://rt.cpan.org/Public/Dist/Display.html?Name=ExtUtils-Depends" }, "homepage" : "http://gtk2-perl.sourceforge.net", "license" : [ "http://dev.perl.org/licenses/" ], "repository" : { "type" : "git", "url" : "git://git.gnome.org/perl-ExtUtils-Depends", "web" : "http://git.gnome.org/browse/perl-ExtUtils-Depends" }, "x_MailingList" : "https://mail.gnome.org/mailman/listinfo/gtk-perl-list" }, "version" : "0.405" } ExtUtils-Depends-0.405/META.yml000644 001750 000024 00000001753 12627070170 017237 0ustar00bdmanningstaff000000 000000 --- abstract: unknown author: - 'Gtk2-Perl Team ' build_requires: ExtUtils::MakeMaker: '0' Test::More: '0' configure_requires: Data::Dumper: '0' ExtUtils::MakeMaker: '0' File::Spec: '0' IO::File: '0' dynamic_config: 1 generated_by: 'ExtUtils::MakeMaker version 7.04, CPAN::Meta::Converter version 2.150001' keywords: - XS - 'XS extensions' - dependency license: perl meta-spec: url: http://module-build.sourceforge.net/META-spec-v1.4.html version: '1.4' name: ExtUtils-Depends no_index: directory: - t - inc package: - ExtUtils::MM requires: Data::Dumper: '0' File::Spec: '0' IO::File: '0' perl: '5.006' resources: MailingList: https://mail.gnome.org/mailman/listinfo/gtk-perl-list bugtracker: http://rt.cpan.org/Public/Dist/Display.html?Name=ExtUtils-Depends homepage: http://gtk2-perl.sourceforge.net license: http://dev.perl.org/licenses/ repository: git://git.gnome.org/perl-ExtUtils-Depends version: '0.405' ExtUtils-Depends-0.405/perl-ExtUtils-Depends.spec.in000644 001750 000024 00000003031 12221715315 023334 0ustar00bdmanningstaff000000 000000 Summary: ExtUtils-Depends Perl module Name: perl-ExtUtils-Depends Version: @VERSION@ Release: 1 Packager: gtk-perl-list@gnome.org License: Perl Group: Development/Tools URL: http://search.cpan.org/dist/ExtUtils-Depends/ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildArch: noarch BuildRequires: perl >= 2:5.8.0 Source0: @SOURCE@ %description This module tries to make it easy to build Perl extensions that use functions and typemaps provided by other perl extensions. This means that a perl extension is treated like a shared library that provides also a C and an XS interface besides the perl one. This works as long as the base extension is loaded with the RTLD_GLOBAL flag (usually done with a sub dl_load_flags {0x01} in the main .pm file) if you need to use functions defined in the module. %prep %setup -q -n ExtUtils-Depends-%{version} %build CFLAGS="$RPM_OPT_FLAGS" perl Makefile.PL PREFIX=$RPM_BUILD_ROOT%{_prefix} make OPTIMIZE="$RPM_OPT_FLAGS" make test %install %makeinstall [ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress find $RPM_BUILD_ROOT \( -name perllocal.pod -o -name .packlist \) -exec rm -v {} \; find $RPM_BUILD_ROOT/usr -type f -print | \ sed "s@^$RPM_BUILD_ROOT@@g" | \ grep -v perllocal.pod | \ grep -v "\.packlist" > %{name}-%{version}-filelist if [ "$(cat %{name}-%{version}-filelist)X" = "X" ] ; then exit -1 fi %clean rm -rf $RPM_BUILD_ROOT %files -f %{name}-%{version}-filelist %defattr(-,root,root) %changelog * @DATE@ gtk-perl-list@gnome.org - @VERSION@ - Specfile autogenerated. ExtUtils-Depends-0.405/README000644 001750 000024 00000021477 12627070170 016653 0ustar00bdmanningstaff000000 000000 NAME ExtUtils::Depends - Easily build XS extensions that depend on XS extensions SYNOPSIS use ExtUtils::Depends; $package = new ExtUtils::Depends ('pkg::name', 'base::package') # set the flags and libraries to compile and link the module $package->set_inc("-I/opt/blahblah"); $package->set_libs("-lmylib"); # add a .c and an .xs file to compile $package->add_c('code.c'); $package->add_xs('module-code.xs'); # add the typemaps to use $package->add_typemaps("typemap"); # install some extra data files and headers $package->install (qw/foo.h data.txt/); # save the info $package->save_config('Files.pm'); WriteMakefile( 'NAME' => 'Mymodule', $package->get_makefile_vars() ); DESCRIPTION This module tries to make it easy to build Perl extensions that use functions and typemaps provided by other perl extensions. This means that a perl extension is treated like a shared library that provides also a C and an XS interface besides the perl one. This works as long as the base extension is loaded with the RTLD_GLOBAL flag (usually done with a sub dl_load_flags {0x01} in the main .pm file) if you need to use functions defined in the module. The basic scheme of operation is to collect information about a module in the instance, and then store that data in the Perl library where it may be retrieved later. The object can also reformat this information into the data structures required by ExtUtils::MakeMaker's WriteMakefile function. For information on how to make your module fit into this scheme, see "hashref = ExtUtils::Depends::load (name)". When creating a new Depends object, you give it a name, which is the name of the module you are building. You can also specify the names of modules on which this module depends. These dependencies will be loaded automatically, and their typemaps, header files, etc merged with your new object's stuff. When you store the data for your object, the list of dependencies are stored with it, so that another module depending on your needn't know on exactly which modules yours depends. For example: Gtk2 depends on Glib Gnome2::Canvas depends on Gtk2 ExtUtils::Depends->new ('Gnome2::Canvas', 'Gtk2'); this command automatically brings in all the stuff needed for Glib, since Gtk2 depends on it. When the configuration information is saved, it also includes a class method called "Inline", inheritable by your module. This allows you in your module to simply say at the top: package Mymod; use parent 'Mymod::Install::Files'; # to inherit 'Inline' method And users of "Mymod" who want to write inline code (using Inline) will simply be able to write: use Inline with => 'Mymod'; And all the necessary header files, defines, and libraries will be added for them. The "Mymod::Install::Files" will also implement a "deps" method, which will return a list of any modules that "Mymod" depends on - you will not normally need to use this: require Mymod::Install::Files; @deps = Mymod::Install::Files->deps; METHODS $object = ExtUtils::Depends->new($name, @deps) Create a new depends object named *$name*. Any modules listed in *@deps* (which may be empty) are added as dependencies and their dependency information is loaded. An exception is raised if any dependency information cannot be loaded. $depends->add_deps (@deps) Add modules listed in *@deps* as dependencies. (hashes) = $depends->get_deps Fetch information on the dependencies of *$depends* as a hash of hashes, which are dependency information indexed by module name. See "load". $depends->set_inc (@newinc) Add strings to the includes or cflags variables. $depends->set_libs (@newlibs) Add strings to the libs (linker flags) variable. $depends->add_pm (%pm_files) Add files to the hash to be passed through ExtUtils::WriteMakefile's PM key. $depends->add_xs (@xs_files) Add xs files to be compiled. $depends->add_c (@c_files) Add C files to be compiled. $depends->add_typemaps (@typemaps) Add typemap files to be used and installed. $depends->add_headers (list) No-op, for backward compatibility. $depends->install (@files) Install *@files* to the data directory for *$depends*. This actually works by adding them to the hash of pm files that gets passed through WriteMakefile's PM key. $depends->save_config ($filename) Save the important information from *$depends* to *$filename*, and set it up to be installed as *name*::Install::Files. Note: the actual value of *$filename* is unimportant so long as it doesn't clash with any other local files. It will be installed as *name*::Install::Files. hash = $depends->get_makefile_vars Return the information in *$depends* in a format digestible by WriteMakefile. This sets at least the following keys: INC LIBS TYPEMAPS PM And these if there is data to fill them: clean OBJECT XS hashref = ExtUtils::Depends::load (name) Load and return dependency information for *name*. Croaks if no such information can be found. The information is returned as an anonymous hash containing these keys: instpath The absolute path to the data install directory for this module. typemaps List of absolute pathnames for this module's typemap files. inc CFLAGS string for this module. libs LIBS string for this module. deps List of modules on which this one depends. This key will not exist when loading files created by old versions of ExtUtils::Depends. If you want to make module *name* support this, you must provide a module *name*::Install::Files, which on loading will implement the following class methods: $hashref = name::Install::Files->Inline('C'); # hash to contain any necessary TYPEMAPS (array-ref), LIBS, INC @deps = name::Install::Files->deps; # any modules on which "name" depends An easy way to achieve this is to use the method "$depends->save_config ($filename)", but your package may have different facilities already. $depends->load_deps Load *$depends* dependencies, by calling "load" on each dependency module. This is usually done for you, and should only be needed if you want to call "get_deps" after calling "add_deps" manually. SUPPORT Bugs/Feature Requests Version 0.2 discards some of the more esoteric features provided by the older versions. As they were completely undocumented, and this module has yet to reach 1.0, this may not exactly be a bug. This module is tightly coupled to the ExtUtils::MakeMaker architecture. You can submit new bugs/feature requests by using one of two bug trackers (below). CPAN Request Tracker You can submit bugs/feature requests via the web by going to (requires PAUSE ID or Bitcard), or by sending an e-mail to "bug-ExtUtils-Depends at rt.cpan.org". Gnome.org Bugzilla Report bugs/feature requests to the 'gnome-perl' product (requires login) Patches that implement new features with test cases, and/or test cases that exercise existing bugs are always welcome. The Gtk-Perl mailing list is at "gtk-perl-list at gnome dot org". Source Code The source code to ExtUtils::Depends is available at the Gnome.org Git repo (). Create your own copy of the Git repo with: git clone git://git.gnome.org/perl-ExtUtils-Depends (Git protocol) git clone https://git.gnome.org/browse/perl-ExtUtils-Depends/ (HTTPS) SEE ALSO ExtUtils::MakeMaker. AUTHOR Paolo Molaro wrote the original version for Gtk-Perl. muppet rewrote the innards for version 0.2, borrowing liberally from Paolo's code. MAINTAINER The Gtk2 project, /"gtk-perl-list at gnome dot org". LICENSE This library is free software; you may redistribute it and/or modify it under the same terms as Perl itself. ExtUtils-Depends-0.405/t/000755 001750 000024 00000000000 12627070170 016223 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/01_load.t000644 001750 000024 00000000144 11664366503 017636 0ustar00bdmanningstaff000000 000000 #!/usr/bin/perl use strict; use warnings; use Test::More tests => 1; use_ok ('ExtUtils::Depends'); ExtUtils-Depends-0.405/t/02_save_load.t000644 001750 000024 00000011300 12462351277 020650 0ustar00bdmanningstaff000000 000000 #!/usr/bin/perl use strict; use warnings; use Test::More tests => 40; use FindBin; use lib "$FindBin::Bin/lib"; use TestHelper; use File::Path 'mkpath'; use File::Spec::Functions 'catdir'; use ExtUtils::Depends; my $tmp_inc = temp_inc; my $dep_info = ExtUtils::Depends->new ('DepTest'); my $inc = '-Iinclude -I/usr/local/include -W -Wall -Werror -ansi'; $dep_info->set_inc ($inc); my $libs = '-L/usr/local/lib -lfoobar'; $dep_info->set_libs ($libs); my %pm_mapping = ('DepTest.pm' => 'build/DepTest.pm', 'DepTest/Helper.pm' => 'build/DepTest/Helper.pm'); $dep_info->add_pm (%pm_mapping); my @xs_files = qw(DepTestFoo.xs DepTestBar.xs); $dep_info->add_xs (@xs_files); my @c_files = qw(dep-test-foo.c dep-test-bar.c); $dep_info->add_c (@c_files); my @typemaps = qw(build/foo.typemap build/bar.typemap); $dep_info->add_typemaps (@typemaps); my @installed_files = qw(dep.h dep-private.h); $dep_info->install (@installed_files); use Data::Dumper; $Data::Dumper::Terse = 1; my $IFpm = catfile $tmp_inc, qw(DepTest Install Files.pm); $dep_info->save_config ($IFpm); # ensure '/' used for config filename in require, not File::Spec open my $iffh, '>>', $IFpm or die "write $IFpm: $!"; print $iffh qq{\nwarn "LOADING\\n";\n1;\n}; undef $iffh; # --------------------------------------------------------------------------- # my %vars = $dep_info->get_makefile_vars; is_deeply ($vars{TYPEMAPS}, \@typemaps, 'makefile vars typemaps'); is ($vars{INC}, $inc, 'makefile vars inc'); is ($vars{LIBS}, $libs, 'makefile vars libs'); foreach my $pm (keys %pm_mapping) { like ($vars{PM}{$pm}, qr/\Q$pm_mapping{$pm}\E/, 'makefile vars PM'); } ok (exists $vars{PM}{catfile $tmp_inc, qw(DepTest Install Files.pm)}, 'PM'); foreach my $file (@installed_files) { like ($vars{PM}{$file}, qr/\Q$file\E/, "PM $file"); } foreach my $xs_file (@xs_files) { ok (exists $vars{XS}{$xs_file}, "XS $xs_file"); } foreach my $file (@c_files, @xs_files) { (my $stem = $file) =~ s/\.(?:c|xs)\z//; like ($vars{OBJECT}, qr/\Q$stem\E/, "OBJECT $stem"); like ($vars{clean}{FILES}, qr/\Q$stem\E/, "FILES $stem"); } # --------------------------------------------------------------------------- # my $info; { my $warning = ''; local $SIG{__WARN__} = sub { $warning .= join '', @_; }; $info = ExtUtils::Depends::load ('DepTest'); like $warning, qr/LOADING/, 'loaded once'; $warning = ''; require DepTest::Install::Files; unlike $warning, qr/LOADING/, 'not loaded twice'; } my $install_part = qr|DepTest.Install|; like ($info->{inc}, $install_part, "loaded inc"); isnt (index($info->{inc}, $inc), -1, "loaded inc content"); my @typemaps_expected = map { my $t = $_; $t =~ s#build/##; $t } @typemaps; sub strip_typemap { my $t = $_; my $tmp = catfile('DepTest','Install',' '); $tmp =~ s# $##; $t =~ s#.*\Q$tmp\E##; $t } is_deeply ( [ map { strip_typemap($_) } @{$info->{typemaps}} ], \@typemaps_expected, 'check typemaps actually saved/loaded' ); like ($info->{instpath}, $install_part, 'instpath'); is_deeply ($info->{deps}, [], 'basic deps'); is ($info->{libs}, $libs, 'basic libs'); # now check package vars are set, per the ::load doc! { no warnings qw(once); is ($DepTest::Install::Files::inc, $inc, 'package inc'); is_deeply ( [ map { strip_typemap($_) } @DepTest::Install::Files::typemaps ], \@typemaps_expected, 'package typemaps' ); is_deeply (\@DepTest::Install::Files::deps, [], 'package deps'); is ($DepTest::Install::Files::libs, $libs, 'package libs'); } # test Inline class methods is_deeply ( DepTest::Install::Files->Inline('C'), { INC => $inc, LIBS => $libs, TYPEMAPS => \@typemaps_expected, }, 'api check Inline method' ); is_deeply ([ DepTest::Install::Files->deps ], [], 'api check deps method'); # --------------------------------------------------------------------------- # my $INC_FRAG = '-Ddistinctive'; make_test_pkg('PSnew', < '$INC_FRAG' } } sub deps { qw(PSold) } EOF make_test_pkg('PSold', "\@deps = qw(PSnew); \$inc = '$INC_FRAG';"); sub make_test_pkg { my ($base, $text) = @_; my $dir = catdir($tmp_inc, $base, qw(Install)); mkpath($dir, 0, 0711); local *FH; open FH, '>', catfile($dir, 'Files.pm'); print FH sprintf "package %s;\n%s\n1;\n", $base . '::Install::Files', $text; close FH; } sub test_load { my ($info, $msg) = @_; my $install_part = qr|PS.*Install|; like ($info->{inc}, $install_part, "$msg inc generic"); like ($info->{inc}, qr/$INC_FRAG/, "$msg inc specific"); ok (scalar(grep { /PS/ } @{$info->{deps}}), $msg); ok (exists $info->{libs}, $msg); } test_load (ExtUtils::Depends::load('PSnew'), 'load new scheme'); test_load (ExtUtils::Depends::load('PSold'), 'load old scheme'); ExtUtils-Depends-0.405/t/03_deps.t000644 001750 000024 00000001450 11664366503 017655 0ustar00bdmanningstaff000000 000000 #!/usr/bin/perl use strict; use warnings; use Test::More tests => 2; use FindBin; use lib "$FindBin::Bin/lib"; use TestHelper; use ExtUtils::Depends; my $tmp_inc = temp_inc; my $dep_info = ExtUtils::Depends->new ('DepTest'); $dep_info->save_config (catfile $tmp_inc, qw(DepTest Install Files.pm)); # --------------------------------------------------------------------------- # my $info = ExtUtils::Depends->new ('UseTest', 'DepTest'); my %deps = $info->get_deps; ok (exists $deps{DepTest}); # --------------------------------------------------------------------------- # $info = ExtUtils::Depends->new ('UseTest'); $info->add_deps ('DepTest'); $info->load_deps; %deps = $info->get_deps; ok (exists $deps{DepTest}); # --------------------------------------------------------------------------- # ExtUtils-Depends-0.405/t/04_extra_libs.t000644 001750 000024 00000001601 12435270223 021043 0ustar00bdmanningstaff000000 000000 #!/usr/bin/perl use strict; use warnings; use Test::More; use FindBin; use lib "$FindBin::Bin/lib"; use TestHelper; use ExtUtils::Depends; my $tmp_inc = temp_inc; plan (($^O eq 'MSWin32' || $^O eq 'cygwin' || $^O eq 'android') ? (tests => 1) : (skip_all => "test only for 'MSWin32', 'cygwin', and 'android'")); my $dep_info = ExtUtils::Depends->new ('DepTest'); $dep_info->save_config (catfile $tmp_inc, qw(DepTest Install Files.pm)); # --------------------------------------------------------------------------- # my $use_info = ExtUtils::Depends->new ('UseTest', 'DepTest'); my %vars = $use_info->get_makefile_vars; my $libname = 'DepTest'; require DynaLoader; $libname = DynaLoader::mod2fname([$libname]) if defined &DynaLoader::mod2fname; like ($vars{LIBS}, qr/$libname/); # --------------------------------------------------------------------------- # ExtUtils-Depends-0.405/t/inc/000755 001750 000024 00000000000 12627070170 016774 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/lib/000755 001750 000024 00000000000 12627070170 016771 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/lib/TestHelper.pm000644 001750 000024 00000000570 11664366503 021420 0ustar00bdmanningstaff000000 000000 use strict; use warnings; package TestHelper; use File::Temp 'tempdir'; use File::Path 'mkpath'; use File::Spec::Functions 'catdir', 'catfile'; use base 'Exporter'; our @EXPORT = ('temp_inc', 'catfile'); sub temp_inc { my $tmpinc = tempdir(CLEANUP => 1); mkpath(catdir($tmpinc, qw(DepTest Install)), 0, 0711); unshift @INC, $tmpinc; return $tmpinc; } 1; ExtUtils-Depends-0.405/t/inc/DepTest/000755 001750 000024 00000000000 12627070170 020344 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/DepTest.dll000644 001750 000024 00000000000 11664366503 022407 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/DepTest.lib000644 001750 000024 00000000000 11664366503 022402 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/Install/000755 001750 000024 00000000000 12627070170 021752 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/libDepTest.dll.a000644 001750 000024 00000000000 11664366503 023315 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/PL_DepTest.dll000644 001750 000024 00000000000 12435270223 022770 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/PL_DepTest.lib000644 001750 000024 00000000000 12435270223 022763 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/PL_DepTest.so000644 001750 000024 00000000000 12435270223 022636 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/PL_libDepTest.dll.a000644 001750 000024 00000000000 12435270223 023676 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/t/inc/DepTest/Install/.keep000644 001750 000024 00000000000 11664366503 022675 0ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/lib/ExtUtils/000755 001750 000024 00000000000 12627070170 020307 5ustar00bdmanningstaff000000 000000 ExtUtils-Depends-0.405/lib/ExtUtils/Depends.pm000644 001750 000024 00000044070 12627067656 022253 0ustar00bdmanningstaff000000 000000 # # $Id$ # package ExtUtils::Depends; use strict; use warnings; use Carp; use Config; use File::Find; use File::Spec; use Data::Dumper; our $VERSION = '0.405'; sub import { my $class = shift; return unless @_; die "$class version $_[0] is required--this is only version $VERSION" if $VERSION < $_[0]; } sub new { my ($class, $name, @deps) = @_; my $self = bless { name => $name, deps => {}, inc => [], libs => '', pm => {}, typemaps => [], xs => [], c => [], }, $class; $self->add_deps (@deps); # attempt to load these now, so we'll find out as soon as possible # whether the dependencies are valid. we'll load them again in # get_makefile_vars to catch any added between now and then. $self->load_deps; return $self; } sub add_deps { my $self = shift; foreach my $d (@_) { $self->{deps}{$d} = undef unless $self->{deps}{$d}; } } sub get_deps { my $self = shift; $self->load_deps; # just in case return %{$self->{deps}}; } sub set_inc { my $self = shift; push @{ $self->{inc} }, @_; } sub set_libs { my ($self, $newlibs) = @_; $self->{libs} = $newlibs; } sub add_pm { my ($self, %pm) = @_; while (my ($key, $value) = each %pm) { $self->{pm}{$key} = $value; } } sub _listkey_add_list { my ($self, $key, @list) = @_; $self->{$key} = [] unless $self->{$key}; push @{ $self->{$key} }, @list; } sub add_xs { shift->_listkey_add_list ('xs', @_) } sub add_c { shift->_listkey_add_list ('c', @_) } sub add_typemaps { my $self = shift; $self->_listkey_add_list ('typemaps', @_); $self->install (@_); } # no-op, only used for source back-compat sub add_headers { carp "add_headers() is a no-op" } ####### PRIVATE sub basename { (File::Spec->splitdir ($_[0]))[-1] } # get the name in Makefile syntax. sub installed_filename { my $self = shift; return '$(INST_ARCHLIB)/$(FULLEXT)/Install/'.basename ($_[0]); } sub install { # install things by adding them to the hash of pm files that gets # passed through WriteMakefile's PM key. my $self = shift; foreach my $f (@_) { $self->add_pm ($f, $self->installed_filename ($f)); } } sub save_config { use Data::Dumper; local $Data::Dumper::Terse = 0; local $Data::Dumper::Sortkeys = 1; use IO::File; my ($self, $filename) = @_; my $file = IO::File->new (">".$filename) or croak "can't open '$filename' for writing: $!\n"; print $file "package $self->{name}\::Install::Files;\n\n"; print $file "".Data::Dumper->Dump([{ inc => join (" ", @{ $self->{inc} }), libs => $self->{libs}, typemaps => [ map { basename $_ } @{ $self->{typemaps} } ], deps => [sort keys %{ $self->{deps} }], }], ['self']); print $file <<'EOF'; @deps = @{ $self->{deps} }; @typemaps = @{ $self->{typemaps} }; $libs = $self->{libs}; $inc = $self->{inc}; EOF # this is ridiculous, but old versions of ExtUtils::Depends take # first $loadedmodule::CORE and then $INC{$file} --- the fallback # includes the Filename.pm, which is not useful. so we must add # this crappy code. we don't worry about portable pathnames, # as the old code didn't either. (my $mdir = $self->{name}) =~ s{::}{/}g; print $file <<"EOT"; \$CORE = undef; foreach (\@INC) { if ( -f \$_ . "/$mdir/Install/Files.pm") { \$CORE = \$_ . "/$mdir/Install/"; last; } } sub deps { \@{ \$self->{deps} }; } sub Inline { my (\$class, \$lang) = \@_; if (\$lang ne 'C') { warn "Warning: Inline hints not available for \$lang language\n"; return; } +{ map { (uc(\$_) => \$self->{\$_}) } qw(inc libs typemaps) }; } EOT print $file "\n1;\n"; close $file; # we need to ensure that the file we just created gets put into # the install dir with everything else. #$self->install ($filename); $self->add_pm ($filename, $self->installed_filename ('Files.pm')); } sub load { my $dep = shift; my @pieces = split /::/, $dep; my @suffix = qw/ Install Files /; # not File::Spec - see perldoc -f require my $relpath = join('/', @pieces, @suffix) . '.pm'; my $depinstallfiles = join "::", @pieces, @suffix; eval { require $relpath } or die " *** Can't load dependency information for $dep:\n $@\n"; #print Dumper(\%INC); # effectively $instpath = dirname($INC{$relpath}) @pieces = File::Spec->splitdir ($INC{$relpath}); pop @pieces; my $instpath = File::Spec->catdir (@pieces); no strict; croak "No dependency information found for $dep" unless $instpath; if (not File::Spec->file_name_is_absolute ($instpath)) { $instpath = File::Spec->rel2abs ($instpath); } my (@typemaps, $inc, $libs, @deps); # this will not exist when loading files from old versions # of ExtUtils::Depends. @deps = eval { $depinstallfiles->deps }; @deps = @{"$depinstallfiles\::deps"} if $@ and exists ${"$depinstallfiles\::"}{deps}; my $inline = eval { $depinstallfiles->Inline('C') }; if (!$@) { $inc = $inline->{INC} || ''; $libs = $inline->{LIBS} || ''; @typemaps = @{ $inline->{TYPEMAPS} || [] }; } else { $inc = ${"$depinstallfiles\::inc"} || ''; $libs = ${"$depinstallfiles\::libs"} || ''; @typemaps = @{"$depinstallfiles\::typemaps"}; } @typemaps = map { File::Spec->rel2abs ($_, $instpath) } @typemaps; { instpath => $instpath, typemaps => \@typemaps, inc => "-I$instpath $inc", libs => $libs, deps => \@deps, } } sub load_deps { my $self = shift; my @load = grep { not $self->{deps}{$_} } keys %{ $self->{deps} }; foreach my $d (@load) { my $dep = load ($d); $self->{deps}{$d} = $dep; if ($dep->{deps}) { foreach my $childdep (@{ $dep->{deps} }) { push @load, $childdep unless $self->{deps}{$childdep} or grep {$_ eq $childdep} @load; } } } } sub uniquify { my %seen; # we use a seen hash, but also keep indices to preserve # first-seen order. my $i = 0; foreach (@_) { $seen{$_} = ++$i unless exists $seen{$_}; } #warn "stripped ".(@_ - (keys %seen))." redundant elements\n"; sort { $seen{$a} <=> $seen{$b} } keys %seen; } sub get_makefile_vars { my $self = shift; # collect and uniquify things from the dependencies. # first, ensure they are completely loaded. $self->load_deps; ##my @defbits = map { split } @{ $self->{defines} }; my @incbits = map { split } @{ $self->{inc} }; my @libsbits = split /\s+/, $self->{libs}; my @typemaps = @{ $self->{typemaps} }; foreach my $d (sort keys %{ $self->{deps} }) { my $dep = $self->{deps}{$d}; #push @defbits, @{ $dep->{defines} }; push @incbits, @{ $dep->{defines} } if $dep->{defines}; push @incbits, split /\s+/, $dep->{inc} if $dep->{inc}; push @libsbits, split /\s+/, $dep->{libs} if $dep->{libs}; push @typemaps, @{ $dep->{typemaps} } if $dep->{typemaps}; } # we have a fair bit of work to do for the xs files... my @clean = (); my @OBJECT = (); my %XS = (); foreach my $xs (@{ $self->{xs} }) { (my $c = $xs) =~ s/\.xs$/\.c/i; (my $o = $xs) =~ s/\.xs$/\$(OBJ_EXT)/i; $XS{$xs} = $c; push @OBJECT, $o; # according to the MakeMaker manpage, the C files listed in # XS will be added automatically to the list of cleanfiles. push @clean, $o; } # we may have C files, as well: foreach my $c (@{ $self->{c} }) { (my $o = $c) =~ s/\.c$/\$(OBJ_EXT)/i; push @OBJECT, $o; push @clean, $o; } my %vars = ( INC => join (' ', uniquify @incbits), LIBS => join (' ', uniquify $self->find_extra_libs, @libsbits), TYPEMAPS => [@typemaps], ); $self->build_dll_lib(\%vars) if $^O =~ /MSWin32/; # we don't want to provide these if there is no data in them; # that way, the caller can still get default behavior out of # MakeMaker when INC, LIBS and TYPEMAPS are all that are required. $vars{PM} = $self->{pm} if %{ $self->{pm} }; $vars{clean} = { FILES => join (" ", @clean), } if @clean; $vars{OBJECT} = join (" ", @OBJECT) if @OBJECT; $vars{XS} = \%XS if %XS; %vars; } sub build_dll_lib { my ($self, $vars) = @_; $vars->{macro} ||= {}; $vars->{macro}{'INST_DYNAMIC_LIB'} = '$(INST_ARCHAUTODIR)/$(DLBASE)$(LIB_EXT)'; } # Search for extra library files to link against on Windows (either native # Windows library # files, or Cygwin library files) # NOTE: not meant to be called publicly, so no POD documentation sub find_extra_libs { my $self = shift; my %mappers = ( MSWin32 => sub { $_[0] . '\.(?:lib|a)' }, cygwin => sub { $_[0] . '\.dll'}, android => sub { $_[0] . '\.' . $Config{dlext} }, ); my $mapper = $mappers{$^O}; return () unless defined $mapper; my @found_libs = (); foreach my $name (keys %{ $self->{deps} }) { (my $stem = $name) =~ s/^.*:://; if ( defined &DynaLoader::mod2fname ) { my @parts = split /::/, $name; $stem = DynaLoader::mod2fname([@parts]); } my $lib = $mapper->($stem); my $pattern = qr/$lib$/; my $matching_dir; my $matching_file; find (sub { if ((not $matching_file) && /$pattern/) {; $matching_dir = $File::Find::dir; $matching_file = $File::Find::name; } }, map { -d $_ ? ($_) : () } @INC); # only extant dirs if ($matching_file && -f $matching_file) { push @found_libs, ('-L' . $matching_dir, '-l' . $stem); # Android's linker ignores the RTLD_GLOBAL flag # and loads everything as if under RTLD_LOCAL. # What this means in practice is that modules need # to explicitly link to their dependencies, # because otherwise they won't be able to locate any # functions they define. # We use the -l:foo.so flag to indicate that the # actual library name to look for is foo.so, not # libfoo.so if ( $^O eq 'android' ) { $found_libs[-1] = "-l:$stem.$Config{dlext}"; } next; } } return @found_libs; } # Hook into ExtUtils::MakeMaker to create an import library on MSWin32 when gcc # is used. FIXME: Ideally, this should be done in EU::MM itself. package # wrap to fool the CPAN indexer ExtUtils::MM; use Config; sub static_lib { my $base = shift->SUPER::static_lib(@_); return $base unless $^O =~ /MSWin32/ && $Config{cc} =~ /\bgcc\b/i; my $DLLTOOL = $Config{'dlltool'} || 'dlltool'; return <<"__EOM__" # This isn't actually a static lib, it just has the same name on Win32. \$(INST_DYNAMIC_LIB): \$(INST_DYNAMIC) $DLLTOOL --def \$(EXPORT_LIST) --output-lib \$\@ --dllname \$(DLBASE).\$(DLEXT) \$(INST_DYNAMIC) dynamic:: \$(INST_DYNAMIC_LIB) __EOM__ } 1; __END__ =head1 NAME ExtUtils::Depends - Easily build XS extensions that depend on XS extensions =head1 SYNOPSIS use ExtUtils::Depends; $package = new ExtUtils::Depends ('pkg::name', 'base::package') # set the flags and libraries to compile and link the module $package->set_inc("-I/opt/blahblah"); $package->set_libs("-lmylib"); # add a .c and an .xs file to compile $package->add_c('code.c'); $package->add_xs('module-code.xs'); # add the typemaps to use $package->add_typemaps("typemap"); # install some extra data files and headers $package->install (qw/foo.h data.txt/); # save the info $package->save_config('Files.pm'); WriteMakefile( 'NAME' => 'Mymodule', $package->get_makefile_vars() ); =head1 DESCRIPTION This module tries to make it easy to build Perl extensions that use functions and typemaps provided by other perl extensions. This means that a perl extension is treated like a shared library that provides also a C and an XS interface besides the perl one. This works as long as the base extension is loaded with the RTLD_GLOBAL flag (usually done with a sub dl_load_flags {0x01} in the main .pm file) if you need to use functions defined in the module. The basic scheme of operation is to collect information about a module in the instance, and then store that data in the Perl library where it may be retrieved later. The object can also reformat this information into the data structures required by ExtUtils::MakeMaker's WriteMakefile function. For information on how to make your module fit into this scheme, see L. When creating a new Depends object, you give it a name, which is the name of the module you are building. You can also specify the names of modules on which this module depends. These dependencies will be loaded automatically, and their typemaps, header files, etc merged with your new object's stuff. When you store the data for your object, the list of dependencies are stored with it, so that another module depending on your needn't know on exactly which modules yours depends. For example: Gtk2 depends on Glib Gnome2::Canvas depends on Gtk2 ExtUtils::Depends->new ('Gnome2::Canvas', 'Gtk2'); this command automatically brings in all the stuff needed for Glib, since Gtk2 depends on it. When the configuration information is saved, it also includes a class method called C, inheritable by your module. This allows you in your module to simply say at the top: package Mymod; use parent 'Mymod::Install::Files'; # to inherit 'Inline' method And users of C who want to write inline code (using L) will simply be able to write: use Inline with => 'Mymod'; And all the necessary header files, defines, and libraries will be added for them. The C will also implement a C method, which will return a list of any modules that C depends on - you will not normally need to use this: require Mymod::Install::Files; @deps = Mymod::Install::Files->deps; =head1 METHODS =over =item $object = ExtUtils::Depends->new($name, @deps) Create a new depends object named I<$name>. Any modules listed in I<@deps> (which may be empty) are added as dependencies and their dependency information is loaded. An exception is raised if any dependency information cannot be loaded. =item $depends->add_deps (@deps) Add modules listed in I<@deps> as dependencies. =item (hashes) = $depends->get_deps Fetch information on the dependencies of I<$depends> as a hash of hashes, which are dependency information indexed by module name. See C. =item $depends->set_inc (@newinc) Add strings to the includes or cflags variables. =item $depends->set_libs (@newlibs) Add strings to the libs (linker flags) variable. =item $depends->add_pm (%pm_files) Add files to the hash to be passed through ExtUtils::WriteMakefile's PM key. =item $depends->add_xs (@xs_files) Add xs files to be compiled. =item $depends->add_c (@c_files) Add C files to be compiled. =item $depends->add_typemaps (@typemaps) Add typemap files to be used and installed. =item $depends->add_headers (list) No-op, for backward compatibility. =item $depends->install (@files) Install I<@files> to the data directory for I<$depends>. This actually works by adding them to the hash of pm files that gets passed through WriteMakefile's PM key. =item $depends->save_config ($filename) Save the important information from I<$depends> to I<$filename>, and set it up to be installed as I::Install::Files. Note: the actual value of I<$filename> is unimportant so long as it doesn't clash with any other local files. It will be installed as I::Install::Files. =item hash = $depends->get_makefile_vars Return the information in I<$depends> in a format digestible by WriteMakefile. This sets at least the following keys: INC LIBS TYPEMAPS PM And these if there is data to fill them: clean OBJECT XS =item hashref = ExtUtils::Depends::load (name) Load and return dependency information for I. Croaks if no such information can be found. The information is returned as an anonymous hash containing these keys: =over =item instpath The absolute path to the data install directory for this module. =item typemaps List of absolute pathnames for this module's typemap files. =item inc CFLAGS string for this module. =item libs LIBS string for this module. =item deps List of modules on which this one depends. This key will not exist when loading files created by old versions of ExtUtils::Depends. =back If you want to make module I support this, you must provide a module I::Install::Files, which on loading will implement the following class methods: $hashref = name::Install::Files->Inline('C'); # hash to contain any necessary TYPEMAPS (array-ref), LIBS, INC @deps = name::Install::Files->deps; # any modules on which "name" depends An easy way to achieve this is to use the method Lsave_config ($filename)">, but your package may have different facilities already. =item $depends->load_deps Load I<$depends> dependencies, by calling C on each dependency module. This is usually done for you, and should only be needed if you want to call C after calling C manually. =back =head1 SUPPORT =head2 Bugs/Feature Requests Version 0.2 discards some of the more esoteric features provided by the older versions. As they were completely undocumented, and this module has yet to reach 1.0, this may not exactly be a bug. This module is tightly coupled to the ExtUtils::MakeMaker architecture. You can submit new bugs/feature requests by using one of two bug trackers (below). =over =item CPAN Request Tracker You can submit bugs/feature requests via the web by going to L (requires PAUSE ID or Bitcard), or by sending an e-mail to L. =item Gnome.org Bugzilla Report bugs/feature requests to the 'gnome-perl' product (requires login) L =back Patches that implement new features with test cases, and/or test cases that exercise existing bugs are always welcome. The Gtk-Perl mailing list is at L. =head2 Source Code The source code to L is available at the Gnome.org Git repo (L). Create your own copy of the Git repo with: git clone git://git.gnome.org/perl-ExtUtils-Depends (Git protocol) git clone https://git.gnome.org/browse/perl-ExtUtils-Depends/ (HTTPS) =head1 SEE ALSO ExtUtils::MakeMaker. =head1 AUTHOR Paolo Molaro wrote the original version for Gtk-Perl. muppet rewrote the innards for version 0.2, borrowing liberally from Paolo's code. =head1 MAINTAINER The Gtk2 project, L/L. =head1 LICENSE This library is free software; you may redistribute it and/or modify it under the same terms as Perl itself. =cut