~ubuntu-branches/ubuntu/maverick/eucalyptus/maverick

« back to all changes in this revision

Viewing changes to clc/modules/bootstrap/eucalyptus-opts.c

  • Committer: Bazaar Package Importer
  • Author(s): Dave Walker (Daviey)
  • Date: 2010-07-21 17:27:10 UTC
  • mfrom: (1.1.38 upstream)
  • Revision ID: james.westby@ubuntu.com-20100721172710-7xv07dmdqgivc3t9
Tags: 2.0~bzr1211-0ubuntu1
* New major upstream version merge, 2.0 (r1211).
* debian/patches/:
  - 01-wsdl-stubs.patch, debian/wsdl.md5sums: wsdl stubs updated.
  - 02-Makefile.patch: Updated to reflect new code layout.
  - 07-local_support_euca_conf-in.patch: Updated to reflect new code layout.
  - 08-ubuntu-default-networking.patch: Refreshed.
  - 09-small-128-192MB.patch: Updated to point to new location.
  - 10-disable-iscsi.patch: Refreshed.
  - 11-state-cleanup-memleakfix.patch: Removed, fixed upstream.
  - 15-fix-default-ramdisk.patch: Updated to point to new location.
  - 16-kvm_libvirt_xml_default_use_kvm.patch: Updated to reflect changes.
  - 17-fix_walrus_OOM_errors.patch: Removed, fixed upstream.
  - 18-priv_security.patch: Updated to reflect upstream changes.
  - 20-brute-force-webui.patch: Updated to reflect upstream changes. 
  - 21-eucalyptus-1.7-with-gwt-1.6.4.patch: New patch, allows 
    eucalyptus-1.7 to be built against gwt 1.6.4. Based on patch courtesy 
    of Dmitrii Zagorodnov, upstream. (LP: #597330)
* debian/eucalyptus-java-common.links: 
  - Changed symlink for groovy, point to groovy.all.jar, making compatiable 
    with groovy versions >1.7. (LP: #595421)
  - Added ant.jar & jetty-rewrite-handler.jar as they are now required.
* debian/control
  - & debian/build-jars: Added libjavassist-java and libjetty-extra-java as 
    build dependencies.
  - Added libjetty-extra-java as a dependency of eucalyptus-java-common
* The binary resulting jar's have been renamed from eucalyptus-*-1.6.2.jar
  to eucalyptus-*-main.jar:    
  - debian/eucalyptus-cc.upstart
  - debian/eucalyptus-cloud.install
  - debian/eucalyptus-common.eucalyptus.upstart
  - debian/eucalyptus-java-common.install
  - debian/eucalyptus-network.upstart
  - debian/eucalyptus-sc.install
  - debian/eucalyptus-walrus.install
* debian/eucalyptus-java-common.install: New upstream jars that have been
  installed:
  - eucalyptus-db-hsqldb-ext-main.jar
  - eucalyptus-component-main.jar
* debian/control:
  - Updated Standards Version to 3.8.4 (no change)
  - Updated the upstream Homepage to: http://open.eucalyptus.com/
  - Changed Vcs-Bzr to reflect new location of Ubuntu hosted development branch.
  - Made the Build Dependency of groovy and the binary eucalyptus-java-common
    package depend on version >=1.7.

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
  "      --exhaustive-db           Individually enable exhaustive connection \n                                  information for database connections.  \n                                  (default=off)",
48
48
  "      --exhaustive-user         Individually enable exhaustive connection \n                                  information for client connections.  \n                                  (default=off)",
49
49
  "      --exhaustive-cc           Individually enable exhaustive connection \n                                  information for client connections.  \n                                  (default=off)",
 
50
  "      --exhaustive-external     Individually enable exhaustive logging for \n                                  external libraries.  (default=off)",
50
51
  "  -L, --log-appender=log4j-appender-name\n                                Control the destination for console output.  \n                                  (default=`console-log')",
51
52
  "  -o, --out=filename            Redirect standard out to file.  (default=`&1')",
52
53
  "  -e, --err=filename            Redirect standard error to file.  \n                                  (default=`&2')",
74
75
  "      --debug-port=INT          Set the port to use for the debugger.  \n                                  (default=`5005')",
75
76
  "      --debug-suspend           Set the port to use for the debugger.  \n                                  (default=off)",
76
77
  "  -p, --profile                 Launch with jprofiler enabled.  (default=off)",
77
 
  "  -P, --profiler-home=jprofiler directory\n                                Set the home for jprofiler.  \n                                  (default=`/opt/jprofiler5')",
 
78
  "  -a, --agentlib=agentlib       Launch with agentlib enabled.",
 
79
  "  -P, --profiler-home=jprofiler directory\n                                Set the home for jprofiler.  \n                                  (default=`/opt/jprofiler6')",
78
80
    0
79
81
};
80
82
 
122
124
  eucalyptus_opts_help[38] = eucalyptus_opts_full_help[38];
123
125
  eucalyptus_opts_help[39] = eucalyptus_opts_full_help[39];
124
126
  eucalyptus_opts_help[40] = eucalyptus_opts_full_help[40];
125
 
  eucalyptus_opts_help[41] = 0; 
 
127
  eucalyptus_opts_help[41] = eucalyptus_opts_full_help[41];
 
128
  eucalyptus_opts_help[42] = 0; 
126
129
  
127
130
}
128
131
 
