Subversion Repositories filter_foundry

Rev

Rev 2 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 toby 1
	This file is part of "Filter Foundry", a filter plugin for Adobe Photoshop
2
    Copyright (C) 2003-5 Toby Thain, toby@telegraphics.com.au
3
 
4
    This program is free software; you can redistribute it and/or modify
5
    it under the terms of the GNU General Public License as published by  
6
    the Free Software Foundation; either version 2 of the License, or
7
    (at your option) any later version.
8
 
9
    This program is distributed in the hope that it will be useful,
10
    but WITHOUT ANY WARRANTY; without even the implied warranty of
11
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
    GNU General Public License for more details.
13
 
14
    You should have received a copy of the GNU General Public License  
15
    along with this program; if not, write to the Free Software
16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17
 
18
Building the Filter Foundry plugin for Photoshop
19
------------------------------------------------
20
 
21
Notes on source code
22
 
15 toby 23
Source code, makefiles and IDE projects under GPL license are provided for MPW (Classic & Carbon PowerPC targets), 
2 toby 24
CodeWarrior 7 (Classic & Carbon PowerPC, Win32, 68K targets) and mingw32 (Win32 target).
25
 
26
A Photoshop SDK is required (available from Adobe Systems, http://www.adobe.com/).
27
The SDK was also distributed with Photoshop 6.0 and earlier. 
28
 
29
The source was built with SDK 6.0 but earlier versions of the SDK can be used.
30
(If building with SDK v4, edit 68k.r, carbon.r, classic.r, and PiMI_68k.r
31
to remove references to "PIResDefines.h", "PiPL.r" and "PiMI.r" and replace with
32
a single #include "PIGeneral.r"; also remove "fmtCanWriteTransparency" from PiPL_common.r.)
33
 
34
Before attempting to build, you must edit the makefiles ("FilterFoundry.make" for MPW, "Makefile" for mingw32),
35
or change your CodeWarrior project's access paths, to reflect the SDK's installed location.
36
 
37
In order to build the Carbon plugin with an SDK prior to version 7.0, it is necessary to edit
38
the SDK file :PhotoshopAPI:Resources:PIPL.r as follows:
39
1. find the line "case CodePowerPC:"
40
2. duplicate the next 15 lines
41
3. in the copy only, change "case CodePowerPC:" to "case CodePowerPCbundle:"
42
   and change the 5 occurrences of "pwpc" to "ppcb"
43
 
44
This code has not been tested with the Photoshop v7.0 SDK.
45
 
46
 
47
Mac notes
48
 
49
The Mac build requires Apple's MoreFiles library, which can be obtained via
50
http://developer.apple.com/samplecode/Sample_Code/Files/MoreFiles.htm
51
 
52
Before building with MPW, create the "debug" directory:
53
	newfolder debug
54
 
55
Depending on how the source files were extracted, it may be necessary to set
56
the correct Mac file types before attempting to build. In MPW, this can be done as follows. 
57
First set the current directory to the Filter Foundry source directory, then:
58
	setfile -t TEXT -c 'MPS ' Å.[chrly] Å.make Å.rc ::common:tt:Å ::common:adobeplugin:Å
15 toby 59
This can also be necessary after regenerating y.tab.c and lex.yy.c.
2 toby 60
These files are generated from the parser and lexical analyser definitions, parser.y and lexer.l,
61
by a UNIX (not MPW!) command such as:
15 toby 62
	make y.tab.c lex.yy.c
2 toby 63
Pre-generated versions of these files (and y.tab.h, which is a byproduct) are included
64
in the source archive.
65
 
66
If building with MPW, finished binaries are left in the "debug" directory; these should be used
67
for testing and debugging, as they can be re-built and re-run without having to restart Photoshop.
68
 
69
The finished "universal" binary, which contains separate executables for Classic and Carbon,
70
is left in the "dist" directory. 
71
 
72
 
73
Development systems
74
 
75
While a CodeWarrior 7 project is provided, MPW and mingw32 are recommended 
76
as they produce much smaller executables.
77
 
78
These industrial strength development tools can be freely downloaded from
79
http://developer.apple.com/tools/mpw-tools/ and http://www.mingw.org/ respectively.
80
 
81
Mingw32 can be hosted on virtually any UNIX or Linux system, or under Windows.
82
MPW runs on PowerPC and 68K Macs under Mac OS 9 or earlier, or Classic mode under OS X.
83