[SCM] BOINC packaging branch, master, updated. debian/6.10.17+dfsg-3-204-g9cb9f65
Steffen Moeller
moeller at debian.org
Tue Mar 29 14:55:38 UTC 2011
The following commit has been merged in the master branch:
commit ea18fb84adb43f5aa705c1dca9bcf26831d2c7bd
Merge: 48e962673a59fa02188e29c70624cb18c61142c4 82a2f7131c88711358481313c3c7fd826f88fe6b
Author: Steffen Moeller <moeller at debian.org>
Date: Wed Mar 23 22:30:26 2011 +0100
Merge branch 'master' of git+ssh://git.debian.org/git/pkg-boinc/boinc
Conflicts:
debian/rules
diff --combined Makefile.am
index 5a5b9b5,5a5b9b5..058c70e
--- a/Makefile.am
+++ b/Makefile.am
@@@ -21,10 -21,10 +21,10 @@@ if ENABLE_CLIEN
endif
if ENABLE_MANAGER
-- CLIENTGUI_SUBDIRS = clientgui clientgui/res locale
-- if BUILD_X11_SCREENSAVER
-- CLIENTGUI_SUBDIRS += clientscr
-- endif
++CLIENTGUI_SUBDIRS = clientgui clientgui/res locale
++##if BUILD_X11_SCREENSAVER
++## CLIENTGUI_SUBDIRS += clientscr
++##endif
endif
# ORDER MATTERS below. One must build dependencies FIRST, then things
diff --combined api/Makefile.am
index d2cf273,d2cf273..5956b65
--- a/api/Makefile.am
+++ b/api/Makefile.am
@@@ -16,12 -16,12 +16,12 @@@ graphics2_files =
gutil.cpp \
gutil_text.cpp \
reduce_lib.cpp \
-- texfont.cpp \
texture.cpp \
graphics2.cpp \
graphics2_unix.cpp
++# removed: texfont.cpp txf_util.cpp
++
if OS_DARWIN
graphics2_files += mac_icon.cpp
graphics2_files += macglutfix.m
diff --combined api/graphics2_unix.cpp
index 54ef255,54ef255..15b35ad
--- a/api/graphics2_unix.cpp
+++ b/api/graphics2_unix.cpp
@@@ -45,8 -45,8 +45,6 @@@ static int win=0
static int checkparentcounter=0;
#ifdef __APPLE__
--#include <sys/param.h> // for MAXPATHLEN
--
static bool need_show = false;
#endif
@@@ -224,8 -224,8 +222,7 @@@ void boinc_graphics_loop(int argc, char
}
#ifdef __APPLE__
-- char dir [MAXPATHLEN];
-- getcwd(dir, MAXPATHLEN);
++ char *dir=get_current_dir_name();
#endif
for (int i=1; i<argc; i++) {
if (!strcmp(argv[i], "--fullscreen")) {
@@@ -237,7 -237,7 +234,10 @@@
glutTimerFunc(TIMER_INTERVAL_MSEC, timer_handler, 0);
#ifdef __APPLE__
// Apparently glut changed our working directory in OS 10.3.9
-- chdir(dir);
++ if (chdir(dir)) {
++ # some error message should be here;
++ }
++ free(dir);
#endif
glutMainLoop();
}
diff --combined api/mac_icon.cpp
index 80bc0c9,80bc0c9..4a9604d
--- a/api/mac_icon.cpp
+++ b/api/mac_icon.cpp
@@@ -30,7 -30,7 +30,6 @@@
*/
#include <Carbon/Carbon.h>
--#include <sys/param.h> // for MAXPATHLEN
#include <sys/stat.h>
#include "boinc_api.h"
@@@ -141,12 -141,12 +140,13 @@@ static char * PersistentFGets(char *buf
void getPathToThisApp(char* pathBuf, size_t bufSize) {
FILE *f;
-- char buf[MAXPATHLEN], *c;
++ char *buf; // A fixed buffer of MAXPATHLEN is too much and not required to fix this way
++ char *c;
pid_t myPID = getpid();
int i;
struct stat stat_buf;
-- strcpy(pathBuf, GRAPHICS_APP_FILENAME);
++ strncpy(pathBuf, GRAPHICS_APP_FILENAME, bufSize);
if (!stat(pathBuf, &stat_buf)) {
// stat() returns zero on success
return;
@@@ -159,8 -159,8 +159,12 @@@
// (or the soft-link to it.) So all we need for the path to this
// application is the file name. We use the -c option so ps strips off
// any command-line arguments for us.
-- sprintf(buf, "ps -wcp %d -o command=", myPID);
++ buf=(char*)malloc(sizeof(char)*(20+100));
++ if (!buf)
++ return;
++ snprintf(buf, 20+100-1, "ps -wcp %d -o command=", myPID);
f = popen(buf, "r");
++ free(buf); buf=(char*)NULL;
if (!f)
return;
PersistentFGets(pathBuf, bufSize, f); // Skip over line of column headings
diff --combined api/txf_util.cpp
index 7121152,7121152..fc57b95
--- a/api/txf_util.cpp
+++ b/api/txf_util.cpp
@@@ -26,14 -26,14 +26,15 @@@
#include "filesys.h"
#include "boinc_api.h"
--#include "texfont.h"
++//#include "texfont.h"
#include "txf_util.h"
#ifndef _MAX_PATH
#define _MAX_PATH 256
#endif
--static TexFont* txf[TXF_NUM_FONT];
++//static TexFont* txf[TXF_NUM_FONT];
++static void* txf[TXF_NUM_FONT];
// load fonts. call once.
//
diff --combined api/txf_util.h
index 93a1599,93a1599..be006a6
--- a/api/txf_util.h
+++ b/api/txf_util.h
@@@ -21,6 -21,6 +21,8 @@@
#ifndef _TXF_UTIL_
#define _TXF_UTIL_
++#include <GL/gl.h>
++
#ifdef __cplusplus
extern "C" {
#endif
diff --combined client/check_security.cpp
index 1686a4c,1686a4c..40876b8
--- a/client/check_security.cpp
+++ b/client/check_security.cpp
@@@ -23,7 -23,7 +23,12 @@@
#include <unistd.h>
#include <pwd.h> // getpwnam
#include <grp.h>
--#include <sys/param.h> // for MAXPATHLEN
++
++#include <sys/param.h> // for MAXPATHLEN, not available e.g. for HURD
++#ifndef MAXPATHLEN
++#define MAXPATHLEN 40000
++#endif
++
#include <dirent.h>
#include <cerrno>
diff --combined client/hostinfo_unix.cpp
index cd90f7b,cd90f7b..3433328
--- a/client/hostinfo_unix.cpp
+++ b/client/hostinfo_unix.cpp
@@@ -1098,8 -1098,8 +1098,8 @@@ int GetMaxCPUTemperature()
// see if Virtualbox is installed
//
int HOST_INFO::get_virtualbox_version() {
-- char path[MAXPATHLEN];
-- char cmd [MAXPATHLEN+35];
++ char path[500]; // less than MAXPATHLEN and more than required below
++ char cmd [500+35];
char *newlinePtr;
FILE* fd;
diff --combined client/switcher.cpp
index 237feda,237feda..cd0a263
--- a/client/switcher.cpp
+++ b/client/switcher.cpp
@@@ -27,9 -27,9 +27,6 @@@
#include <cstdio>
#include <cstring>
#include <cerrno>
--#ifdef HAVE_SYS_PARAM_H
--#include <sys/param.h> // for MAXPATHLEN
--#endif
#include <pwd.h> // getpwuid
#include <grp.h>
@@@ -52,10 -52,10 +49,9 @@@ int main(int argc, char** argv)
strcpy(group_name, "boinc_project");
#if 0 // For debugging only
-- char current_dir[MAXPATHLEN];
--
-- getcwd( current_dir, sizeof(current_dir));
++ char *current_dir=get_current_dir_name();
fprintf(stderr, "current directory = %s\n", current_dir);
++ free(current_dir); current_dir=NULL;
for (int i=0; i<argc; i++) {
fprintf(stderr, "switcher arg %d: %s\n", i, argv[i]);
diff --combined clientgui/common/wxFlatNotebookImages.h
index ffd3b6c,ffd3b6c..9796141
--- a/clientgui/common/wxFlatNotebookImages.h
+++ b/clientgui/common/wxFlatNotebookImages.h
@@@ -25,7 -25,7 +25,7 @@@ namespace FN
// Images used by the control
////////////////////////////////////////////////////////////
/* XPM */
-- static char *left_arrow_disabled_xpm[] = {
++ static const char *left_arrow_disabled_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -57,7 -57,7 +57,7 @@@
};
/* XPM */
-- static char *x_button_pressed_xpm[] = {
++ static const char *x_button_pressed_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -90,7 -90,7 +90,7 @@@
/* XPM */
-- static char *left_arrow_xpm[] = {
++ static const char *left_arrow_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -122,7 -122,7 +122,7 @@@
};
/* XPM */
-- static char *x_button_hilite_xpm[] = {
++ static const char *x_button_hilite_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -154,7 -154,7 +154,7 @@@
};
/* XPM */
-- static char *x_button_xpm[] = {
++ static const char *x_button_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -186,7 -186,7 +186,7 @@@
};
/* XPM */
-- static char *left_arrow_pressed_xpm[] = {
++ static const char *left_arrow_pressed_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -218,7 -218,7 +218,7 @@@
};
/* XPM */
-- static char *left_arrow_hilite_xpm[] = {
++ static const char *left_arrow_hilite_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -250,7 -250,7 +250,7 @@@
};
/* XPM */
-- static char *right_arrow_disabled_xpm[] = {
++ static const char *right_arrow_disabled_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -282,7 -282,7 +282,7 @@@
};
/* XPM */
-- static char *right_arrow_hilite_xpm[] = {
++ static const char *right_arrow_hilite_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -314,7 -314,7 +314,7 @@@
};
/* XPM */
-- static char *right_arrow_pressed_xpm[] = {
++ static const char *right_arrow_pressed_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -347,7 -347,7 +347,7 @@@
/* XPM */
-- static char *right_arrow_xpm[] = {
++ static const char *right_arrow_xpm[] = {
/* width height num_colors chars_per_pixel */
" 16 16 8 1",
/* colors */
@@@ -381,7 -381,7 +381,7 @@@
const int tab_x_size = 9;
/* XPM */
-- static char *tab_x_button_pressed_xpm[] = {
++ static const char *tab_x_button_pressed_xpm[] = {
/* width height num_colors chars_per_pixel */
" 9 9 8 1",
/* colors */
@@@ -406,7 -406,7 +406,7 @@@
};
/* XPM */
-- static char *tab_x_button_xpm[] = {
++ static const char *tab_x_button_xpm[] = {
/* width height num_colors chars_per_pixel */
" 9 9 8 1",
/* colors */
@@@ -431,7 -431,7 +431,7 @@@
};
/* XPM */
-- static char *tab_x_button_hilite_xpm[] = {
++ static const char *tab_x_button_hilite_xpm[] = {
/* width height num_colors chars_per_pixel */
" 9 9 8 1",
/* colors */
diff --combined clientscr/gfx_switcher.cpp
index 68f4474,68f4474..939f574
--- a/clientscr/gfx_switcher.cpp
+++ b/clientscr/gfx_switcher.cpp
@@@ -27,8 -27,8 +27,12 @@@
#include <cstring>
#include <cerrno>
#ifdef HAVE_SYS_PARAM_H
--#include <sys/param.h> // for MAXPATHLEN
++#include <sys/param.h> // for MAXPATHLEN, not available e.g. for HURD
#endif
++#ifndef MAXPATHLEN
++#define MAXPATHLEN 40000
++#endif
++
#include <pwd.h> // getpwuid
#include <grp.h>
@@@ -84,10 -84,10 +88,9 @@@ int main(int argc, char** argv)
// NOTE: call print_to_log_file only after switching user and group
#if 0 // For debugging only
-- char current_dir[MAXPATHLEN];
--
-- getcwd( current_dir, sizeof(current_dir));
++ char *current_dir = get_current_dir_name();
print_to_log_file( "current directory = %s", current_dir);
++ free(current_dir); current_dir=(char *) NULL;
for (int i=0; i<argc; i++) {
print_to_log_file("switcher arg %d: %s", i, argv[i]);
diff --combined clientscr/mac_saver_module.cpp
index f1b684c,f1b684c..52e2b68
--- a/clientscr/mac_saver_module.cpp
+++ b/clientscr/mac_saver_module.cpp
@@@ -30,7 -30,7 +30,6 @@@
#include <unistd.h>
#include <limits.h>
#include <sys/stat.h>
--#include <sys/param.h> // for MAXPATHLEN
#include "gui_rpc_client.h"
#include "common_defs.h"
diff --combined debian/rules
index 99c8f68,0ec8d22..6051bc0
--- a/debian/rules
+++ b/debian/rules
@@@ -3,7 -3,7 +3,7 @@@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
- # Uncomment this to compile with gcc-snapshot.
+ # Uncomment the following lines to compile with gcc-snapshot.
#export CC=/usr/lib/gcc-snapshot/bin/gcc
#export CXX=/usr/lib/gcc-snapshot/bin/g++
#export CPP=/usr/lib/gcc-snapshot/bin/cpp
@@@ -23,9 -23,6 +23,9 @@@ endi
# because projects mostly provide applications for official BOINC platforms
# only. See http://boinc.berkeley.edu/trac/wiki/BoincPlatforms for the list
# of official BOINC platforms.
+#
+# The table of architectures known to dpkg-architecture are listed on
+# /usr/share/dpkg/archtable
# Change BOINC platform alpha-unknown-linux-gnu to alpha-hp-linux-gnu and
# declare alpha-unknown-linux-gnu as alternate platform, because some projects
@@@ -46,13 -43,6 +46,13 @@@ ifeq ($(DEB_HOST_GNU_TYPE), i486-kfreeb
TYPE_FLAGS += --with-boinc-platform=i686-pc-kfreebsd-gnu
endif
+# Declare i686-pc-kfreebsd-gnu as alternate platform for
+# x86_64-pc-kfreebsd-gnu.
+ifeq ($(DEB_HOST_GNU_TYPE), x86_64-kfreebsd-gnu)
+ TYPE_FLAGS += --with-boinc-platform=x86_64-pc-kfreebsd-gnu
+ TYPE_FLAGS += --with-boinc-alt-platform=i686-pc-kfreebsd-gnu
+endif
+
# Change BOINC platform ia64-unknown-linux-gnu to ia64-linux-gnu.
ifeq ($(DEB_HOST_GNU_TYPE), ia64-linux-gnu)
TYPE_FLAGS += --with-boinc-platform=ia64-linux-gnu
@@@ -75,6 -65,21 +75,16 @@@ ifeq ($(DEB_HOST_GNU_TYPE), sparc-linux
TYPE_FLAGS += --with-boinc-platform=sparc-sun-linux-gnu
endif
-# Declare i686-pc-kfreebsd-gnu as alternate platform for
-# x86_64-pc-kfreebsd-gnu.
-ifeq ($(DEB_HOST_GNU_TYPE), x86_64-kfreebsd-gnu)
- TYPE_FLAGS += --with-boinc-alt-platform=i686-pc-kfreebsd-gnu
-endif
-
+ # Not touching BOINC platform for hurd for the very moment.
+ # Manually specify the MAXPATHLEN for GNU where this limit
+ # is not existing.
+ ifeq ($(DEB_HOST_GNU_TYPE), i486-gnu)
+ # setting it to the regular limit for the other flavours of Debian
+ CFLAGS += -DMAXPATHLEN=4096
+ #TYPE_FLAGS += --with-boinc-platform=i686-pc-hurd-gnu
+ endif
+
++
CFLAGS += -g -Wall
CXXFLAGS += -g -Wall
LDFLAGS += -Wl,--as-needed
diff --combined generate_svn_version.sh
index b90f9bc,b90f9bc..41add3c
--- a/generate_svn_version.sh
+++ b/generate_svn_version.sh
@@@ -7,7 -7,7 +7,9 @@@ echo "#ifndef SVN_VERSION_H" > $TMPFIL
echo "#define SVN_VERSION_H" >> $TMPFILE
echo "" >> $TMPFILE
--if [ -d .git ]; then
++if [ -d debian ]; then
++ CMD=""
++elif [ -d .git ]; then
CMD="git svn info"
elif [ -d .svn ]; then
CMD="svn info"
diff --combined samples/sleeper/Makefile
index 13492ec,13492ec..d5cf8f7
--- a/samples/sleeper/Makefile
+++ b/samples/sleeper/Makefile
@@@ -1,29 -1,29 +1,43 @@@
# This should work on Linux. Modify as needed for other platforms.
--BOINC_DIR = ../..
++# Change the following to match your installation
++BOINC_DIR = /usr/include/boinc
BOINC_API_DIR = $(BOINC_DIR)/api
BOINC_LIB_DIR = $(BOINC_DIR)/lib
CXXFLAGS = -g \
++ -I../.. \
++ -I../../api \
++ -I../../lib \
++ -L../../lib \
-I$(BOINC_DIR) \
-I$(BOINC_LIB_DIR) \
-I$(BOINC_API_DIR) \
-L$(BOINC_API_DIR) \
-L$(BOINC_LIB_DIR) \
-- -L.
--PROGS = sleeper
++PROGS= sleeper
++EXTRA_SOURCES=
all: $(PROGS)
--libstdc++.a:
-- ln -s `g++ -print-file-name=libstdc++.a`
++LIBS=libstdc++.a libboinc_api.a libboinc.a
++
++$(LIBS):
++ if [ -r "../../lib/$@" ]; then \
++ ln -sf "../../lib/$@" . ; \
++ elif [ -r "../../api/$@" ]; then \
++ ln -sf "../../api/$@" . ; \
++ else \
++ ln -sf `g++ -print-file-name=$@` ; \
++ fi
clean:
-- rm $(PROGS)
++ rm -f $(PROGS) *.o *.a
distclean:
-- /bin/rm -f $(PROGS) *.o libstdc++.a
++ /bin/rm -f $(PROGS) *.o $(LIBS)
++
++$(PROGS): $(LIBS)
++ g++ $(CXXFLAGS) -Wl,--as-needed -o $@ $(@).cpp $(EXTRA_SOURCES) -L . $(LIBS) -pthread
--sleeper: sleeper.o libstdc++.a $(BOINC_LIB_DIR)/libboinc.a $(BOINC_API_DIR)/libboinc_api.a
-- g++ $(CXXFLAGS) -o sleeper sleeper.o libstdc++.a -pthread -lboinc_api -lboinc
diff --combined samples/wrapper/Makefile
index 8b6f5b2,8b6f5b2..4cf869f
--- a/samples/wrapper/Makefile
+++ b/samples/wrapper/Makefile
@@@ -1,30 -1,30 +1,43 @@@
# This should work on Linux. Modify as needed for other platforms.
# Change the following to match your installation
--BOINC_DIR = ../..
++BOINC_DIR = /usr/include/boinc
BOINC_API_DIR = $(BOINC_DIR)/api
BOINC_LIB_DIR = $(BOINC_DIR)/lib
CXXFLAGS = -g \
++ -I../.. \
++ -I../../api \
++ -I../../lib \
++ -L../../lib \
-I$(BOINC_DIR) \
-I$(BOINC_LIB_DIR) \
-I$(BOINC_API_DIR) \
-L$(BOINC_API_DIR) \
-L$(BOINC_LIB_DIR) \
-- -L.
--PROGS = wrapper
++PROGS= wrapper
++EXTRA_SOURCES=
all: $(PROGS)
--libstdc++.a:
-- ln -s `g++ -print-file-name=libstdc++.a`
++LIBS=libstdc++.a libboinc_api.a libboinc.a
++
++$(LIBS):
++ if [ -r "../../lib/$@" ]; then \
++ ln -sf "../../lib/$@" . ; \
++ elif [ -r "../../api/$@" ]; then \
++ ln -sf "../../api/$@" . ; \
++ else \
++ ln -sf `g++ -print-file-name=$@` ; \
++ fi
clean:
-- rm $(PROGS) *.o
++ rm -f $(PROGS) *.o *.a
distclean:
-- /bin/rm -f $(PROGS) *.o libstdc++.a
++ /bin/rm -f $(PROGS) *.o $(LIBS)
++
++$(PROGS): $(LIBS)
++ g++ $(CXXFLAGS) -Wl,--as-needed -o $@ $(@).cpp $(EXTRA_SOURCES) -L . $(LIBS) -pthread
--wrapper: wrapper.o libstdc++.a $(BOINC_LIB_DIR)/libboinc.a $(BOINC_API_DIR)/libboinc_api.a
-- g++ $(CXXFLAGS) -o wrapper wrapper.o libstdc++.a -pthread -lboinc_api -lboinc
diff --combined samples/wrapper/wrapper.cpp
index fdd2db9,fdd2db9..add597e
--- a/samples/wrapper/wrapper.cpp
+++ b/samples/wrapper/wrapper.cpp
@@@ -25,7 -25,7 +25,7 @@@
// - checkpointing
// (at the level of task; or potentially within task)
//
--// See http://boinc.berkeley.edu/wrapper.php for details
++// See http://boinc.berkeley.edu/trac/wiki/WrapperApp for details
// Contributor: Andrew J. Younge (ajy4490 at umiacs.umd.edu)
#include <stdio.h>
diff --combined tools/calculate_credit_multiplier
index 192d6b6,192d6b6..f512dc5
--- a/tools/calculate_credit_multiplier
+++ b/tools/calculate_credit_multiplier
@@@ -23,7 -23,7 +23,7 @@@ f
MYSQL="mysql -D $dbname -h $dbhost -u $dbuser -N -B"
MYSQL_R="mysql -D $dbname -h $replica_dbhost -u $dbuser -N -B"
--function median_host_query() {
++median_host_query() {
$MYSQL --execute="
create temporary table medians (id int auto_increment primary key)
select $1 from host
@@@ -40,7 -40,7 +40,7 @@@
drop table ids;"
}
--function get_recent_credited_results() {
++get_recent_credited_results() {
$MYSQL_R --execute="
set session transaction isolation level read uncommitted;
create temporary table recent_results
diff --combined tools/db_query
index f5649da,f5649da..02aaf54
--- a/tools/db_query
+++ b/tools/db_query
@@@ -1,4 -1,4 +1,4 @@@
--#! /bin/csh
++#!/usr/bin/tcsh
set CIVDATE = `date "+%Y:%m:%d:%H:%M"`
set UNIXDATE = `perl -e 'print time()'`
diff --combined tools/watch_tcp
index 3f4eede,3f4eede..5686014
--- a/tools/watch_tcp
+++ b/tools/watch_tcp
@@@ -1,4 -1,4 +1,4 @@@
--#! /bin/csh
++#!/usr/bin/tcsh
#
# by jeffc
#
--
BOINC packaging
More information about the pkg-boinc-commits
mailing list