Browse Source

initialise pystub correctly

rdb 13 years ago
parent
commit
1f20cfe19c

+ 4 - 0
panda/src/downloadertools/apply_patch.cxx

@@ -13,6 +13,7 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandabase.h"
+#include "pystub.h"
 #include "panda_getopt.h"
 #include "preprocess_argv.h"
 #include "patchfile.h"
@@ -20,6 +21,9 @@
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   preprocess_argv(argc, argv);
 
   if (argc < 3) {

+ 4 - 0
panda/src/downloadertools/build_patch.cxx

@@ -13,6 +13,7 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandabase.h"
+#include "pystub.h"
 #include "panda_getopt.h"
 #include "preprocess_argv.h"
 #include "patchfile.h"
@@ -53,6 +54,9 @@ help() {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   Filename patch_file;
   bool complete_file = false;
   int footprint_length = 0;

+ 4 - 0
panda/src/downloadertools/check_adler.cxx

@@ -13,9 +13,13 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "download_utils.h"
+#include "pystub.h"
 
 int
 main(int argc, char *argv[]) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   if (argc < 2) {
     cerr << "Usage: check_adler <file>" << endl;
     return 1;

+ 4 - 0
panda/src/downloadertools/check_crc.cxx

@@ -13,9 +13,13 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "download_utils.h"
+#include "pystub.h"
 
 int
 main(int argc, char *argv[]) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   if (argc < 2) {
     cerr << "Usage: check_crc <file>" << endl;
     return 1;

+ 4 - 0
panda/src/downloadertools/check_md5.cxx

@@ -13,6 +13,7 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandabase.h"
+#include "pystub.h"
 #include "hashVal.h"
 #include "filename.h"
 #include "panda_getopt.h"
@@ -67,6 +68,9 @@ output_hash(const string &filename, const HashVal &hash) {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   extern char *optarg;
   extern int optind;
   const char *optstr = "i:db:qh";

+ 4 - 0
panda/src/downloadertools/multify.cxx

@@ -13,6 +13,7 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandabase.h"
+#include "pystub.h"
 #include "panda_getopt.h"
 #include "preprocess_argv.h"
 #include "multifile.h"
@@ -749,6 +750,9 @@ tokenize_extensions(const string &str, pset<string> &extensions) {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   preprocess_argv(argc, argv);
   if (argc < 2) {
     usage();

+ 4 - 0
panda/src/downloadertools/pdecrypt.cxx

@@ -12,6 +12,7 @@
 //
 ////////////////////////////////////////////////////////////////////
 
+#include "pystub.h"
 #include "filename.h"
 #include "encrypt_string.h"
 #include "pnotify.h"
@@ -46,6 +47,9 @@ usage() {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   extern char *optarg;
   extern int optind;
   const char *optstr = "o:p:h";

+ 1 - 0
panda/src/downloadertools/pencrypt.cxx

@@ -12,6 +12,7 @@
 //
 ////////////////////////////////////////////////////////////////////
 
+#include "pystub.h"
 #include "filename.h"
 #include "encrypt_string.h"
 #include "pnotify.h"

+ 4 - 0
panda/src/downloadertools/punzip.cxx

@@ -12,6 +12,7 @@
 //
 ////////////////////////////////////////////////////////////////////
 
+#include "pystub.h"
 #include "filename.h"
 #include "compress_string.h"
 #include "pnotify.h"
@@ -33,6 +34,9 @@ usage() {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   extern char *optarg;
   extern int optind;
   const char *optstr = "o:ch";

+ 4 - 0
panda/src/downloadertools/pzip.cxx

@@ -12,6 +12,7 @@
 //
 ////////////////////////////////////////////////////////////////////
 
+#include "pystub.h"
 #include "filename.h"
 #include "compress_string.h"
 #include "pnotify.h"
@@ -57,6 +58,9 @@ usage() {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   extern char *optarg;
   extern int optind;
   const char *optstr = "o:c123456789h";

+ 4 - 0
panda/src/downloadertools/show_ddb.cxx

@@ -13,11 +13,15 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandabase.h"
+#include "pystub.h"
 #include "downloadDb.h"
 #include "filename.h"
 
 int
 main(int argc, char *argv[]) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   if (argc != 3) {
     cerr << "Usage: show_ddb server.ddb client.ddb\n";
     return 1;

+ 4 - 0
panda/src/testbed/pgrid.cxx

@@ -13,6 +13,7 @@
 ////////////////////////////////////////////////////////////////////
 
 #include "pandaFramework.h"
+#include "pystub.h"
 #include "pandaNode.h"
 #include "transformState.h"
 #include "clockObject.h"
@@ -384,6 +385,9 @@ load_gridded_models(WindowFramework *window,
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   preprocess_argv(argc, argv);
   PandaFramework framework;
   framework.open_framework(argc, argv);

+ 4 - 0
panda/src/testbed/pview.cxx

@@ -14,6 +14,7 @@
 
 #include "pandaFramework.h"
 #include "pandaSystem.h"
+#include "pystub.h"
 #include "textNode.h"
 #include "configVariableBool.h"
 #include "texturePool.h"
@@ -225,6 +226,9 @@ report_version() {
 
 int
 main(int argc, char **argv) {
+  // A call to pystub() to force libpystub.so to be linked in.
+  pystub();
+
   preprocess_argv(argc, argv);
   framework.open_framework(argc, argv);
   framework.set_window_title("Panda Viewer");