Revision 1834

trunk/config.h.win32 (revision 1834)
1
/* config.h.  Generated from config.h.in by configure.  */
2
/* config.h.in.  Generated from configure.in by autoheader.  */
3

                
4
/* Activate IPV6 support */
5
#define ENABLE_IPV6 1
6

                
7
/* always defined to indicate that i18n is enabled */
8
#define ENABLE_NLS 1
9

                
10
/* Define if SSP C support is enabled. */
11
/* #undef ENABLE_SSP_CC */
12

                
13
/* Define if SSP C++ support is enabled. */
14
/* #undef ENABLE_SSP_CXX */
15

                
16
/* Gettext package */
17
#define GETTEXT_PACKAGE "NNTPGrab"
18

                
19
/* backtrace_symbols check */
20
/* #undef HAVE_BACKTRACE */
21

                
22
/* Define to 1 if you have the `bind_textdomain_codeset' function. */
23
#define HAVE_BIND_TEXTDOMAIN_CODESET 1
24

                
25
/* Define to 1 if you have the `dcgettext' function. */
26
#define HAVE_DCGETTEXT 1
27

                
28
/* Define to 1 if you have the  header file. */
29
/* #undef HAVE_DLFCN_H */
30

                
31
/* Define if the GNU gettext() function is already present or preinstalled. */
32
#define HAVE_GETTEXT 1
33

                
34
/* Define to 1 if you have the  header file. */
35
#define HAVE_INTTYPES_H 1
36

                
37
/* Define if your  file defines LC_MESSAGES. */
38
/* #undef HAVE_LC_MESSAGES */
39

                
40
/* Define to 1 if you have the  header file. */
41
#define HAVE_LOCALE_H 1
42

                
43
/* Define to 1 if you have the  header file. */
44
#define HAVE_MEMORY_H 1
45

                
46
/* Define to 1 if you have the  header file. */
47
#define HAVE_STDINT_H 1
48

                
49
/* Define to 1 if you have the  header file. */
50
#define HAVE_STDLIB_H 1
51

                
52
/* Define to 1 if you have the  header file. */
53
#define HAVE_STRINGS_H 1
54

                
55
/* Define to 1 if you have the  header file. */
56
#define HAVE_STRING_H 1
57

                
58
/* strptime check */
59
/* #undef HAVE_STRPTIME */
60

                
61
/* Define to 1 if you have the  header file. */
62
#define HAVE_SYS_STAT_H 1
63

                
64
/* Define to 1 if you have the  header file. */
65
#define HAVE_SYS_TYPES_H 1
66

                
67
/* Define to 1 if you have the  header file. */
68
/* #undef HAVE_UNISTD_H */
69

                
70
/* Define to 1 if you have the  header file. */
71
#define HAVE_IO_H 1
72

                
73
/* Major version number */
74
#define MAJOR_VERSION 0
75

                
76
/* Micro version number */
77
#define MICRO_VERSION 89
78

                
79
/* Minor version number */
80
#define MINOR_VERSION 3
81

                
82
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
83
/* #undef NO_MINUS_C_MINUS_O */
84

                
85
/* Name of package */
86
#define PACKAGE "nntpgrab"
87

                
88
/* Define to the address where bug reports for this package should be sent. */
89
#define PACKAGE_BUGREPORT ""
90

                
91
/* Define to the full name of this package. */
92
#define PACKAGE_NAME "nntpgrab"
93

                
94
/* Define to the full name and version of this package. */
95
#define PACKAGE_STRING "nntpgrab 0.3.89"
96

                
97
/* Define to the one symbol short name of this package. */
98
#define PACKAGE_TARNAME "nntpgrab"
99

                
100
/* Define to the version of this package. */
101
#define PACKAGE_VERSION "0.3.89"
102

                
103
/* Location of NNTPGrab icons */
104
#define SHARE_DIR "/dist/share/nntpgrab"
105

                
106
/* The size of `long', as computed by sizeof. */
107
#define SIZEOF_LONG 4
108

                
109
/* The size of `time_t', as computed by sizeof. */
110
#define SIZEOF_TIME_T 4
111

                
112
/* Define to 1 if you have the ANSI C header files. */
113
#define STDC_HEADERS 1
114

                
115
/* SVN revision number */
116
#define SVN_REVISION "-1"
117

                
118
/* Version number of package */
119
#define VERSION "0.3.89"
120

                
121
/* Is this an Win32 platform */
122
#define WIN32 1
trunk/NNTPGrab.includes (revision 1834)
41 41
/usr/include/libgtkhtml-3.14
42 42
/usr/include/libgtkhtml-3.14/editor
43 43
/usr/include/libgtkhtml-3.14/gtkhtml
44
/usr/include/libsoup-2.4
45
/usr/include/libsoup-gnome-2.4
46
/usr/include/libnm-glib
47
/usr/include/NetworkManager
44 48
/usr/include/gnutls
45 49
/usr/lib64/glib-2.0/include
46 50
/usr/include/QtSolutions/
trunk/nntpgrab_core/nntpconnection_backend_gio.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
23
#ifdef HAVE_GIO_SOCKET
24

                
19 25
#include 
20 26
#include 
21
//#include 
22 27

                
23 28
#include "nntpconnection_backend_gio.h"
24 29
#include "nntpgrab_plugin.h"
... ...
428 433
    iface->send_msg = nntpconnection_backend_gio_send_msg;
429 434
    iface->get_has_ssl_support = nntpconnection_backend_gio_get_has_ssl_support;
430 435
}
436

                
437
#endif
trunk/nntpgrab_core/collection_alloc.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef _MSC_VER
20
#include "config.h.win32"
21
#else
19
#ifdef HAVE_CONFIG_H
22 20
#include "config.h"
23 21
#endif
24 22

                
trunk/nntpgrab_core/download_thread.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
trunk/nntpgrab_core/nntpconnection_backend_native.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
trunk/nntpgrab_core/Makefile.am (revision 1834)
5 5

                
6 6
libnntpgrab_la_SOURCES = configuration.c core_signals.c marshalers.c \
7 7
       nntpconnection.c nntpconnection_backend_iface.c nntpconnection_backend_native.c \
8
       nntpconnection_utils.c nntpgrab_core.c collection_alloc.c decoder_thread.c \
9
       download_thread.c download_queue.c queue_rawfile.c plugins.c throttle.c
10
libnntpgrab_la_CFLAGS = $(GLIB_CFLAGS) $(PCRE_CFLAGS) $(OPENSSL_CFLAGS) -I. -I$(top_srcdir)/plugins -I$(top_srcdir)/base -DG_LOG_DOMAIN=\"NNTPGrab-Core\" -Wall -DIN_NNTPGRAB_CORE
8
       nntpconnection_backend_gio.c nntpconnection_utils.c nntpgrab_core.c collection_alloc.c \
9
       decoder_thread.c download_thread.c download_queue.c queue_rawfile.c plugins.c throttle.c
