- Merge in missing changes from gkrellm-2.3.3 release

- Revert gkrellm version header change, there are too many places in code/docs containing the version number, one more or less will not hurt
- configure: Make configure shell script write configure.mk and move logic for compiler and linker flags into configure
- configure: Also search openssl and libntlm via pkg-config and fall back to hardcoded library names for linking if not found
- Makefile: Workaround environment-bugs in win32 toolchain by switching from "override CC" to a normal makefile rule for building .o from .c files
This commit is contained in:
Stefan Gehn 2009-12-27 11:48:30 +00:00
parent a9c193f84c
commit 25076e8a0f
15 changed files with 113 additions and 165 deletions

View File

@ -51,7 +51,7 @@ endif
CC ?= gcc CC ?= gcc
STRIP ?= -s STRIP ?= -s
GKRELLMD_INCLUDES = gkrellmd.h gkrellmd-version.h $(SHARED_PATH)/log.h GKRELLMD_INCLUDES = gkrellmd.h $(SHARED_PATH)/log.h
PKG_INCLUDE = `$(PKG_CONFIG) --cflags glib-2.0 gthread-2.0` PKG_INCLUDE = `$(PKG_CONFIG) --cflags glib-2.0 gthread-2.0`
PKG_LIB = `$(PKG_CONFIG) --libs glib-2.0 gmodule-2.0 gthread-2.0` PKG_LIB = `$(PKG_CONFIG) --libs glib-2.0 gmodule-2.0 gthread-2.0`
@ -107,8 +107,6 @@ ifeq ($(HAVE_GETADDRINFO),1)
FLAGS += -DHAVE_GETADDRINFO FLAGS += -DHAVE_GETADDRINFO
endif endif
override CC += -Wall $(FLAGS)
OS_NAME=$(shell uname -s) OS_NAME=$(shell uname -s)
OS_RELEASE=$(shell uname -r) OS_RELEASE=$(shell uname -r)
@ -234,7 +232,7 @@ SYSDEPS = ../src/sysdeps/bsd-common.c ../src/sysdeps/bsd-net-open.c \
../src/sysdeps/openbsd.c ../src/sysdeps/sensors-common.c \ ../src/sysdeps/openbsd.c ../src/sysdeps/sensors-common.c \
../src/sysdeps/solaris.c ../src/sysdeps/win32.c ../src/sysdeps/solaris.c ../src/sysdeps/win32.c
GKRELLMD_H = gkrellmd.h gkrellmd-version.h gkrellmd-private.h GKRELLMD_H = gkrellmd.h gkrellmd-private.h
main.o: main.c $(GKRELLMD_H) main.o: main.c $(GKRELLMD_H)
monitor.o: monitor.c $(GKRELLMD_H) monitor.o: monitor.c $(GKRELLMD_H)
@ -247,7 +245,10 @@ log.o: $(SHARED_PATH)/log.c $(SHARED_PATH)/log.h $(GKRELLMD_H)
win32-gui.o: win32-gui.c win32-gui.o: win32-gui.c
win32-plugin.o: win32-plugin.c win32-plugin.h $(GKRELLMD_H) win32-plugin.o: win32-plugin.c win32-plugin.h $(GKRELLMD_H)
win32-resource.o: win32-resource.rc win32-resource.h win32-resource.o: win32-resource.rc win32-resource.h
windres -v -I.. -o win32-resource.o win32-resource.rc windres -I.. -o win32-resource.o win32-resource.rc
win32-libgkrellmd.o: win32-libgkrellmd.c win32-plugin.h $(GKRELLMD_H) win32-libgkrellmd.o: win32-libgkrellmd.c win32-plugin.h $(GKRELLMD_H)
libgkrellmd.a: win32-libgkrellmd.o libgkrellmd.a: win32-libgkrellmd.o
ar -cr libgkrellmd.a win32-libgkrellmd.o ar -cr libgkrellmd.a win32-libgkrellmd.o
%.o: %.c
$(CC) -c -Wall $(FLAGS) $(CFLAGS) $(CPPFLAGS) $< -o $@

View File

