~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to client/drizzle.cc

  • Committer: Monty Taylor
  • Date: 2010-10-02 05:07:25 UTC
  • mto: (1817.1.3 build)
  • mto: This revision was merged to the branch mainline in revision 1818.
  • Revision ID: mordred@inaugust.com-20101002050725-h1b30b0nr3leeoh1
Embed a modified version of parse_config_file. There are several more bugs
that we'll want to fix in it, and then submit upstream. Eventually we should
be able to remove this- but for now the version on lucid is completely
broken.

Show diffs side-by-side

added added

removed removed

Lines of Context:
158
158
#define vidattr(A) {}      // Can't get this to work
159
159
#endif
160
160
#include <boost/program_options.hpp>
 
161
#include "drizzled/program_options/config_file.h"
161
162
 
162
163
using namespace std;
163
164
namespace po=boost::program_options;
 
165
namespace dpo=drizzled::program_options;
164
166
 
165
167
/* Don't try to make a nice table if the data is too big */
166
168
const uint32_t MAX_COLUMN_LENGTH= 1024;
1420
1422
    user_config_dir_client.append("/drizzle/client.cnf");
1421
1423
 
1422
1424
    ifstream user_drizzle_ifs(user_config_dir_drizzle.c_str());
1423
 
    po::store(parse_config_file(user_drizzle_ifs, drizzle_options), vm);
 
1425
    po::store(dpo::parse_config_file(user_drizzle_ifs, drizzle_options), vm);
1424
1426
 
1425
1427
    ifstream user_client_ifs(user_config_dir_client.c_str());
1426
 
    po::store(parse_config_file(user_client_ifs, client_options), vm);
 
1428
    po::store(dpo::parse_config_file(user_client_ifs, client_options), vm);
1427
1429
 
1428
1430
    ifstream system_drizzle_ifs(system_config_dir_drizzle.c_str());
1429
 
    store(parse_config_file(system_drizzle_ifs, drizzle_options), vm);
 
1431
    store(dpo::parse_config_file(system_drizzle_ifs, drizzle_options), vm);
1430
1432
 
1431
1433
    ifstream system_client_ifs(system_config_dir_client.c_str());
1432
 
    po::store(parse_config_file(system_client_ifs, client_options), vm);
 
1434
    po::store(dpo::parse_config_file(system_client_ifs, client_options), vm);
1433
1435
  }
1434
1436
 
1435
1437
  po::notify(vm);