]>
git.saurik.com Git - apple/mdnsresponder.git/blob - mDNSMacOS9/mDNSPrefix.h
1 /* -*- Mode: C; tab-width: 4 -*-
3 * Copyright (c) 2004 Apple Computer, Inc. All rights reserved.
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
17 Change History (most recent first):
19 $Log: mDNSPrefix.h,v $
20 Revision 1.4 2006/08/14 23:24:29 cheshire
21 Re-licensed mDNSResponder daemon source code under Apache License, Version 2.0
23 Revision 1.3 2004/06/11 00:03:28 cheshire
24 Add code for testing avail/busy subtypes
26 Revision 1.2 2004/05/21 01:57:08 cheshire
27 Add macros for malloc() and free() so that dnssd_clientlib.c can use them
29 Revision 1.1 2004/03/12 21:30:26 cheshire
30 Build a System-Context Shared Library from mDNSCore, for the benefit of developers
31 like Muse Research who want to be able to use mDNS/DNS-SD from GPL-licensed code.
35 // Global definitions that apply to all source files
37 // Symbols that are defined here are available within all source files.
38 // This is the equivalent of using using "-d SYMBOL=VALUE" in a Makefile
39 // in command-line build environments.
41 // For normal DeferredTask time execution, set MDNS_ONLYSYSTEMTASK to 0
42 // For easier debugging, set MDNS_ONLYSYSTEMTASK to 1, and OT Notifier executions
43 // will be deferred until SystemTask time. (This option is available only for building
44 // the standalone application samples that have their own event loop -- don't try
45 // to build the System Extension with MDNS_ONLYSYSTEMTASK set because it won't work.)
47 #if __ide_target("Standalone TestResponder") || __ide_target("Standalone TestSearcher") || __ide_target("Standalone SubTypeTester")
48 #define TARGET_API_MAC_CARBON 1
49 #define OTCARBONAPPLICATION 1
50 #define MDNS_ONLYSYSTEMTASK 0
51 #define MDNS_DEBUGMSGS 0
53 #elif __ide_target("Standalone TestResponder (Debug)") || __ide_target("Standalone TestSearcher (Debug)")
54 #define TARGET_API_MAC_CARBON 1
55 #define OTCARBONAPPLICATION 1
56 #define MDNS_ONLYSYSTEMTASK 1
57 #define MDNS_DEBUGMSGS 1
59 #elif __ide_target("Standalone TestResponder (Classic)") || __ide_target("Standalone TestSearcher (Classic)")
60 #define MDNS_ONLYSYSTEMTASK 0
61 #define MDNS_DEBUGMSGS 0
63 #elif __ide_target("CFM Library for Extensions Folder")
64 #define MDNS_BUILDINGSHAREDLIBRARY 2
66 #elif __ide_target("CFM Library for Extensions (Debug)")
67 #define MDNS_DEBUGMSGS 0
68 #define MDNS_BUILDINGSHAREDLIBRARY 1
70 #elif __ide_target("CFM Stub for clients to link against")
71 #define MDNS_BUILDINGSTUBLIBRARY 1
74 #error Options for this target not found in prefix file
77 // dnssd_clientlib.c assumes malloc() and free(), so we #define them here to be the OT equivalents
78 #if MDNS_BUILDINGSHAREDLIBRARY || MDNS_BUILDINGSTUBLIBRARY
79 #define malloc(x) OTAllocMem(x)
80 #define free(x) OTFreeMem(x)