From 4b6899c098f97960bf58456313ac8d643336dcd0 Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Sun, 14 Oct 2012 09:45:11 +0000 Subject: YAMN: folders restructurization git-svn-id: http://svn.miranda-ng.org/main/trunk@1919 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/YAMN/filter/Simple/AggressiveOptimize.h | 168 ----------------- .../YAMN/filter/Simple/docs/simple-readme.txt | 51 ----- protocols/YAMN/filter/Simple/maindll.cpp | 132 ------------- protocols/YAMN/filter/Simple/simple.dsp | 105 ----------- protocols/YAMN/filter/Simple/simple.mak | 207 --------------------- 5 files changed, 663 deletions(-) delete mode 100644 protocols/YAMN/filter/Simple/AggressiveOptimize.h delete mode 100644 protocols/YAMN/filter/Simple/docs/simple-readme.txt delete mode 100644 protocols/YAMN/filter/Simple/maindll.cpp delete mode 100644 protocols/YAMN/filter/Simple/simple.dsp delete mode 100644 protocols/YAMN/filter/Simple/simple.mak (limited to 'protocols/YAMN/filter/Simple') diff --git a/protocols/YAMN/filter/Simple/AggressiveOptimize.h b/protocols/YAMN/filter/Simple/AggressiveOptimize.h deleted file mode 100644 index 1bf0e19c2c..0000000000 --- a/protocols/YAMN/filter/Simple/AggressiveOptimize.h +++ /dev/null @@ -1,168 +0,0 @@ - -////////////////////////////// -// Version 1.40 -// October 22nd, 2002 - .NET (VC7, _MSC_VER=1300) support! -// Version 1.30 -// Nov 24th, 2000 -// Version 1.20 -// Jun 9th, 2000 -// Version 1.10 -// Jan 23rd, 2000 -// Version 1.00 -// May 20th, 1999 -// Todd C. Wilson, Fresh Ground Software -// (todd@nopcode.com) -// This header file will kick in settings for Visual C++ 5 and 6 that will (usually) -// result in smaller exe's. -// The "trick" is to tell the compiler to not pad out the function calls; this is done -// by not using the /O1 or /O2 option - if you do, you implicitly use /Gy, which pads -// out each and every function call. In one single 500k dll, I managed to cut out 120k -// by this alone! -// The other two "tricks" are telling the Linker to merge all data-type segments together -// in the exe file. The relocation, read-only (constants) data, and code section (.text) -// sections can almost always be merged. Each section merged can save 4k in exe space, -// since each section is padded out to 4k chunks. This is very noticeable with smaller -// exes, since you could have only 700 bytes of data, 300 bytes of code, 94 bytes of -// strings - padded out, this could be 12k of runtime, for 1094 bytes of stuff! For larger -// programs, this is less overall, but can save at least 4k. -// Note that if you're using MFC static or some other 3rd party libs, you may get poor -// results with merging the readonly (.rdata) section - the exe may grow larger. -// To use this feature, define _MERGE_DATA_ in your project or before this header is used. -// With Visual C++ 5, the program uses a file alignment of 512 bytes, which results -// in a small exe. Under VC6, the program instead uses 4k, which is the same as the -// section size. The reason (from what I understand) is that 4k is the chunk size of -// the virtual memory manager, and that WinAlign (an end-user tuning tool for Win98) -// will re-align the programs on this boundary. The problem with this is that all of -// Microsoft's system exes and dlls are *NOT* tuned like this, and using 4k causes serious -// exe bloat. This is very noticeable for smaller programs. -// The "trick" for this is to use the undocumented FILEALIGN linker parm to change the -// padding from 4k to 1/2k, which results in a much smaller exe - anywhere from 20%-75% -// depending on the size. Note that this is the same as using /OPT:NOWIN98, which *is* -// a previously documented switch, but was left out of the docs for some reason in VC6 and -// all of the current MSDN's - see KB:Q235956 for more information. -// Microsoft does say that using the 4k alignment will "speed up process loading", -// but I've been unable to notice a difference, even on my P180, with a very large (4meg) exe. -// Please note, however, that this will probably not change the size of the COMPRESSED -// file (either in a .zip file or in an install archive), since this 4k is all zeroes and -// gets compressed away. -// Also, the /ALIGN:4096 switch will "magically" do the same thing, even though this is the -// default setting for this switch. Apparently this sets the same values as the above two -// switches do. We do not use this in this header, since it smacks of a bug and not a feature. -// Thanks to Michael Geary for some additional tips! -// -// Notes about using this header in .NET -// First off, VC7 does not allow a lot of the linker command options in pragma's. There is no -// honest or good reason why Microsoft decided to make this change, it just doesn't. -// So that is why there are a lot of <1300 #if's in the header. -// If you want to take full advantage of the VC7 linker options, you will need to do it on a -// PER PROJECT BASIS; you can no longer use a global header file like this to make it better. -// Items I strongly suggest putting in all your VC7 project linker options command line settings: -// /ignore:4078 /RELEASE -// Compiler options: -// /GL (Whole Program Optimization) -// If you're making an .EXE and not a .DLL, consider adding in: -// /GA (Optimize for Windows Application) -// Some items to consider using in your VC7 projects (not VC6): -// Link-time Code Generation - whole code optimization. Put this in your exe/dll project link settings. -// /LTCG:NOSTATUS -// The classic no-padding and no-bloat compiler C/C++ switch: -// /opt:nowin98 -// -// (C++ command line options: /GL /opt:nowin98 and /GA for .exe files) -// (Link command line options: /ignore:4078 /RELEASE /LTCG:NOSTATUS) -// -// Now, notes on using these options in VC7 vs VC6. -// VC6 consistently, for me, produces smaller code from C++ the exact same sources, -// with or without this header. On average, VC6 produces 5% smaller binaries compared -// to VC7 compiling the exact same project, *without* this header. With this header, VC6 -// will make a 13k file, while VC7 will make a 64k one. VC7 is just bloaty, pure and -// simple - all that managed/unmanaged C++ runtimes, and the CLR stuff must be getting -// in the way of code generation. However, template support is better, so there. -// Both VC6 and VC7 show the same end kind of end result savings - larger binary output -// will shave about 2% off, where as smaller projects (support DLL's, cpl's, -// activex controls, ATL libs, etc) get the best result, since the padding is usually -// more than the actual usable code. But again, VC7 does not compile down as small as VC6. -// -// The argument can be made that doing this is a waste of time, since the "zero bytes" -// will be compressed out in a zip file or install archive. Not really - it doesn't matter -// if the data is a string of zeroes or ones or 85858585 - it will still take room (20 bytes -// in a zip file, 29 bytes if only *4* of them 4k bytes are not the same) and time to -// compress that data and decompress it. Also, 20k of zeros is NOT 20k on disk - it's the -// size of the cluster slop- for Fat32 systems, 20k can be 32k, NTFS could make it 24k if you're -// just 1 byte over (round up). Most end users do not have the dual P4 Xeon systems with -// two gigs of RDram and a Raid 0+1 of Western Digital 120meg Special Editions that all -// worthy developers have (all six of us), so they will need any space and LOADING TIME -// savings they will need; taking an extra 32k or more out of your end user's 64megs of -// ram on Windows 98 is Not a Good Thing. -// -// Now, as a ADDED BONUS at NO EXTRA COST TO YOU! Under VC6, using the /merge:.text=.data -// pragma will cause the output file to be un-disassembleable! (is that a word?) At least, -// with the normal tools - WinDisam, DumpBin, and the like will not work. Try it - use the -// header, compile release, and then use DUMPBIN /DISASM filename.exe - no code! -// Thanks to Gëzim Pani for discovering this gem - for a full writeup on -// this issue and the ramifactions of it, visit www.nopcode.com for the Aggressive Optimize -// article. - -#ifndef _AGGRESSIVEOPTIMIZE_H_ -#define _AGGRESSIVEOPTIMIZE_H_ - -#pragma warning(disable:4711) - -#ifdef NDEBUG -// /Og (global optimizations), /Os (favor small code), /Oy (no frame pointers) -#pragma optimize("gsy",on) - -#if (_MSC_VER<1300) - #pragma comment(linker,"/RELEASE") -#endif - -/* -// Note that merging the .rdata section will result in LARGER exe's if you using -// MFC (esp. static link). If this is desirable, define _MERGE_RDATA_ in your project. -#ifdef _MERGE_RDATA_ -#pragma comment(linker,"/merge:.rdata=.data") -#endif // _MERGE_RDATA_ - -#pragma comment(linker,"/merge:.text=.data") -#if (_MSC_VER<1300) - // In VC7, this causes problems with the relocation and data tables, so best to not merge them - #pragma comment(linker,"/merge:.reloc=.data") -#endif -*/ - -// Merging sections with different attributes causes a linker warning, so -// turn off the warning. From Michael Geary. Undocumented, as usual! -#if (_MSC_VER<1300) - // In VC7, you will need to put this in your project settings - #pragma comment(linker,"/ignore:4078") -#endif - -// With Visual C++ 5, you already get the 512-byte alignment, so you will only need -// it for VC6, and maybe later. -#if _MSC_VER >= 1000 - -// Option #1: use /filealign -// Totally undocumented! And if you set it lower than 512 bytes, the program crashes. -// Either leave at 0x200 or 0x1000 -//#pragma comment(linker,"/FILEALIGN:0x200") - -// Option #2: use /opt:nowin98 -// See KB:Q235956 or the READMEVC.htm in your VC directory for info on this one. -// This is our currently preferred option, since it is fully documented and unlikely -// to break in service packs and updates. -#if (_MSC_VER<1300) - // In VC7, you will need to put this in your project settings - #pragma comment(linker,"/opt:nowin98") -#else - -// Option #3: use /align:4096 -// A side effect of using the default align value is that it turns on the above switch. -// Does nothing under Vc7 that /opt:nowin98 doesn't already give you -// #pragma comment(linker,"/ALIGN:512") -#endif - -#endif // _MSC_VER >= 1000 - -#endif // NDEBUG - -#endif // _AGGRESSIVEOPTIMIZE_H_ diff --git a/protocols/YAMN/filter/Simple/docs/simple-readme.txt b/protocols/YAMN/filter/Simple/docs/simple-readme.txt deleted file mode 100644 index 34c0842c87..0000000000 --- a/protocols/YAMN/filter/Simple/docs/simple-readme.txt +++ /dev/null @@ -1,51 +0,0 @@ -========================== -= Simple Filter for YAMN = -========================== - -Q: What??? -A: YAMN filter to classify incoming email. - -Q: How? -A: Regarding what the email is from and finding it in the blacklist email file. - -Q: Blacklist email file? -A: Yes. It is created by yourself and located in Miranda directory with name 'simplefilterdeny.txt' - -Q: Created by myself? -A: Just create the file and write there your blacklist mails in every line. - -Q: That's all? -A: Yes and no. You can specify spamlevel for each mail. - -Q: Spamlevel? -A: Yes. - 1=notify, display with another color in mailbrowser - 2=do not notify, display with another color in mailbrowser - 3=delete, display in mailbrowser about deleted mail - 4=delete, do not display (mail's quick death, hehe) - -Q: How to specify it? -A: After email press and write number 1-4. Note this is optional. If not defined, level 2 is default. - -Q: Ok, that's easy. -A: Yes, this is the example: -<------ start of file ------> -nigeria@spamserver.com 2 -cheapsoftware@junkmails.net 3 -learnenglish@commercial.org -<------ end of file -------> - -Q: Wait while. Ok, but it does not work. -A: Check if you have this plugin listed in Miranda/Options/Plugins/YAMN item as YAMN plugin. - -Q: No, it is not listed in YAMN plugins. -A: Then check if the dll residents in Plugins/YAMN direcotry. - -Q: This directory does not exists. -A: Create it and put the dll there. Restart Miranda. - -Q: Hmmm, ok. But it is not still listed. -A: Your version of YAMN and filter does not match. - -Q: And? -A: Try to look to http://www.majvan.host.sk/Projekty/YAMN for updates. \ No newline at end of file diff --git a/protocols/YAMN/filter/Simple/maindll.cpp b/protocols/YAMN/filter/Simple/maindll.cpp deleted file mode 100644 index 44a277d4fa..0000000000 --- a/protocols/YAMN/filter/Simple/maindll.cpp +++ /dev/null @@ -1,132 +0,0 @@ -//--------------------------------------------------------------------------- -#include -#include -#include -#include -#include -#include -#include -#include -#include "../../m_filterplugin.h" -#if !defined(_WIN64) - #include "aggressiveoptimize.h" -#endif - -typedef INT_PTR(* MIRANDASERVICE)(WPARAM,LPARAM); - -DWORD WINAPI FilterMail(HACCOUNT Account,DWORD AccountVer,HYAMNMAIL Mail,DWORD MailVer);//Function marks mail as spam when it is spam... -DWORD WINAPI UnLoadFilter(LPVOID); - -YAMN_FILTERIMPORTFCN FilterFunctions= //we set for YAMN which is our filter function -{ - FilterMail, - UnLoadFilter, //No unloading -}; - -YAMN_FILTERREGISTRATION FilterRegistration= //classical YAMN registration -{ - "Simple filter plugin for YAMN", - "", - "© porter+ majvan", - "Classifies mails using the blacklist emails stored in file", - "porterbox@hotmail.com", - "http://www.majvan.host.sk/Projekty/YAMN?fm=soft", -}; - -char *FilterPath=NULL; - -struct YAMNExportedFcn -{ - YAMN_SETFILTERPLUGINFCNIMPORTFCN SetFilterPluginFcnImportFcn; - MIRANDASERVICE RegisterFilterPlugin; -} YAMNFcn,*pYAMNFcn; //exported functions from YAMN we will use - -HYAMNFILTERPLUGIN POPFilePlugin; //handle of this plugin for YAMN -HINSTANCE hInst; //handle of this DLL for Windows - -extern "C" BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fwdreason, LPVOID lpvReserved) -{ - hInst=hinstDLL; - return true; -} - -extern "C" int __declspec(dllexport) LoadFilter(MIRANDASERVICE GetYAMNFcnPtr) -{ - FilterPath=new char[MAX_PATH]; - char *delim; - pYAMNFcn=&YAMNFcn; - - GetModuleFileName(GetModuleHandle(NULL),FilterPath,MAX_PATH); - if(NULL!=(delim=strrchr(FilterPath,'\\'))) - *delim=0; - lstrcat(FilterPath,"\\simplefilterdeny.txt"); - - pYAMNFcn->RegisterFilterPlugin=(MIRANDASERVICE)GetYAMNFcnPtr((WPARAM)MS_YAMN_REGISTERFILTERPLUGIN,(LPARAM)0); - pYAMNFcn->SetFilterPluginFcnImportFcn=(YAMN_SETFILTERPLUGINFCNIMPORTFCN)GetYAMNFcnPtr((WPARAM)YAMN_SETFILTERPLUGINFCNIMPORTID,(LPARAM)0); -//Register our filter plugin to YAMN - if(NULL==(POPFilePlugin=(HYAMNFILTERPLUGIN)pYAMNFcn->RegisterFilterPlugin((WPARAM)&FilterRegistration,(LPARAM)YAMN_FILTERREGISTRATIONVERSION))) - return 0; -//And add our imported functions for YAMN - if (!pYAMNFcn->SetFilterPluginFcnImportFcn(POPFilePlugin,0xb0000000,&FilterFunctions,YAMN_FILTERIMPORTFCNVERSION)) - return 0; - return 1; //Load luccess -} - -DWORD WINAPI UnLoadFilter(LPVOID) -{ - if(FilterPath!=NULL) - delete[] FilterPath; - FilterPath=NULL; - - return 0; -} - -extern "C" int __declspec(dllexport) UninstallFilter() -{ - if(FilterPath==NULL) - MessageBox(NULL,"Cannot delete blacklist file when Simple Filter is not loaded. Please do it manually.","Simple Filter uninstalling",MB_OK|MB_ICONWARNING); - else - DeleteFile(FilterPath); - return 0; -} - - -//And this is main filter function. -DWORD WINAPI FilterMail(HACCOUNT Account,DWORD AccountVer,HYAMNMAIL Mail,DWORD MailVer) -{ - FILE *fp; - char EmailSpam[256]; - unsigned char spamLevel; - struct CMimeItem *Browser; - - if(MailVer!=YAMN_MAILVERSION) //we test if we work with the right YAMNMAIL - return 0; - if(Mail->MailData==NULL) //MailData should be available - return 0; - fp=fopen(FilterPath,"rt"); - if(fp != NULL) { - if (!(Mail->Flags & YAMN_MSG_VIRTUAL)) - for(Browser=Mail->MailData->TranslatedHeader;Browser!=NULL;Browser=Browser->Next) { //we browse all header stored in Mail->TranslatedHeader - if ((!lstrcmp(Browser->name,"Return-Path")) || (!lstrcmp(Browser->name,"From"))) { //and if we find - fseek(fp, 0L, SEEK_SET); - while(!feof(fp)) { - if(fscanf(fp, "%255s", EmailSpam) != 0) { - if (!feof(fp)) - if(fscanf(fp, "%d", &spamLevel)==0) - spamLevel=2; - if(spamLevel>4) - spamLevel=2; - if(strstr(Browser->value,EmailSpam)!=NULL) { - if ((Mail->Flags & (YAMN_MSG_SPAMMASK==0)) && (spamLevel==0)) - Mail->Flags&=~(YAMN_MSG_SOUND | YAMN_MSG_APP | YAMN_MSG_POPUP | YAMN_MSG_SYSTRAY | YAMN_MSG_BROWSER); - else if ((Mail->Flags & YAMN_MSG_SPAMMASK) < spamLevel) //if some filter plugin set higher level of spam, we do nothing - Mail->Flags=(Mail->Flags & ~YAMN_MSG_SPAMMASK)+spamLevel; //else we set spam level 2 (clearing spam bits and then settting them to level 2 - } - } - } - } - } - fclose(fp); - } - return 1; -} diff --git a/protocols/YAMN/filter/Simple/simple.dsp b/protocols/YAMN/filter/Simple/simple.dsp deleted file mode 100644 index dc6d52e6c1..0000000000 --- a/protocols/YAMN/filter/Simple/simple.dsp +++ /dev/null @@ -1,105 +0,0 @@ -# Microsoft Developer Studio Project File - Name="simple" - Package Owner=<4> -# Microsoft Developer Studio Generated Build File, Format Version 6.00 -# ** NICHT BEARBEITEN ** - -# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102 - -CFG=simple - Win32 Release -!MESSAGE Dies ist kein gültiges Makefile. Zum Erstellen dieses Projekts mit NMAKE -!MESSAGE verwenden Sie den Befehl "Makefile exportieren" und führen Sie den Befehl -!MESSAGE -!MESSAGE NMAKE /f "simple.mak". -!MESSAGE -!MESSAGE Sie können beim Ausführen von NMAKE eine Konfiguration angeben -!MESSAGE durch Definieren des Makros CFG in der Befehlszeile. Zum Beispiel: -!MESSAGE -!MESSAGE NMAKE /f "simple.mak" CFG="simple - Win32 Release" -!MESSAGE -!MESSAGE Für die Konfiguration stehen zur Auswahl: -!MESSAGE -!MESSAGE "simple - Win32 Release" (basierend auf "Win32 (x86) Dynamic-Link Library") -!MESSAGE "simple - Win32 Debug" (basierend auf "Win32 (x86) Dynamic-Link Library") -!MESSAGE - -# Begin Project -# PROP AllowPerConfigDependencies 0 -# PROP Scc_ProjName "" -# PROP Scc_LocalPath "" -CPP=cl.exe -MTL=midl.exe -RSC=rc.exe - -!IF "$(CFG)" == "simple - Win32 Release" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 0 -# PROP BASE Output_Dir "Release" -# PROP BASE Intermediate_Dir "Release" -# PROP BASE Ignore_Export_Lib 1 -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 0 -# PROP Output_Dir "Release" -# PROP Intermediate_Dir "Release" -# PROP Ignore_Export_Lib 1 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /G4 /Zp4 /MD /W3 /GX /O1 /Ob0 /I "../../../../include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c -# ADD CPP /nologo /G4 /Zp4 /MD /W3 /GX /Zi /O1 /Ob0 /I "../../../../include" /I "../../../../include/msapi" /I "../../../../include_API" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c -# ADD BASE RSC /l 0x417 /d "NDEBUG" -# ADD RSC /l 0x417 /d "NDEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib /nologo /dll /machine:I386 /out:"../../../../bin/release/plugins/YAMN-filter/simple.dll" /filealign:512 -# ADD LINK32 kernel32.lib user32.lib /nologo /dll /pdb:"../../../../bin/Release/plugins/YAMN/simple.pdb" /debug /machine:I386 /out:"../../../../bin/Release/plugins/YAMN/simple.dll" /filealign:512 - -!ELSEIF "$(CFG)" == "simple - Win32 Debug" - -# PROP BASE Use_MFC 0 -# PROP BASE Use_Debug_Libraries 1 -# PROP BASE Output_Dir "Debug" -# PROP BASE Intermediate_Dir "Debug" -# PROP BASE Ignore_Export_Lib 1 -# PROP BASE Target_Dir "" -# PROP Use_MFC 0 -# PROP Use_Debug_Libraries 1 -# PROP Output_Dir "Debug" -# PROP Intermediate_Dir "Debug" -# PROP Ignore_Export_Lib 1 -# PROP Target_Dir "" -# ADD BASE CPP /nologo /G4 /Zp4 /MDd /W3 /Gm /Gi /GX /ZI /Od /I "../../../../include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /YX /FD /GZ /c -# ADD CPP /nologo /G4 /Zp4 /MDd /W3 /Gm /Gi /GX /ZI /Od /I "../../../../include" /I "../../../../include/msapi" /I "../../../../include_API" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /YX /FD /GZ /c -# ADD BASE RSC /l 0x417 /d "_DEBUG" -# ADD RSC /l 0x417 /d "_DEBUG" -BSC32=bscmake.exe -# ADD BASE BSC32 /nologo -# ADD BSC32 /nologo -LINK32=link.exe -# ADD BASE LINK32 kernel32.lib user32.lib /nologo /dll /debug /machine:I386 /out:"../../../../bin/Debug/plugins/YAMN-filter/simple.dll" -# ADD LINK32 kernel32.lib user32.lib /nologo /dll /pdb:"../../../../bin/Debug/plugins/YAMN/simple.pdb" /debug /machine:I386 /out:"../../../../bin/Debug/plugins/YAMN/simple.dll" /pdbtype:sept - -!ENDIF - -# Begin Target - -# Name "simple - Win32 Release" -# Name "simple - Win32 Debug" -# Begin Group "Source Files" - -# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat" -# Begin Source File - -SOURCE=.\maindll.cpp -# End Source File -# End Group -# Begin Group "Header Files" - -# PROP Default_Filter "h;hpp;hxx;hm;inl" -# End Group -# Begin Group "Resource Files" - -# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe" -# End Group -# End Target -# End Project diff --git a/protocols/YAMN/filter/Simple/simple.mak b/protocols/YAMN/filter/Simple/simple.mak deleted file mode 100644 index 085dc22e33..0000000000 --- a/protocols/YAMN/filter/Simple/simple.mak +++ /dev/null @@ -1,207 +0,0 @@ -# Microsoft Developer Studio Generated NMAKE File, Based on simple.dsp -!IF "$(CFG)" == "" -CFG=simple - Win32 Release -!MESSAGE No configuration specified. Defaulting to simple - Win32 Release. -!ENDIF - -!IF "$(CFG)" != "simple - Win32 Release" && "$(CFG)" != "simple - Win32 Debug" -!MESSAGE Invalid configuration "$(CFG)" specified. -!MESSAGE You can specify a configuration when running NMAKE -!MESSAGE by defining the macro CFG on the command line. For example: -!MESSAGE -!MESSAGE NMAKE /f "simple.mak" CFG="simple - Win32 Release" -!MESSAGE -!MESSAGE Possible choices for configuration are: -!MESSAGE -!MESSAGE "simple - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE "simple - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") -!MESSAGE -!ERROR An invalid configuration is specified. -!ENDIF - -!IF "$(OS)" == "Windows_NT" -NULL= -!ELSE -NULL=nul -!ENDIF - -!IF "$(CFG)" == "simple - Win32 Release" - -OUTDIR=.\Release -INTDIR=.\Release - -ALL : "..\..\..\..\bin\release\plugins\YAMN-filter\simple.dll" - - -CLEAN : - -@erase "$(INTDIR)\maindll.obj" - -@erase "$(INTDIR)\vc60.idb" - -@erase "$(OUTDIR)\simple.exp" - -@erase "..\..\..\..\bin\release\plugins\YAMN-filter\simple.dll" - -"$(OUTDIR)" : - if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" - -CPP=cl.exe -CPP_PROJ=/nologo /G4 /Zp4 /MD /W3 /GX /O1 /Ob0 /I "../../../../include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /Fp"$(INTDIR)\simple.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c - -.c{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.c{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -MTL=midl.exe -MTL_PROJ= -RSC=rc.exe -BSC32=bscmake.exe -BSC32_FLAGS=/nologo /o"$(OUTDIR)\simple.bsc" -BSC32_SBRS= \ - -LINK32=link.exe -LINK32_FLAGS=kernel32.lib user32.lib /nologo /dll /incremental:no /pdb:"$(OUTDIR)\simple.pdb" /machine:I386 /out:"../../../../bin/release/plugins/YAMN-filter/simple.dll" /implib:"$(OUTDIR)\simple.lib" /filealign:512 -LINK32_OBJS= \ - "$(INTDIR)\maindll.obj" - -"..\..\..\..\bin\release\plugins\YAMN-filter\simple.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) - $(LINK32) @<< - $(LINK32_FLAGS) $(LINK32_OBJS) -<< - -!ELSEIF "$(CFG)" == "simple - Win32 Debug" - -OUTDIR=.\Debug -INTDIR=.\Debug -# Begin Custom Macros -OutDir=.\Debug -# End Custom Macros - -ALL : "..\..\..\..\bin\Debug\plugins\YAMN-filter\simple.dll" "$(OUTDIR)\simple.bsc" - - -CLEAN : - -@erase "$(INTDIR)\maindll.obj" - -@erase "$(INTDIR)\maindll.sbr" - -@erase "$(INTDIR)\vc60.idb" - -@erase "$(INTDIR)\vc60.pdb" - -@erase "$(OUTDIR)\simple.bsc" - -@erase "$(OUTDIR)\simple.exp" - -@erase "$(OUTDIR)\simple.pdb" - -@erase "..\..\..\..\bin\Debug\plugins\YAMN-filter\simple.dll" - -@erase "..\..\..\..\bin\Debug\plugins\YAMN-filter\simple.ilk" - -"$(OUTDIR)" : - if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" - -CPP=cl.exe -CPP_PROJ=/nologo /G4 /Zp4 /MDd /W3 /Gm /Gi /GX /ZI /Od /I "../../../../include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR"$(INTDIR)\\" /Fp"$(INTDIR)\simple.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c - -.c{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.obj:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.c{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cpp{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -.cxx{$(INTDIR)}.sbr:: - $(CPP) @<< - $(CPP_PROJ) $< -<< - -MTL=midl.exe -MTL_PROJ= -RSC=rc.exe -BSC32=bscmake.exe -BSC32_FLAGS=/nologo /o"$(OUTDIR)\simple.bsc" -BSC32_SBRS= \ - "$(INTDIR)\maindll.sbr" - -"$(OUTDIR)\simple.bsc" : "$(OUTDIR)" $(BSC32_SBRS) - $(BSC32) @<< - $(BSC32_FLAGS) $(BSC32_SBRS) -<< - -LINK32=link.exe -LINK32_FLAGS=kernel32.lib user32.lib /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\simple.pdb" /debug /machine:I386 /out:"../../../../bin/Debug/plugins/YAMN-filter/simple.dll" /implib:"$(OUTDIR)\simple.lib" -LINK32_OBJS= \ - "$(INTDIR)\maindll.obj" - -"..\..\..\..\bin\Debug\plugins\YAMN-filter\simple.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) - $(LINK32) @<< - $(LINK32_FLAGS) $(LINK32_OBJS) -<< - -!ENDIF - - -!IF "$(NO_EXTERNAL_DEPS)" != "1" -!IF EXISTS("simple.dep") -!INCLUDE "simple.dep" -!ELSE -!MESSAGE Warning: cannot find "simple.dep" -!ENDIF -!ENDIF - - -!IF "$(CFG)" == "simple - Win32 Release" || "$(CFG)" == "simple - Win32 Debug" -SOURCE=.\maindll.cpp - -!IF "$(CFG)" == "simple - Win32 Release" - - -"$(INTDIR)\maindll.obj" : $(SOURCE) "$(INTDIR)" - - -!ELSEIF "$(CFG)" == "simple - Win32 Debug" - - -"$(INTDIR)\maindll.obj" "$(INTDIR)\maindll.sbr" : $(SOURCE) "$(INTDIR)" - - -!ENDIF - - -!ENDIF - -- cgit v1.2.3