10
libnntpgrab_la_CFLAGS = $(GLIB_CFLAGS) $(PCRE_CFLAGS) $(OPENSSL_CFLAGS) $(LIBPROXY_CFLAGS) $(GIO_CFLAGS) $(GNUTLS_CFLAGS) $(NSS_CFLAGS) -I. -I$(top_srcdir)/plugins -I$(top_srcdir)/base -DG_LOG_DOMAIN=\"NNTPGrab-Core\" -Wall -DIN_NNTPGRAB_CORE
11 11
libnntpgrab_la_LDFLAGS = -no-undefined -version-info 0:0:0 -export-symbols nntpgrab.def
12
libnntpgrab_la_LIBADD = $(GLIB_LIBS) $(PCRE_LIBS) $(OPENSSL_LIBS) $(top_srcdir)/base/libnntpgrab_utils.la
12
libnntpgrab_la_LIBADD = $(GLIB_LIBS) $(PCRE_LIBS) $(OPENSSL_LIBS) $(LIBPROXY_LIBS) $(GIO_LIBS) $(GNUTLS_LIBS) $(NSS_LIBS) $(top_srcdir)/base/libnntpgrab_utils.la
13 13
if WIN32
14 14
libnntpgrab_la_LIBADD += -lws2_32 -lshlwapi
15 15
libnntpgrab_la_SOURCES += strptime.c
... ...
39 39
pkgconfig_DATA = nntpgrab.pc
40 40
DISTCLEANFILES = nntpgrab.pc
41 41

                
42
if HAVE_SSL
43
libnntpgrab_la_CFLAGS += -DHAVE_SSL
44
endif
45

                
46
if HAVE_GNUTLS
47
libnntpgrab_la_CFLAGS += $(GNUTLS_CFLAGS) -DHAVE_GNUTLS
48
libnntpgrab_la_LIBADD += $(GNUTLS_LIBS)
49
endif
50

                
51
if HAVE_NSS_COMPAT_OSSL
52
libnntpgrab_la_CFLAGS += $(NSS_CFLAGS) -DHAVE_NSS_COMPAT_OSSL
53
libnntpgrab_la_LIBADD += $(NSS_LIBS)
54
endif
55

                
56
if HAVE_LIBPROXY
57
libnntpgrab_la_CFLAGS += $(LIBPROXY_CFLAGS) -DHAVE_LIBPROXY
58
libnntpgrab_la_LIBADD += $(LIBPROXY_LIBS)
59
endif
60

                
61
if HAVE_GIO_SOCKET
62
libnntpgrab_la_CFLAGS += $(GIO_CFLAGS) -DHAVE_GIO_SOCKET
63
libnntpgrab_la_LIBADD += $(GIO_LIBS)
64
libnntpgrab_la_SOURCES += nntpconnection_backend_gio.c
65
endif
66

                
67
if HAVE_GLIB_NETWORKING
68
libnntpgrab_la_CFLAGS += -DHAVE_GLIB_NETWORKING
69
endif
70

                
trunk/nntpgrab_core/nntpconnection_backend_iface.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
... ...
53 57
#include "nntpconnection_backend_iface.h"
54 58
#include "nntpconnection_utils.h"
55 59

                
60
/* throttle.c */
61
void throttle_pause(struct timeval start_time, off_t xferlen, int max_bandwidth);
62

                
56 63
struct _NntpConnectionClass
57 64
{
58 65
    GObjectClass parent;
trunk/nntpgrab_core/queue_rawfile.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef _MSC_VER
20
#include "config.h.win32"
21
#else
19
#ifdef HAVE_CONFIG_H
22 20
#include "config.h"
23 21
#endif
24 22

                
trunk/tests/test_nntpconnection_backend.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25

                
trunk/tests/Makefile.am (revision 1834)
49 49
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_backend_gio.c \
50 50
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_backend_native.c
51 51

                
52
if HAVE_SSL
53
AM_CFLAGS += -DHAVE_SSL
54
endif
55

                
56
if HAVE_GNUTLS
57
AM_CFLAGS += -DHAVE_GNUTLS
58
endif
59

                
60
if HAVE_GLIB_NETWORKING
61
AM_CFLAGS += -DHAVE_GLIB_NETWORKING
62
endif
63

                
64
if HAVE_NSS_COMPAT_OSSL
65
AM_CFLAGS += -DHAVE_NSS_COMPAT_OSSL
66
endif
67

                
68
if HAVE_LIBPROXY
69
AM_CFLAGS += -DHAVE_LIBPROXY
70
endif
71

                
72 52
TEST_PROGS += test_nzbcreator test_nntpconnection_backend
73 53

                
trunk/server/main.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
19 20
#include "config.h"
21
#endif
20 22

                
21 23
#include 
22 24
#include 
trunk/NNTPGrab.config (revision 1834)
1 1
// ADD PREDEFINED MACROS HERE!
2
#define HAVE_CONFIG_H
trunk/plugins/unpack/plugin_unpack.c (revision 1834)
501 501
        ng_plugin_emit_log_msg(plugin_data, NG_LOG_LEVEL_INFO, _("Now unpacking '%s'"), file->filename);
502 502

                
503 503
        if (!unpack_do_unpack(plugin_data, collection_name, total_filename, target_directory, &errmsg)) {
504
            char *params[4];
504
            const char *params[4];
505 505

                
506 506
            if (!errmsg || strlen(errmsg) == 0) {
507 507
                errmsg = g_strdup_printf(_("process stopped unexpectedly"));
... ...
516 516
            ng_plugin_emit_log_msg(plugin_data, NG_LOG_LEVEL_WARNING, _("Automatic unpack failed due to an error: %s"), errmsg);
517 517
            g_free(errmsg);
518 518
        } else {
519
            char *params[3];
519
            const char *params[3];
520 520
            params[0] = collection_name;
521 521
            params[1] = file->filename;
522 522
            params[2] = NULL;
trunk/plugins/jsonrpc/plugin_webserver.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
... ...
26 30
#include "json.h"
27 31
#include "jsonrpc.h"
28 32
#include "marshalers.h"
29
#include "config.h"
30 33

                
31 34
static struct mg_context *ctx = NULL;
32 35
static NGPlugin *plugin_data_global = NULL;
trunk/plugins/jsonrpc/mongoose_hacks.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
... ...
24 28
#include "nntpgrab_plugin.h"
25 29
#include "nntpgrab_utils.h"
26 30
#include "mongoose.h"
27
#include "config.h"
28 31

                
29 32
#ifdef WIN32
30 33
#include 
trunk/configure.in (revision 1834)
22 22
dnl Find pkg-config
23 23
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
24 24
if test "x$PKG_CONFIG" = "xno"; then
25
        AC_MSG_ERROR([You need to install pkg-config])
25
       AC_MSG_ERROR([You need to install pkg-config])
26 26
fi
27 27

                
28 28
AM_PATH_GLIB_2_0("2.10.0")
29 29

                
30
# Optional configure arguments
30 31
AC_ARG_ENABLE(dbus,
31
    [  --disable-dbus          Activate DBUS integration (enabled by default)],
32
    [case "x${enableval}" in
33
        xyes) dbus=true ;;
34
        xno) dbus=false ;;
35
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-dbus) ;;
36
    esac],[dbus=true])
32
       [  --disable-dbus          Activate DBUS integration (enabled by default)],
33
       [case "x${enableval}" in
34
               xyes) dbus=true ;;
35
               xno) dbus=false ;;
36
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-dbus) ;;
37
       esac],[dbus=true])
37 38

                
38
AC_ARG_ENABLE(online_search,
39
    [  --disable-online-search Activate support for the Online Search(enabled by default)],
40
    [case "x${enableval}" in
41
        xyes) online_search=true ;;
42
        xno) online_search=false ;;