129
 
const char *eucalyptus_opts_help[42];
 
132
const char *eucalyptus_opts_help[43];
130
133
 
131
134
typedef enum {ARG_NO
132
135
  , ARG_FLAG
166
169
  args_info->exhaustive_db_given = 0 ;
167
170
  args_info->exhaustive_user_given = 0 ;
168
171
  args_info->exhaustive_cc_given = 0 ;
 
172
  args_info->exhaustive_external_given = 0 ;
169
173
  args_info->log_appender_given = 0 ;
170
174
  args_info->out_given = 0 ;
171
175
  args_info->err_given = 0 ;
189
193
  args_info->debug_port_given = 0 ;
190
194
  args_info->debug_suspend_given = 0 ;
191
195
  args_info->profile_given = 0 ;
 
196
  args_info->agentlib_given = 0 ;
192
197
  args_info->profiler_home_given = 0 ;
193
198
}
194
199
 
213
218
  args_info->exhaustive_db_flag = 0;
214
219
  args_info->exhaustive_user_flag = 0;
215
220
  args_info->exhaustive_cc_flag = 0;
 
221
  args_info->exhaustive_external_flag = 0;
216
222
  args_info->log_appender_arg = gengetopt_strdup ("console-log");
217
223
  args_info->log_appender_orig = NULL;
218
224
  args_info->out_arg = gengetopt_strdup ("&1");
244
250
  args_info->debug_port_orig = NULL;
245
251
  args_info->debug_suspend_flag = 0;
246
252
  args_info->profile_flag = 0;
247
 
  args_info->profiler_home_arg = gengetopt_strdup ("/opt/jprofiler5");
 
253
  args_info->agentlib_arg = NULL;
 
254
  args_info->agentlib_orig = NULL;
 
255
  args_info->profiler_home_arg = gengetopt_strdup ("/opt/jprofiler6");
248
256
  args_info->profiler_home_orig = NULL;
249
257
  
250
258
}
270
278
  args_info->exhaustive_db_help = eucalyptus_opts_full_help[12] ;
271
279
  args_info->exhaustive_user_help = eucalyptus_opts_full_help[13] ;
272
280
  args_info->exhaustive_cc_help = eucalyptus_opts_full_help[14] ;
273
 
  args_info->log_appender_help = eucalyptus_opts_full_help[15] ;
274
 
  args_info->out_help = eucalyptus_opts_full_help[16] ;
275
 
  args_info->err_help = eucalyptus_opts_full_help[17] ;
276
 
  args_info->remote_cloud_help = eucalyptus_opts_full_help[19] ;
277
 
  args_info->remote_walrus_help = eucalyptus_opts_full_help[20] ;
278
 
  args_info->remote_dns_help = eucalyptus_opts_full_help[21] ;
279
 
  args_info->remote_storage_help = eucalyptus_opts_full_help[22] ;
280
 
  args_info->disable_cloud_help = eucalyptus_opts_full_help[24] ;
281
 
  args_info->disable_walrus_help = eucalyptus_opts_full_help[25] ;
282
 
  args_info->disable_dns_help = eucalyptus_opts_full_help[26] ;
283
 
  args_info->disable_storage_help = eucalyptus_opts_full_help[27] ;
284
 
  args_info->disable_iscsi_help = eucalyptus_opts_full_help[28] ;
285
 
  args_info->check_help = eucalyptus_opts_full_help[30] ;
286
 
  args_info->stop_help = eucalyptus_opts_full_help[31] ;
287
 
  args_info->fork_help = eucalyptus_opts_full_help[32] ;
288
 
  args_info->pidfile_help = eucalyptus_opts_full_help[33] ;
289
 
  args_info->java_home_help = eucalyptus_opts_full_help[35] ;