@ -1,35 +0,0 @@
/* GKrellM
| Copyright (C) 1999-2007 Bill Wilson
|
| Author: Bill Wilson billw@gkrellm.net
| Latest versions might be found at: http://gkrellm.net
|
|
| GKrellM is free software: you can redistribute it and/or modify it
| under the terms of the GNU General Public License as published by
| the Free Software Foundation, either version 3 of the License, or
| (at your option) any later version.
|
| GKrellM is distributed in the hope that it will be useful, but WITHOUT
| ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
| or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
| License for more details.
|
| You should have received a copy of the GNU General Public License
| along with this program. If not, see http://www.gnu.org/licenses/
*/
#ifndef GKRELLMD_VERSION_H
#define GKRELLMD_VERSION_H
#define GKRELLMD_VERSION_MAJOR 2
#define GKRELLMD_VERSION_MINOR 3
#define GKRELLMD_VERSION_REV 3
#define GKRELLMD_EXTRAVERSION ""
#define GKRELLMD_CHECK_VERSION(major,minor,rev) \
(GKRELLMD_VERSION_MAJOR > (major) || \
(GKRELLMD_VERSION_MAJOR == (major) && GKRELLMD_VERSION_MINOR > (minor)) || \
(GKRELLMD_VERSION_MAJOR == (major) && GKRELLMD_VERSION_MINOR == (minor) && \
GKRELLMD_VERSION_REV >= (rev)))
#endif // GKRELLMD_VERSION_H

View File

@ -34,7 +34,6 @@
#define GKRELLMD_H #define GKRELLMD_H
#include "log.h" #include "log.h"
#include "gkrellmd-version.h"
#include <glib.h> #include <glib.h>
#include <glib/gstdio.h> #include <glib/gstdio.h>
@ -105,6 +104,19 @@
# define bindtextdomain(Domain,Directory) (Domain) # define bindtextdomain(Domain,Directory) (Domain)
#endif /* ENABLE_NLS */ #endif /* ENABLE_NLS */
/* -------------------------------------------------------------------
*/
#define GKRELLMD_VERSION_MAJOR 2
#define GKRELLMD_VERSION_MINOR 3
#define GKRELLMD_VERSION_REV 3
#define GKRELLMD_EXTRAVERSION ""
#define GKRELLMD_CHECK_VERSION(major,minor,rev) \
(GKRELLMD_VERSION_MAJOR > (major) || \
(GKRELLMD_VERSION_MAJOR == (major) && GKRELLMD_VERSION_MINOR > (minor)) || \
(GKRELLMD_VERSION_MAJOR == (major) && GKRELLMD_VERSION_MINOR == (minor) && \
GKRELLMD_VERSION_REV >= (rev)))
#define GKRELLMD_CONFIG "gkrellmd.conf" #define GKRELLMD_CONFIG "gkrellmd.conf"
#if defined(WIN32) #if defined(WIN32)
// no dot in front of config-filename on win32 // no dot in front of config-filename on win32

View File

