Mozilla-ConsoleService
view release on metacpan or search on metacpan
ConsoleService.xs view on Meta::CPAN
#include <nsCOMPtr.h>
#include <nsIConsoleService.h>
#include <nsIConsoleListener.h>
#include <nsIConsoleMessage.h>
#include <nsIScriptError.h>
#include <nsIServiceManager.h>
#include <nsEmbedString.h>
#include <nsServiceManagerUtils.h>
#include "build/version.h"
#if MCS_MOZEMBED_VERSION < 1900
#define GetMessageMoz GetMessage
#endif /* MCS_MOZEMBED_VERSION */
static SV *wrap_unichar_string(const PRUnichar *uni_str) {
nsEmbedString utf8;
nsEmbedCString u8c;
const char * u8str;
utf8 = uni_str;
NS_UTF16ToCString(utf8, NS_CSTRING_ENCODING_UTF8, u8c);
u8str = u8c.get();
Makefile.PL view on Meta::CPAN
use ExtUtils::PkgConfig;
use ExtUtils::Depends;
use File::Slurp;
my %pkgcfg = ExtUtils::PkgConfig->find("mozilla-gtkmozembed >= 1.7"
, "firefox-gtkmozembed >= 1.5");
my $ver = $pkgcfg{modversion};
$ver =~ s/\.//g;
mkdir "build";
write_file("build/version.h", "#define MCS_MOZEMBED_VERSION $ver\n");
my $dep = ExtUtils::Depends->new('Mozilla::ConsoleService', 'Gtk2::MozEmbed');
$dep->set_inc($pkgcfg{cflags});
$dep->set_libs($pkgcfg{libs});
WriteMakefile(
NAME => 'Mozilla::ConsoleService',
VERSION_FROM => 'lib/Mozilla/ConsoleService.pm', # finds $VERSION
PREREQ_PM => { 'Mozilla::Mechanize' => 0.05 },
($] >= 5.005 ? ## Add these new keywords supported since 5.005
( run in 2.629 seconds using v1.01-cache-2.11-cpan-71847e10f99 )