Wrap up version 1.3.3.
[minidlna.git] / options.h
blob1ff5b2208043a435fb31eb9ab161172ed6004e86
1 /* MiniUPnP project
2 * http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
3 * author: Ryan Wagoner
5 * Copyright (c) 2006, Thomas Bernard
6 * All rights reserved.
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions are met:
10 * * Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer.
12 * * Redistributions in binary form must reproduce the above copyright
13 * notice, this list of conditions and the following disclaimer in the
14 * documentation and/or other materials provided with the distribution.
15 * * The name of the author may not be used to endorse or promote products
16 * derived from this software without specific prior written permission.
18 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
22 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28 * POSSIBILITY OF SUCH DAMAGE.
30 #ifndef __OPTIONS_H__
31 #define __OPTIONS_H__
33 #include "config.h"
35 /* enum of option available in the miniupnpd.conf */
36 enum upnpconfigoptions {
37 UPNP_INVALID = 0,
38 UPNPIFNAME = 1, /* ext_ifname */
39 UPNPPORT, /* port */
40 UPNPPRESENTATIONURL, /* presentation_url */
41 UPNPNOTIFY_INTERVAL, /* notify_interval */
42 UPNPUUID, /* uuid */
43 UPNPSERIAL, /* serial */
44 UPNPMODEL_NAME, /* model_name */
45 UPNPMODEL_NUMBER, /* model_number */
46 UPNPFRIENDLYNAME, /* how the system should show up to DLNA clients */
47 UPNPMEDIADIR, /* directory to search for UPnP-A/V content */
48 UPNPALBUMART_NAMES, /* list of '/'-delimited file names to check for album art */
49 UPNPINOTIFY, /* enable inotify on the media directories */
50 UPNPDBDIR, /* base directory to store the database and album art cache */
51 UPNPLOGDIR, /* base directory to store the log file */
52 UPNPLOGLEVEL, /* logging verbosity */
53 UPNPMINISSDPDSOCKET, /* minissdpdsocket */
54 ENABLE_TIVO, /* enable support for streaming images and music to TiVo */
55 ENABLE_DLNA_STRICT, /* strictly adhere to DLNA specs */
56 ROOT_CONTAINER, /* root ObjectID (instead of "0") */
57 USER_ACCOUNT, /* user account to run as */
58 FORCE_SORT_CRITERIA, /* force sorting by a given sort criteria */
59 MAX_CONNECTIONS, /* maximum number of simultaneous connections */
60 MERGE_MEDIA_DIRS, /* don't add an extra directory level when there are multiple media dirs */
61 WIDE_LINKS, /* allow following symlinks outside the defined media_dirs */
62 TIVO_DISCOVERY, /* TiVo discovery protocol: bonjour or beacon. Defaults to bonjour if supported */
63 ENABLE_SUBTITLES, /* Enable generic subtitle support for all clients by default */
66 /* readoptionsfile()
67 * parse and store the option file values
68 * returns: 0 success, -1 failure */
69 int
70 readoptionsfile(const char * fname);
72 /* freeoptions()
73 * frees memory allocated to option values */
74 void
75 freeoptions(void);
77 #define MAX_OPTION_VALUE_LEN (200)
78 struct option
80 enum upnpconfigoptions id;
81 char value[MAX_OPTION_VALUE_LEN];
84 extern struct option * ary_options;
85 extern int num_options;
87 #endif