43
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-online-search) ;;
44
    esac],[online_search=true])
39
AC_ARG_ENABLE(online-search,
40
       [  --disable-online-search Activate support for the Online Search(enabled by default)],
41
       [case "x${enableval}" in
42
               xyes) online_search=true ;;
43
               xno) online_search=false ;;
44
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-online-search) ;;
45
       esac],[online_search=true])
45 46

                
46 47
AC_ARG_ENABLE(proxy,
47
    [  --disable-proxy         Activate support for downloading using a proxy server (enabled by default)],
48
    [case "x${enableval}" in
49
        xyes) proxy=true ;;
50
        xno) proxy=false ;;
51
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-proxy) ;;
52
    esac],[proxy=true])
48
       [  --disable-proxy         Activate support for downloading using a proxy server (enabled by default)],
49
       [case "x${enableval}" in
50
               xyes) proxy=true ;;
51
               xno) proxy=false ;;
52
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-proxy) ;;
53
       esac],[proxy=true])
53 54

                
54
PKG_CHECK_MODULES(GLIB, glib-2.0 >= 2.10.0 gthread-2.0 gmodule-2.0 gobject-2.0,,[AC_MSG_ERROR([* GLib 2.10.0 or higher could not be found (is the package glib2-devel installed?)])])
55
PKG_CHECK_MODULES(GIO, glib-2.0 >= 2.16.0 gio-2.0,have_gio=true,[AC_MSG_RESULT([* GLib 2.16.0 or higher could not be found. Without GLib 2.16.0, automatic NZB import won't be possible])]; have_gio=false)
55
# Search for GLib
56
PKG_CHECK_MODULES(GLIB,
57
       glib-2.0 >= 2.10.0 gthread-2.0 gmodule-2.0 gobject-2.0,
58
       ,
59
       [AC_MSG_ERROR([* GLib 2.10.0 or higher could not be found (is the package glib2-devel installed?)])])
56 60

                
57
if test "$dbus" = "true" ; then
58
    PKG_CHECK_MODULES(DBUS, dbus-glib-1 >= 0.60,have_dbus=true,[AC_MSG_RESULT([* DBUS-Glib 0.60 or higher could not be found (is the package dbus-devel and/or dbus-glib-devel installed?).])]; have_dbus=false)
61
# Search for GIO
62
PKG_CHECK_MODULES(GIO,
63
       glib-2.0 >= 2.16.0 gio-2.0,
64
       have_gio=true; AC_DEFINE_UNQUOTED(HAVE_GIO, 1, [Do we have GIO]),
65
       have_gio=false; [AC_MSG_RESULT([* GLib 2.16.0 or higher could not be found. Without GLib 2.16.0, automatic NZB import won't be possible])])
66

                
67
# Search for socket support in GIO
68
AC_MSG_CHECKING(if GIO >= 2.22.0)
69
pkg-config --atleast-version=2.22.0 gio-2.0
70
if test `echo $?` = 0; then
71
       AC_MSG_RESULT([yes]);
72
       AC_DEFINE_UNQUOTED(HAVE_GIO_SOCKET, 1, [Do we have socket support in GIO])
59 73
else
60
    have_dbus="false"
74
       AC_MSG_RESULT([no])
61 75
fi
62 76

                
77
# Search for dbus-glib
78
if test "$dbus" = "true" ; then
79
       PKG_CHECK_MODULES(DBUS,
80
               dbus-glib-1 >= 0.60,
81
               have_dbus=true; AC_DEFINE_UNQUOTED(HAVE_DBUS, 1, [Do we have DBus-glib]),
82
               have_dbus=false; [AC_MSG_RESULT([* DBUS-Glib 0.60 or higher could not be found (is the package dbus-devel and/or dbus-glib-devel installed?).])])
83
fi
84

                
85
# Search for libsoup
63 86
if test "$online_search" = "true" ; then
64
    PKG_CHECK_MODULES(SOUP, libsoup-2.4, have_soup=true,[AC_MSG_RESULT([* libsoup 2.4 or higher could not be found (is the package libsoup-devel installed?). Without libsoup, the NZBCreator service can't be accessed])]; have_soup=false)
65
    PKG_CHECK_MODULES(SOUP_GZIP, libsoup-2.4 >= 2.28.2, have_soup_gzip=true,[AC_MSG_RESULT([* libsoup 2.28.2 or higher could not be found. This is required to enable compression in the NZBCreator service])]; have_soup_gzip=false)
87
       PKG_CHECK_MODULES(SOUP,
88
               libsoup-2.4,
89
               have_soup=true; [AC_DEFINE_UNQUOTED(HAVE_SOUP, 1, [Do we have libsoup])],
90
               have_soup=false; [AC_MSG_RESULT([* libsoup 2.4 or higher could not be found (is the package libsoup-devel installed?). Without libsoup, the NZBCreator service can't be accessed])])
91

                
92
       PKG_CHECK_MODULES(SOUP_GZIP,
93
               libsoup-2.4 >= 2.28.2,
94
               [AC_DEFINE_UNQUOTED(HAVE_SOUP_GZIP, 1, [Do we have gzip support in libsoup])],
95
               [AC_MSG_RESULT([* libsoup 2.28.2 or higher could not be found. This is required to enable compression in the NZBCreator service])])
66 96
else
67 97
    have_soup="false"
68
    have_soup_gzip="false"
69 98
fi
70 99

                
100
# Search for libproxy and libsoup-gnome
71 101
if test "$proxy" = "true" ; then
72
    PKG_CHECK_MODULES(SOUP_GNOME, libsoup-gnome-2.4, have_soup_gnome=true,[AC_MSG_RESULT([* libsoup-gnome 2.4 or higher could not be found (is the package libsoup-devel installed?). Without libsoup-gnome proxy settings won't be detected on Linux])]; have_soup_gnome=false)
73
    PKG_CHECK_MODULES(LIBPROXY, libproxy-1.0, have_libproxy=true,[AC_MSG_RESULT([* libproxy could not be found (is the package libproxy-devel installed?). Without libproxy proxy settings won't be detected])]; have_libproxy=false)
74
else
75
    have_soup_gnome="false"
76
    have_libproxy="false"
77
fi
102
       PKG_CHECK_MODULES(SOUP_GNOME,
103
               libsoup-gnome-2.4,
104
               [AC_DEFINE_UNQUOTED(HAVE_SOUP_GNOME, 1, [Do we have libsoup-gnome])],
105
               [AC_MSG_RESULT([* libsoup-gnome 2.4 or higher could not be found (is the package libsoup-devel installed?). Without libsoup-gnome proxy settings won't be detected on Linux])])
78 106

                
79
if test "$have_gio" = "true" ; then
80
    AC_MSG_CHECKING(if GIO >= 2.22.0)
81
    pkg-config --atleast-version=2.22.0 gio-2.0
82
    if test `echo $?` = 0; then
83
        have_gio_socket=true
84
        AC_MSG_RESULT([yes])
85
    else
86
        have_gio_socket=false
87
        AC_MSG_RESULT([no])
88
    fi
89
else
90
    have_gio_socket=false
107
       PKG_CHECK_MODULES(LIBPROXY,
108
               libproxy-1.0,
109
               [AC_DEFINE_UNQUOTED(HAVE_LIBPROXY, 1, [Do we have libproxy])],
110
               [AC_MSG_RESULT([* libproxy could not be found (is the package libproxy-devel installed?). Without libproxy proxy settings won't be detected])])
91 111
fi
92 112

                
113
# Search for glib-networking
93 114
AC_MSG_CHECKING([for glib-networking (glib TLS implementation)])
94 115
save_CFLAGS="$CFLAGS"
95 116
save_LIBS="$LIBS"
96 117
CFLAGS="$CFLAGS $GIO_CFLAGS"
97 118
LIBS="$LIBS $GIO_LIBS"
98 119
AC_RUN_IFELSE([AC_LANG_PROGRAM([#include ],
99
                              [g_type_init (); return !g_tls_backend_supports_tls (g_tls_backend_get_default ());])],
100
             [have_glib_networking=yes],
101
             [have_glib_networking=no],
102
             [have_glib_networking="unknown (cross-compiling)"])
120
                               [g_type_init (); return !g_tls_backend_supports_tls (g_tls_backend_get_default ());])],
121
       [have_glib_networking=yes]; [AC_DEFINE_UNQUOTED(HAVE_GLIB_NETWORKING, 1, [Do we have glib-networking])],
122
       [have_glib_networking=no],
123
       [have_glib_networking="unknown (cross-compiling)"])
103 124
CFLAGS="$save_CFLAGS"
104 125
LIBS="$save_LIBS"
105 126
AC_MSG_RESULT($have_glib_networking)
... ...
109 130
AC_SUBST(GIO_LIBS)
110 131
AC_SUBST(GIO_CFLAGS)
111 132
AM_CONDITIONAL(HAVE_GIO, $have_gio)
112
AM_CONDITIONAL(HAVE_GIO_SOCKET, $have_gio_socket)
113 133
AC_SUBST(LIBXML2_LIBS)
114 134
AC_SUBST(LIBXML2_CFLAGS)
115 135
AC_SUBST(DBUS_LIBS)
... ...
117 137
AM_CONDITIONAL(HAVE_DBUS, $have_dbus)
118 138
AC_SUBST(SOUP_LIBS)
119 139
AC_SUBST(SOUP_CFLAGS)
120
AM_CONDITIONAL(HAVE_SOUP, $have_soup)
121
AM_CONDITIONAL(HAVE_SOUP_GZIP, $have_soup_gzip)
122 140
AC_SUBST(SOUP_GNOME_LIBS)
123 141
AC_SUBST(SOUP_GNOME_CFLAGS)
124
AM_CONDITIONAL(HAVE_SOUP_GNOME, $have_soup_gnome)
125 142
AC_SUBST(LIBPROXY_LIBS)
126 143
AC_SUBST(LIBPROXY_CFLAGS)
127
AM_CONDITIONAL(HAVE_LIBPROXY, $have_libproxy)
128
AM_CONDITIONAL(HAVE_GLIB_NETWORKING, test "$have_glib_networking" = "yes")
129 144

                
130 145
AC_ARG_ENABLE(ssl,
131
    [  --disable-ssl           Activate NNTP-over-SSL support (enabled by default)],
132
    [case "x${enableval}" in
133
        xyes) ssl=true ;;
134
        xno) ssl=false ;;
135
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-ssl) ;;
136
    esac],[ssl=true])
146
       [  --disable-ssl           Activate NNTP-over-SSL support (enabled by default)],
147
       [case "x${enableval}" in
148
               xyes) ssl=true ;;
149
               xno) ssl=false ;;
150
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-ssl) ;;
151
       esac],[ssl=true])
137 152

                
138 153
AC_ARG_ENABLE(php_module,
139
    [  --enable-php-module     Compile an PHP module which allows PHP scripts to call NNTPGrab methods (disabled by default)],
140
    [case "x${enableval}" in
141
        xyes) php_module=true ;;
142
        xno) php_module=false ;;
143
        *) AC_MSG_ERROR(bad value ${enableval} for --enable-php-module) ;;
144
    esac],[php_module=false])
154
       [  --enable-php-module     Compile an PHP module which allows PHP scripts to call NNTPGrab methods (disabled by default)],
155
       [case "x${enableval}" in
156
               xyes) php_module=true ;;
157
               xno) php_module=false ;;
158
               *) AC_MSG_ERROR(bad value ${enableval} for --enable-php-module) ;;
159
       esac],[php_module=false])
145 160

                
146 161
AM_CONDITIONAL(ENABLE_PHP_MODULE, $php_module)
147 162

                
148 163
AC_ARG_ENABLE(networkmanager,
149
    [  --disable-networkmanager
164
       [  --disable-networkmanager
150 165
                          Activate NetworkManager integration (enabled by default)],
151
    [case "x${enableval}" in
152
        xyes) networkmanager=true ;;
153
        xno) networkmanager=false ;;
154
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-networkmanager) ;;
155
    esac],[networkmanager=true])
166
       [case "x${enableval}" in
167
               xyes) networkmanager=true ;;
168
               xno) networkmanager=false ;;
169
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-networkmanager) ;;
170
       esac],[networkmanager=true])
156 171

                
157 172
if test "$networkmanager" = "true" ; then
158
    PKG_CHECK_MODULES(NETWORKMANAGER, libnm-glib, have_networkmanager=true,have_networkmanager=false)
159
    if test "$have_networkmanager" = "false" ; then
160
        PKG_CHECK_MODULES(NETWORKMANAGER, libnm_glib > 0.7.0, have_networkmanager=true,[AC_MSG_RESULT([* NetworkManager-glib could not be found (is the package NetworkManager-glib-devel installed?) Without NetworkManager-glib, NetworkManager integration won't be possible])]; have_networkmanager=false)
161
    fi
173
       PKG_CHECK_MODULES(NETWORKMANAGER, libnm-glib, have_networkmanager=true,have_networkmanager=false)
174
       if test "$have_networkmanager" = "false" ; then
175
               PKG_CHECK_MODULES(NETWORKMANAGER,
176
                       libnm_glib > 0.7.0,
177
                       have_networkmanager=true,
178
                       [AC_MSG_RESULT([* NetworkManager-glib could not be found (is the package NetworkManager-glib-devel installed?) Without NetworkManager-glib, NetworkManager integration won't be possible])]; have_networkmanager=false)
179
       fi
162 180
else
163 181
    have_networkmanager=false
164 182
fi
165 183

                
166 184
AC_ARG_ENABLE(automatic_shutdown,
167
    [  --disable-automatic-shutdown
185
       [  --disable-automatic-shutdown
168 186
                          Activate support for automatic shutdown (enabled by default)],
169
    [case "x${enableval}" in
170
        xyes) automatic_shutdown=true ;;
171
        xno) automatic_shutdown=false ;;
172
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-automatic-shutdown) ;;
173
    esac],[automatic_shutdown=true])
187
       [case "x${enableval}" in
188
               xyes) automatic_shutdown=true ;;
189
               xno) automatic_shutdown=false ;;
190
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-automatic-shutdown) ;;
191
       esac],[automatic_shutdown=true])
174 192

                
175 193
AC_SUBST(NETWORKMANAGER_LIBS)
176 194
AC_SUBST(NETWORKMANAGER_CFLAGS)
177 195
AM_CONDITIONAL(HAVE_NETWORKMANAGER, $have_networkmanager)
178 196

                
179 197
AC_ARG_ENABLE(gui,
180
    [  --disable-gui           Turn on GUI client (enabled by default)],
181
    [case "x${enableval}" in
182
        xyes) gui=true ;;
183
        xno)  gui=false ;;
184
        x) gui=true ;;
185
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-gui) ;;
186
    esac],[gui=true])
198
       [  --disable-gui           Turn on GUI client (enabled by default)],
199
       [case "x${enableval}" in
200
               xyes) gui=true ;;
201
               xno)  gui=false ;;
202
               x) gui=true ;;
203
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-gui) ;;
204
       esac],[gui=true])
187 205

                
188 206
AC_ARG_ENABLE(gtk3,
189
    [  --disable-gtk3          Build against GTK+ 3 if it's available (enabled by default)],
190
    [case "x${enableval}" in
191
        xyes) gtk3=true ;;
192
        xno) gtk3=false ;;
193
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-gtk3) ;;
194
    esac],[gtk3=true])
207
       [  --disable-gtk3          Build against GTK+ 3 if it's available (enabled by default)],
208
       [case "x${enableval}" in
209
               xyes) gtk3=true ;;
210
               xno) gtk3=false ;;
211
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-gtk3) ;;
212
       esac],[gtk3=true])
