Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2004-04-16 19:55:16 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2004-04-16 19:55:16 +0400
commit39a8c014c4572f7f5f9ca099482929b67fe4273e (patch)
tree84224067db57aaa5717930d2c5703f7ab70f14f8 /source/blender/writestreamglue
parent2cc124cf3b1281488c726b71090c1d2640e8078d (diff)
This commit removes the glue from Blender, and with it
the directories decrypt, deflate, encrypt, inflate, readstreamglue, sign, writeblenfile and writestreamglue. Sirdude was so kind to modify the makefiles, so SCons and Make are ready to build with the new Blender. Visual Studio workspaces, solutions and projectfiles still need to be updated (I'll do the .vcprojs and .sln myself after this commit). Runtimes created with the Blender Publisher are not anymore recognised - if you want these available, you'll have to convert them first to .blends with the Publisher.
Diffstat (limited to 'source/blender/writestreamglue')
-rw-r--r--source/blender/writestreamglue/BLO_getPubKey.h37
-rw-r--r--source/blender/writestreamglue/BLO_writeStreamErrors.h86
-rw-r--r--source/blender/writestreamglue/BLO_writeStreamGlue.h91
-rw-r--r--source/blender/writestreamglue/Makefile38
-rw-r--r--source/blender/writestreamglue/SConscript20
-rw-r--r--source/blender/writestreamglue/intern/BLO_dumpFromMemory.c85
-rw-r--r--source/blender/writestreamglue/intern/BLO_dumpFromMemory.h39
-rw-r--r--source/blender/writestreamglue/intern/BLO_getPubKey.c77
-rw-r--r--source/blender/writestreamglue/intern/BLO_streamGlueControl.c94
-rw-r--r--source/blender/writestreamglue/intern/BLO_writeStreamGlue.c158
-rw-r--r--source/blender/writestreamglue/intern/Makefile64
-rw-r--r--source/blender/writestreamglue/stub/BLO_getPubKeySTUB.c54
-rw-r--r--source/blender/writestreamglue/stub/BLO_keyStoreSTUB.c62
-rw-r--r--source/blender/writestreamglue/stub/BLO_streamGlueControlSTUB.c89
-rw-r--r--source/blender/writestreamglue/stub/BLO_writeStreamGlueSTUB.c65
-rw-r--r--source/blender/writestreamglue/stub/Makefile55
-rw-r--r--source/blender/writestreamglue/test/Makefile37
-rw-r--r--source/blender/writestreamglue/test/readwritetest/Makefile76
-rw-r--r--source/blender/writestreamglue/test/readwritetest/readwritetest.c192
-rw-r--r--source/blender/writestreamglue/test/typetest/Makefile48
-rw-r--r--source/blender/writestreamglue/test/typetest/typetest.c98
21 files changed, 0 insertions, 1565 deletions
diff --git a/source/blender/writestreamglue/BLO_getPubKey.h b/source/blender/writestreamglue/BLO_getPubKey.h
deleted file mode 100644
index 838da0c142d..00000000000
--- a/source/blender/writestreamglue/BLO_getPubKey.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * PUBLISHER: get the public key from the .BPkeyfile
- * STUB: give back the dataStreamPubKey
- */
-
-int getPubKey(unsigned char *dataStreamPubKey, int dataStreamPubKeyLen,
- unsigned char **publisherPubKey, int *publisherPubKeyLen);
-
diff --git a/source/blender/writestreamglue/BLO_writeStreamErrors.h b/source/blender/writestreamglue/BLO_writeStreamErrors.h
deleted file mode 100644
index cc86660b8d0..00000000000
--- a/source/blender/writestreamglue/BLO_writeStreamErrors.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * all Blender Write Stream errors
- * NOTE: adding stuff here means you also have to update the error
- * messages in writefile.c
- */
-
-#ifndef BLO_WRITESTREAMERRORS_H
-#define BLO_WRITESTREAMERRORS_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define BWS_SETFUNCTION(x) ( (int)(x) << 1)
-#define BWS_GETFUNCTION(x) (( (int)(x) >> 1) & 7)
-#define BWS_SETGENERR(x) ( (int)(x) << 4)
-#define BWS_GETGENERR(x) (( (int)(x) >> 4) & 7)
-#define BWS_SETSPECERR(x) ( (int)(x) << 7)
-#define BWS_GETSPECERR(x) (( (int)(x) >> 7) & 7)
-
-// FUNCTION
-#define BWS_WRITESTREAMGLUE 1
-#define BWS_DEFLATE 2
-#define BWS_ENCRYPT 3
-#define BWS_SIGN 4
-#define BWS_WRITEBLENFILE 5
-
-// GENeric errors
-#define BWS_MALLOC 1
-#define BWS_STUB 2
-#define BWS_RSA 3
-
-// WRITESTREAMGLUE specific
-#define BWS_UNKNOWN 1
-
-// DEFLATE specific
-#define BWS_DEFLATEERROR 1
-
-// ENCRYPT specific
-#define BWS_RSANEWERROR 1
-#define BWS_ENCRYPTERROR 2
-
-// SIGN specific
-#define BWS_RSANEWERROR 1
-#define BWS_SIGNERROR 2
-
-// WRITEBLENFILE specific
-#define BWS_FILEDES 1
-#define BWS_WRITE 2
-#define BWS_PARAM 3
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* BLO_WRITESTREAMERRORS_H */
-
diff --git a/source/blender/writestreamglue/BLO_writeStreamGlue.h b/source/blender/writestreamglue/BLO_writeStreamGlue.h
deleted file mode 100644
index 85101d8c79b..00000000000
--- a/source/blender/writestreamglue/BLO_writeStreamGlue.h
+++ /dev/null
@@ -1,91 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * struct/function that connects the data stream processors
- */
-
-#ifndef BLO_WRITESTREAMGLUE_H
-#define BLO_WRITESTREAMGLUE_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "BLO_readStreamGlue.h"
-#include "BLO_writeStreamErrors.h"
-
-/******************** start BLO_streamGlueControl.c part *****************/
-struct streamGlueControlStruct {
- int actions;
- int actionsDone;
- unsigned char action[MAXSTREAMLENGTH];
-};
-
- struct streamGlueControlStruct *
-streamGlueControlConstructor(
- void);
-
- void
-streamGlueControlDestructor(
- struct streamGlueControlStruct *streamControl);
-
- int
-streamGlueControlAppendAction(
- struct streamGlueControlStruct *streamControl,
- unsigned char nextAction);
-
- unsigned char
-streamGlueControlGetNextAction(
- struct streamGlueControlStruct *streamControl);
-
-// TODO avoid this global variable
-extern struct streamGlueControlStruct *Global_streamGlueControl;
-/******************** end BLO_streamGlueControl.c part *****************/
-
-struct writeStreamGlueStruct {
- int dataProcessorType;
- unsigned int streamBufferCount;
- unsigned char *streamBuffer;
-};
-
- int
-writeStreamGlue(
- struct streamGlueControlStruct *streamGlueControl,
- struct writeStreamGlueStruct **streamGlue,
- unsigned char *data,
- unsigned int dataIn,
- int finishUp);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* BLO_WRITESTREAMGLUE_H */
-
diff --git a/source/blender/writestreamglue/Makefile b/source/blender/writestreamglue/Makefile
deleted file mode 100644
index 22f3adb345e..00000000000
--- a/source/blender/writestreamglue/Makefile
+++ /dev/null
@@ -1,38 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-# Bounces make to subdirectories.
-
-SOURCEDIR = source/blender/writestreamglue
-DIRS = intern stub
-TESTDIRS = test
-
-include nan_subdirs.mk
diff --git a/source/blender/writestreamglue/SConscript b/source/blender/writestreamglue/SConscript
deleted file mode 100644
index 1a41ecee12c..00000000000
--- a/source/blender/writestreamglue/SConscript
+++ /dev/null
@@ -1,20 +0,0 @@
-Import ('extra_includes')
-Import ('user_options_dict')
-Import ('library_env')
-
-wrstrgl_env = library_env.Copy ()
-
-source_files = ['intern/BLO_dumpFromMemory.c',
- 'intern/BLO_getPubKey.c',
- 'intern/BLO_streamGlueControl.c',
- 'intern/BLO_writeStreamGlue.c']
-
-wrstrgl_env.Append (CPPPATH = ['.',
- '../readstreamglue',
- '../deflate',
- '../writeblenfile',
- '../../kernel/gen_messaging'])
-wrstrgl_env.Append (CPPPATH = user_options_dict['Z_INCLUDE'])
-
-wrstrgl_env.Append (CPPPATH = extra_includes)
-wrstrgl_env.Library (target='#'+user_options_dict['BUILD_DIR']+'/lib/blender_writestreamglue', source=source_files)
diff --git a/source/blender/writestreamglue/intern/BLO_dumpFromMemory.c b/source/blender/writestreamglue/intern/BLO_dumpFromMemory.c
deleted file mode 100644
index 52f8ac2e789..00000000000
--- a/source/blender/writestreamglue/intern/BLO_dumpFromMemory.c
+++ /dev/null
@@ -1,85 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * streamglue loopback adds a streamGlueHeader to start of the write stream
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "GEN_messaging.h"
-#include "zlib.h"
-#include "BLO_writeStreamGlue.h"
-#include "BLO_dumpFromMemory.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- int
-BLO_dumpFromMemory(
- unsigned char *data,
- unsigned int dataIn,
- struct streamGlueHeaderStruct *streamGlueHeader)
-{
- struct writeStreamGlueStruct *streamGlue = NULL;
- int err = 0;
-
-#ifndef NDEBUG
- fprintf(GEN_errorstream,
- "BLO_dumpFromMemory: %u streamGlueHeader + %u data = %u\n",
- STREAMGLUEHEADERSIZE,
- dataIn,
- STREAMGLUEHEADERSIZE + dataIn);
-#endif
-
- // all data is in. set size in streamGlueHeader and write it out
- streamGlueHeader->totalStreamLength = htonl(dataIn);
- streamGlueHeader->crc = htonl(crc32(0L, (const Bytef *) streamGlueHeader,
- STREAMGLUEHEADERSIZE - 4));
- err = writeStreamGlue(
- Global_streamGlueControl,
- &streamGlue,
- (unsigned char *)streamGlueHeader,
- STREAMGLUEHEADERSIZE,
- 0);
- if (err) return err;
-
- // write out data
- err = writeStreamGlue(
- Global_streamGlueControl,
- &streamGlue,
- data,
- dataIn,
- 1);
-
- return err;
-}
-
diff --git a/source/blender/writestreamglue/intern/BLO_dumpFromMemory.h b/source/blender/writestreamglue/intern/BLO_dumpFromMemory.h
deleted file mode 100644
index cb418f67f01..00000000000
--- a/source/blender/writestreamglue/intern/BLO_dumpFromMemory.h
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * streamglue loopback adds a streamGlueHeader to start of the write stream
- */
-
- int
-BLO_dumpFromMemory(
- unsigned char *data,
- unsigned int dataIn,
- struct streamGlueHeaderStruct *streamGlueHeader);
-
diff --git a/source/blender/writestreamglue/intern/BLO_getPubKey.c b/source/blender/writestreamglue/intern/BLO_getPubKey.c
deleted file mode 100644
index 99193417591..00000000000
--- a/source/blender/writestreamglue/intern/BLO_getPubKey.c
+++ /dev/null
@@ -1,77 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * Publisher only: get the public key from the .BPkeyfile
- */
-
-#include <stdlib.h>
-#include <string.h>
-
-#include "BLO_keyStore.h"
-#include "BLO_getPubKey.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- int
-getPubKey(byte *dataStreamPubKey,
- int dataStreamPubKeyLen,
- byte **publisherPubKey,
- int *publisherPubKeyLen)
-{
- int err = 0;
-
- *publisherPubKeyLen = keyStoreGetPubKey(publisherPubKey);
-
- if (*publisherPubKeyLen == 0) {
- // we're a publisher without .BPkey
- *publisherPubKey = NULL;
- return 1;
- }
-
- if (dataStreamPubKeyLen != *publisherPubKeyLen) {
- // different keys
- *publisherPubKeyLen = 0;
- *publisherPubKey = NULL;
- return 2;
- }
-
- if (memcmp(dataStreamPubKey, *publisherPubKey, *publisherPubKeyLen)
- != 0) {
- // different keys
- *publisherPubKeyLen = 0;
- *publisherPubKey = NULL;
- return 3;
- }
-
- return err;
-}
-
diff --git a/source/blender/writestreamglue/intern/BLO_streamGlueControl.c b/source/blender/writestreamglue/intern/BLO_streamGlueControl.c
deleted file mode 100644
index 2d4d408d848..00000000000
--- a/source/blender/writestreamglue/intern/BLO_streamGlueControl.c
+++ /dev/null
@@ -1,94 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * define what actions a write stream should do
- */
-
-#include <string.h>
-#include <stdlib.h>
-#include <assert.h>
-
-#include "BLO_writeStreamGlue.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- struct streamGlueControlStruct *
-streamGlueControlConstructor(
- void)
-{
- struct streamGlueControlStruct *control;
- control = malloc(sizeof(struct streamGlueControlStruct));
- assert(control);
- // TODO handle malloc errors
- control->actions = 0;
- control->actionsDone = 0;
- memset(control->action, 0, MAXSTREAMLENGTH);
- return(control);
-}
-
- void
-streamGlueControlDestructor(
- struct streamGlueControlStruct *streamControl)
-{
- free(streamControl);
-}
-
- int
-streamGlueControlAppendAction(
- struct streamGlueControlStruct *streamControl,
- unsigned char nextAction)
-{
- assert(streamControl);
- assert(streamControl->actions < MAXSTREAMLENGTH);
- streamControl->action[streamControl->actions] = nextAction;
- streamControl->actions++;
- return(streamControl->actions);
-}
-
- unsigned char
-streamGlueControlGetNextAction(
- struct streamGlueControlStruct *streamControl)
-{
- unsigned char nextAction;
- assert(streamControl);
- assert(streamControl->actionsDone < streamControl->actions);
- if (streamControl->actionsDone >= streamControl->actions) {
- // the stream should have been terminated by a data
- // processor, but instead streamGlue is called again ...
- nextAction = UNKNOWN; // best guess ...
- } else {
- nextAction = streamControl->action[streamControl->actionsDone];
- streamControl->actionsDone++;
- }
- return(nextAction);
-}
-
diff --git a/source/blender/writestreamglue/intern/BLO_writeStreamGlue.c b/source/blender/writestreamglue/intern/BLO_writeStreamGlue.c
deleted file mode 100644
index 2da560b4278..00000000000
--- a/source/blender/writestreamglue/intern/BLO_writeStreamGlue.c
+++ /dev/null
@@ -1,158 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * connect the data stream processors
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <assert.h>
-
-#include "zlib.h"
-#include "GEN_messaging.h"
-#include "BLO_writeStreamGlue.h"
-#include "BLO_dumpFromMemory.h"
-#include "BLO_writeblenfile.h"
-#include "BLO_deflate.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-/**
- * streamGlueWrite does not really stream; it buffers all data it gets
- * because it needs everything to create the header, which is in front
- * of the data (to make reading easier, which occurs much more often
- * than writing and is thus more important to optimize for).
- * @param streamControl contains a list of Glue actions. Every
- * streamGlueWrite constructor eats up the next first action.
- */
- int
-writeStreamGlue(
- struct streamGlueControlStruct *streamGlueControl,
- struct writeStreamGlueStruct **streamGlue,
- unsigned char *data,
- unsigned int dataIn,
- int finishUp)
-{
- int err = 0;
-
- if (NULL == *streamGlue) {
- /* we are called for the first time; play constructor */
- (*streamGlue) = malloc(sizeof(struct writeStreamGlueStruct));
-
- if (!(*streamGlue)) {
- err = BWS_SETFUNCTION(BWS_WRITESTREAMGLUE) |
- BWS_SETGENERR(BWS_MALLOC);
- return err;
- }
-
- (*streamGlue)->dataProcessorType =
- streamGlueControlGetNextAction(streamGlueControl);
- (*streamGlue)->streamBufferCount = 0;
- (*streamGlue)->streamBuffer = NULL;
- }
- if (dataIn > 0) {
- /* simply buffer it */
- (*streamGlue)->streamBuffer = realloc((*streamGlue)->streamBuffer,
- dataIn + (*streamGlue)->streamBufferCount);
- if (!(*streamGlue)->streamBuffer) {
- err = BWS_SETFUNCTION(BWS_WRITESTREAMGLUE) |
- BWS_SETGENERR(BWS_MALLOC);
- free(*streamGlue);
- return err;
- }
- memcpy((*streamGlue)->streamBuffer + (*streamGlue)->streamBufferCount,
- data, dataIn);
- (*streamGlue)->streamBufferCount += dataIn;
- }
- if (finishUp) {
- /* all data is in, create header and call data processor */
-
- /* first create the streamGlueHeaderStruct */
- struct streamGlueHeaderStruct *streamGlueHeader;
- streamGlueHeader = malloc(STREAMGLUEHEADERSIZE);
- if (!streamGlueHeader) {
- err = BWS_SETFUNCTION(BWS_WRITESTREAMGLUE) |
- BWS_SETGENERR(BWS_MALLOC);
- free((*streamGlue)->streamBuffer);
- free(*streamGlue);
- return err;
- }
- streamGlueHeader->magic = 'A';
- streamGlueHeader->totalStreamLength = 0; // set in the actions _end
- streamGlueHeader->dataProcessorType =
- htonl((*streamGlue)->dataProcessorType);
- streamGlueHeader->crc = 0; // set in in the actions _end
-
-#ifndef NDEBUG
- fprintf(GEN_errorstream,
- "streamGlue: write %d gets %u data + %u streamGlueHeader = %u\n",
- (*streamGlue)->dataProcessorType,
- (*streamGlue)->streamBufferCount,
- STREAMGLUEHEADERSIZE,
- (*streamGlue)->streamBufferCount + STREAMGLUEHEADERSIZE);
-#endif
-
- /* all data ready, start the right data processor */
- switch ((*streamGlue)->dataProcessorType) {
- case DUMPFROMMEMORY:
- err = BLO_dumpFromMemory((*streamGlue)->streamBuffer,
- (*streamGlue)->streamBufferCount,
- streamGlueHeader);
- break;
- case DEFLATE:
- err = BLO_deflate((*streamGlue)->streamBuffer,
- (*streamGlue)->streamBufferCount,
- streamGlueHeader);
- break;
- case WRITEBLENFILE:
- err = BLO_writeblenfile((*streamGlue)->streamBuffer,
- (*streamGlue)->streamBufferCount,
- streamGlueHeader);
- break;
- default:
-#ifndef NDEBUG
- fprintf(GEN_errorstream,
- "unknown dataProcessorType %d\n",
- (*streamGlue)->dataProcessorType);
-#endif
- err = BWS_SETFUNCTION(BWS_WRITESTREAMGLUE) |
- BWS_SETSPECERR(BWS_UNKNOWN);
- break;
- }
-
- free(streamGlueHeader);
- free((*streamGlue)->streamBuffer);
- free(*streamGlue);
- }
- return err;
-}
-
diff --git a/source/blender/writestreamglue/intern/Makefile b/source/blender/writestreamglue/intern/Makefile
deleted file mode 100644
index 7388b338ca9..00000000000
--- a/source/blender/writestreamglue/intern/Makefile
+++ /dev/null
@@ -1,64 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-#
-
-LIBNAME = writestreamglue
-DIR = $(OCGDIR)/blender/$(LIBNAME)
-
-include nan_compile.mk
-
-ifeq ($(OS),$(findstring $(OS), "beos darwin freebsd linux openbsd solaris windows"))
- CFLAGS += -funsigned-char
-endif
-
-CFLAGS += $(LEVEL_2_C_WARNINGS)
-
-# path to our own private header files
-CPPFLAGS += -I.
-
-# path to our own external header files
-CPPFLAGS += -I..
-
-# path to external modules
-CPPFLAGS += -I../../../kernel/gen_messaging
-
-CPPFLAGS += -I../../readstreamglue
-
-CPPFLAGS += -I../../writeblenfile
-CPPFLAGS += -I../../blenloader
-
-CPPFLAGS += -I../../deflate
-
-ifeq ($(OS),$(findstring $(OS), "solaris windows"))
- CPPFLAGS += -I$(NAN_ZLIB)/include
-endif
-
diff --git a/source/blender/writestreamglue/stub/BLO_getPubKeySTUB.c b/source/blender/writestreamglue/stub/BLO_getPubKeySTUB.c
deleted file mode 100644
index 9a6e7e1bb21..00000000000
--- a/source/blender/writestreamglue/stub/BLO_getPubKeySTUB.c
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * player/plugin only: 'get' the public key from the datastream
- * note really a STUB eh ...
- */
-
-#include "BLO_getPubKey.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- int
-getPubKey(unsigned char *dataStreamPubKey,
- int dataStreamPubKeyLen,
- unsigned char **publisherPubKey,
- int *publisherPubKeyLen)
-{
- int err = 0;
-
- *publisherPubKeyLen = dataStreamPubKeyLen;
- *publisherPubKey = dataStreamPubKey;
-
- return err;
-}
-
diff --git a/source/blender/writestreamglue/stub/BLO_keyStoreSTUB.c b/source/blender/writestreamglue/stub/BLO_keyStoreSTUB.c
deleted file mode 100644
index a3a9fa14c9e..00000000000
--- a/source/blender/writestreamglue/stub/BLO_keyStoreSTUB.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * keyStore stubs
- */
-
-#include <stdio.h>
-
-#include "BLO_keyStore.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- void
-keyStoreConstructor(
- struct UserStruct *keyUserStruct,
- char *privHexKey,
- char *pubHexKey,
- unsigned char *ByteChecks,
- char *HexPython)
-{
- keyUserStruct = NULL;
- privHexKey = NULL;
- pubHexKey = NULL;
- ByteChecks = NULL;
- HexPython = NULL;
-}
-
- void
-keyStoreDestructor(
- void)
-{
-}
-
diff --git a/source/blender/writestreamglue/stub/BLO_streamGlueControlSTUB.c b/source/blender/writestreamglue/stub/BLO_streamGlueControlSTUB.c
deleted file mode 100644
index 8f4165c8c64..00000000000
--- a/source/blender/writestreamglue/stub/BLO_streamGlueControlSTUB.c
+++ /dev/null
@@ -1,89 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- *
- */
-
-#include <stdio.h>
-#include "GEN_messaging.h"
-#include "BLO_writeStreamGlue.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- struct streamGlueControlStruct *
-streamGlueControlConstructor(
- void)
-{
-#ifdef NDEBUG
- fprintf(GEN_errorstream,
- "Error streamGlueControlConstructor is a stub\n");
-#endif
- return(NULL);
-}
-
- void
-streamGlueControlDestructor(
- struct streamGlueControlStruct *streamControl)
-{
- streamControl = NULL;
-#ifdef NDEBUG
- fprintf(GEN_errorstream,
- "Error streamGlueControlDestructor is a stub\n");
-#endif
-}
-
- int
-streamGlueControlAppendAction(
- struct streamGlueControlStruct *streamControl,
- unsigned char nextAction)
-{
- streamControl = NULL;
- nextAction = 0;
-#ifdef NDEBUG
- fprintf(GEN_errorstream,
- "Error streamGlueControlAppendAction is a stub\n");
-#endif
- return(0);
-}
-
- unsigned char
-streamGlueControlGetNextAction(
- struct streamGlueControlStruct *streamControl)
-{
- streamControl = NULL;
-#ifdef NDEBUG
- fprintf(GEN_errorstream,
- "Error streamGlueControlGetNextAction is a stub\n");
-#endif
- return(0);
-}
-
diff --git a/source/blender/writestreamglue/stub/BLO_writeStreamGlueSTUB.c b/source/blender/writestreamglue/stub/BLO_writeStreamGlueSTUB.c
deleted file mode 100644
index 07a7c48e6b6..00000000000
--- a/source/blender/writestreamglue/stub/BLO_writeStreamGlueSTUB.c
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * streamGlueRead stubs
- */
-
-#include <stdio.h>
-
-#include "GEN_messaging.h"
-#include "BLO_writeStreamGlue.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
- int
-writeStreamGlue(
- struct streamGlueControlStruct *streamGlueControl,
- struct writeStreamGlueStruct **streamGlue,
- unsigned char *data,
- unsigned int dataIn,
- int finishUp)
-{
- int err = 0;
- streamGlueControl = NULL;
- *streamGlue = NULL;
- data = NULL;
- dataIn = 0;
- finishUp = 0;
-#ifndef NDEBUG
- fprintf(GEN_errorstream,
- "Error writeStreamGlue is a stub\n");
-#endif
- err = BWS_SETFUNCTION(BWS_WRITESTREAMGLUE) |
- BWS_SETGENERR(BWS_STUB);
- return err;
-}
-
diff --git a/source/blender/writestreamglue/stub/Makefile b/source/blender/writestreamglue/stub/Makefile
deleted file mode 100644
index 8711941a06c..00000000000
--- a/source/blender/writestreamglue/stub/Makefile
+++ /dev/null
@@ -1,55 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-#
-
-LIBNAME = writestreamglueSTUB
-DIR = $(OCGDIR)/blender/$(LIBNAME)
-
-include nan_compile.mk
-
-ifeq ($(OS),$(findstring $(OS), "beos darwin freebsd linux openbsd solaris windows"))
- CFLAGS += -funsigned-char
-endif
-
-CFLAGS += $(LEVEL_2_C_WARNINGS)
-
-# path to our own external headerfiles
-CPPFLAGS += -I..
-
-#
-CPPFLAGS += -I../../../kernel/gen_messaging
-CPPFLAGS += -I../../readstreamglue
-
-ifeq ($(OS),$(findstring $(OS), "solaris windows"))
- CPPFLAGS += -I$(NAN_ZLIB)/include
-endif
-
diff --git a/source/blender/writestreamglue/test/Makefile b/source/blender/writestreamglue/test/Makefile
deleted file mode 100644
index ee2708e55ff..00000000000
--- a/source/blender/writestreamglue/test/Makefile
+++ /dev/null
@@ -1,37 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-# Bounces make to subdirectories.
-
-SOURCEDIR = source/blender/writestreamglue/test
-DIRS = typetest #readwritetest
-
-include nan_subdirs.mk
diff --git a/source/blender/writestreamglue/test/readwritetest/Makefile b/source/blender/writestreamglue/test/readwritetest/Makefile
deleted file mode 100644
index bedb9f42a99..00000000000
--- a/source/blender/writestreamglue/test/readwritetest/Makefile
+++ /dev/null
@@ -1,76 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-# Streamglue read/write testing
-#
-
-DIR = $(OCGDIR)/blender/writestreamglue/readwritetest
-ALLTARGETS = $(OBJS) $(DIR)/$(DEBUG_DIR)readwritetest
-
-include nan_compile.mk
-
-CFLAGS += -funsigned-char -g
-
-# includes:
-CPPFLAGS += -I../..
-CPPFLAGS += -I../../../readstreamglue
-
-# libs:
-TESTLIBS += $(OCGDIR)/blender/readstreamglue/$(DEBUG_DIR)libreadstreamglue.a
-TESTLIBS += $(OCGDIR)/blender/writestreamglue/$(DEBUG_DIR)libwritestreamglue.a
-TESTLIBS += $(OCGDIR)/blender/inflate/$(DEBUG_DIR)libinflate.a
-TESTLIBS += $(OCGDIR)/blender/deflate/$(DEBUG_DIR)libdeflate.a
-TESTLIBS += $(OCGDIR)/blender/writeblenfile/$(DEBUG_DIR)libwriteblenfile.a
-TESTLIBS += $(OCGDIR)/blender/writestreamglue/$(DEBUG_DIR)libwritestreamglue.a
-TESTLIBS += $(OCGDIR)/blender/readstreamglue/$(DEBUG_DIR)libreadstreamglue.a
-TESTLIBS += $(OCGDIR)/blender/readblenfile/$(DEBUG_DIR)libreadblenfile.a
-
-ifeq ($(OS),$(findstring $(OS), "linux freebsd"))
- TESTLIBS += -lz
-endif
-
-ifeq ($(OS),windows)
- TESTLIBS += ws2_32.lib
- TESTLIBS += $(NAN_ZLIB)/lib/libz.a
- TESTLIBS += kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
- TESTLIBS += advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
- TESTLIBS += winmm.lib opengl32.lib glu32.lib largeint.lib dxguid.lib
-endif
-
-
-$(DIR)/readwritetest: $(OBJS)
- $(CC) $(LDFLAGS) -o $(DIR)/readwritetest $(OBJS) $(TESTLIBS)
-
-clean::
- $(RM) $(DIR)/readwritetest
-
-test:: all
- $(DIR)/readwritetest $(NAN_TEST_VERBOSITY)
diff --git a/source/blender/writestreamglue/test/readwritetest/readwritetest.c b/source/blender/writestreamglue/test/readwritetest/readwritetest.c
deleted file mode 100644
index d0a8ddef50e..00000000000
--- a/source/blender/writestreamglue/test/readwritetest/readwritetest.c
+++ /dev/null
@@ -1,192 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- */
-
-/* Test for the streamglue read/write components
- *
- * The streamglue functions connect dataprocessors.
- *
- * Tested functions
- *
- * - streamGlueWrite (from BLO_streamglue.h)
- * - streamGlueRead (from BLO_streamglue.h)
- *
- */
-
-#include <stdio.h>
-#include <string.h>
-#include <stdlib.h>
-#include <fcntl.h>
-
-#include "BLO_writeStreamGlue.h"
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#ifndef _WIN32
-#define O_BINARY 0
-#endif
-
-struct streamGlueControlStruct *Global_streamGlueControl;
-
-/* Some stubs here, because otherwise we have to link all of blender... */
-
-//FILE* mywfile = NULL;
-int mywfile = 0;
-
- void *
-BLO_readstreamfile_begin(
- void)
-{
- fprintf(stderr, "|--> BLO_readstreamfile_begin: local loopback\n");
- return NULL;
-}
-
- int
-BLO_readstreamfile_process(
- void *filedataVoidPtr,
- unsigned char *data,
- unsigned int dataIn)
-{
- fprintf(stderr, "|--> BLO_readstreamfile_process: local loopback\n");
- return 0;
-}
-
-
- int
-BLO_readstreamfile_end(
- void *filedataVoidPtr)
-{
- fprintf(stderr, "|--> BLO_readstreamfile_end: local loopback\n");
- return 0;
-}
-
-int main (int argc, char *argv[])
-{
- int verbose = 0;
- int error_status = 0;
- int retval = 0;
- int i = 0;
-
- int datachunksize = 12345;
- char* datachunk = NULL;
- char* dataptr = NULL;
- struct writeStreamGlueStruct *sgp = NULL;
-
- switch (argc) {
- case 2:
- verbose = atoi(argv[1]);
- if (verbose < 0) verbose = 0;
- break;
- case 1:
- default:
- verbose = 0;
- }
-
- /* ----------------------------------------------------------------- */
-
- if (verbose > 0) {
- fprintf(stderr,"\n*** Streamglue read/write test\n");
- }
-
- Global_streamGlueControl = streamGlueControlConstructor();
-
-// mywfile = fopen("readwritetestdump","wb");
- mywfile = open("readwritetestdump",O_BINARY+O_WRONLY+O_CREAT+O_TRUNC, 0666);
-
- error_status = (mywfile == NULL);
-// error_status |= fprintf(mywfile,"|\n|-- Opened file for testing: %d\n|\n", mywfile);
-
-
- if (verbose > 1) {
- fprintf(stderr,"|\n|-- Opened file for testing: %d with \n|\n", mywfile);
- }
-
-/* streamGlueControlAppendAction(Global_streamGlueControl, DUMPFROMMEMORY); */
-/* streamGlueControlAppendAction(Global_streamGlueControl, DEFLATE); */
-/* streamGlueControlAppendAction(Global_streamGlueControl, ENCRYPT); */
-/* streamGlueControlAppendAction(Global_streamGlueControl, SIGN); */
- streamGlueControlAppendAction(Global_streamGlueControl, WRITEBLENFILE);
-
- if (verbose >1) {
- fprintf(stderr,"|\n|-- Created and initialized streamGlueControl thingy \n");
- fflush(stderr);
- }
-
- /* 2: the size */
- datachunksize = 12345;
-
- /* 1: a data chunk. We fill it with some numbers */
- datachunk = (char*) malloc(datachunksize);
-
- /* an ascending-ish thingy */
- dataptr = datachunk;
- for (i = 0 ;
- i < datachunksize;
- i++, dataptr++) {
- *dataptr = (i % 0xFF);
- }
-
- if (verbose >1) {
- fprintf(stderr,"|\n|-- Calling streamGlueWrite\n");
- fflush(stderr);
- }
-
- retval =
- writeStreamGlue(
- Global_streamGlueControl, // general controller
- &sgp, // ie. construct this for me
- datachunk, // raw data
- datachunksize, // data size
- 1); // i.e. finalize this write
-
- if (verbose >1) {
- fprintf(stderr,"|\n|-- streamGlueWrite returned with %d\n", retval);
- }
-
- /* ----------------------------------------------------------------- */
-
- if (close(mywfile)) {
- error_status = 1;
- if (verbose > 1) {
- fprintf(stderr,"|\n|-- file close failed.\n");
- }
- }
-
- if (verbose > 0) {
- fprintf(stderr,"|\n*** Finished test\n\n");
- }
- exit(error_status);
-}
-
-
-/* eof */
diff --git a/source/blender/writestreamglue/test/typetest/Makefile b/source/blender/writestreamglue/test/typetest/Makefile
deleted file mode 100644
index 617e358bcce..00000000000
--- a/source/blender/writestreamglue/test/typetest/Makefile
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# $Id$
-#
-# ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
-#
-# This program 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
-# of the License, or (at your option) any later version. The Blender
-# Foundation also sells licenses for use in proprietary software under
-# the Blender License. See http://www.blender.org/BL/ for information
-# about this.
-#
-# This program 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, write to the Free Software Foundation,
-# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-#
-# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): none yet.
-#
-# ***** END GPL/BL DUAL LICENSE BLOCK *****
-#
-# Make a little test for the sys_types replacement.
-#
-
-DIR = $(OCGDIR)/blender/writestreamglue/test
-ALLTARGETS = $(OBJS) $(DIR)/typetest
-
-include nan_compile.mk
-
-$(DIR)/typetest: $(OBJS)
- $(CC) $(LDFLAGS) -o $(DIR)/typetest $(OBJS)
-
-clean::
- $(RM) $(DIR)/typetest
-
-test:: $(DIR)/typetest
- $(DIR)/typetest $(NAN_TEST_VERBOSITY)
-
diff --git a/source/blender/writestreamglue/test/typetest/typetest.c b/source/blender/writestreamglue/test/typetest/typetest.c
deleted file mode 100644
index 3bab75340c8..00000000000
--- a/source/blender/writestreamglue/test/typetest/typetest.c
+++ /dev/null
@@ -1,98 +0,0 @@
-/**
- * $Id$
- *
- * ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
- *
- * This program 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
- * of the License, or (at your option) any later version. The Blender
- * Foundation also sells licenses for use in proprietary software under
- * the Blender License. See http://www.blender.org/BL/ for information
- * about this.
- *
- * This program 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, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL/BL DUAL LICENSE BLOCK *****
- * A little test to see how our type defines behave.
- */
-
-#include "../../../readstreamglue/BLO_sys_types.h"
-#include <stdio.h>
-#include <stdlib.h>
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-int main (int argc, char *argv[])
-{
- int verbose = 0;
- int error_status = 0;
- int char_size = 0;
- int short_size = 0;
- int int_size = 0;
- int long_size = 0;
-
- switch (argc) {
- case 2:
- verbose = atoi(argv[1]);
- if (verbose < 0) verbose = 0;
- break;
- case 1:
- default:
- verbose = 0;
- }
-
- /* ----------------------------------------------------------------- */
- if (verbose > 0) {
- printf("*** Type define size test\n|\n");
- }
- /* Check if these exist, and show their sizes. */
-
-
- char_size = sizeof(uint8_t);
- short_size = sizeof(uint16_t);
- int_size = sizeof(uint32_t);
- long_size = sizeof(uint64_t);
-
- if (verbose > 1) {
- printf("|- uint8_t : \t%4d, expected 1.\n", char_size);
- printf("|- uint16_t : \t%4d, expected 2.\n", short_size);
- printf("|- uint32_t : \t%4d, expected 4.\n", int_size);
- printf("|- uint64_t : \t%4d, expected 8.\n\n", long_size);
- }
-
- if ((char_size != 1)
- || (short_size != 2)
- || (int_size != 4)
- || (long_size != 8)
- ) {
- error_status = 1;
- }
-
- if (verbose > 0) {
- if (error_status) {
- printf("|-- Size mismatch detected !!!\n|\n");
- } else {
- printf("|-- Sizes are correct.\n");
- }
- printf("|\n*** End of type define size test\n");
- }
-
- exit(error_status);
-}