@ -1,6 +1,6 @@
/* GKrellM Windows Portion /* GKrellM Windows Portion
| Copyright (C) 2002 Bill Nalen | Copyright (C) 2002 Bill Nalen
| 2007-2008 Stefan Gehn | 2007-2009 Stefan Gehn
| |
| Authors: Bill Nalen bill@nalens.com | Authors: Bill Nalen bill@nalens.com
| Stefan Gehn stefan@gkrellm.srcbox.net | Stefan Gehn stefan@gkrellm.srcbox.net

View File

@ -1,5 +1,5 @@
/* GKrellM Windows Portion /* GKrellM Windows Portion
| Copyright (C) 2006-2008 Stefan Gehn | Copyright (C) 2006-2009 Stefan Gehn
| |
| Authors: Stefan Gehn stefan@gkrellm.srcbox.net | Authors: Stefan Gehn stefan@gkrellm.srcbox.net
| Latest versions might be found at: http://gkrellm.net | Latest versions might be found at: http://gkrellm.net

View File

@ -1,6 +1,6 @@
/* GKrellM /* GKrellM
| Copyright (C) 1999-2008 Bill Wilson | Copyright (C) 1999-2009 Bill Wilson
| 2007-2008 Stefan Gehn | 2007-2009 Stefan Gehn
| |
| Authors: Bill Wilson billw@gkrellm.net | Authors: Bill Wilson billw@gkrellm.net
| Stefan Gehn stefan@gkrellm.srcbox.net | Stefan Gehn stefan@gkrellm.srcbox.net

View File

@ -3,20 +3,15 @@
// http://www.resedit.net // http://www.resedit.net
#include "win32-resource.h" #include "win32-resource.h"
#include "gkrellmd-version.h" #include "windows.h"
#include <windows.h>
// you don't really want to know why this looks so ugly :P
#define STRINGIFY(x) #x
#define TOSTRING(x) STRINGIFY(x)
#define RC_VER_STRING TOSTRING(GKRELLMD_VERSION_MAJOR) "." TOSTRING(GKRELLMD_VERSION_MINOR) "." TOSTRING(GKRELLMD_VERSION_REV) GKRELLMD_EXTRAVERSION
// //
// Version Information resources // Version Information resources
// //
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
1 VERSIONINFO 1 VERSIONINFO
FILEVERSION GKRELLMD_VERSION_MAJOR,GKRELLMD_VERSION_MINOR,GKRELLMD_VERSION_REV,0 FILEVERSION 2,3,3,0
PRODUCTVERSION 0,0,0,0 PRODUCTVERSION 0,0,0,0
FILEOS VOS_NT_WINDOWS32 FILEOS VOS_NT_WINDOWS32
FILETYPE VFT_APP FILETYPE VFT_APP
@ -27,12 +22,12 @@ BEGIN
BEGIN BEGIN
VALUE "CompanyName", "" VALUE "CompanyName", ""
VALUE "FileDescription", "GKrellM Daemon" VALUE "FileDescription", "GKrellM Daemon"
VALUE "FileVersion", RC_VER_STRING VALUE "FileVersion", "2.3.3"
VALUE "InternalName", "gkrellmd" VALUE "InternalName", "gkrellmd"
VALUE "LegalCopyright", "Copyright (C) 1999-2009 Bill Wilson" VALUE "LegalCopyright", "Copyright (C) 1999-2009 Bill Wilson"
VALUE "OriginalFilename", "gkrellmd.exe" VALUE "OriginalFilename", "gkrellmd.exe"
VALUE "ProductName", "GKrellM" VALUE "ProductName", "GKrellM"
VALUE "ProductVersion", RC_VER_STRING VALUE "ProductVersion", "2.3.3"
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"

View File

@ -51,44 +51,28 @@ endif
ifeq ($(without-ntlm),1) ifeq ($(without-ntlm),1)
CONFIGURE_ARGS += --without-ntlm CONFIGURE_ARGS += --without-ntlm
endif endif
# run configure shell script
DUMMY_VAR := $(shell ./configure $(CONFIGURE_ARGS)) DUMMY_VAR := $(shell ./configure $(CONFIGURE_ARGS))
# pull in variables set by configure script
include configure.mk
HAVE_GNUTLS = $(shell grep -c HAVE_GNUTLS configure.h) # Only use own md5-code if neither OpenSSL nor GnuTLS are present
HAVE_SSL = $(shell grep -c HAVE_SSL configure.h) ifneq ($(HAVE_SSL),1)
HAVE_NTLM = $(shell grep -c HAVE_NTLM configure.h)
HAVE_LIBSENSORS = $(shell grep -c HAVE_LIBSENSORS configure.h)
ifeq ($(HAVE_GNUTLS),1)
SSL_LIBS ?= -lgnutls-openssl
else
ifeq ($(HAVE_SSL),1)
SSL_LIBS ?= -lssl -lcrypto
else
EXTRAOBJS ?= md5c.o EXTRAOBJS ?= md5c.o
endif endif
endif
ifeq ($(HAVE_NTLM),1)
NTLM_INCLUDES = `$(PKG_CONFIG) --cflags libntlm`
NTLM_LIBS = `$(PKG_CONFIG) --libs libntlm`
endif
ifeq ($(HAVE_LIBSENSORS),1)
SENSORS_LIBS ?= -lsensors
endif
CC ?= gcc CC ?= gcc
STRIP ?= -s STRIP ?= -s
GKRELLM_INCLUDES = gkrellm.h gkrellm-version.h gkrellm-public-proto.h $(SHARED_PATH)/log.h GKRELLM_INCLUDES = gkrellm.h gkrellm-public-proto.h $(SHARED_PATH)/log.h
PKG_INCLUDE = `$(PKG_CONFIG) --cflags gtk+-2.0 gthread-2.0` PKG_INCLUDE = `$(PKG_CONFIG) --cflags gtk+-2.0 gthread-2.0`
PKG_LIB = `$(PKG_CONFIG) --libs gtk+-2.0 gthread-2.0` PKG_LIB = `$(PKG_CONFIG) --libs gtk+-2.0 gthread-2.0`
FLAGS = -O2 -I.. -I$(SHARED_PATH) $(PKG_INCLUDE) $(GTOP_INCLUDE) $(PTHREAD_INC) \ FLAGS = -O2 -I.. -I$(SHARED_PATH) $(PKG_INCLUDE) $(GTOP_INCLUDE) $(PTHREAD_INC)\
${NTLM_INCLUDES} -DGKRELLM_CLIENT ${SSL_INCLUDE} ${NTLM_INCLUDE} -DGKRELLM_CLIENT
LIBS = $(PKG_LIB) $(GTOP_LIBS) $(SMC_LIBS) $(SYS_LIBS) $(SSL_LIBS) $(SENSORS_LIBS) \ LIBS = $(PKG_LIB) $(GTOP_LIBS) $(SMC_LIBS) $(SYS_LIBS) $(SSL_LIBS) $(SENSORS_LIBS)\
$(NTLM_LIBS) $(NTLM_LIBS)
ifeq ($(debug),1) ifeq ($(debug),1)
@ -121,8 +105,6 @@ ifeq ($(HAVE_GETADDRINFO),1)
endif endif
override CC += -Wall $(FLAGS)
OBJS = main.o alerts.o battery.o base64.o clock.o cpu.o disk.o fs.o \ OBJS = main.o alerts.o battery.o base64.o clock.o cpu.o disk.o fs.o \
hostname.o inet.o mail.o mem.o net.o proc.o sensors.o uptime.o \ hostname.o inet.o mail.o mem.o net.o proc.o sensors.o uptime.o \
chart.o panel.o config.o gui.o krell.o plugins.o pixops.o \ chart.o panel.o config.o gui.o krell.o plugins.o pixops.o \
@ -257,7 +239,7 @@ install_windows:
$(INSTALL) -c -m $(BINMODE) libgkrellm.a $(LIBDIR) $(INSTALL) -c -m $(BINMODE) libgkrellm.a $(LIBDIR)
clean: clean:
$(RM) *.o *~ *.bak configure.h configure.log gkrellm gkrellm.exe \ $(RM) *.o *~ *.bak configure.h configure.mk configure.log gkrellm gkrellm.exe \
libgkrellm.a sysdeps/*.o core libgkrellm.a sysdeps/*.o core
IMAGES = \ IMAGES = \
@ -317,7 +299,7 @@ SYSDEPS_SRC = sysdeps/bsd-common.c sysdeps/bsd-net-open.c sysdeps/freebsd.c \
sysdeps/solaris.c sysdeps/darwin.c sysdeps/sensors-common.c \ sysdeps/solaris.c sysdeps/darwin.c sysdeps/sensors-common.c \
sysdeps/win32.c sysdeps/win32.c
GKRELLM_H = gkrellm.h gkrellm-version.h gkrellm-private.h GKRELLM_H = gkrellm.h gkrellm-private.h
GKRELLM_H_SYS = gkrellm.h gkrellm-public-proto.h gkrellm-private.h \ GKRELLM_H_SYS = gkrellm.h gkrellm-public-proto.h gkrellm-private.h \
gkrellm-sysdeps.h gkrellm-sysdeps.h
@ -358,7 +340,7 @@ winops-win32.o: winops-win32.c $(GKRELLM_H)
win32-plugin.o: win32-plugin.c win32-plugin.h win32-plugin.o: win32-plugin.c win32-plugin.h
win32-libgkrellm.o: win32-libgkrellm.c win32-plugin.h win32-libgkrellm.o: win32-libgkrellm.c win32-plugin.h
win32-resource.o: win32-resource.rc win32-resource.h win32-resource.o: win32-resource.rc win32-resource.h
windres -v -o win32-resource.o win32-resource.rc windres -o win32-resource.o win32-resource.rc
libgkrellm.a: win32-libgkrellm.o libgkrellm.a: win32-libgkrellm.o
ar -cr libgkrellm.a win32-libgkrellm.o ar -cr libgkrellm.a win32-libgkrellm.o
@ -366,3 +348,6 @@ libgkrellm.a: win32-libgkrellm.o
# Checks if the build environment is ok # Checks if the build environment is ok
check_env: check_env:
$(PKG_CONFIG) --atleast-version=2.4 gtk+-2.0 $(PKG_CONFIG) --atleast-version=2.4 gtk+-2.0
%.o: %.c
$(CC) -c -Wall $(FLAGS) $(CFLAGS) $(CPPFLAGS) $< -o $@

64
src/configure vendored
View File

@ -4,6 +4,7 @@
# This configure is run automatically so no need to run it by hand. # This configure is run automatically so no need to run it by hand.
# #
# Copyright (C) 2003-2009 Bill Wilson # Copyright (C) 2003-2009 Bill Wilson
set -e
for i for i
do do
@ -25,32 +26,40 @@ do
fi fi
done done
PKG_INCLUDE=`pkg-config gtk+-2.0 --cflags` GTK_CFLAGS=`pkg-config gtk+-2.0 --cflags`
PKG_LIBS=`pkg-config gtk+-2.0 --libs` GTK_LIBS=`pkg-config gtk+-2.0 --libs`
rm -f configure.h configure.log test test.o test.c
touch configure.h
CC=${CC-gcc} CC=${CC-gcc}
rm -f configure.h configure.mk configure.log
touch configure.h
touch configure.mk
exec 5>./configure.log exec 5>./configure.log
echo "CC : ${CC}" 1>& 5
echo "CFLAGS: ${CFLAGS}" 1>& 5
rm -f test test.exe test.o test.c rm -f test test.exe test.o test.c
if [ "$without_ssl" != "yes" ] if [ "$without_ssl" != "yes" ]
then then
# echo "Checking for ssl... " 1>& 2 # echo "Checking for ssl... " 1>& 2
echo "Checking for ssl... " 1>& 5 echo "Checking for ssl... " 1>& 5
OPENSSL_INCLUDE=`pkg-config openssl --cflags`
OPENSSL_LIBS=`pkg-config openssl --libs`
if [ -z "$OPENSSL_LIBS" ]
then
echo "OpenSSL not found via pkg-config, using hardcoded library names" 1>& 5
OPENSSL_LIBS="-lssl -lcrypto"
fi
cat << EOF > test.c cat << EOF > test.c
#include <openssl/ssl.h> #include <openssl/ssl.h>
int main() int main()
{ {
SSL_METHOD *ssl_method = NULL; const SSL_METHOD *ssl_method = NULL;
SSLeay_add_ssl_algorithms(); SSLeay_add_ssl_algorithms();
SSL_load_error_strings(); SSL_load_error_strings();
@ -60,14 +69,17 @@ int main()
} }
EOF EOF
$CC ${CFLAGS} ${PKG_INCLUDE} -c test.c -o test.o 2>& 5 $CC ${CFLAGS} ${GTK_INCLUDE} ${OPENSSL_INCLUDE} -c test.c -o test.o 2>& 5
$CC test.o -o test ${LINK_FLAGS} ${PKG_LIBS} -lssl -lcrypto 2>& 5 $CC test.o -o test ${LINK_FLAGS} ${GTK_LIBS} ${OPENSSL_LIBS} 2>& 5
if [ -x ./test ] && ./test if [ -x ./test ] && ./test
then then
# echo 'Defining HAVE_SSL' 1>& 2 # echo 'Defining HAVE_SSL' 1>& 2
echo 'Defining HAVE_SSL' 1>& 5 echo 'Defining HAVE_SSL' 1>& 5
echo '#define HAVE_SSL 1' >> configure.h echo '#define HAVE_SSL 1' >> configure.h
echo 'HAVE_SSL=1' >> configure.mk
echo "SSL_LIBS=${OPENSSL_LIBS}" >> configure.mk
echo "SSL_INCLUDE=${OPENSSL_INCLUDE}" >> configure.mk
without_gnutls=yes without_gnutls=yes
else else
# echo "Not found, mail check will not have ssl support..." 1>& 2 # echo "Not found, mail check will not have ssl support..." 1>& 2
@ -83,6 +95,14 @@ then
# echo "Checking for gnutls... " 1>& 2 # echo "Checking for gnutls... " 1>& 2
echo "Checking for gnutls... " 1>& 5 echo "Checking for gnutls... " 1>& 5
GNUTLS_INCLUDE=`pkg-config gnutls --cflags`
GNUTLS_LIBS=`pkg-config gnutls --libs`
if [ -z "$GNUTLS_LIBS" ]
then
echo "GnuTLS not found via pkg-config, using hardcoded library names" 1>& 5
GNUTLS_LIBS="-lgnutls-openssl"
fi
cat << EOF > test.c cat << EOF > test.c
#include <gnutls/openssl.h> #include <gnutls/openssl.h>
#include <gcrypt.h> #include <gcrypt.h>
@ -106,8 +126,8 @@ int main()
} }
EOF EOF
$CC ${CFLAGS} ${PKG_INCLUDE} -c test.c -o test.o 2>& 5 ${CC} ${CFLAGS} ${GTK_INCLUDE} ${GNUTLS_INCLUDE} -c test.c -o test.o 2>& 5
$CC test.o -o test ${LINK_FLAGS} ${PKG_LIBS} -lgnutls-openssl 2>& 5 ${CC} test.o -o test ${LINK_FLAGS} ${GTK_LIBS} ${GNUTLS_LIBS} 2>& 5
if [ -x ./test ] && ./test if [ -x ./test ] && ./test
then then
@ -115,6 +135,9 @@ then
echo 'Defining HAVE_GNUTLS' 1>& 5 echo 'Defining HAVE_GNUTLS' 1>& 5
echo '#define HAVE_GNUTLS 1' >> configure.h echo '#define HAVE_GNUTLS 1' >> configure.h
echo '#define HAVE_SSL 1' >> configure.h echo '#define HAVE_SSL 1' >> configure.h
echo 'HAVE_SSL=1' >> configure.mk
echo "SSL_LIBS=${GNUTLS_LIBS}" >> configure.mk
echo "SSL_INCLUDE=${GNUTLS_INCLUDE}" >> configure.mk
else else
# echo "Not found, mail check will not have gnutls support..." 1>& 2 # echo "Not found, mail check will not have gnutls support..." 1>& 2
echo "Not found, mail check will not have gnutls support..." 1>& 5 echo "Not found, mail check will not have gnutls support..." 1>& 5
@ -145,14 +168,17 @@ int main()
} }
EOF EOF
$CC ${CFLAGS} ${PKG_INCLUDE} ${PKG_NTLM_INCLUDE} -c test.c -o test.o 2>& 5 ${CC} ${CFLAGS} ${GTK_INCLUDE} ${PKG_NTLM_INCLUDE} -c test.c -o test.o 2>& 5
$CC test.o -o test ${LINK_FLAGS} ${PKG_LIBS} ${PKG_NTLM_LIBS} -lntlm 2>& 5 ${CC} test.o -o test ${LINK_FLAGS} ${GTK_LIBS} ${PKG_NTLM_LIBS} -lntlm 2>& 5
if [ -x ./test ] && ./test if [ -x ./test ] && ./test
then then
# echo 'Defining HAVE_NTLM' 1>& 2 # echo 'Defining HAVE_NTLM' 1>& 2
echo 'Defining HAVE_NTLM' 1>& 5 echo 'Defining HAVE_NTLM' 1>& 5
echo '#define HAVE_NTLM 1' >> configure.h echo '#define HAVE_NTLM 1' >> configure.h
echo 'HAVE_NTLM=1' >> configure.mk
echo "NTLM_LIBS=${PKG_NTLM_LIBS}" >> configure.mk
echo "NTLM_INCLUDE=${PKG_NTLM_INCLUDE}" >> configure.mk
else else
# echo "Not found, mail check will not have ntlm support..." 1>& 2 # echo "Not found, mail check will not have ntlm support..." 1>& 2
echo "Not found, mail check will not have ntlm support..." 1>& 5 echo "Not found, mail check will not have ntlm support..." 1>& 5
@ -191,13 +217,15 @@ int main()
} }
EOF EOF
$CC ${CFLAGS} ${PKG_INCLUDE} -c test.c -o test.o 2>& 5 ${CC} ${CFLAGS} ${GTK_INCLUDE} -c test.c -o test.o 2>& 5
$CC test.o -o test ${LINK_FLAGS} ${PKG_LIBS} -lsensors 2>& 5 ${CC} test.o -o test ${LINK_FLAGS} ${GTK_LIBS} -lsensors 2>& 5
if [ -x ./test ] && ./test if [ -x ./test ] && ./test
then then
echo 'Defining HAVE_LIBSENSORS' 1>& 5 echo 'Defining HAVE_LIBSENSORS' 1>& 5
echo '#define HAVE_LIBSENSORS 1' >> configure.h echo '#define HAVE_LIBSENSORS 1' >> configure.h
echo 'HAVE_LIBSENSORS=1' >> configure.mk
echo 'SENSORS_LIBS="-lsensors"' >> configure.mk
else else
echo "Not found, sensors will not have libsensors support..." 1>& 5 echo "Not found, sensors will not have libsensors support..." 1>& 5
fi fi

View File

@ -1,5 +1,5 @@
/* GKrellM /* GKrellM
| Copyright (C) 1999-2008 Bill Wilson | Copyright (C) 1999-2009 Bill Wilson
| |
| Author: Bill Wilson billw@gkrellm.net | Author: Bill Wilson billw@gkrellm.net
| Latest versions might be found at: http://gkrellm.net | Latest versions might be found at: http://gkrellm.net

View File

@ -1,47 +0,0 @@
/* GKrellM
| Copyright (C) 1999-2008 Bill Wilson
|
| Author: Bill Wilson billw@gkrellm.net
| Latest versions might be found at: http://gkrellm.net
|
|
| GKrellM is free software: you can redistribute it and/or modify it
| under the terms of the GNU General Public License as published by
| the Free Software Foundation, either version 3 of the License, or
| (at your option) any later version.
|
| GKrellM is distributed in the hope that it will be useful, but WITHOUT
| ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
| or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
| License for more details.
|
| You should have received a copy of the GNU General Public License
| along with this program. If not, see http://www.gnu.org/licenses/
|
|
| Additional permission under GNU GPL version 3 section 7
|
| If you modify this program, or any covered work, by linking or
| combining it with the OpenSSL project's OpenSSL library (or a
| modified version of that library), containing parts covered by
| the terms of the OpenSSL or SSLeay licenses, you are granted
| additional permission to convey the resulting work.
| Corresponding Source for a non-source form of such a combination
| shall include the source code for the parts of OpenSSL used as well
| as that of the covered work.
*/
#ifndef GKRELLM_VERSION_H
#define GKRELLM_VERSION_H
#define GKRELLM_VERSION_MAJOR 2
#define GKRELLM_VERSION_MINOR 3
#define GKRELLM_VERSION_REV 3
#define GKRELLM_EXTRAVERSION ""
#define GKRELLM_CHECK_VERSION(major,minor,rev) \
(GKRELLM_VERSION_MAJOR > (major) || \
(GKRELLM_VERSION_MAJOR == (major) && GKRELLM_VERSION_MINOR > (minor)) || \
(GKRELLM_VERSION_MAJOR == (major) && GKRELLM_VERSION_MINOR == (minor) && \
GKRELLM_VERSION_REV >= (rev)))
#endif // GKRELLM_VERSION_H

