Rev 198 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
190 | dmarschall | 1 | |
2 | |||
198 | daniel-mar | 3 | Building FilterFoundry with Visual Studio |
4 | ========================================= |
||
5 | |||
532 | daniel-mar | 6 | Most recently tested with Visual Studio 2022 and Adobe Photoshop SDK 2023. |
190 | dmarschall | 7 | |
8 | |||
192 | daniel-mar | 9 | Prerequisites |
10 | ------------- |
||
190 | dmarschall | 11 | |
192 | daniel-mar | 12 | 1) Visual Studio (Visual C++) |
190 | dmarschall | 13 | There is a free "Community Edition" available here: |
192 | daniel-mar | 14 | https://visualstudio.microsoft.com/de/vs/community/ |
190 | dmarschall | 15 | |
16 | 2) Flex and Bison |
||
17 | Download the tools here: |
||
192 | daniel-mar | 18 | https://sourceforge.net/projects/winflexbison/ |
19 | Extract the contents of the package in the directory "..\win_flex_bison" |
||
190 | dmarschall | 20 | |
21 | 3) Adobe Photoshop SDK |
||
22 | Available on some Photoshop CDs, or can be downloaded at |
||
192 | daniel-mar | 23 | https://www.adobe.com/devnet/photoshop/sdk.html |
24 | Extract the contents of the package in the directory "..\photoshop_sdk" |
||
190 | dmarschall | 25 | |
193 | daniel-mar | 26 | 4) Windows SDK |
190 | dmarschall | 27 | Download the Windows SDK here: |
192 | daniel-mar | 28 | https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk/ |
190 | dmarschall | 29 | and install the following components: |
192 | daniel-mar | 30 | - Windows SDK for Desktop C++ x86 Apps |
31 | - Windows SDK for Desktop C++ amd64 Apps |
||
32 | For some reason, you only need to install the Windows SDK if you |
||
33 | build using the IDE, but not if you build using command-line (*.mak files). |
||
190 | dmarschall | 34 | |
35 | |||
192 | daniel-mar | 36 | Build setup using the IDE |
37 | ------------------------- |
||
190 | dmarschall | 38 | |
192 | daniel-mar | 39 | 1. Open the visual_studio\FilterFoundry.sln with Visual Studio |
190 | dmarschall | 40 | |
194 | daniel-mar | 41 | 2. Go to the project settings and change the Windows SDK version and |
42 | Platform Toolset to the one you have installed. |
||
190 | dmarschall | 43 | |
192 | daniel-mar | 44 | 3. You can now compile the x86 and x64 plugins inside the IDE. |
190 | dmarschall | 45 | The output files are: |
192 | daniel-mar | 46 | C:\FilterFoundry\Source\visual_studio\Win32\(Release|Debug)\FilterFoundry.8bf |
47 | C:\FilterFoundry\Source\visual_studio\Win64\(Release|Debug)\FilterFoundry64.8bf |
||
190 | dmarschall | 48 | |
49 | |||
192 | daniel-mar | 50 | Build setup using command line/nmake |
51 | ------------------------------------ |
||
190 | dmarschall | 52 | |
192 | daniel-mar | 53 | 1. Check/Edit visual_studio\vc_make_3264.bat: Change the Visual Studio path to the one you have on your system. |
190 | dmarschall | 54 | |
192 | daniel-mar | 55 | 2. You can now use the script visual_studio\vc_make_3264.bat to build both x86 and x64 with one click. |
190 | dmarschall | 56 | The output files are: |
192 | daniel-mar | 57 | ...\visual_studio\FilterFoundry.8bf |
58 | ...\visual_studio\FilterFoundry64.8bf |
||
190 | dmarschall | 59 | |
60 | |||
192 | daniel-mar | 61 | Troubleshooting |
62 | --------------- |
||
190 | dmarschall | 63 | |
64 | - If "rc" can't be found, install the Windows 10 SDK, and then copy |
||
192 | daniel-mar | 65 | C:\Program Files (x86)\Windows Kits\10\bin\...\x64 to |
66 | C:\Program Files (x86)\Windows Kits\10\bin\x86 |
||
190 | dmarschall | 67 | see also https://stackoverflow.com/questions/43847542/rc-exe-no-longer-found-in-vs-2015-command-prompt |
68 | |||
192 | daniel-mar | 69 | - If lex.yy.c can't be found, check the flex command (it generates lex.yy.c) |
70 | in the project properties or the mak-file, respectively. |
||
190 | dmarschall | 71 | |
72 | - If nmake gives the error message "makefile(28) : fatal error U1000: Syntax error: ")" missing in macro invocation" |
||
73 | then run nmake with the parameter "/f nmake.mak" or "/f nmake64.mak" |
||
74 | (nmake calls Makefile by default, which is written for the 'normal' "make" and not "nmake") |
||
75 | |||
76 | - If you run into any problems, try "nmake /f nmake.mak clean" followed by "nmake /f nmake.mak", |
||
77 | or for 64 bit: "nmake /f nmake64.mak clean" followed by "nmake /f nmake64.mak" |
||
192 | daniel-mar | 78 | It is necessary to run the "clean" command when switching between 32-bit and 64-bit builds. |
190 | dmarschall | 79 | |
80 | - Since the RC files have a complex structure, you cannot edit the resources inside the IDE. |
||
81 | You need to edit the *.rc files manually. |
||
192 | daniel-mar | 82 | |
83 | - If the winflex/bison prebuild commands fail, Visual Studio will just show the message |
||
84 | 'The command "cd ..' |
||
85 | because the command contains line breaks and so you will only see the first command "cd ..". |
||
86 | Hover the mouse over the error message to display the whole message (commands), |
||
87 | or copy it using Ctrl+C and paste it into a text editor. |