195 213

                
196 214
AC_ARG_ENABLE(notifications,
197
    [  --disable-notifications Activate support for showing notifications using libnotify (enabled by default)],
198
    [case "x${enableval}" in
199
        xyes) notifications=true ;;
200
        xno) notifications=false ;;
201
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-notifications) ;;
202
    esac],[notifications=true])
215
       [  --disable-notifications Activate support for showing notifications using libnotify (enabled by default)],
216
       [case "x${enableval}" in
217
               xyes) notifications=true ;;
218
               xno) notifications=false ;;
219
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-notifications) ;;
220
       esac],[notifications=true])
203 221

                
204 222
AM_CONDITIONAL(ENABLE_GUI, $gui)
205 223
if [ "$gui" = "true" ]; then
206
  if test "$gtk3" = "true" ; then
207
    PKG_CHECK_MODULES(GTK3, gtk+-3.0 gdk-3.0 gthread-2.0, have_gtk3=true,[AC_MSG_RESULT([* GTK+-3.0 or higher could not be found (is the package gtk3+-devel installed?)])]; have_gtk3=false)
208
  else
209
    have_gtk3="false"
210
  fi
224
       if test "$gtk3" = "true" ; then
225
               PKG_CHECK_MODULES(GTK3,
226
                       gtk+-3.0 gdk-3.0 gthread-2.0,
227
                       have_gtk3=true; AC_DEFINE_UNQUOTED(HAVE_GTK3, 1, [Do we have GTK-3 available]),
228
                       have_gtk3=false; [AC_MSG_RESULT([* GTK+-3.0 or higher could not be found (is the package gtk3+-devel installed?)])])