290
 
  args_info->jvm_name_help = eucalyptus_opts_full_help[36] ;
291
 
  args_info->jvm_args_help = eucalyptus_opts_full_help[37] ;
 
281
  args_info->exhaustive_external_help = eucalyptus_opts_full_help[15] ;
 
282
  args_info->log_appender_help = eucalyptus_opts_full_help[16] ;
 
283
  args_info->out_help = eucalyptus_opts_full_help[17] ;
 
284
  args_info->err_help = eucalyptus_opts_full_help[18] ;
 
285
  args_info->remote_cloud_help = eucalyptus_opts_full_help[20] ;
 
286
  args_info->remote_walrus_help = eucalyptus_opts_full_help[21] ;
 
287
  args_info->remote_dns_help = eucalyptus_opts_full_help[22] ;
 
288
  args_info->remote_storage_help = eucalyptus_opts_full_help[23] ;
 
289
  args_info->disable_cloud_help = eucalyptus_opts_full_help[25] ;
 
290
  args_info->disable_walrus_help = eucalyptus_opts_full_help[26] ;
 
291
  args_info->disable_dns_help = eucalyptus_opts_full_help[27] ;
 
292
  args_info->disable_storage_help = eucalyptus_opts_full_help[28] ;
 
293
  args_info->disable_iscsi_help = eucalyptus_opts_full_help[29] ;
 
294
  args_info->check_help = eucalyptus_opts_full_help[31] ;
 
295
  args_info->stop_help = eucalyptus_opts_full_help[32] ;
 
296
  args_info->fork_help = eucalyptus_opts_full_help[33] ;
 
297
  args_info->pidfile_help = eucalyptus_opts_full_help[34] ;
 
298
  args_info->java_home_help = eucalyptus_opts_full_help[36] ;
 
299
  args_info->jvm_name_help = eucalyptus_opts_full_help[37] ;
 
300
  args_info->jvm_args_help = eucalyptus_opts_full_help[38] ;
292
301
  args_info->jvm_args_min = 0;
293
302
  args_info->jvm_args_max = 0;
294
 
  args_info->debug_help = eucalyptus_opts_full_help[38] ;
295
 
  args_info->debug_port_help = eucalyptus_opts_full_help[39] ;
296
 
  args_info->debug_suspend_help = eucalyptus_opts_full_help[40] ;
297
 
  args_info->profile_help = eucalyptus_opts_full_help[41] ;
298
 
  args_info->profiler_home_help = eucalyptus_opts_full_help[42] ;
 
303
  args_info->debug_help = eucalyptus_opts_full_help[39] ;
 
304
  args_info->debug_port_help = eucalyptus_opts_full_help[40] ;
 
305
  args_info->debug_suspend_help = eucalyptus_opts_full_help[41] ;
 
306
  args_info->profile_help = eucalyptus_opts_full_help[42] ;
 
307
  args_info->agentlib_help = eucalyptus_opts_full_help[43] ;
 
308
  args_info->profiler_home_help = eucalyptus_opts_full_help[44] ;
299
309
  
300
310
}
301
311
 
455
465
  free_string_field (&(args_info->jvm_name_orig));
456
466
  free_multiple_string_field (args_info->jvm_args_given, &(args_info->jvm_args_arg), &(args_info->jvm_args_orig));
457
467
  free_string_field (&(args_info->debug_port_orig));
 
468
  free_string_field (&(args_info->agentlib_arg));
 
469
  free_string_field (&(args_info->agentlib_orig));
458
470
  free_string_field (&(args_info->profiler_home_arg));
459
471
  free_string_field (&(args_info->profiler_home_orig));
460
472
  
522
534
    write_into_file(outfile, "exhaustive-user", 0, 0 );
523
535
  if (args_info->exhaustive_cc_given)
524
536
    write_into_file(outfile, "exhaustive-cc", 0, 0 );
 
537
  if (args_info->exhaustive_external_given)
 
538
    write_into_file(outfile, "exhaustive-external", 0, 0 );
525
539
  if (args_info->log_appender_given)
526
540
    write_into_file(outfile, "log-appender", args_info->log_appender_orig, 0);
527
541
  if (args_info->out_given)
567
581
    write_into_file(outfile, "debug-suspend", 0, 0 );
568
582
  if (args_info->profile_given)
569
583
    write_into_file(outfile, "profile", 0, 0 );
 
584
  if (args_info->agentlib_given)
 
585
    write_into_file(outfile, "agentlib", args_info->agentlib_orig, 0);
570
586
  if (args_info->profiler_home_given)
