mirror of https://github.com/BOINC/boinc.git
*** empty log message ***
svn path=/trunk/boinc/; revision=3034
This commit is contained in:
parent
fc72b3b33b
commit
06c039bb56
|
@ -21,10 +21,10 @@
|
|||
// graphics-related code goes in graphics_api.C, not here
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#include "win/Stackwalker.h"
|
||||
#include "stdafx.h"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
@ -44,6 +44,7 @@
|
|||
#include <sys/types.h>
|
||||
|
||||
using namespace std;
|
||||
#endif
|
||||
|
||||
#include "parse.h"
|
||||
#include "shmem.h"
|
||||
|
|
|
@ -20,16 +20,13 @@
|
|||
#ifndef _BOINC_API_
|
||||
#define _BOINC_API_
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <string>
|
||||
#include <assert.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <crtdbg.h>
|
||||
#endif
|
||||
|
||||
#include "app_ipc.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
// ****************************************************************************
|
||||
// ****************************************************************************
|
||||
|
|
|
@ -20,14 +20,15 @@
|
|||
// The part of the BOINC app lib having to do with graphics.
|
||||
// This code is NOT linked into the core client.
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#include "stdafx.h"
|
||||
extern DWORD WINAPI win_graphics_event_loop( LPVOID duff );
|
||||
HANDLE graphics_threadh=NULL;
|
||||
#else
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#ifdef __APPLE_CC__
|
||||
#include "mac_app_opengl.h"
|
||||
#endif
|
||||
|
@ -38,6 +39,7 @@ HANDLE graphics_threadh=NULL;
|
|||
#ifdef HAVE_PTHREAD
|
||||
#include <pthread.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include "parse.h"
|
||||
#include "util.h"
|
||||
|
|
|
@ -1,18 +1,7 @@
|
|||
#ifndef BOINC_GRAPHICS_API_H
|
||||
#define BOINC_GRAPHICS_API_H
|
||||
|
||||
#ifdef __APPLE_CC__
|
||||
#ifndef HAVE_GL_LIB
|
||||
#define HAVE_GL_LIB 1
|
||||
#endif
|
||||
#ifndef HAVE_OPENGL_GL_H
|
||||
#define HAVE_OPENGL_GL_H
|
||||
#endif
|
||||
#include <Carbon/Carbon.h>
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#ifndef HAVE_GL_LIB
|
||||
#define HAVE_GL_LIB 1
|
||||
#endif
|
||||
|
@ -27,6 +16,16 @@
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE_CC__
|
||||
#ifndef HAVE_GL_LIB
|
||||
#define HAVE_GL_LIB 1
|
||||
#endif
|
||||
#ifndef HAVE_OPENGL_GL_H
|
||||
#define HAVE_OPENGL_GL_H
|
||||
#endif
|
||||
#include <Carbon/Carbon.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_GL_H
|
||||
#include <gl.h>
|
||||
#elif defined(HAVE_GL_GL_H)
|
||||
|
|
31
api/gutil.C
31
api/gutil.C
|
@ -17,28 +17,19 @@
|
|||
// Contributor(s):
|
||||
//
|
||||
|
||||
#ifndef _WIN32
|
||||
#include "config.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "stdafx.h"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <math.h>
|
||||
#include <setjmp.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#include "jpeglib.h"
|
||||
#include "bmplib.h"
|
||||
#include "tgalib.h"
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glu.h>
|
||||
#include <GLUT/glut.h>
|
||||
#else
|
||||
#include <jpeglib.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_GL_H
|
||||
#include "gl.h"
|
||||
#elif defined(HAVE_GL_GL_H)
|
||||
|
@ -65,6 +56,18 @@
|
|||
#elif defined(HAVE_GLUT_GLUT_H)
|
||||
#include <GLUT/glut.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "jpeglib.h"
|
||||
#include "bmplib.h"
|
||||
#include "tgalib.h"
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glu.h>
|
||||
#include <GLUT/glut.h>
|
||||
#else
|
||||
#include <jpeglib.h>
|
||||
#endif
|
||||
|
||||
#include "gutil.h"
|
||||
#include "filesys.h"
|
||||
|
@ -1350,7 +1353,7 @@ void print_text(char* string) {
|
|||
if(string==NULL) return;
|
||||
glPushAttrib(GL_LIST_BIT);
|
||||
glListBase(listBase);
|
||||
glCallLists(strlen(string), GL_UNSIGNED_BYTE, string);
|
||||
glCallLists((GLsizei)strlen(string), GL_UNSIGNED_BYTE, string);
|
||||
glPopAttrib();
|
||||
}
|
||||
|
||||
|
|
12
api/mfile.C
12
api/mfile.C
|
@ -17,6 +17,11 @@
|
|||
// Contributor(s):
|
||||
//
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "stdafx.h"
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdarg.h>
|
||||
|
@ -28,6 +33,7 @@
|
|||
#endif
|
||||
|
||||
using namespace std;
|
||||
#endif
|
||||
|
||||
#include "filesys.h"
|
||||
#include "error_numbers.h"
|
||||
|
@ -49,7 +55,7 @@ int MFILE::printf(const char* format, ...) {
|
|||
va_start(ap, format);
|
||||
k = vsprintf(buf2, format, ap);
|
||||
va_end(ap);
|
||||
n = strlen(buf2);
|
||||
n = (int)strlen(buf2);
|
||||
buf = (char*)realloc(buf, len+n);
|
||||
if (!buf) {
|
||||
errno = ERR_MALLOC;
|
||||
|
@ -67,7 +73,7 @@ size_t MFILE::write(const void *ptr, size_t size, size_t nitems) {
|
|||
return 0;
|
||||
}
|
||||
memcpy( buf+len, ptr, size*nitems );
|
||||
len += size*nitems;
|
||||
len += (int)size*(int)nitems;
|
||||
return nitems;
|
||||
}
|
||||
|
||||
|
@ -83,7 +89,7 @@ int MFILE::_putchar(char c) {
|
|||
}
|
||||
|
||||
int MFILE::puts(const char* p) {
|
||||
int n = strlen(p);
|
||||
int n = (int)strlen(p);
|
||||
buf = (char*)realloc(buf, len+n);
|
||||
if (!buf) {
|
||||
errno = ERR_MALLOC;
|
||||
|
|
28
api/reduce.C
28
api/reduce.C
|
@ -1,18 +1,36 @@
|
|||
// Copyright 2003 Regents of the University of California
|
||||
|
||||
// SETI_BOINC 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 2, or (at your option) any later
|
||||
// version.
|
||||
|
||||
// SETI_BOINC 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 SETI_BOINC; see the file COPYING. If not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "stdafx.h"
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <windows.h>
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE_CC__
|
||||
#include <OpenGL/gl.h>
|
||||
#define max(a,b) (a>b?a:b)
|
||||
#define min(a,b) (a>b?b:a)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#include "gutil.h"
|
||||
#include "reduce.h"
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -26,7 +26,7 @@
|
|||
#endif
|
||||
|
||||
// Only MS VC++ 5 to 7
|
||||
#if (_MSC_VER < 1100) || (_MSC_VER > 1400)
|
||||
#if (_MSC_VER < 1100) || (_MSC_VER > 1310)
|
||||
#error Only MS VC++ 5/6/7 supported. Check if the '_CrtMemBlockHeader' has not changed with this compiler!
|
||||
#endif
|
||||
|
||||
|
@ -41,10 +41,6 @@ typedef enum eAllocCheckOutput
|
|||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
extern int InitAllocCheckWN(eAllocCheckOutput eOutput, LPCTSTR pszFilename, ULONG ulShowStackAtAlloc = 0);
|
||||
extern int InitAllocCheck(eAllocCheckOutput eOutput = ACOutput_Simple, BOOL bSetUnhandledExeptionFilter = TRUE, ULONG ulShowStackAtAlloc = 0); // will create the filename by itself
|
||||
|
||||
extern ULONG DeInitAllocCheck();
|
||||
|
||||
extern DWORD StackwalkFilter( EXCEPTION_POINTERS *ep, DWORD status, LPCTSTR pszLogFile);
|
||||
|
||||
|
|
|
@ -14,13 +14,7 @@
|
|||
* Adapted to BOINC by Eric Heien
|
||||
*/
|
||||
|
||||
//remove if there are windows problems
|
||||
#define WIN32_LEAN_AND_MEAN // This trims down the windows libraries.
|
||||
#define WIN32_EXTRA_LEAN // Trims even farther.
|
||||
|
||||
#include <windows.h>
|
||||
#include <stdio.h>
|
||||
#include <winuser.h>
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "boinc_api.h"
|
||||
#include "graphics_api.h"
|
||||
|
|
|
@ -10319,7 +10319,7 @@ Rom Mar 4 2004
|
|||
boinc.dll (Before Changes) 136KB 44KB
|
||||
|
||||
boinc_gui.exe (After Changes) 1.716MB 428KB
|
||||
boinc_cli.exe (After Changes) 1.508MB 272KB
|
||||
boinc_cli.exe (After Changes) 1.508MB 412KB
|
||||
boinc.scr (After Changes) 188KB 116KB
|
||||
boinc.dll (After Changes) 140KB 58KB
|
||||
|
||||
|
@ -10356,8 +10356,18 @@ Rom Mar 4 2004
|
|||
util.h
|
||||
|
||||
Rom Mar 5 2004
|
||||
- Fix profile path problem that I didn't check-in after fixing it in the alpha project
|
||||
the first time.
|
||||
- Include file overhaul for the Windows platform ( Part 2 )
|
||||
|
||||
html/user/
|
||||
profile_menu.php
|
||||
Compiled Source Sizes: Debug Release
|
||||
boinc_gui.exe (Before Changes) 1.732MB 328KB
|
||||
boinc_cli.exe (Before Changes) 2.080MB Unknown
|
||||
boinc.scr (Before Changes) 244KB 88KB
|
||||
boinc.dll (Before Changes) 136KB 44KB
|
||||
|
||||
boinc_gui.exe (After Changes) 1.716MB 428KB
|
||||
boinc_cli.exe (After Changes) 624KB 412KB
|
||||
boinc.scr (After Changes) 188KB 116KB
|
||||
boinc.dll (After Changes) 140KB 58KB
|
||||
|
||||
I pretty much touched all the source and header files. This checkin should not have any
|
||||
effect on any platform other than Windows.
|
||||
|
|
|
@ -60,6 +60,7 @@
|
|||
#include <process.h>
|
||||
#include <commctrl.h>
|
||||
#include <raserror.h>
|
||||
#include <mmsystem.h>
|
||||
|
||||
#include "Stackwalker.h"
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,51 +0,0 @@
|
|||
/*////////////////////////////////////////////////////////////////////////////
|
||||
* Project:
|
||||
* Memory_and_Exception_Trace
|
||||
*
|
||||
* ///////////////////////////////////////////////////////////////////////////
|
||||
* File:
|
||||
* Stackwalker.h
|
||||
*
|
||||
* Remarks:
|
||||
*
|
||||
*
|
||||
* Note:
|
||||
*
|
||||
*
|
||||
* Author:
|
||||
* Jochen Kalmbach
|
||||
*
|
||||
*////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __STACKWALKER_H__
|
||||
#define __STACKWALKER_H__
|
||||
|
||||
// Only valid in the following environment: Intel platform, MS VC++ 5/6/7
|
||||
#ifndef _X86_
|
||||
#error Only INTEL envirnoments are supported!
|
||||
#endif
|
||||
|
||||
// Only MS VC++ 5 to 7
|
||||
#if (_MSC_VER < 1100) || (_MSC_VER > 1310)
|
||||
#error Only MS VC++ 5/6/7 supported. Check if the '_CrtMemBlockHeader' has not changed with this compiler!
|
||||
#endif
|
||||
|
||||
typedef enum eAllocCheckOutput
|
||||
{
|
||||
ACOutput_Simple,
|
||||
ACOutput_Advanced,
|
||||
ACOutput_XML
|
||||
};
|
||||
|
||||
// Make extern "C", so it will also work with normal C-Programs
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern DWORD StackwalkFilter( EXCEPTION_POINTERS *ep, DWORD status, LPCTSTR pszLogFile);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // __STACKWALKER_H__
|
|
@ -120,8 +120,8 @@ void copy_stream(FILE* in, FILE* out) {
|
|||
char buf[1024];
|
||||
int n, m;
|
||||
while (1) {
|
||||
n = fread(buf, 1, 1024, in);
|
||||
m = fwrite(buf, 1, n, out);
|
||||
n = (int)fread(buf, 1, 1024, in);
|
||||
m = (int)fwrite(buf, 1, n, out);
|
||||
if (n < 1024) break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,12 +17,10 @@
|
|||
// Contributor(s):
|
||||
//
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
using std::string;
|
||||
#endif
|
||||
using namespace std;
|
||||
|
||||
|
||||
extern bool parse(char* , char* );
|
||||
|
|
|
@ -293,7 +293,7 @@ void strip_whitespace(char *str) {
|
|||
strcpy(str, str+1);
|
||||
}
|
||||
while (1) {
|
||||
n = strlen(str);
|
||||
n = (int)strlen(str);
|
||||
if (n == 0) break;
|
||||
if (!isascii(str[n-1])) break;
|
||||
if (!isspace(str[n-1])) break;
|
||||
|
@ -307,7 +307,7 @@ void strip_whitespace(string& str) {
|
|||
str.erase(0, 1);
|
||||
}
|
||||
while (1) {
|
||||
n = str.length();
|
||||
n = (int)str.length();
|
||||
if (n == 0) break;
|
||||
if (!isascii(str[n-1])) break;
|
||||
if (!isspace(str[n-1])) break;
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
//
|
||||
// Revision History
|
||||
// $Log$
|
||||
// Revision 1.28 2004/03/06 09:45:25 rwalton
|
||||
// *** empty log message ***
|
||||
//
|
||||
// Revision 1.27 2004/01/22 17:57:41 davea
|
||||
// *** empty log message ***
|
||||
//
|
||||
|
@ -32,12 +35,14 @@
|
|||
//
|
||||
//
|
||||
#include "config.h"
|
||||
|
||||
#include <cctype>
|
||||
#include <vector>
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
#include <cstring>
|
||||
#include <cstdio>
|
||||
|
||||
#include "std_fixes.h"
|
||||
#include "xml_util.h"
|
||||
|
||||
|
@ -562,7 +567,7 @@ std::string x_csv_encode_char(const unsigned char *bin, size_t nelements) {
|
|||
rv << ival << ',';
|
||||
if ((static_cast<int>(rv.str().size())-lastlen-std::min(xml_indent_level,XML_MAX_INDENT))>73) {
|
||||
rv << std::endl << xml_indent();
|
||||
lastlen=rv.str().size();
|
||||
lastlen=(long)rv.str().size();
|
||||
}
|
||||
}
|
||||
unsigned int ival=bin[i];
|
||||
|
@ -644,6 +649,9 @@ bool extract_xml_record(const std::string &field, const char *tag, std::string &
|
|||
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.28 2004/03/06 09:45:25 rwalton
|
||||
// *** empty log message ***
|
||||
//
|
||||
// Revision 1.27 2004/01/22 17:57:41 davea
|
||||
// *** empty log message ***
|
||||
//
|
||||
|
|
205
lib/xml_util.h
205
lib/xml_util.h
|
@ -21,6 +21,9 @@
|
|||
//
|
||||
// Revision History:
|
||||
// $Log$
|
||||
// Revision 1.20 2004/03/06 09:45:25 rwalton
|
||||
// *** empty log message ***
|
||||
//
|
||||
// Revision 1.19 2004/02/05 05:32:22 quarl
|
||||
// *** empty log message ***
|
||||
//
|
||||
|
@ -36,14 +39,19 @@
|
|||
|
||||
#ifndef _XML_UTIL_H_
|
||||
#define _XML_UTIL_H_
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <iostream>
|
||||
#include <fstream>
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
#include <vector>
|
||||
|
||||
#include "error_numbers.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
typedef enum tag_xml_encoding {
|
||||
_x_xml_entity=0,
|
||||
_x_xml_cdata,
|
||||
|
@ -82,15 +90,15 @@ const char * const xml_encoding_names[]={
|
|||
// the closing tag is written.
|
||||
class xml_ostream {
|
||||
public:
|
||||
xml_ostream(std::ostream &o, const char *tag);
|
||||
xml_ostream(ostream &o, const char *tag);
|
||||
~xml_ostream();
|
||||
template <typename T>
|
||||
xml_ostream &operator <<(const T &t) { os << t; return *this; };
|
||||
private:
|
||||
void write_head();
|
||||
void write_foot();
|
||||
std::string my_tag;
|
||||
std::ostream &os;
|
||||
string my_tag;
|
||||
ostream &os;
|
||||
};
|
||||
|
||||
// the xml_ofstream class is an ofstream. When the file is opened,
|
||||
|
@ -100,16 +108,16 @@ class xml_ofstream {
|
|||
public:
|
||||
xml_ofstream();
|
||||
explicit xml_ofstream(const char *filename, const char *tag,
|
||||
std::ios_base::openmode m=std::ios_base::out|std::ios_base::binary);
|
||||
ios_base::openmode m=ios_base::out|ios_base::binary);
|
||||
~xml_ofstream();
|
||||
void open(const char *p, const char *tag,
|
||||
std::ios_base::openmode m=std::ios_base::out|std::ios_base::binary);
|
||||
ios_base::openmode m=ios_base::out|ios_base::binary);
|
||||
void close();
|
||||
private:
|
||||
void write_head();
|
||||
void write_foot();
|
||||
std::string my_tag;
|
||||
std::ofstream &os;
|
||||
string my_tag;
|
||||
ofstream &os;
|
||||
};
|
||||
|
||||
// the xml_istream class is an istream that can be constructed from
|
||||
|
@ -118,13 +126,13 @@ class xml_ofstream {
|
|||
// for reading XML from stdin.
|
||||
class xml_istream {
|
||||
public:
|
||||
explicit xml_istream(std::istream &i, const char *tag=0);
|
||||
explicit xml_istream(istream &i, const char *tag=0);
|
||||
~xml_istream();
|
||||
operator std::istream &() {return is;};
|
||||
operator istream &() {return is;};
|
||||
private:
|
||||
void seek_head();
|
||||
std::string my_tag;
|
||||
std::istream &is;
|
||||
string my_tag;
|
||||
istream &is;
|
||||
};
|
||||
// the xml_ifstream class is an ifstream. When the file is opened,
|
||||
// the file pointer is set after the opening tag. An attempt to
|
||||
|
@ -144,20 +152,20 @@ class xml_ifstream {
|
|||
public:
|
||||
xml_ifstream();
|
||||
explicit xml_ifstream(const char *filename, const char *tag=0,
|
||||
std::ios_base::openmode m=std::ios_base::in|std::ios_base::binary);
|
||||
ios_base::openmode m=ios_base::in|ios_base::binary);
|
||||
~xml_ifstream();
|
||||
void open(const char *filename, const char *tag=0,
|
||||
std::ios_base::openmode m=std::ios_base::in|std::ios_base::binary);
|
||||
ios_base::openmode m=ios_base::in|ios_base::binary);
|
||||
xml_ifstream &seekg(pos_type p);
|
||||
xml_ifstream &seekg(off_type o, std::ios_base::seekdir d);
|
||||
xml_ifstream &seekg(off_type o, ios_base::seekdir d);
|
||||
pos_type tellg();
|
||||
bool eof();
|
||||
private:
|
||||
void seek_head();
|
||||
std::string my_tag;
|
||||
string my_tag;
|
||||
pos_type xml_start;
|
||||
pos_type xml_end;
|
||||
std::ifstream &ifs;
|
||||
ifstream &ifs;
|
||||
};
|
||||
|
||||
#endif // 0
|
||||
|
@ -176,7 +184,7 @@ struct xml_entity {
|
|||
// change the xml indent level (number of spaces) by adding or subtracting
|
||||
// "i" spaces. return a string of spaces corresponding to the current xml
|
||||
// indent level.
|
||||
std::string xml_indent(int i=0);
|
||||
string xml_indent(int i=0);
|
||||
static const int XML_MAX_INDENT=40;
|
||||
extern int xml_indent_level;
|
||||
|
||||
|
@ -184,21 +192,21 @@ extern int xml_indent_level;
|
|||
// decode an XML character string. Return a the decoded string in a vector
|
||||
// (null not necessarily a terminator).
|
||||
//template <typename T>
|
||||
//std::vector<T> xml_decode_string(const char *input, size_t length=0,
|
||||
//vector<T> xml_decode_string(const char *input, size_t length=0,
|
||||
// const char *encoding="x_xml_entity");
|
||||
|
||||
// do the same thing, but get the length and encoding type from the
|
||||
// xml tag properties.
|
||||
template <typename T>
|
||||
std::vector<T> xml_decode_field(const std::string &input, const char *tag);
|
||||
vector<T> xml_decode_field(const string &input, const char *tag);
|
||||
|
||||
// encode an XML character string. Return the encoded string.
|
||||
//template <typename T>
|
||||
//std::string xml_encode_string(const T *input, size_t n_elements=0,
|
||||
//string xml_encode_string(const T *input, size_t n_elements=0,
|
||||
// xml_encoding encoding=_x_xml_entity);
|
||||
|
||||
template <typename T>
|
||||
inline std::string xml_encode_string(const std::vector<T> &input,
|
||||
inline string xml_encode_string(const vector<T> &input,
|
||||
xml_encoding encoding=_x_xml_entity) {
|
||||
return xml_encode_string<T>(&(*(input.begin())),input.size(),encoding);
|
||||
}
|
||||
|
@ -214,15 +222,15 @@ bool isencchar(char c);
|
|||
bool isencchar85(char c);
|
||||
|
||||
template <typename T>
|
||||
std::string base64_encode(const T *tbin, size_t n_elements) {
|
||||
string base64_encode(const T *tbin, size_t n_elements) {
|
||||
size_t nbytes=n_elements*sizeof(T);
|
||||
const unsigned char *bin=(const unsigned char *)(tbin);
|
||||
int count=0, offset=0, nleft;
|
||||
const char crlf[]={0xa,0xd,0x0};
|
||||
std::string rv("");
|
||||
string rv("");
|
||||
rv.reserve(nbytes*4/3+nbytes*2/57);
|
||||
char c[5];
|
||||
for (nleft = nbytes; nleft > 0; nleft -= 3) {
|
||||
for (nleft = (int)nbytes; nleft > 0; nleft -= 3) {
|
||||
int i;
|
||||
c[0] = (bin[offset]>>2) & 0x3f ; // 6
|
||||
c[1] = (bin[offset]<<4) & 0x3f | ((bin[offset+1]>>4)&0xf); // 2+4
|
||||
|
@ -243,12 +251,12 @@ std::string base64_encode(const T *tbin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> base64_decode(const char *data, size_t nbytes) {
|
||||
vector<T> base64_decode(const char *data, size_t nbytes) {
|
||||
const char *p=data,*eol,*eol2;
|
||||
const char cr=0xa,lf=0xd;
|
||||
char in[4],c[3];
|
||||
int i;
|
||||
std::vector<unsigned char> rv;
|
||||
vector<unsigned char> rv;
|
||||
rv.reserve(nbytes*3/4);
|
||||
while (p<(data+nbytes)) {
|
||||
while (!isencchar(*p)) {
|
||||
|
@ -257,7 +265,7 @@ std::vector<T> base64_decode(const char *data, size_t nbytes) {
|
|||
eol=strchr(p,cr);
|
||||
eol2=strchr(p,lf);
|
||||
if (eol && eol2) {
|
||||
eol=std::min(eol,eol2);
|
||||
eol=min(eol,eol2);
|
||||
}
|
||||
for (;p<(eol-1);p+=4) {
|
||||
for ( i=0;i<4;i++) {
|
||||
|
@ -283,16 +291,16 @@ std::vector<T> base64_decode(const char *data, size_t nbytes) {
|
|||
for ( i=0;i<3;i++) rv.push_back(c[i]);
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::string base85_encode(const T *tbin, size_t n_elements) {
|
||||
string base85_encode(const T *tbin, size_t n_elements) {
|
||||
size_t nbytes=n_elements*sizeof(T);
|
||||
const unsigned char *bin=(const unsigned char *)(tbin);
|
||||
int count=0;
|
||||
const char crlf[]={0xa,0xd,0x0};
|
||||
std::string rv("");
|
||||
string rv("");
|
||||
rv.reserve(nbytes*4/3+nbytes*2/57);
|
||||
char c[6];
|
||||
int n_pads;
|
||||
|
@ -324,19 +332,19 @@ std::string base85_encode(const T *tbin, size_t n_elements) {
|
|||
rv+=crlf;
|
||||
count=0;
|
||||
}
|
||||
count+=strlen(c);
|
||||
count+=(int)strlen(c);
|
||||
rv+=c;
|
||||
}
|
||||
return rv;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> base85_decode(const char *data, size_t nbytes) {
|
||||
vector<T> base85_decode(const char *data, size_t nbytes) {
|
||||
const char *p=data,*eol,*eol2;
|
||||
const char cr=0xa,lf=0xd;
|
||||
unsigned long val;
|
||||
int npads;
|
||||
std::vector<unsigned char> rv;
|
||||
vector<unsigned char> rv;
|
||||
rv.reserve(nbytes*4/5);
|
||||
while (p<(data+nbytes)) {
|
||||
while (!isencchar85(*p)) {
|
||||
|
@ -345,7 +353,7 @@ std::vector<T> base85_decode(const char *data, size_t nbytes) {
|
|||
eol=strchr(p,cr);
|
||||
eol2=strchr(p,lf);
|
||||
if (eol && eol2) {
|
||||
eol=std::min(eol,eol2);
|
||||
eol=min(eol,eol2);
|
||||
}
|
||||
while (p<eol) {
|
||||
val=0;
|
||||
|
@ -358,7 +366,7 @@ std::vector<T> base85_decode(const char *data, size_t nbytes) {
|
|||
if (p[i]!='_') break;
|
||||
npads++;
|
||||
}
|
||||
for (i=0;i<std::min(eol-p,5-npads);i++) {
|
||||
for (i=0;i<min(eol-p,5-npads);i++) {
|
||||
val*=85;
|
||||
if ((p[i]>='0') && (p[i]<='9')) {
|
||||
val=p[i]-'0';
|
||||
|
@ -379,21 +387,21 @@ std::vector<T> base85_decode(const char *data, size_t nbytes) {
|
|||
rv.push_back(val);
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
|
||||
template <typename T>
|
||||
std::string x_setiathome_encode(const T *tbin, size_t n_elements) {
|
||||
string x_setiathome_encode(const T *tbin, size_t n_elements) {
|
||||
size_t nbytes=n_elements*sizeof(T);
|
||||
const unsigned char *bin=(const unsigned char *)(tbin);
|
||||
int count=0, offset=0, nleft;
|
||||
const char cr=0xa;
|
||||
std::string rv("");
|
||||
string rv("");
|
||||
rv.reserve(nbytes*4/3+nbytes*2/48);
|
||||
rv+="\n";
|
||||
char c[5];
|
||||
for (nleft = nbytes; nleft > 0; nleft -= 3) {
|
||||
for (nleft = (int)nbytes; nleft > 0; nleft -= 3) {
|
||||
c[0] = bin[offset]&0x3f; // 6
|
||||
c[1] = (bin[offset]>>6) | (bin[offset+1]<<2)&0x3f; // 2+4
|
||||
c[2] = ((bin[offset+1]>>4)&0xf) | (bin[offset+2]<<4)&0x3f;// 4+2
|
||||
|
@ -414,11 +422,11 @@ std::string x_setiathome_encode(const T *tbin, size_t n_elements) {
|
|||
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_setiathome_decode(const char *data, size_t nbytes) {
|
||||
vector<T> x_setiathome_decode(const char *data, size_t nbytes) {
|
||||
const char *p=data,*eol,*eol2;
|
||||
char in[4],c[3];
|
||||
int i;
|
||||
std::vector<unsigned char> rv;
|
||||
vector<unsigned char> rv;
|
||||
rv.reserve(nbytes*3/4);
|
||||
while (p<(data+nbytes)) {
|
||||
while ((*p<0x20) || (*p>0x60)){
|
||||
|
@ -427,7 +435,7 @@ std::vector<T> x_setiathome_decode(const char *data, size_t nbytes) {
|
|||
eol=strchr(p,'\n');
|
||||
eol2=strchr(p,'\r');
|
||||
if (eol && eol2) {
|
||||
eol=std::min(eol,eol2);
|
||||
eol=min(eol,eol2);
|
||||
}
|
||||
for (;p<(eol-1);p+=4) {
|
||||
memcpy(in,p,4);
|
||||
|
@ -438,16 +446,16 @@ std::vector<T> x_setiathome_decode(const char *data, size_t nbytes) {
|
|||
for ( i=0;i<3;i++) rv.push_back(c[i]);
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::string quoted_printable_encode(const T *tbin, size_t n_elements) {
|
||||
string quoted_printable_encode(const T *tbin, size_t n_elements) {
|
||||
size_t nbytes=n_elements*sizeof(T);
|
||||
const unsigned char *bin=(const unsigned char *)(tbin);
|
||||
int line_len=0;
|
||||
const char crlf[]={'=',0xa,0xd,0x0};
|
||||
std::string rv("");
|
||||
string rv("");
|
||||
rv.reserve(nbytes*4/3+nbytes*2/48);
|
||||
for (size_t i=0;i<nbytes;i++) {
|
||||
if (isprint(bin[i]) && (bin[i]!='=')) {
|
||||
|
@ -471,8 +479,8 @@ std::string quoted_printable_encode(const T *tbin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> quoted_printable_decode(const char* data, size_t nbytes) {
|
||||
std::vector<unsigned char> rv;
|
||||
vector<T> quoted_printable_decode(const char* data, size_t nbytes) {
|
||||
vector<unsigned char> rv;
|
||||
rv.reserve(strlen(data));
|
||||
size_t i=0;
|
||||
while (i<nbytes) {
|
||||
|
@ -488,14 +496,14 @@ std::vector<T> quoted_printable_decode(const char* data, size_t nbytes) {
|
|||
i+=3;
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::string x_hex_encode(const T *tbin, size_t n_elements) {
|
||||
string x_hex_encode(const T *tbin, size_t n_elements) {
|
||||
size_t nbytes=n_elements*sizeof(T);
|
||||
const unsigned char *bin=(const unsigned char *)(tbin);
|
||||
std::string rv;
|
||||
string rv;
|
||||
int count=0;
|
||||
rv.reserve(nbytes*2+nbytes*2/76);
|
||||
for (unsigned int i=0; i<nbytes; i++) {
|
||||
|
@ -512,8 +520,8 @@ std::string x_hex_encode(const T *tbin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_hex_decode(const char *data, size_t nbytes) {
|
||||
std::vector<unsigned char> rv;
|
||||
vector<T> x_hex_decode(const char *data, size_t nbytes) {
|
||||
vector<unsigned char> rv;
|
||||
rv.reserve(nbytes/2);
|
||||
unsigned int i=0;
|
||||
while (i<nbytes) {
|
||||
|
@ -523,24 +531,24 @@ std::vector<T> x_hex_decode(const char *data, size_t nbytes) {
|
|||
i+=2;
|
||||
rv.push_back(static_cast<unsigned char>(c));
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
|
||||
std::string x_csv_encode_char(const unsigned char *bin, size_t nelements);
|
||||
string x_csv_encode_char(const unsigned char *bin, size_t nelements);
|
||||
|
||||
template <typename T>
|
||||
std::string x_csv_encode(const T *bin, size_t nelements) {
|
||||
std::ostringstream rv("");
|
||||
string x_csv_encode(const T *bin, size_t nelements) {
|
||||
ostringstream rv("");
|
||||
long lastlen=0,i;
|
||||
bool ischar=(sizeof(T)==1);
|
||||
rv << std::endl << xml_indent(2);
|
||||
rv << endl << xml_indent(2);
|
||||
if (ischar) return x_csv_encode_char((const unsigned char *)bin, nelements);
|
||||
for (i=0;i<(nelements-1);i++) {
|
||||
rv << bin[i] << ',';
|
||||
if ((static_cast<int>(rv.str().size())-lastlen-std::min(xml_indent_level,XML_MAX_INDENT))>73) {
|
||||
rv << std::endl << xml_indent();
|
||||
lastlen=rv.str().size();
|
||||
if ((static_cast<int>(rv.str().size())-lastlen-min(xml_indent_level,XML_MAX_INDENT))>73) {
|
||||
rv << endl << xml_indent();
|
||||
lastlen=(long)rv.str().size();
|
||||
}
|
||||
}
|
||||
rv << bin[i] << "\n" << xml_indent(-2);
|
||||
|
@ -549,13 +557,13 @@ std::string x_csv_encode(const T *bin, size_t nelements) {
|
|||
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_csv_decode(const char *data, size_t nbytes) {
|
||||
std::vector<T> rv;
|
||||
vector<T> x_csv_decode(const char *data, size_t nbytes) {
|
||||
vector<T> rv;
|
||||
while (!isdigit(*data)) {
|
||||
data++;
|
||||
nbytes--;
|
||||
}
|
||||
std::istringstream in(std::string(data,nbytes));
|
||||
istringstream in(string(data,nbytes));
|
||||
bool ischar=(sizeof(T)==1);
|
||||
|
||||
while (in) {
|
||||
|
@ -578,18 +586,18 @@ std::vector<T> x_csv_decode(const char *data, size_t nbytes) {
|
|||
}
|
||||
|
||||
|
||||
std::string encode_char(unsigned char c);
|
||||
string encode_char(unsigned char c);
|
||||
unsigned char decode_char(const char *s);
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_xml_entity_decode(const char *input, size_t length) {
|
||||
vector<T> x_xml_entity_decode(const char *input, size_t length) {
|
||||
unsigned int i;
|
||||
char c;
|
||||
if (!length) {
|
||||
// We're going to decode until we see a null. Including the null.
|
||||
length=strlen((const char *)input);
|
||||
}
|
||||
std::vector<unsigned char> rv;
|
||||
vector<unsigned char> rv;
|
||||
char *p;
|
||||
rv.reserve(length);
|
||||
for (i=0; i<length; i++) {
|
||||
|
@ -603,15 +611,15 @@ std::vector<T> x_xml_entity_decode(const char *input, size_t length) {
|
|||
rv.push_back(input[i]);
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::string x_xml_entity_encode(const T *tbin, size_t n_elements) {
|
||||
string x_xml_entity_encode(const T *tbin, size_t n_elements) {
|
||||
size_t length=n_elements*sizeof(T);
|
||||
const unsigned char *input=(const unsigned char *)(tbin);
|
||||
unsigned int i;
|
||||
std::string rv;
|
||||
string rv;
|
||||
rv.reserve(length);
|
||||
for (i=0; i<length; i++) {
|
||||
if (isprint(input[i])) {
|
||||
|
@ -636,8 +644,8 @@ std::string x_xml_entity_encode(const T *tbin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::string x_xml_values_encode(const T *bin, size_t n_elements) {
|
||||
std::ostringstream rv("");
|
||||
string x_xml_values_encode(const T *bin, size_t n_elements) {
|
||||
ostringstream rv("");
|
||||
unsigned int i;
|
||||
for (i=0;i<n_elements-1;i++) {
|
||||
rv << bin[i] ;
|
||||
|
@ -648,9 +656,9 @@ std::string x_xml_values_encode(const T *bin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_xml_values_decode(const char *data, size_t length) {
|
||||
std::istringstream r(std::string(data,length));
|
||||
std::vector<T> rv;
|
||||
vector<T> x_xml_values_decode(const char *data, size_t length) {
|
||||
istringstream r(string(data,length));
|
||||
vector<T> rv;
|
||||
T t;
|
||||
while (!r.eof()) {
|
||||
r >> t ;
|
||||
|
@ -664,11 +672,11 @@ std::vector<T> x_xml_values_decode(const char *data, size_t length) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::string x_xml_cdata_encode(const T *tbin, size_t n_elements) {
|
||||
string x_xml_cdata_encode(const T *tbin, size_t n_elements) {
|
||||
size_t length=n_elements*sizeof(T);
|
||||
const unsigned char *input=(const unsigned char *)(tbin);
|
||||
unsigned int i;
|
||||
std::string rv("<![CDATA[");
|
||||
string rv("<![CDATA[");
|
||||
rv.reserve(length);
|
||||
for (i=0; i<length; i++) {
|
||||
if (input[i]>0x1f) {
|
||||
|
@ -694,14 +702,14 @@ std::string x_xml_cdata_encode(const T *tbin, size_t n_elements) {
|
|||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_xml_cdata_decode(const char *input, size_t length) {
|
||||
vector<T> x_xml_cdata_decode(const char *input, size_t length) {
|
||||
unsigned int i;
|
||||
char c;
|
||||
if (!length) {
|
||||
// We're going to decode until we see a null. Including the null.
|
||||
length=strlen(input);
|
||||
}
|
||||
std::vector<unsigned char> rv;
|
||||
vector<unsigned char> rv;
|
||||
char *p;
|
||||
rv.reserve(length);
|
||||
for (i=0; i<length; i++) {
|
||||
|
@ -726,23 +734,23 @@ std::vector<T> x_xml_cdata_decode(const char *input, size_t length) {
|
|||
rv.push_back(input[i]);
|
||||
}
|
||||
}
|
||||
return std::vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
return vector<T>((T *)(&(rv[0])),(T *)(&(rv[0]))+rv.size()/sizeof(T));
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> x_uudecode(const char *data, size_t nbytes) {
|
||||
std::vector<T> rv;
|
||||
vector<T> x_uudecode(const char *data, size_t nbytes) {
|
||||
vector<T> rv;
|
||||
return rv;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::string x_uuencode(const T *data, size_t nbytes) {
|
||||
std::string rv;
|
||||
string x_uuencode(const T *data, size_t nbytes) {
|
||||
string rv;
|
||||
return rv;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> xml_decode_string(const char *input,
|
||||
vector<T> xml_decode_string(const char *input,
|
||||
size_t length=0, const char *encoding="x_xml_entity") {
|
||||
int i=_x_xml_entity;
|
||||
do {
|
||||
|
@ -772,37 +780,37 @@ std::vector<T> xml_decode_string(const char *input,
|
|||
return x_uudecode<T>(input,length);
|
||||
case _8bit:
|
||||
case _binary:
|
||||
return std::vector<T>((const T *)input,(const T *)input+length/sizeof(T));
|
||||
return vector<T>((const T *)input,(const T *)input+length/sizeof(T));
|
||||
default:
|
||||
return x_xml_entity_decode<T>(input,length);
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::vector<T> xml_decode_field(const std::string &input, const char *tag) {
|
||||
std::string start_tag("<"),end_tag("</");
|
||||
vector<T> xml_decode_field(const string &input, const char *tag) {
|
||||
string start_tag("<"),end_tag("</");
|
||||
start_tag+=tag;
|
||||
start_tag+=' ';
|
||||
end_tag+=tag;
|
||||
std::string::size_type start,endt,enc,len;
|
||||
if (((start=input.find(start_tag))==std::string::npos) ||
|
||||
((endt=input.find(end_tag,start))==std::string::npos) ||
|
||||
((enc=input.find("encoding=\"",start))==std::string::npos))
|
||||
string::size_type start,endt,enc,len;
|
||||
if (((start=input.find(start_tag))==string::npos) ||
|
||||
((endt=input.find(end_tag,start))==string::npos) ||
|
||||
((enc=input.find("encoding=\"",start))==string::npos))
|
||||
throw ERR_XML_PARSE;
|
||||
unsigned int length=0;
|
||||
if ((len=input.find("length=",start)!=std::string::npos))
|
||||
if ((len=input.find("length=",start)!=string::npos))
|
||||
length=atoi(&(input[len+strlen("length=")]));
|
||||
const char *encoding=input.c_str()+enc+strlen("encoding=\"");
|
||||
start=input.find('>',start)+1;
|
||||
if (!length) {
|
||||
length=endt-start;
|
||||
length=(unsigned int)endt - (unsigned int)start;
|
||||
}
|
||||
return (xml_decode_string<T>(&(input[start]),length,encoding));
|
||||
}
|
||||
|
||||
|
||||
template <typename T>
|
||||
std::string xml_encode_string(const T *input,
|
||||
string xml_encode_string(const T *input,
|
||||
size_t length=0, xml_encoding encoding=_x_xml_entity) {
|
||||
switch (encoding) {
|
||||
case _x_xml_entity:
|
||||
|
@ -827,19 +835,22 @@ std::string xml_encode_string(const T *input,
|
|||
return x_uuencode<T>(input,length);
|
||||
case _8bit:
|
||||
case _binary:
|
||||
return std::string((const char *)(input),length*sizeof(T));
|
||||
return string((const char *)(input),length*sizeof(T));
|
||||
default:
|
||||
return x_xml_entity_encode<T>(input,length);
|
||||
}
|
||||
}
|
||||
|
||||
extern bool xml_match_tag(const char*, const char*);
|
||||
extern bool xml_match_tag(const std::string &, const char*);
|
||||
extern bool extract_xml_record(const std::string &field, const char *tag, std::string &record);
|
||||
extern bool xml_match_tag(const string &, const char*);
|
||||
extern bool extract_xml_record(const string &field, const char *tag, string &record);
|
||||
|
||||
#endif
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.20 2004/03/06 09:45:25 rwalton
|
||||
// *** empty log message ***
|
||||
//
|
||||
// Revision 1.19 2004/02/05 05:32:22 quarl
|
||||
// *** empty log message ***
|
||||
//
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
ProjectType="Visual C++"
|
||||
Version="7.10"
|
||||
Name="boinc_cli"
|
||||
RootNamespace="boinc_cli"
|
||||
SccProjectName=""
|
||||
SccLocalPath="">
|
||||
<Platforms>
|
||||
|
@ -21,11 +22,12 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_CONSOLE"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../api/win/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_MT;_WINDOWS;_CONSOLE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="0"
|
||||
RuntimeLibrary="1"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Debug\boinc_cli\obj/boinc_cli.pch"
|
||||
AssemblerListingLocation=".\Build\Debug\boinc_cli\obj/"
|
||||
ObjectFile=".\Build\Debug\boinc_cli\obj/"
|
||||
|
@ -39,11 +41,12 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="wsock32.lib wininet.lib winmm.lib nafxcwd.lib libcmtd.lib"
|
||||
AdditionalDependencies="libcmtd.lib libcpmtd.lib kernel32.lib user32.lib advapi32.lib wsock32.lib wininet.lib winmm.lib oldnames.lib"
|
||||
OutputFile=".\Build\Debug/boinc_cli.exe"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreDefaultLibraryNames="libc,nafxcwd,libcmtd,libcmt,libcd"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Debug/boinc_cli.pdb"
|
||||
SubSystem="1"
|
||||
|
@ -82,19 +85,20 @@
|
|||
OutputDirectory=".\Build\Release"
|
||||
IntermediateDirectory=".\Build\Release\boinc_cli\obj"
|
||||
ConfigurationType="1"
|
||||
UseOfMFC="2"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="FALSE"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_CONSOLE"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../api/win/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_MT;_WINDOWS;_CONSOLE"
|
||||
StringPooling="TRUE"
|
||||
RuntimeLibrary="2"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="TRUE"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Release\boinc_cli\obj/boinc_cli.pch"
|
||||
AssemblerListingLocation=".\Build\Release\boinc_cli\obj/"
|
||||
ObjectFile=".\Build\Release\boinc_cli\obj/"
|
||||
|
@ -107,11 +111,13 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="Advapi32.lib wsock32.lib wininet.lib winmm.lib"
|
||||
AdditionalDependencies="kernel32.lib user32.lib advapi32.lib wsock32.lib wininet.lib winmm.lib libcmt.lib libcpmt.lib oldnames.lib"
|
||||
ShowProgress="0"
|
||||
OutputFile=".\Build\Release/boinc_cli.exe"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreDefaultLibraryNames="libc"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Release/boinc_cli.pdb"
|
||||
SubSystem="1"
|
||||
|
@ -987,7 +993,7 @@
|
|||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\win\Stackwalker.cpp">
|
||||
RelativePath="..\api\win\Stackwalker.cpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\stdafx.cpp">
|
||||
|
@ -1172,6 +1178,9 @@
|
|||
<File
|
||||
RelativePath="..\client\win\Stackwalker.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\api\win\Stackwalker.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\stdafx.h">
|
||||
</File>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="..\client\StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Debug\boinc_dll\obj/boinc_dll.pch"
|
||||
AssemblerListingLocation=".\Build\Debug\boinc_dll\obj/"
|
||||
ObjectFile=".\Build\Debug\boinc_dll\obj/"
|
||||
|
@ -37,9 +38,11 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="kernel32.lib user32.lib LIBCMTD.LIB"
|
||||
OutputFile="Build\Debug/boinc.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
ModuleDefinitionFile="..\client\win\win_idle_tracker.def"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Debug/boinc_dll.pdb"
|
||||
|
@ -92,6 +95,7 @@
|
|||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="TRUE"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="..\client\StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Release\boinc_dll\obj/boinc_dll.pch"
|
||||
AssemblerListingLocation=".\Build\Release\boinc_dll\obj/"
|
||||
ObjectFile=".\Build\Release\boinc_dll\obj/"
|
||||
|
@ -103,9 +107,11 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="kernel32.lib user32.lib LIBCMT.LIB"
|
||||
OutputFile="Build\Release/boinc.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
ModuleDefinitionFile="..\client\win\win_idle_tracker.def"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Release/boinc_dll.pdb"
|
||||
|
|
|
@ -24,12 +24,13 @@
|
|||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../api/win/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_MT;_WINDOWS"
|
||||
StringPooling="TRUE"
|
||||
RuntimeLibrary="2"
|
||||
EnableFunctionLevelLinking="TRUE"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Release\boinc_gui\obj/boinc_gui.pch"
|
||||
AssemblerListingLocation=".\Build\Release\boinc_gui\obj/"
|
||||
ObjectFile=".\Build\Release\boinc_gui\obj/"
|
||||
|
@ -91,11 +92,12 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_MT"
|
||||
AdditionalIncludeDirectories="../lib/,../api/,../api/win/,../RSAEuro/source/,../client/win/,../client"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_MT;_WINDOWS"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Debug\boinc_gui\obj/boinc_gui.pch"
|
||||
AssemblerListingLocation=".\Build\Debug\boinc_gui\obj/"
|
||||
ObjectFile=".\Build\Debug\boinc_gui\obj/"
|
||||
|
@ -109,12 +111,14 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="wsock32.lib wininet.lib winmm.lib nafxcwd.lib libcmtd.lib"
|
||||
AdditionalDependencies="nafxcwd.lib atlsd.lib libcmtd.lib libcpmtd.lib kernel32.lib user32.lib gdi32.lib advapi32.lib wsock32.lib wininet.lib winmm.lib comdlg32.lib comctl32.lib shell32.lib shlwapi.lib ole32.lib oleaut32.lib oleacc.lib winspool.lib oldnames.lib uuid.lib"
|
||||
OutputFile=".\Build\Debug/boinc_gui.exe"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
AdditionalLibraryDirectories="..\boinc_dll\Debug"
|
||||
IgnoreDefaultLibraryNames="libc,libcd,nafxcwd,libcmtd"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
DelayLoadDLLs="oleacc.dll"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Debug/boinc_gui.pdb"
|
||||
GenerateMapFile="TRUE"
|
||||
|
@ -992,27 +996,7 @@
|
|||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\win\Stackwalker.cpp">
|
||||
<FileConfiguration
|
||||
Name="Release|Win32">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
CompileAs="2"/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""
|
||||
PreprocessorDefinitions=""
|
||||
BasicRuntimeChecks="3"
|
||||
BrowseInformation="1"
|
||||
CompileAs="2"/>
|
||||
</FileConfiguration>
|
||||
RelativePath="..\api\win\Stackwalker.cpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\stdafx.cpp">
|
||||
|
@ -1359,7 +1343,7 @@
|
|||
RelativePath="..\client\ss_logic.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\win\Stackwalker.h">
|
||||
RelativePath="..\api\win\Stackwalker.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\client\stdafx.h">
|
||||
|
|
|
@ -21,11 +21,12 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../api/;../client/"
|
||||
AdditionalIncludeDirectories="../api/;../api/win/;../client/"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_CONSOLE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Debug\boinc_ss\obj/boinc_ss.pch"
|
||||
AssemblerListingLocation=".\Build\Debug\boinc_ss\obj/"
|
||||
ObjectFile=".\Build\Debug\boinc_ss\obj/"
|
||||
|
@ -39,10 +40,11 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="winmm.lib"
|
||||
AdditionalDependencies="LIBCMTD.LIB winmm.lib kernel32.lib user32.lib gdi32.lib advapi32.lib"
|
||||
OutputFile="Build\Debug\boinc.scr"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Debug/boinc_scr.pdb"
|
||||
|
@ -91,12 +93,13 @@
|
|||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
AdditionalIncludeDirectories="../api/;../client;"
|
||||
AdditionalIncludeDirectories="../api/;../api/win/;../client;"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_CONSOLE"
|
||||
StringPooling="TRUE"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="TRUE"
|
||||
UsePrecompiledHeader="2"
|
||||
PrecompiledHeaderThrough="../client/StdAfx.h"
|
||||
PrecompiledHeaderFile=".\Build\Release\boinc_ss\obj/boinc_ss.pch"
|
||||
AssemblerListingLocation=".\Build\Release\boinc_ss\obj/"
|
||||
ObjectFile=".\Build\Release\boinc_ss\obj/"
|
||||
|
@ -109,11 +112,12 @@
|
|||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="winmm.lib"
|
||||
AdditionalDependencies="LIBCMT.LIB winmm.lib kernel32.lib user32.lib gdi32.lib advapi32.lib"
|
||||
ShowProgress="0"
|
||||
OutputFile="Build\Release/boinc.scr"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="TRUE"
|
||||
IgnoreAllDefaultLibraries="TRUE"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile=".\Build\Release/boinc_scr.pdb"
|
||||
SubSystem="2"
|
||||
|
|
Loading…
Reference in New Issue