Skip to content

Commit 6cbe0bd

Browse files
committed
Imported 1.3.1.
0 parents  commit 6cbe0bd

63 files changed

Lines changed: 14043 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README-Windows.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
The official build of BNCSutil for Windows is produced using Visual Studio 2005 using the solution file in the vc8_build folder. The vc7_build
2+
is no longer officially used or supported.
3+
4+
BNCSutil requires GMP. A modified GMP suitable for

configure

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
#!/usr/bin/env python
2+
# encoding: utf-8
3+
"""
4+
configure.py
5+
6+
Created by Eric Naeseth on 2006-08-24.
7+
Copyright (c) 2006 ionws.com. All rights reserved.
8+
"""
9+
10+
import sys
11+
import getopt
12+
import os.path
13+
14+
15+
help_message = '''
16+
-h --help This help information
17+
-v --version Print BNCSutil version
18+
-p --prefix=PREFIX Install prefix
19+
-e --endian=ORDER Manually specify byte order
20+
-w --windows Force build for Windows
21+
-d --enable-debug Compile in debugging symbols
22+
--enable-debug-output Enable output of debugging information
23+
--with-gmp=PATH Path to GMP library
24+
--with-libtool=TOOL Specify libtool to use
25+
--enable-shared Build shared library (default: yes)
26+
--disable-shared
27+
--enable-static Build static library (default: yes)
28+
--disable-static
29+
'''
30+
31+
32+
class Usage(Exception):
33+
def __init__(self, msg):
34+
self.msg = msg
35+
36+
source = (
37+
('bsha1.cpp', None)
38+
('cdkeydecoder.cpp', None)
39+
('checkrevision.cpp', None)
40+
('debug.c', None)
41+
('decodekey.cpp', None)
42+
('file.c', None)
43+
('hashtable.c', None)
44+
('libinfo.cpp', None)
45+
('nls.c', None)
46+
('oldauth.cpp', None)
47+
('pe.c', None)
48+
('sha1.c', None)
49+
('stack.c', None)
50+
)
51+
52+
common_headers = (
53+
'bncsutil.h', 'mutil.h', 'mutil_types.h'
54+
)
55+
56+
class Makefile(object):
57+
58+
def __init__(self, source_files, common_headers):
59+
self.source_files = source_files
60+
self.common_headers = common_headers
61+
self.f = None
62+
self.path = os.path.abspath(os.path.dirname(sys.argv[0]))
63+
self.decls = {
64+
'prefix': '/usr/local',
65+
'cbase': os.path.join(self.path, 'src'),
66+
'src': os.path.join(self.path, 'src', 'bncsutil'),
67+
'tests': os.path.join(self.path, 'tests'),
68+
'cc': 'gcc',
69+
'cxx': 'g++',
70+
'cflags': '-O2 -I$(CBASE)',
71+
'ldflags':
72+
}
73+
74+
def _decls(self):
75+
76+
77+
def generate(self):
78+
self.f = open('Makefile', 'w')
79+
80+
81+
82+
def main(argv=None):
83+
if argv is None:
84+
argv = sys.argv
85+
try:
86+
try:
87+
opts, args = getopt.getopt(argv[1:], "hvp:e:wd",
88+
["help", "version", "prefix=", "endian=", "windows",
89+
"enable-debug", "enable-debug-output", "with-gmp=",
90+
"with-libtool=", "enable-shared", "disable-shared",
91+
"enable-static", "disable-static"])
92+
except getopt.error, msg:
93+
raise Usage(msg)
94+
95+
# option processing
96+
for option, value in opts:
97+
if option == "-v":
98+
verbose = True
99+
if option in ("-h", "--help"):
100+
raise Usage(help_message)
101+
if option in ("-o", "--output"):
102+
output = value
103+
104+
except Usage, err:
105+
print >> sys.stderr, sys.argv[0].split("/")[-1] + ": " + str(err.msg)
106+
print >> sys.stderr, "\t for help use --help"
107+
return 2
108+
109+
110+
if __name__ == "__main__":
111+
sys.exit(main())

product_version

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1.3.1

source_dist.sh

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/bin/sh
2+
3+
SCRIPT_PATH=`dirname $0`;
4+
5+
PKGDIR=bncsutil-`cat $SCRIPT_PATH/product_version`
6+
rm -fr $PKGDIR
7+
mkdir $PKGDIR
8+
9+
for b in config configure doc product_version src support tests vb6_example \
10+
vc7_build vc8_build windows_dist.bat source_dist.sh windows_dist.sh \
11+
README-Windows.txt
12+
do
13+
cp -R $SCRIPT_PATH/$b $PKGDIR
14+
done
15+
16+
rm -f $PKGDIR.tar.bz2
17+
rm -f $PKGDIR.tar.gz
18+
19+
tar --exclude=.svn -cjvf $PKGDIR.tar.bz2 $PKGDIR
20+
tar --exclude=.svn -czvf $PKGDIR.tar.gz $PKGDIR
21+
22+
rm -fr $PKGDIR
23+
24+
scp $PKGDIR.tar.bz2 $PKGDIR.tar.gz "ionws.com:/home/ericn/public_html/code/bncsutil/static/releases"

src/bncsutil/bncsutil.h

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
/**
2+
* BNCSutil
3+
* Battle.Net Utility Library
4+
*
5+
* Copyright (C) 2004-2006 Eric Naeseth
6+
*
7+
* Common Interface
8+
* November 20, 2004
9+
*
10+
* This library is free software; you can redistribute it and/or
11+
* modify it under the terms of the GNU Lesser General Public
12+
* License as published by the Free Software Foundation; either
13+
* version 2.1 of the License, or (at your option) any later version.
14+
*
15+
* This library is distributed in the hope that it will be useful,
16+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
17+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18+
* Lesser General Public License for more details.
19+
*
20+
* A copy of the GNU Lesser General Public License is included in the BNCSutil
21+
* distribution in the file COPYING. If you did not receive this copy,
22+
* write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
23+
* Boston, MA 02111-1307 USA
24+
*/
25+
26+
#ifndef BNCSUTIL_BNCSUTIL_H_INCLUDED
27+
#define BNCSUTIL_BNCSUTIL_H_INCLUDED
28+
29+
#include <bncsutil/mutil.h> /* Myriad Utility Header */
30+
#include <bncsutil/checkrevision.h> /* CheckRevision / EXE info */
31+
#include <bncsutil/bsha1.h> /* Broken SHA-1 */
32+
#include <bncsutil/oldauth.h> /* Old Logon System */
33+
#include <bncsutil/decodekey.h> /* CD-Key Decoding C wrappers */
34+
#ifdef __cplusplus
35+
#include <bncsutil/cdkeydecoder.h> /* CD-Key Decoding Class */
36+
#endif /* __cplusplus */
37+
#include <bncsutil/nls.h> /* New Logon System */
38+
#include <bncsutil/libinfo.h> /* BNCSutil Library Information */
39+
40+
#endif /* BNCSUTIL_BNCSUTIL_H_INCLUDED */

0 commit comments

Comments
 (0)