229
       else
230
               have_gtk3="false"
231
       fi
211 232

                
212
  if test "$have_gtk3" = "false" ; then
213
    PKG_CHECK_MODULES(GTK, gtk+-2.0 gdk-2.0 gthread-2.0,,[AC_MSG_ERROR([* GTK+-2.2 or higher could not be found (is the package gtk2+-devel installed?)])])
233
       if test "$have_gtk3" = "false" ; then
234
               PKG_CHECK_MODULES(GTK,
235
                       gtk+-2.0 gdk-2.0 gthread-2.0,
236
                       ,
237
                       [AC_MSG_ERROR([* GTK+-2.2 or higher could not be found (is the package gtk2+-devel installed?)])])
214 238

                
215
    AC_MSG_CHECKING(if GTK >= 2.12.0)
216
    pkg-config --atleast-version=2.12.0 gtk+-2.0
217
    if test `echo $?` = 0; then
218
      AC_MSG_RESULT([yes])
219
    else
220
      AC_MSG_RESULT([no])
221
      PKG_CHECK_MODULES(GLADE, libglade-2.0,,[AC_MSG_ERROR([* Glade 2.0 or higher could not be found (is the package libglade2-devel installed?)])])
222
    fi
223
  fi
239
               AC_MSG_CHECKING(if GTK >= 2.12.0)
240
               pkg-config --atleast-version=2.12.0 gtk+-2.0
241
               if test `echo $?` = 0; then
242
                       AC_MSG_RESULT([yes])
243
               else
244
                       AC_MSG_RESULT([no])
245
                       PKG_CHECK_MODULES(GLADE,
246
                               libglade-2.0,
247
                               ,
248
                               [AC_MSG_ERROR([* Glade 2.0 or higher could not be found (is the package libglade2-devel installed?)])])
249
               fi
250
       fi
224 251

                
225
  if test "$notifications" = "true" ; then
