Image-Magick

 view release on metacpan or  search on metacpan

Makefile.nt  view on Meta::CPAN

#  Copyright @ 1999 ImageMagick Studio LLC, a non-profit organization
#  dedicated to making software imaging solutions freely available.
#
#  This program is covered by multiple licenses, which are described in
#  LICENSE.  You should have received a copy of LICENSE with this
#  package; otherwise see https://imagemagick.org/script/license.php.
#
#  Makefile for building PerlMagick under Windows
#
#
#
use ExtUtils::MakeMaker;
use Config;
# See lib/ExtUtils/MakeMaker.pm for details of how to influence
# the contents of the Makefile that is written.
#
# NOTE: The current ActiveState binary distribution does not completely setup
# the values in C:/Perl/lib/Config.pm. You must manually modify the values of
# libpth to add the VisualC++ library path. It should look similar to one of
# the following examples in order to work properly.
#
#  Random developer
#   libpth='"C:\Perl\lib\CORE" "D:\DevStudio\VC98\lib"'
#
#  Visual Studio 6.0 default install:
#   libpth='"C:\Program Files\Microsoft Visual Studio\VC98\lib" "C:\Perl\lib\CORE"'
#
#  Visual Studio 7.0 default install:
#   libpth='"C:\Program Files\Microsoft Visual Studio .NET\vc7\lib" "C:\Perl\lib\CORE"'
#
#  Visual Studio 7.1 default install:
#   libpth='"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\lib" "C:\Perl\lib\CORE"'
#
#  Visual Studio 9.0 default install (C:\Perl\lib\Config.pm):
#  libpth='"C:\Program Files\Microsoft Visual Studio 9.0\VC\lib" "C:\Perl\lib\CORE"'
#
WriteMakefile(
    'ABSTRACT'  => 'ImageMagick PERL Extension',
    'AUTHOR'    => 'ImageMagick Studio',
    'NAME'      => 'Image::Magick',
    'VERSION_FROM' => 'Magick.pm', # finds $VERSION
    'LIBS'      => ['-L..\..\VisualMagick\lib -L..\..\VisualMagick\bin -lCORE_RL_MagickCore_.lib -lCORE_DB_MagickCore_.lib'],
    'DEFINE'    => '-D_VISUALC_ -D_WINDOWS',     # e.g., '-DHAVE_SOMETHING' 
    'INC'       => '-I.. -I..\xlib\include',
    'BINARY_LOCATION'  => 'x86/Image-Magick.tar.gz',
    'dist' => {ZIP => "zip.exe", ZIPFLAGS=>"-r"},
    'clean' => {FILES => "Image-Magick.ppd Image-Magick.tar.gz PerlMagick.zip " },
    ($Config{'archname'} =~ /-object$/i ? ('CAPI' => 'TRUE') : ()),
);

#
# Add a targets for building ActiveState ppm distribution modules 
# Dylan Beattie <dylan@zepler.org>, April 2002
#
# Requires tar, gzip, and zip.  This produces PerlMagick.zip
# Get GNU tar and gzip from http://sourceware.cygnus.com/
# Get Win32 command line PKZIP from http://www.pkware.com/ 
# and rename PKZIP.EXE to ZIP.EXE and PKUNZIP.EXE to UNZIP.EXE
# Make sure tar.exe, gzip.exe and zip.exe are in your system path
#
# 'nmake ppm' will include only the PerlMagick module
# 'nmake ppm-full' also includes all ImageMagick DLLs and MGK files

sub MY::postamble
{
	'
Image-Magick.tar.gz: ppd pure_all #htmlifypods manifypods
	if exist Image-Magick.tar.gz del Image-Magick.tar.gz
	if exist Image-Magick.tar del Image-Magick.tar
	$(TAR) $(TARFLAGS) Image-Magick.tar blib
	$(COMPRESS) -q Image-Magick.tar

release: Image-Magick.tar.gz

ppm: ppd pure_all htmlifypods manifypods
	if exist PerlMagick.zip del PerlMagick.zip
	$(TAR) $(TARFLAGS) Image-Magick.tar blib
	$(COMPRESS) -q Image-Magick.tar
	if exist x86 del x86 /f /q
	if exist x86 rd x86
	md x86
	copy Image-Magick.tar$(SUFFIX) x86
	del Image-Magick.tar$(SUFFIX)
	if exist ppm-readme.txt copy ppm-readme.txt readme
	$(ZIP) $(ZIPFLAGS) PerlMagick.zip readme Image-Magick.ppd x86/Image-Magick.tar$(SUFFIX)
	del x86\Image-Magick.tar$(SUFFIX)
	rd x86

ppm-full: ppd pure_all htmlifypods manifypods
	if exist PerlMagick-full.zip del PerlMagick-full.zip
	copy ..\..\VisualMagick\bin\*.dll blib\arch\auto\Image\Magick
	copy ..\..\VisualMagick\bin\*.xml blib\arch\auto\Image\Magick
	$(TAR) $(TARFLAGS) Image-Magick.tar blib
	$(COMPRESS) -q Image-Magick.tar
	if exist x86 del x86 /f /q
	if exist x86 rd x86
	md x86
	copy Image-Magick.tar$(SUFFIX) x86
	del Image-Magick.tar$(SUFFIX)
	if exist ppm-readme.txt copy ppm-readme.txt readme



( run in 3.104 seconds using v1.01-cache-2.11-cpan-39bf76dae61 )