.\" Automatically generated by Pod::Man 4.11 (Pod::Simple 3.35) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "App::Info::Lib::Iconv 3pm" .TH App::Info::Lib::Iconv 3pm "2020-01-23" "perl v5.30.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" App::Info::Lib::Iconv \- Information about libiconv .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& use App::Info::Lib::Iconv; \& \& my $iconv = App::Info::Lib::Iconv\->new; \& \& if ($iconv\->installed) { \& print "App name: ", $iconv\->name, "\en"; \& print "Version: ", $iconv\->version, "\en"; \& print "Bin dir: ", $iconv\->bin_dir, "\en"; \& } else { \& print "libiconv is not installed. :\-(\en"; \& } .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" App::Info::Lib::Iconv supplies information about the libiconv library installed on the local system. It implements all of the methods defined by App::Info::Lib. Methods that trigger events will trigger them only the first time they're called (See App::Info for documentation on handling events). To start over (after, say, someone has installed libiconv) construct a new App::Info::Lib::Iconv object to aggregate new meta data. .PP Some of the methods trigger the same events. This is due to cross-calling of shared subroutines. However, any one event should be triggered no more than once. For example, although the info event \*(L"Searching for 'iconv.h'\*(R" is documented for the methods \f(CW\*(C`version()\*(C'\fR, \f(CW\*(C`major_version()\*(C'\fR, and \&\f(CW\*(C`minor_version()\*(C'\fR, rest assured that it will only be triggered once, by whichever of those four methods is called first. .SH "INTERFACE" .IX Header "INTERFACE" .SS "Constructor" .IX Subsection "Constructor" \fInew\fR .IX Subsection "new" .PP .Vb 1 \& my $iconv = App::Info::Lib::Iconv\->new(@params); .Ve .PP Returns an App::Info::Lib::Iconv object. See App::Info for a complete description of argument parameters. .PP When called, \f(CW\*(C`new()\*(C'\fR searches the the list of directories returned by the \&\f(CW\*(C`search_bin_dirs()\*(C'\fR method for an executable file with a name returned by the \&\f(CW\*(C`search_exe_names()\*(C'\fR method. If the executable is found, libiconv will be assumed to be installed. Otherwise, most of the object methods will return \&\f(CW\*(C`undef\*(C'\fR. .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for iconv .IP "unknown" 4 .IX Item "unknown" Path to iconv executable? .IP "confirm" 4 .IX Item "confirm" Path to iconv executable? .SS "Class Method" .IX Subsection "Class Method" \fIkey_name\fR .IX Subsection "key_name" .PP .Vb 1 \& my $key_name = App::Info::Lib::Iconv\->key_name; .Ve .PP Returns the unique key name that describes this class. The value returned is the string \*(L"libiconv\*(R". .SS "Object Methods" .IX Subsection "Object Methods" \fIinstalled\fR .IX Subsection "installed" .PP .Vb 2 \& print "libiconv is ", ($iconv\->installed ? \*(Aq\*(Aq : \*(Aqnot \*(Aq), \& "installed.\en"; .Ve .PP Returns true if libiconv is installed, and false if it is not. App::Info::Lib::Iconv determines whether libiconv is installed based on the presence or absence of the \fIiconv\fR application, as found when \f(CW\*(C`new()\*(C'\fR constructed the object. If libiconv does not appear to be installed, then most of the other object methods will return empty values. .PP \fIname\fR .IX Subsection "name" .PP .Vb 1 \& my $name = $iconv\->name; .Ve .PP Returns the name of the application. In this case, \f(CW\*(C`name()\*(C'\fR simply returns the string \*(L"libiconv\*(R". .PP \fIversion\fR .IX Subsection "version" .PP .Vb 1 \& my $version = $iconv\->version; .Ve .PP Returns the full version number for libiconv. App::Info::Lib::Iconv attempts to parse the version number from the \fIiconv.h\fR file, if it exists. .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for 'iconv.h' .Sp Searching for include directory .IP "error" 4 .IX Item "error" Cannot find include directory .Sp Cannot find 'iconv.h' .Sp Cannot parse version number from file 'iconv.h' .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv include directory .Sp Enter a valid libiconv version number .PP \fImajor_version\fR .IX Subsection "major_version" .PP .Vb 1 \& my $major_version = $iconv\->major_version; .Ve .PP Returns the libiconv major version number. App::Info::Lib::Iconv attempts to parse the version number from the \fIiconv.h\fR file, if it exists. For example, if \f(CW\*(C`version()\*(C'\fR returns \*(L"1.7\*(R", then this method returns \*(L"1\*(R". .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for 'iconv.h' .Sp Searching for include directory .IP "error" 4 .IX Item "error" Cannot find include directory .Sp Cannot find 'iconv.h' .Sp Cannot parse version number from file 'iconv.h' .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv include directory .Sp Enter a valid libiconv version number .PP \fIminor_version\fR .IX Subsection "minor_version" .PP .Vb 1 \& my $minor_version = $iconv\->minor_version; .Ve .PP Returns the libiconv minor version number. App::Info::Lib::Iconv attempts to parse the version number from the \fIiconv.h\fR file, if it exists. For example, if \f(CW\*(C`version()\*(C'\fR returns \*(L"1.7\*(R", then this method returns \*(L"7\*(R". .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for 'iconv.h' .Sp Searching for include directory .IP "error" 4 .IX Item "error" Cannot find include directory .Sp Cannot find 'iconv.h' .Sp Cannot parse version number from file 'iconv.h' .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv include directory .Sp Enter a valid libiconv version number .PP \fIpatch_version\fR .IX Subsection "patch_version" .PP .Vb 1 \& my $patch_version = $iconv\->patch_version; .Ve .PP Since libiconv has no patch number in its version number, this method will always return false. .PP \fIexecutable\fR .IX Subsection "executable" .PP .Vb 1 \& my $executable = $iconv\->executable; .Ve .PP Returns the path to the Iconv executable, which will be defined by one of the names returned by \f(CW\*(C`search_exe_names()\*(C'\fR. The executable is searched for in \&\f(CW\*(C`new()\*(C'\fR, so there are no events for this method. .PP \fIbin_dir\fR .IX Subsection "bin_dir" .PP .Vb 1 \& my $bin_dir = $iconv\->bin_dir; .Ve .PP Returns the path of the directory in which the \fIiconv\fR application was found when the object was constructed by \f(CW\*(C`new()\*(C'\fR. .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for bin directory .IP "error" 4 .IX Item "error" Cannot find bin directory .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv bin directory .PP \fIinc_dir\fR .IX Subsection "inc_dir" .PP .Vb 1 \& my $inc_dir = $iconv\->inc_dir; .Ve .PP Returns the directory path in which the file \fIiconv.h\fR was found. App::Info::Lib::Iconv searches for \fIiconv.h\fR in the following directories: .IP "/usr/local/include" 4 .IX Item "/usr/local/include" .PD 0 .IP "/usr/include" 4 .IX Item "/usr/include" .IP "/sw/include" 4 .IX Item "/sw/include" .PD .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for include directory .IP "error" 4 .IX Item "error" Cannot find include directory .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv include directory .PP \fIlib_dir\fR .IX Subsection "lib_dir" .PP .Vb 1 \& my $lib_dir = $iconv\->lib_dir; .Ve .PP Returns the directory path in which a libiconv library was found. The search looks for a file with a name returned by \f(CW\*(C`search_lib_names()\*(C'\fR in a directory returned by \f(CW\*(C`search_lib_dirs()\*(C'\fR. .PP \&\fBEvents:\fR .IP "info" 4 .IX Item "info" Searching for library directory .IP "error" 4 .IX Item "error" Cannot find library directory .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv library directory .PP \fIso_lib_dir\fR .IX Subsection "so_lib_dir" .PP .Vb 1 \& my $so_lib_dir = $iconv\->so_lib_dir; .Ve .PP Returns the directory path in which a libiconv shared object library was found. The search looks for a file with a name returned by \&\f(CW\*(C`search_so_lib_names()\*(C'\fR in a directory returned by \f(CW\*(C`search_lib_dirs()\*(C'\fR. .PP Returns the directory path in which a libiconv shared object library was found. App::Info::Lib::Iconv searches for these files: .PP .IP "info" 4 .IX Item "info" Searching for shared object library directory .IP "error" 4 .IX Item "error" Cannot find shared object library directory .IP "unknown" 4 .IX Item "unknown" Enter a valid libiconv shared object library directory .PP \fIhome_url\fR .IX Subsection "home_url" .PP .Vb 1 \& my $home_url = $iconv\->home_url; .Ve .PP Returns the libiconv home page \s-1URL.\s0 .PP \fIdownload_url\fR .IX Subsection "download_url" .PP .Vb 1 \& my $download_url = $iconv\->download_url; .Ve .PP Returns the libiconv download \s-1URL.\s0 .PP \fIsearch_exe_names\fR .IX Subsection "search_exe_names" .PP .Vb 1 \& my @search_exe_names = $iconv\->search_exe_names; .Ve .PP Returns a list of possible names for the Iconv executable. By default, the only name returned is \fIiconv\fR (\fIiconv.exe\fR on Win32). .PP \fIsearch_bin_dirs\fR .IX Subsection "search_bin_dirs" .PP .Vb 1 \& my @search_bin_dirs = $iconv\->search_bin_dirs; .Ve .PP Returns a list of possible directories in which to search an executable. Used by the \f(CW\*(C`new()\*(C'\fR constructor to find an executable to execute and collect application info. The found directory will also be returned by the \f(CW\*(C`bin_dir\*(C'\fR method. By default, the directories returned are those in your path, followed by these: .IP "\fI/usr/local/bin\fR" 4 .IX Item "/usr/local/bin" .PD 0 .IP "\fI/usr/bin\fR" 4 .IX Item "/usr/bin" .IP "\fI/bin\fR" 4 .IX Item "/bin" .IP "\fI/sw/bin\fR" 4 .IX Item "/sw/bin" .IP "\fI/usr/local/sbin\fR" 4 .IX Item "/usr/local/sbin" .IP "\fI/usr/sbin\fR" 4 .IX Item "/usr/sbin" .IP "\fI/sbin\fR" 4 .IX Item "/sbin" .IP "\fI/sw/sbin\fR" 4 .IX Item "/sw/sbin" .PD .PP \fIsearch_lib_names\fR .IX Subsection "search_lib_names" .PP .Vb 1 \& my @seach_lib_names = $self\->search_lib_nams .Ve .PP Returns a list of possible names for library files. Used by \f(CW\*(C`lib_dir()\*(C'\fR to search for library files. By default, the list is: .IP "libiconv3.a" 4 .IX Item "libiconv3.a" .PD 0 .IP "libiconv3.la" 4 .IX Item "libiconv3.la" .IP "libiconv3.so" 4 .IX Item "libiconv3.so" .IP "libiconv3.so.0" 4 .IX Item "libiconv3.so.0" .IP "libiconv3.so.0.0.1" 4 .IX Item "libiconv3.so.0.0.1" .IP "libiconv3.dylib" 4 .IX Item "libiconv3.dylib" .IP "libiconv3.0.dylib" 4 .IX Item "libiconv3.0.dylib" .IP "libiconv3.0.0.1.dylib" 4 .IX Item "libiconv3.0.0.1.dylib" .IP "libiconv.a" 4 .IX Item "libiconv.a" .IP "libiconv.la" 4 .IX Item "libiconv.la" .IP "libiconv.so" 4 .IX Item "libiconv.so" .IP "libiconv.so.0" 4 .IX Item "libiconv.so.0" .IP "libiconv.so.0.0.1" 4 .IX Item "libiconv.so.0.0.1" .IP "libiconv.dylib" 4 .IX Item "libiconv.dylib" .IP "libiconv.2.dylib" 4 .IX Item "libiconv.2.dylib" .IP "libiconv.2.0.4.dylib" 4 .IX Item "libiconv.2.0.4.dylib" .IP "libiconv.0.dylib" 4 .IX Item "libiconv.0.dylib" .IP "libiconv.0.0.1.dylib" 4 .IX Item "libiconv.0.0.1.dylib" .PD .PP \fIsearch_so_lib_names\fR .IX Subsection "search_so_lib_names" .PP .Vb 1 \& my @seach_so_lib_names = $self\->search_so_lib_nams .Ve .PP Returns a list of possible names for shared object library files. Used by \&\f(CW\*(C`so_lib_dir()\*(C'\fR to search for library files. By default, the list is: .IP "libiconv3.so" 4 .IX Item "libiconv3.so" .PD 0 .IP "libiconv3.so.0" 4 .IX Item "libiconv3.so.0" .IP "libiconv3.so.0.0.1" 4 .IX Item "libiconv3.so.0.0.1" .IP "libiconv3.dylib" 4 .IX Item "libiconv3.dylib" .IP "libiconv3.0.dylib" 4 .IX Item "libiconv3.0.dylib" .IP "libiconv3.0.0.1.dylib" 4 .IX Item "libiconv3.0.0.1.dylib" .IP "libiconv.so" 4 .IX Item "libiconv.so" .IP "libiconv.so.0" 4 .IX Item "libiconv.so.0" .IP "libiconv.so.0.0.1" 4 .IX Item "libiconv.so.0.0.1" .IP "libiconv.dylib" 4 .IX Item "libiconv.dylib" .IP "libiconv.0.dylib" 4 .IX Item "libiconv.0.dylib" .IP "libiconv.0.0.1.dylib" 4 .IX Item "libiconv.0.0.1.dylib" .PD .PP \fIsearch_lib_dirs\fR .IX Subsection "search_lib_dirs" .PP .Vb 1 \& my @search_lib_dirs = $iconv\->search_lib_dirs; .Ve .PP Returns a list of possible directories in which to search for libraries. By default, it returns all of the paths in the \f(CW\*(C`libsdirs\*(C'\fR and \f(CW\*(C`loclibpth\*(C'\fR attributes defined by the Perl Config module \*(-- plus \fI/sw/lib\fR (in support of all you Fink users out there). .PP \fIsearch_inc_names\fR .IX Subsection "search_inc_names" .PP .Vb 1 \& my @search_inc_names = $iconv\->search_inc_names; .Ve .PP Returns a list of include file names to search for. Used by \f(CW\*(C`inc_dir()\*(C'\fR to search for an include file. By default, the only name returned is \fIiconv.h\fR. .PP \fIsearch_inc_dirs\fR .IX Subsection "search_inc_dirs" .PP .Vb 1 \& my @search_inc_dirs = $iconv\->search_inc_dirs; .Ve .PP Returns a list of possible directories in which to search for include files. Used by \f(CW\*(C`inc_dir()\*(C'\fR to search for an include file. By default, the directories are: .IP "/usr/local/include" 4 .IX Item "/usr/local/include" .PD 0 .IP "/usr/include" 4 .IX Item "/usr/include" .IP "/sw/include" 4 .IX Item "/sw/include" .PD .SH "KNOWN ISSUES" .IX Header "KNOWN ISSUES" This is a pretty simple class. It's possible that there are more directories that ought to be searched for libraries and includes. .SH "TO DO" .IX Header "TO DO" Improve this class by borrowing code from Matt Seargent's AxKit \fIMakefil.PL\fR. .SH "SUPPORT" .IX Header "SUPPORT" This module is stored in an open GitHub repository . Feel free to fork and contribute! .PP Please file bug reports via GitHub Issues or by sending mail to bug\-App\-Info@rt.cpan.org . .SH "AUTHOR" .IX Header "AUTHOR" David E. Wheeler based on code by Sam Tregar . .SH "SEE ALSO" .IX Header "SEE ALSO" App::Info, App::Info::Lib, Text::Iconv .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" Copyright (c) 2002\-2011, David E. Wheeler. Some Rights Reserved. .PP This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.