View File

@ -1,5 +1,5 @@
/* GKrellM /* GKrellM
| Copyright (C) 1999-2008 Bill Wilson | Copyright (C) 1999-2009 Bill Wilson
| |
| Author: Bill Wilson billw@gkrellm.net | Author: Bill Wilson billw@gkrellm.net
| Latest versions might be found at: http://gkrellm.net | Latest versions might be found at: http://gkrellm.net
@ -39,7 +39,6 @@
#include "config.h" #include "config.h"
#endif #endif
#include "log.h" #include "log.h"
#include "gkrellm-version.h"
#if !defined(WIN32) #if !defined(WIN32)
#include <sys/param.h> #include <sys/param.h>
@ -103,6 +102,21 @@
#endif /* ENABLE_NLS */ #endif /* ENABLE_NLS */
/* -------------------------------------------------------------------
*/
#define GKRELLM_VERSION_MAJOR 2
#define GKRELLM_VERSION_MINOR 3
#define GKRELLM_VERSION_REV 3
#define GKRELLM_EXTRAVERSION ""
#define GKRELLM_CHECK_VERSION(major,minor,rev) \
(GKRELLM_VERSION_MAJOR > (major) || \
(GKRELLM_VERSION_MAJOR == (major) && GKRELLM_VERSION_MINOR > (minor)) || \
(GKRELLM_VERSION_MAJOR == (major) && GKRELLM_VERSION_MINOR == (minor) && \
GKRELLM_VERSION_REV >= (rev)))
#define GKRELLM_DIR ".gkrellm2" #define GKRELLM_DIR ".gkrellm2"
#define GKRELLM_USER_CONFIG ".gkrellm2/user-config" #define GKRELLM_USER_CONFIG ".gkrellm2/user-config"
#define GKRELLM_2_1_14_CONFIG ".gkrellm2/user_config" #define GKRELLM_2_1_14_CONFIG ".gkrellm2/user_config"