571
587
    write_into_file(outfile, "profiler-home", args_info->profiler_home_orig, 0);
572
588
  
837
853
      fprintf (stderr, "%s: '--debug-suspend' option depends on option 'debug'%s\n", prog_name, (additional_error ? additional_error : ""));
838
854
      error = 1;
839
855
    }
 
856
  if (args_info->agentlib_given && ! args_info->profile_given)
 
857
    {
 
858
      fprintf (stderr, "%s: '--agentlib' ('-a') option depends on option 'profile'%s\n", prog_name, (additional_error ? additional_error : ""));
 
859
      error = 1;
 
860
    }
840
861
  if (args_info->profiler_home_given && ! args_info->profile_given)
841
862
    {
842
863
      fprintf (stderr, "%s: '--profiler-home' ('-P') option depends on option 'profile'%s\n", prog_name, (additional_error ? additional_error : ""));
1145
1166
        { "exhaustive-db",      0, NULL, 0 },
1146
1167
        { "exhaustive-user",    0, NULL, 0 },
1147
1168
        { "exhaustive-cc",      0, NULL, 0 },
 
1169
        { "exhaustive-external",        0, NULL, 0 },
1148
1170
        { "log-appender",       1, NULL, 'L' },
1149
1171
        { "out",        1, NULL, 'o' },
1150
1172
        { "err",        1, NULL, 'e' },
1168
1190
        { "debug-port", 1, NULL, 0 },
1169
1191
        { "debug-suspend",      0, NULL, 0 },
1170
1192
        { "profile",    0, NULL, 'p' },
 
1193
        { "agentlib",   1, NULL, 'a' },
1171
1194
        { "profiler-home",      1, NULL, 'P' },
1172
1195
        { 0,  0, 0, 0 }
1173
1196
      };
1174
1197
 
1175
 
      c = getopt_long (argc, argv, "Vu:h:c:w:D:vl:xL:o:e:CSfj:J:X:dpP:", long_options, &option_index);
 
1198
      c = getopt_long (argc, argv, "Vu:h:c:w:D:vl:xL:o:e:CSfj:J:X:dpa:P:", long_options, &option_index);
1176
1199
 
1177
1200
      if (c == -1) break;       /* Exit from `while (1)' loop.  */
1178
1201
 
1391
1414
            goto failure;
1392
1415
        
1393
1416
          break;
 
1417
        case 'a':       /* Launch with agentlib enabled..  */
 
1418
        
 
1419
        
 
1420
          if (update_arg( (void *)&(args_info->agentlib_arg), 
 
1421
               &(args_info->agentlib_orig), &(args_info->agentlib_given),
 
1422
              &(local_args_info.agentlib_given), optarg, 0, 0, ARG_STRING,
 
1423
              check_ambiguity, override, 0, 0,
 
1424
              "agentlib", 'a',
 
1425
              additional_error))
 
1426
            goto failure;
 
1427
        
 
1428
          break;
1394
1429
        case 'P':       /* Set the home for jprofiler..  */
1395
1430
        
1396
1431
        
1397
1432
          if (update_arg( (void *)&(args_info->profiler_home_arg), 
1398
1433
               &(args_info->profiler_home_orig), &(args_info->profiler_home_given),
1399
 
              &(local_args_info.profiler_home_given), optarg, 0, "/opt/jprofiler5", ARG_STRING,
 
1434
              &(local_args_info.profiler_home_given), optarg, 0, "/opt/jprofiler6", ARG_STRING,
1400
1435
              check_ambiguity, override, 0, 0,
1401
1436
              "profiler-home", 'P',
1402
1437
              additional_error))
1453
1488
              goto failure;
1454
1489
          
1455
1490
          }
 
1491
          /* Individually enable exhaustive logging for external libraries..  */
 
1492
          else if (strcmp (long_options[option_index].name, "exhaustive-external") == 0)
 
1493
          {
 
1494
          
 
1495
          
 
1496
            if (update_arg((void *)&(args_info->exhaustive_external_flag), 0, &(args_info->exhaustive_external_given),
 
1497
                &(local_args_info.exhaustive_external_given), optarg, 0, 0, ARG_FLAG,
 
1498
                check_ambiguity, override, 1, 0, "exhaustive-external", '-',
 
1499
                additional_error))
 
1500
              goto failure;
 
1501
          
 
1502
          }
1456
1503
          /* Do not try to bootstrap cloud services locally..  */
1457
1504
          else if (strcmp (long_options[option_index].name, "remote-cloud") == 0)
1458
1505
          {