226
    PKG_CHECK_MODULES(LIBNOTIFY, libnotify >= 0.4.1, have_libnotify=true,[AC_MSG_RESULT([* libnotify 0.4.1 or higher could not be found (is the package libnotify-devel installed?). Without libnotify, notification balloons aren't possible])]; have_libnotify=false)
227
  else
228
    have_libnotify="false"
229
  fi
252
       if test "$notifications" = "true" ; then
253
               PKG_CHECK_MODULES(LIBNOTIFY,
254
                       libnotify >= 0.4.1,
255
                       AC_DEFINE_UNQUOTED(HAVE_LIBNOTIFY, 1, [Do we have libnotify available]),
256
                       [AC_MSG_RESULT([* libnotify 0.4.1 or higher could not be found (is the package libnotify-devel installed?). Without libnotify, notification balloons aren't possible])])
230 257

                
231
  if test "$have_libnotify" = "true" ; then
232
    AC_MSG_CHECKING(if libnotify >= 0.7.0)
233
    pkg-config --atleast-version=0.7.0 libnotify
234
    if test `echo $?` = 0; then
235
      AC_MSG_RESULT([yes])
236
      have_libnotify_0_7="true"
237
    else
238
      AC_MSG_RESULT([no])
239
      have_libnotify_0_7="false"
240
    fi
241
  fi
258
               AC_MSG_CHECKING(if libnotify >= 0.7.0)
259
               pkg-config --atleast-version=0.7.0 libnotify
260
               if test `echo $?` = 0; then
261
                       AC_MSG_RESULT([yes])
262
                       AC_DEFINE_UNQUOTED(HAVE_LIBNOTIFY_0_7, 1, [Do we have libnotify 0.7 available])
263
               else
264
                       AC_MSG_RESULT([no])
265
               fi
266
       fi
242 267

                
243
  if test "$automatic_shutdown" = "true" ; then
244
    PKG_CHECK_MODULES(POLKIT, polkit-gobject-1, have_polkit1=true, [PKG_CHECK_MODULES(POLKIT, polkit-gnome, have_polkit_old=true,[AC_MSG_RESULT([* PolicyKit could not be found (is the package polkit-devel or PolicyKit-gnome-devel installed?). Without PolicyKit, automatic shutdown won't be possible])]; have_polkit_old=false)]; have_polkit1=false)
245
  else
246
    have_polkit_old=false
247
    have_polkit1=false
248
  fi
268
       if test "$automatic_shutdown" = "true" ; then
269
               PKG_CHECK_MODULES(POLKIT,
270
                       polkit-gobject-1,
271
                       AC_DEFINE_UNQUOTED(HAVE_POLKIT1, 1, [Do we have PolicyKit 1.0 available]),
272
                       [PKG_CHECK_MODULES(POLKIT,
273
                               polkit-gnome,
274
                               AC_DEFINE_UNQUOTED(HAVE_POLKIT_OLD, 1, [Do we have PolicyKit 0.9 available]),
275
                               [AC_MSG_RESULT([* PolicyKit could not be found (is the package polkit-devel or PolicyKit-gnome-devel installed?). Without PolicyKit, automatic shutdown won't be possible])])
276
                       ])
277
       fi
249 278

                
250
  PKG_CHECK_MODULES(LIBXML2, libxml-2.0,,[AC_MSG_ERROR([* LibXML 2.0 or higher could not be found (is the package libxml2-devel installed?)])])
279
       PKG_CHECK_MODULES(LIBXML2,
280
               libxml-2.0,
281
               ,
282
               [AC_MSG_ERROR([* LibXML 2.0 or higher could not be found (is the package libxml2-devel installed?)])])
251 283
fi
252 284

                
253 285
AC_ARG_ENABLE(par2cmdline-check,
254
    [  --disable-par2cmdline-check
286
       [  --disable-par2cmdline-check
255 287
                          Check for the existance of the par2 binary (enabled by default)],
256
    [case "x${enableval}" in
257
        xyes) par2_check=true ;;
258
        xno) par2_check=false ;;
259
        *) AC_MSG_ERROR(bad value ${enableval} for --disable-par2cmdline-check) ;;
260
    esac],[par2_check=true])
288
       [case "x${enableval}" in
289
               xyes) par2_check=true ;;
290
               xno) par2_check=false ;;
291
               *) AC_MSG_ERROR(bad value ${enableval} for --disable-par2cmdline-check) ;;
292
       esac],[par2_check=true])
261 293

                
262 294
if test "$par2_check" = "true" ; then
263
  AC_CHECK_PROGS([PAR2CMDLINE], [par2])
264
  if test "x$PAR2CMDLINE" = "x" ; then
265
    AC_MSG_ERROR([par2cmdline is not found. This is required for NNTPGrab])
266
  fi
295
       AC_CHECK_PROGS([PAR2CMDLINE], [par2])
296
       if test "x$PAR2CMDLINE" = "x" ; then
297
               AC_MSG_ERROR([par2cmdline is not found. This is required for NNTPGrab])
298
       fi
267 299
fi
268 300

                
269
dnl PKG_CHECK_MODULES(LIBPAR2, libpar2, libpar2_found=true, libpar2_found=false)
270
dnl if test "$libpar2_found" != "true" ; then
271
dnl     AC_LANG_PUSH([C++])
272
dnl     PKG_CHECK_MODULES(SIGC, sigc++-2.0,, [AC_MSG_ERROR([* libsigc++-2.0 could not be found (is the package libsigc++-2.0 installed?)])])
273
dnl     CPPFLAGS="$CXXFLAGS $SIGC_CFLAGS"
274
dnl     AC_CHECK_LIB(par2, main,,[AC_MSG_ERROR([* libpar2 could not be found])])
275
dnl     AC_CHECK_HEADERS([libpar2/par2cmdline.h],, [AC_MSG_ERROR([* libpar2 headers could not be found])])
276
dnl     LIBPAR2_LIBS="-lpar2 $SIGC_LIBS"
277
dnl     LIBPAR2_CFLAGS="$SIGC_CFLAGS"
278
dnl     AC_LANG_POP([C++])
279
dnl fi
280

                
281 301
AC_SUBST(GTK3_LIBS)
282 302
AC_SUBST(GTK3_CFLAGS)
283
AM_CONDITIONAL(HAVE_GTK3, $have_gtk3)
284 303
AC_SUBST(GTK_LIBS)
285 304
AC_SUBST(GTK_CFLAGS)
286 305
AC_SUBST(GLADE_CFLAGS)
287 306
AC_SUBST(GLADE_LIBS)
288 307
AC_SUBST(POLKIT_LIBS)
289 308
AC_SUBST(POLKIT_CFLAGS)
290
AM_CONDITIONAL(HAVE_POLKIT, test "$have_polkit1" = "true" -o "$have_polkit_old" = "true")
291
AM_CONDITIONAL(HAVE_POLKIT1, test "$have_polkit1" = "true")
292
AM_CONDITIONAL(HAVE_POLKIT_OLD, test "$have_polkit_old" = "true")
293 309
AC_SUBST(LIBNOTIFY_LIBS)
294 310
AC_SUBST(LIBNOTIFY_CFLAGS)
295
AM_CONDITIONAL(HAVE_LIBNOTIFY, $have_libnotify)
296
AM_CONDITIONAL(HAVE_LIBNOTIFY_0_7, $have_libnotify_0_7)
297
dnl AC_SUBST(LIBPAR2_LIBS)
298
dnl AC_SUBST(LIBPAR2_CFLAGS)
299 311

                
300 312
# check for gtk-doc
301 313
GTK_DOC_CHECK([1.14],[--flavour no-tmpl])
... ...
336 348
                        AC_MSG_ERROR([*** Could not find an implementation of windres in your PATH.]) 
337 349
                fi
338 350
                AM_CONDITIONAL(WIN32, true)
339
                AC_DEFINE(WIN32, 1, [Is this an Win32 platform])
351
                AC_DEFINE(WIN32, 1, [Is this a Win32 platform])
340 352
                AM_CONDITIONAL(DARWIN, false);;
341 353
       cygwin)
342 354
                CFLAGS="$CFLAGS -DOS=\"\\\"Windows\\\"\""
... ...
345 357
                        AC_MSG_ERROR([*** Could not find an implementation of windres in your PATH.])
346 358
                fi
347 359
                AM_CONDITIONAL(WIN32, true)
348
                AC_DEFINE(WIN32, 1, [Is this an Win32 platform])
360
                AC_DEFINE(WIN32, 1, [Is this a Win32 platform])
349 361
                AM_CONDITIONAL(DARWIN, false)
350 362
                LDFLAGS="$LDFLAGS -mwindows";;
351 363
        darwin*)
... ...
425 437

                
426 438
AM_CONDITIONAL(HAVE_SSL, $ssl)
427 439
if test "$ssl" = "true" ; then
428
  PKG_CHECK_MODULES(GNUTLS, gnutls, gnutls_found=true,[AC_MSG_RESULT([* GNUTLS could not be found (is the package gnutls-devel installed?)])]; gnutls_found=false)
429
  if test "$gnutls_found" = "false" ; then
430
    PKG_CHECK_MODULES(NSS, nss, nss_found=true,[AC_MSG_RESULT([* NSS could not be found (is the package nss-devel installed?)])]; nss_found=false)
431
    if test "$nss_found" = "true" ; then
432
      AC_FIND_LIB(nss_compat_ossl, $ac_default_lib_searchpath, nss_compat_ossl_libraries,
433
       [nss_compat_ossl libraries],
434
       [nss_compat_ossl libraries could not be found])
440
       AC_DEFINE_UNQUOTED(HAVE_SSL, 1, [Do we have to build with SSL support])
435 441

                
436
      AC_FIND_HEADER(nss_compat_ossl/nss_compat_ossl.h, $ac_default_inc_searchpath, nss_compat_ossl_headers,
437
       [nss_compat_ossl headers],
438
       [nss_compat_oss header could not be found],
439
       nss_compat_ossl)
440
    fi
442
       PKG_CHECK_MODULES(GNUTLS,
443
               gnutls,
444
               gnutls_found=true; AC_DEFINE_UNQUOTED(HAVE_GNUTLS, 1, [Do we have to build with GNUTLS support]),
445
               [AC_MSG_RESULT([* GNUTLS could not be found (is the package gnutls-devel installed?)])]; gnutls_found=false)
441 446

                
442
    if test    "$nss_found" = "true" -a \
443
       "$nss_compat_ossl_libraries_ok" = "true" -a \
444
       "$nss_compat_ossl_headers_ok" = "true" ; then
445
               have_nss_compat_ossl=true
446
               NSS_LIBS="$NSS_LIBS -lnss_compat_ossl"
447
    else
448
               have_nss_compat_ossl=false
449
               NSS_CFLAGS=""
450
               NSS_LIBS=""
451
    fi
447
       if test "$gnutls_found" = "false" ; then
448
               PKG_CHECK_MODULES(NSS,
449
                       nss,
450
                       nss_found=true,
451
                       [AC_MSG_RESULT([* NSS could not be found (is the package nss-devel installed?)])]; nss_found=false)
452 452

                
453
    if test "$have_nss_compat_ossl" = "false" ; then
454
       AC_FIND_LIB2(ssl, $ac_default_lib_searchpath, openssl_libraries,
455
               [OpenSSL libraries],
456
               [OpenSSL library not found])
453
               if test "$nss_found" = "true" ; then
454
                       AC_FIND_LIB(nss_compat_ossl, $ac_default_lib_searchpath, nss_compat_ossl_libraries,
455
                               [nss_compat_ossl libraries],
456
                               [nss_compat_ossl libraries could not be found])
457

                
458
                       AC_FIND_HEADER(nss_compat_ossl/nss_compat_ossl.h, $ac_default_inc_searchpath, nss_compat_ossl_headers,
459
                               [nss_compat_ossl headers],
460
                               [nss_compat_oss header could not be found],
461
                               nss_compat_ossl)
462
               fi
463

                
464
               if test "$nss_found" = "true" -a \
465
                       "$nss_compat_ossl_libraries_ok" = "true" -a \
466
                       "$nss_compat_ossl_headers_ok" = "true" ; then
467

                
468
                       have_nss_compat_ossl=true
469
                       AC_DEFINE_UNQUOTED(HAVE_NSS_COMPAT_OSSL, 1, [Do we have to build with nss-compat-openSSL support])
470
                       NSS_LIBS="$NSS_LIBS -lnss_compat_ossl"
471
               else
472
                       have_nss_compat_ossl=false
473
                       NSS_CFLAGS=""
474
                       NSS_LIBS=""
475
               fi
476

                
477
               if test "$have_nss_compat_ossl" = "false" ; then
478
                       AC_FIND_LIB2(ssl, $ac_default_lib_searchpath, openssl_libraries,
479
                               [OpenSSL libraries],
480
                               [OpenSSL library not found])
457 481
  
458
       AC_FIND_HEADER2(openssl/md5.h, $ac_default_inc_searchpath, openssl_headers,
459
               [OpenSSL headers],
460
               [OpenSSL headers could not be found])
482
                       AC_FIND_HEADER2(openssl/md5.h, $ac_default_inc_searchpath, openssl_headers,
483
                               [OpenSSL headers],
484
                               [OpenSSL headers could not be found])
461 485
  
462
       openssl_libraries_LIBS="$openssl_libraries_LIBS -lcrypto"
463
    fi
464
  fi
486
                       openssl_libraries_LIBS="$openssl_libraries_LIBS -lcrypto"
487
               fi
488
       fi
465 489
fi
466 490

                
467
AM_CONDITIONAL(HAVE_GNUTLS, test "$gnutls_found" = "true")
468
AM_CONDITIONAL(HAVE_NSS_COMPAT_OSSL, test "$have_nss_compat_ossl" = "true")
469

                
470 491
AC_SUBST(PCRE_CFLAGS, $pcre_headers_CFLAGS)
471 492
AC_SUBST(PCRE_LIBS, $pcre_libraries_LIBS)
472 493
AC_SUBST(CURL_CFLAGS, $libcurl_headers_CFLAGS)
trunk/glue/glue_json.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef _MSC_VER
20
#include "config.h.win32"
21
#else
19
#ifdef HAVE_CONFIG_H
22 20
#include "config.h"
23 21
#endif
24 22

                
trunk/glue/glue_signals.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef _MSC_VER
20
#include "config.h.win32"
21
#else
19
#ifdef HAVE_CONFIG_H
22 20
#include "config.h"
23 21
#endif
24 22

                
trunk/base/nzbcreator.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include 
trunk/base/auto_shutdown_linux.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include "nntpgrab_utils.h"
20
#ifdef HAVE_POLKIT
24
#if defined(HAVE_POLKIT_OLD) || defined(HAVE_POLKIT1)
21 25
#include 
22 26
#include 
23 27
#include 
... ...
251 255
ngboolean
252 256
nntpgrab_utils_perform_shutdown(void)
253 257
{
254
#ifdef HAVE_POLKIT
258
#if defined(HAVE_POLKIT_OLD) || defined(HAVE_POLKIT1)
255 259
    if (!perform_shutdown_gnome() && !perform_shutdown_kde()) {
256 260
        return FALSE;
257 261
    }
trunk/base/Makefile.am (revision 1834)
1 1
## Process this file with automake to produce Makefile.in
2 2
include $(top_srcdir)/Makefile.decl
3 3

                
4
INCLUDES = $(GLIB_CFLAGS) $(GIO_CFLAGS) $(PCRE_CFLAGS) $(SOUP_CFLAGS) $(SOUP_GNOME_CFLAGS) -I. -DG_LOG_DOMAIN=\"NNTPGrab-utils\"
4
INCLUDES = $(GLIB_CFLAGS) $(GIO_CFLAGS) $(PCRE_CFLAGS) $(SOUP_CFLAGS) $(SOUP_GNOME_CFLAGS)  $(POLKIT_CFLAGS) $(DBUS_CFLAGS) -I. -DG_LOG_DOMAIN=\"NNTPGrab-utils\"
5 5

                
6 6
lib_LTLIBRARIES = libnntpgrab_utils.la
7 7

                
8 8
libnntpgrab_utils_la_SOURCES = regex.c utils.c nzbcreator.c monitor.c nzb.c nglist.c ngsignals.c ngobject.c ngeventloop.c
9 9
libnntpgrab_utils_la_LDFLAGS = -no-undefined -version-info 0:0:0 -export-symbols nntpgrab_utils.def
10
libnntpgrab_utils_la_LIBADD = $(GLIB_LIBS) $(GIO_LIBS) $(PCRE_LIBS) $(SOUP_LIBS) $(SOUP_GNOME_LIBS)
10
libnntpgrab_utils_la_LIBADD = $(GLIB_LIBS) $(GIO_LIBS) $(PCRE_LIBS) $(SOUP_LIBS) $(SOUP_GNOME_LIBS) $(POLKIT_LIBS) $(DBUS_LIBS)
11 11
libnntpgrab_utils_la_CFLAGS =
12 12

                
13 13
if WIN32
14 14
libnntpgrab_utils_la_LIBADD += -lshlwapi
15 15
endif
16 16

                
17
if HAVE_SOUP
18
libnntpgrab_utils_la_CFLAGS += -DHAVE_SOUP
19
if HAVE_SOUP_GNOME
20
libnntpgrab_utils_la_CFLAGS += -DHAVE_SOUP_GNOME
21
endif
22
if HAVE_SOUP_GZIP
23
libnntpgrab_utils_la_CFLAGS += -DHAVE_SOUP_GZIP
24
endif
25
endif
26

                
27
if HAVE_POLKIT
28
libnntpgrab_utils_la_CFLAGS += -DHAVE_POLKIT $(POLKIT_CFLAGS) $(DBUS_CFLAGS)
29
libnntpgrab_utils_la_LIBADD += $(POLKIT_LIBS) $(DBUS_LIBS)
30

                
31
if HAVE_POLKIT1
32
libnntpgrab_utils_la_CFLAGS += -DHAVE_POLKIT1
33
endif
34

                
35
if HAVE_POLKIT_OLD
36
libnntpgrab_utils_la_CFLAGS += -DHAVE_POLKIT_OLD
37
endif
38
endif
39

                
40 17
if DARWIN
41 18
libnntpgrab_utils_la_SOURCES += auto_shutdown_osx.c
42 19
libnntpgrab_utils_la_LDFLAGS += -Wl,-framework,Cocoa,-framework,Carbon
trunk/base/ngobject.c (revision 1834)
16 16
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17 17
*/
18 18

                
19
#ifdef HAVE_CONFIG_H
20
#include "config.h"
21
#endif
22

                
19 23
#include 
20 24
#include 
21 25
#include "nntpgrab_utils.h"
trunk/NNTPGrab.files (revision 1834)
1 1
automation/automation_auto_import.c
2 2
automation/nntpgrab_automation.h
3
base/auto_shutdown_linux.c
3 4
base/collections.h
4 5
base/monitor.c
5 6
base/ngeventloop.c
... ...
115 116
nntpgrab_core/plugins.h
116 117
nntpgrab_core/queue_rawfile.c
117 118
nntpgrab_core/queue_rawfile.h
118
nntpgrab_core/queue_sqlite.c
119
nntpgrab_core/queue_sqlite.h
120 119
nntpgrab_core/throttle.c
121 120
plugins/antisleep/antisleep.c
122 121
plugins/auto_import/auto_import.c
trunk/client/gui/Makefile.am (revision 1834)
1 1
## Process this file with automake to produce Makefile.in
2 2
include $(top_srcdir)/Makefile.decl
3 3

                
4
INCLUDES = $(GLIB_CFLAGS) $(GTK3_CFLAGS) $(GTK_CFLAGS) $(GLADE_CFLAGS) $(CURL_CFLAGS) $(LIBXML2_CFLAGS) $(SOUP_CFLAGS) $(SOUP_GNOME_CFLAGS) -I$(top_srcdir)/base -I$(top_srcdir)/nntpgrab_core -I$(top_srcdir)/glue -I$(top_srcdir)/gui_base -I$(top_srcdir)/automation -DNNTPGRABLOCALEDIR=\""$(nntpgrablocaledir)"\"
4
INCLUDES = $(GLIB_CFLAGS) $(GTK3_CFLAGS) $(GTK_CFLAGS) $(GLADE_CFLAGS) $(CURL_CFLAGS) $(LIBXML2_CFLAGS) $(SOUP_CFLAGS) $(SOUP_GNOME_CFLAGS) $(DBUS_CFLAGS) $(LIBNOTIFY_CFLAGS) -I$(top_srcdir)/base -I$(top_srcdir)/nntpgrab_core -I$(top_srcdir)/glue -I$(top_srcdir)/gui_base -I$(top_srcdir)/automation -DNNTPGRABLOCALEDIR=\""$(nntpgrablocaledir)"\"
5 5

                
6 6
AM_CFLAGS = -Wall -g
7 7

                
... ...
20 20
nntpgrab_gui_debug_LDFLAGS = -mconsole
21 21
endif
22 22

                
23
nntpgrab_gui_LDADD = $(top_srcdir)/base/libnntpgrab_utils.la $(top_srcdir)/glue/libnntpgrab_glue.la $(top_srcdir)/gui_base/libnntpgrab_gui_base.la $(top_srcdir)/automation/libnntpgrab_automation.la $(GLIB_LIBS) $(GTK3_LIBS) $(GTK_LIBS) $(GLADE_LIBS) $(CURL_LIBS) $(LIBXML2_LIBS) $(SOUP_LIBS) $(SOUP_GNOME_LIBS)
23
nntpgrab_gui_LDADD = $(top_srcdir)/base/libnntpgrab_utils.la $(top_srcdir)/glue/libnntpgrab_glue.la $(top_srcdir)/gui_base/libnntpgrab_gui_base.la $(top_srcdir)/automation/libnntpgrab_automation.la $(GLIB_LIBS) $(GTK3_LIBS) $(GTK_LIBS) $(GLADE_LIBS) $(CURL_LIBS) $(LIBXML2_LIBS) $(SOUP_LIBS) $(SOUP_GNOME_LIBS) $(DBUS_LIBS) $(LIBNOTIFY_LIBS)
24 24

                
25
if HAVE_LIBNOTIFY
26
nntpgrab_gui_CFLAGS += -DHAVE_LIBNOTIFY $(LIBNOTIFY_CFLAGS)
27
nntpgrab_gui_LDADD += $(LIBNOTIFY_LIBS)
28
endif
29

                
30
if HAVE_LIBNOTIFY_0_7
31
nntpgrab_gui_CFLAGS += -DHAVE_LIBNOTIFY_0_7
32
endif
33

                
34
if HAVE_SOUP
35
nntpgrab_gui_CFLAGS += -DHAVE_SOUP
36
endif
37

                
38
if HAVE_SOUP_GNOME
39
nntpgrab_gui_CFLAGS += -DHAVE_SOUP_GNOME
40
endif
41

                
42
if HAVE_SOUP_GZIP
43
nntpgrab_gui_CFLAGS += -DHAVE_SOUP_GZIP
44
endif
45

                
46 25
EXTRA_DIST += \
47 26
       nntpgrab_gui.glade \
48 27
       nntpgrab_gui.ui \
... ...
118 97

                
119 98
nntpgrab_gui_dbus_glue.h: nntpgrab_gui_dbus.xml
120 99
       $(LIBTOOL) --mode=execute dbus-binding-tool --prefix=nntpgrab_dbus --mode=glib-server --output=nntpgrab_gui_dbus_glue.h $(srcdir)/nntpgrab_gui_dbus.xml
121
nntpgrab_gui_CFLAGS += -DHAVE_DBUS $(DBUS_CFLAGS)
122
nntpgrab_gui_LDADD += $(DBUS_LIBS)
123 100
endif
124 101

                
125 102
nntpgrab_gui_SOURCES += ipc_linux.c
trunk/client/gui/gui.h (revision 1834)
19 19
#ifndef _NNTPGRAB_GUI_H_
20 20
#define _NNTPGRAB_GUI_H_
21 21

                
22
#ifdef HAVE_CONFIG_H
23
#include "config.h"
24
#endif
25

                
22 26
#include "nntpgrab_gui_base.h"
23 27
#include "nntpgrab_glue.h"
24 28
#include "nntpgrab_utils.h"

Also available in: Unified diff