Rev 192 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
106 | dmarschall | 1 | This file is part of "Filter Foundry", a filter plugin for Adobe Photoshop |
192 | daniel-mar | 2 | Copyright (C) 2003-2009 Toby Thain, toby@telegraphics.com.au |
3 | Copyright (C) 2018-2019 Daniel Marschall, ViaThinkSoft |
||
2 | toby | 4 | |
5 | This program is free software; you can redistribute it and/or modify |
||
6 | it under the terms of the GNU General Public License as published by |
||
7 | the Free Software Foundation; either version 2 of the License, or |
||
8 | (at your option) any later version. |
||
9 | |||
10 | This program is distributed in the hope that it will be useful, |
||
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||
13 | GNU General Public License for more details. |
||
14 | |||
15 | You should have received a copy of the GNU General Public License |
||
16 | along with this program; if not, write to the Free Software |
||
17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
||
18 | |||
69 | toby | 19 | |
2 | toby | 20 | Building the Filter Foundry plugin for Photoshop |
21 | ------------------------------------------------ |
||
22 | |||
23 | Notes on source code |
||
64 | toby | 24 | -------------------- |
69 | toby | 25 | Source code, makefiles and IDE projects under GPL license are provided |
26 | for MPW (Classic & Carbon PowerPC targets), CodeWarrior 7 |
||
192 | daniel-mar | 27 | (Classic & Carbon PowerPC, Win32, 68K targets), |
28 | Microsoft Visual C++ (Win32 target), OpenWatcom (Win32 target), |
||
29 | and mingw32 (Win32 target). |
||
2 | toby | 30 | |
192 | daniel-mar | 31 | A Photoshop SDK is required (available from Adobe Systems, |
32 | https://www.adobe.com/devnet/photoshop/sdk.html ). |
||
69 | toby | 33 | The SDK was also distributed with Photoshop 6.0 and earlier. |
193 | daniel-mar | 34 | The source code has been built with SDK 6.0, CS2, CS3 beta, and CC 2017 but older |
35 | versions should work, too. |
||
2 | toby | 36 | (If building with SDK v4, edit 68k.r, carbon.r, classic.r, and PiMI_68k.r |
69 | toby | 37 | to remove references to "PIResDefines.h", "PiPL.r" and "PiMI.r" and replace |
38 | with a single #include "PIGeneral.r"; also remove "fmtCanWriteTransparency" |
||
39 | from PiPL_common.r.) |
||
193 | daniel-mar | 40 | |
41 | The dependency "telegraphics_common" is available here |
||
42 | http://www.telegraphics.com.au/svn/common/ |
||
43 | Revision 84 (dated 9 October 2019) is included in this repository |
||
44 | to simplify the build process. |
||
2 | toby | 45 | |
192 | daniel-mar | 46 | |
47 | Mac notes |
||
48 | --------- |
||
69 | toby | 49 | Before attempting to build, you must edit the makefiles |
192 | daniel-mar | 50 | ("FilterFoundry.make" for MPW), or change your |
69 | toby | 51 | CodeWarrior project's access paths, to reflect the SDK's installed location. |
2 | toby | 52 | |
192 | daniel-mar | 53 | To build the Carbon plugin with an SDK prior to version 7.0, |
69 | toby | 54 | it is necessary to edit the SDK file :PhotoshopAPI:Resources:PIPL.r |
55 | as follows: |
||
2 | toby | 56 | 1. find the line "case CodePowerPC:" |
57 | 2. duplicate the next 15 lines |
||
69 | toby | 58 | 3. in the copy only, change "case CodePowerPC:" to "case CodeCarbonPowerPC:" |
2 | toby | 59 | and change the 5 occurrences of "pwpc" to "ppcb" |
60 | |||
192 | daniel-mar | 61 | Photoshop 7.0, CS, and CS2 will load Carbon/PEF plugins built in this manner. |
69 | toby | 62 | Only CodeWarrior and MPW can build these. |
2 | toby | 63 | |
69 | toby | 64 | Photoshop CS2 also supports Mach-O format plugins. For details on how |
65 | these are built, see the Makefile (target "osx"). |
||
66 | |||
67 | Photoshop CS3 supports "universal" (or "fat") plugins having native code |
||
68 | for both PowerPC and Intel architectures. The provided Makefile can build |
||
69 | a "universal" plugin if you have the CS3 "Beta" SDK (use target "fat"). |
||
70 | |||
71 | Note that building Mach-O plugins requires Apple's Developer Tools |
||
192 | daniel-mar | 72 | to be installed (from the DVD that came with your Mac, or downloaded from |
69 | toby | 73 | http://developer.apple.com/ if you have an ADC login). |
74 | |||
2 | toby | 75 | The Mac build requires Apple's MoreFiles library, which can be obtained via |
186 | dmarschall | 76 | https://developer.apple.com/library/archive/samplecode/MoreFiles/ |
2 | toby | 77 | |
78 | Depending on how the source files were extracted, it may be necessary to set |
||
69 | toby | 79 | the correct Mac file types before attempting to build. In MPW, this can |
80 | be done as follows. First set the current directory to the Filter Foundry |
||
81 | source directory, then: |
||
82 | setfile -t TEXT Å.[chrly] Å.make Å.rc ::common:tt:Å ::common:adobeplugin:Å |
||
15 | toby | 83 | This can also be necessary after regenerating y.tab.c and lex.yy.c. |
192 | daniel-mar | 84 | These files are generated from the parser and lexical analyzer definitions, |
69 | toby | 85 | parser.y and lexer.l, by a UNIX Terminal (not MPW!) command such as: |
15 | toby | 86 | make y.tab.c lex.yy.c |
2 | toby | 87 | |
69 | toby | 88 | If building with MPW, finished binaries are left in the "debug" directory; |
89 | these are good for testing and debugging, as they can be updated |
||
90 | and re-run without having to re-launch Photoshop. |
||
2 | toby | 91 | |
69 | toby | 92 | The finished binary, which contains executables for Classic and Carbon, |
64 | toby | 93 | is left in the "dist" directory. |
94 | |||
192 | daniel-mar | 95 | While a CodeWarrior 7 project is provided, MPW and mingw32 are recommended |
96 | as they produce much smaller executables. |
||
64 | toby | 97 | |
192 | daniel-mar | 98 | MPW (Macintosh Programmer's Workshop) runs on PowerPC and |
99 | 68K Macs under Mac OS 9 or earlier, or Classic under OS X. |
||
100 | |||
101 | |||
106 | dmarschall | 102 | Windows notes |
103 | ------------- |
||
104 | |||
172 | dmarschall | 105 | BUILDING WITH VISUAL STUDIO |
192 | daniel-mar | 106 | * For Windows, Visual Studio works best (the community edition is even free), |
107 | and it can compile the 32-bit and 64-bit plugins for Windows. |
||
108 | * Download: https://visualstudio.microsoft.com/de/vs/community/ |
||
109 | * To build in Windows with Visual Studio (IDE or command line), see the visual_studio |
||
110 | subdirectory and notes (README.TXT). |
||
111 | * Most recently tested with Visual C++ 2019 with Adobe Photoshop SDK CC 2017 |
||
107 | dmarschall | 112 | |
172 | dmarschall | 113 | BUILDING WITH OPEN WATCOM |
192 | daniel-mar | 114 | * OpenWatcom can also be used, but only for 32 Bit, and it is officially not |
115 | supported by Adobe. |
||
116 | * Download: https://sourceforge.net/projects/openwatcom/files/ |
||
117 | * To build in Windows with the OpenWatcom IDE, see the wpj |
||
118 | subdirectory and notes (README.TXT), kindly provided by Peter Heckert and Daniel Marschall. |
||
119 | * Most recently tested with Open Watcom 1.9 with Adobe Photoshop SDK CC 2017 |
||
106 | dmarschall | 120 | |
192 | daniel-mar | 121 | BUILDING WITH MINGW32 |
122 | * Mingw32 can be hosted on virtually any UNIX or Linux system, or under Windows. |
||
123 | * Download: http://mingw-w64.org/doku.php/download |
||
124 | * Before attempting to build, you must edit the file "Makefile". |