View File

@ -1,7 +1,7 @@
/* GKrellM /* GKrellM
| Copyright (C) 1999-2008 Bill Wilson | Copyright (C) 1999-2009 Bill Wilson
| 2002 Bill Nalen | 2002 Bill Nalen
| 2007-2008 Stefan Gehn | 2007-2009 Stefan Gehn
| |
| Authors: Bill Wilson billw@gkrellm.net | Authors: Bill Wilson billw@gkrellm.net
| Bill Nalen bill@nalens.com | Bill Nalen bill@nalens.com

View File

@ -1,6 +1,6 @@
/* GKrellM Windows Portion /* GKrellM Windows Portion
| Copyright (C) 2002 Bill Nalen | Copyright (C) 2002 Bill Nalen
| 2007-2008 Stefan Gehn | 2007-2009 Stefan Gehn
| |
| Authors: Bill Nalen bill@nalens.com | Authors: Bill Nalen bill@nalens.com
| Stefan Gehn stefan@gkrellm.srcbox.net | Stefan Gehn stefan@gkrellm.srcbox.net

View File

@ -3,13 +3,8 @@
// http://www.resedit.net // http://www.resedit.net
#include "win32-resource.h" #include "win32-resource.h"
#include "gkrellm-version.h" #include "windows.h"
#include <windows.h>
// you don't really want to know why this looks so ugly :P
#define STRINGIFY(x) #x
#define TOSTRING(x) STRINGIFY(x)
#define RC_VER_STRING TOSTRING(GKRELLM_VERSION_MAJOR) "." TOSTRING(GKRELLM_VERSION_MINOR) "." TOSTRING(GKRELLM_VERSION_REV) GKRELLM_EXTRAVERSION
// //
// Icon resources // Icon resources
@ -23,7 +18,7 @@ IDI_ICON3 ICON "gkrellm.ico"
// //
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
1 VERSIONINFO 1 VERSIONINFO
FILEVERSION GKRELLM_VERSION_MAJOR,GKRELLM_VERSION_MINOR,GKRELLM_VERSION_REV,0 FILEVERSION 2,3,3,0
PRODUCTVERSION 0,0,0,0 PRODUCTVERSION 0,0,0,0
FILEOS VOS_NT_WINDOWS32 FILEOS VOS_NT_WINDOWS32
FILETYPE VFT_APP FILETYPE VFT_APP
@ -34,12 +29,12 @@ BEGIN
BEGIN BEGIN
VALUE "CompanyName", "" VALUE "CompanyName", ""
VALUE "FileDescription", "GKrellM" VALUE "FileDescription", "GKrellM"
VALUE "FileVersion", RC_VER_STRING VALUE "FileVersion", "2.3.3"
VALUE "InternalName", "gkrellm" VALUE "InternalName", "gkrellm"
VALUE "LegalCopyright", "Copyright (C) 1999-2009 Bill Wilson" VALUE "LegalCopyright", "Copyright (C) 1999-2009 Bill Wilson"
VALUE "OriginalFilename", "gkrellm.exe" VALUE "OriginalFilename", "gkrellm.exe"
VALUE "ProductName", "GKrellM" VALUE "ProductName", "GKrellM"
VALUE "ProductVersion", RC_VER_STRING VALUE "ProductVersion", "2.3.3"
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"