From 7356dc177af4d4c51961d2a3675acbf2a3861b4b Mon Sep 17 00:00:00 2001 From: Tobias Werth Date: Fri, 7 Jun 2024 22:09:44 +0200 Subject: [PATCH] fixes and deletions --- judge/runguard_test/runguard_test.sh | 2 +- lib/libcgroup-3.1.0/.gitignore | 14 - lib/libcgroup-3.1.0/CONTRIBUTING.md | 184 - lib/libcgroup-3.1.0/COPYING | 510 - lib/libcgroup-3.1.0/INSTALL | 237 - lib/libcgroup-3.1.0/Makefile.am | 13 - lib/libcgroup-3.1.0/Makefile.in | 937 - lib/libcgroup-3.1.0/README | 183 - lib/libcgroup-3.1.0/README_daemon | 182 - lib/libcgroup-3.1.0/README_systemd | 69 - lib/libcgroup-3.1.0/aclocal.m4 | 1578 - lib/libcgroup-3.1.0/build-aux/ar-lib | 271 - lib/libcgroup-3.1.0/build-aux/compile | 348 - lib/libcgroup-3.1.0/build-aux/config.guess | 1768 -- lib/libcgroup-3.1.0/build-aux/config.sub | 1890 -- lib/libcgroup-3.1.0/build-aux/depcomp | 791 - lib/libcgroup-3.1.0/build-aux/install-sh | 541 - lib/libcgroup-3.1.0/build-aux/ltmain.sh | 11429 -------- lib/libcgroup-3.1.0/build-aux/missing | 215 - lib/libcgroup-3.1.0/build-aux/test-driver | 153 - lib/libcgroup-3.1.0/build-aux/ylwrap | 247 - lib/libcgroup-3.1.0/config.h.in | 190 - lib/libcgroup-3.1.0/configure | 23756 ---------------- lib/libcgroup-3.1.0/configure.ac | 266 - lib/libcgroup-3.1.0/dist/Makefile.am | 1 - lib/libcgroup-3.1.0/dist/Makefile.in | 477 - lib/libcgroup-3.1.0/dist/libcgroup.spec | 168 - lib/libcgroup-3.1.0/dist/libcgroup.spec.in | 168 - lib/libcgroup-3.1.0/doc/Makefile.am | 3 - lib/libcgroup-3.1.0/doc/Makefile.in | 653 - lib/libcgroup-3.1.0/doc/man/Makefile.am | 7 - lib/libcgroup-3.1.0/doc/man/Makefile.in | 650 - lib/libcgroup-3.1.0/doc/man/cgclassify.1 | 93 - lib/libcgroup-3.1.0/doc/man/cgconfig.conf.5 | 824 - lib/libcgroup-3.1.0/doc/man/cgconfigparser.8 | 92 - lib/libcgroup-3.1.0/doc/man/cgcreate.1 | 113 - lib/libcgroup-3.1.0/doc/man/cgdelete.1 | 51 - lib/libcgroup-3.1.0/doc/man/cgexec.1 | 106 - lib/libcgroup-3.1.0/doc/man/cgget.1 | 115 - lib/libcgroup-3.1.0/doc/man/cgred.conf.5 | 49 - lib/libcgroup-3.1.0/doc/man/cgrules.conf.5 | 165 - lib/libcgroup-3.1.0/doc/man/cgrulesengd.8 | 84 - lib/libcgroup-3.1.0/doc/man/cgset.1 | 57 - lib/libcgroup-3.1.0/doc/man/cgsnapshot.1 | 113 - lib/libcgroup-3.1.0/doc/man/cgxget.1 | 127 - lib/libcgroup-3.1.0/doc/man/cgxset.1 | 81 - lib/libcgroup-3.1.0/doc/man/lscgroup.1 | 49 - lib/libcgroup-3.1.0/doc/man/lssubsys.1 | 101 - .../include/gtest/gtest-death-test.h | 294 - .../googletest/include/gtest/gtest-message.h | 250 - .../include/gtest/gtest-param-test.h | 1444 - .../include/gtest/gtest-param-test.h.pump | 510 - .../googletest/include/gtest/gtest-printers.h | 993 - .../googletest/include/gtest/gtest-spi.h | 232 - .../include/gtest/gtest-test-part.h | 179 - .../include/gtest/gtest-typed-test.h | 263 - .../googletest/include/gtest/gtest.h | 2236 -- .../include/gtest/gtest_pred_impl.h | 358 - .../googletest/include/gtest/gtest_prod.h | 58 - .../gtest/internal/custom/gtest-port.h | 69 - .../gtest/internal/custom/gtest-printers.h | 42 - .../include/gtest/internal/custom/gtest.h | 41 - .../internal/gtest-death-test-internal.h | 319 - .../include/gtest/internal/gtest-filepath.h | 206 - .../include/gtest/internal/gtest-internal.h | 1238 - .../include/gtest/internal/gtest-linked_ptr.h | 243 - .../internal/gtest-param-util-generated.h | 5146 ---- .../gtest-param-util-generated.h.pump | 286 - .../include/gtest/internal/gtest-param-util.h | 731 - .../include/gtest/internal/gtest-port-arch.h | 93 - .../include/gtest/internal/gtest-port.h | 2554 -- .../include/gtest/internal/gtest-string.h | 167 - .../include/gtest/internal/gtest-tuple.h | 1020 - .../include/gtest/internal/gtest-tuple.h.pump | 347 - .../include/gtest/internal/gtest-type-util.h | 3331 --- .../gtest/internal/gtest-type-util.h.pump | 297 - .../googletest/googletest/libgtest.so | Bin 1064536 -> 0 bytes .../googletest/googletest/libgtest_main.so | Bin 16808 -> 0 bytes lib/libcgroup-3.1.0/include/Makefile.am | 9 - lib/libcgroup-3.1.0/include/Makefile.in | 607 - lib/libcgroup-3.1.0/include/libcgroup.h | 43 - .../include/libcgroup/config.h | 138 - lib/libcgroup-3.1.0/include/libcgroup/error.h | 111 - .../include/libcgroup/groups.h | 706 - lib/libcgroup-3.1.0/include/libcgroup/init.h | 86 - .../include/libcgroup/init.h.in | 86 - .../include/libcgroup/iterators.h | 435 - lib/libcgroup-3.1.0/include/libcgroup/log.h | 158 - .../include/libcgroup/systemd.h | 140 - lib/libcgroup-3.1.0/include/libcgroup/tasks.h | 214 - lib/libcgroup-3.1.0/include/libcgroup/tools.h | 61 - lib/libcgroup-3.1.0/libcgroup.doxyfile | 1519 - lib/libcgroup-3.1.0/libcgroup.pc.in | 10 - lib/libcgroup-3.1.0/m4/ax_code_coverage.m4 | 264 - lib/libcgroup-3.1.0/m4/libtool.m4 | 8403 ------ lib/libcgroup-3.1.0/m4/ltoptions.m4 | 437 - lib/libcgroup-3.1.0/m4/ltsugar.m4 | 124 - lib/libcgroup-3.1.0/m4/ltversion.m4 | 24 - lib/libcgroup-3.1.0/m4/lt~obsolete.m4 | 99 - lib/libcgroup-3.1.0/myconfigure | 7 - lib/libcgroup-3.1.0/samples/Makefile.am | 2 - lib/libcgroup-3.1.0/samples/Makefile.in | 653 - lib/libcgroup-3.1.0/samples/c/Makefile.am | 33 - lib/libcgroup-3.1.0/samples/c/Makefile.in | 880 - .../samples/c/create_systemd_scope.c | 613 - .../samples/c/empty_cgroup_v2.c | 40 - .../samples/c/get_all_controller.c | 36 - .../samples/c/get_controller.c | 34 - .../samples/c/get_mount_point.c | 50 - lib/libcgroup-3.1.0/samples/c/get_procs.c | 37 - .../samples/c/get_setup_mode.c | 44 - .../samples/c/get_variable_names.c | 61 - lib/libcgroup-3.1.0/samples/c/logger.c | 47 - lib/libcgroup-3.1.0/samples/c/proctest.c | 48 - lib/libcgroup-3.1.0/samples/c/read_stats.c | 86 - lib/libcgroup-3.1.0/samples/c/setuid.c | 74 - .../samples/c/test_named_hierarchy.c | 50 - lib/libcgroup-3.1.0/samples/c/walk_task.c | 51 - lib/libcgroup-3.1.0/samples/c/walk_test.c | 126 - lib/libcgroup-3.1.0/samples/c/wrapper_test.c | 46 - .../samples/cmdline/Makefile.am | 13 - .../samples/cmdline/Makefile.in | 483 - .../samples/config/Makefile.am | 9 - .../samples/config/Makefile.in | 484 - .../samples/config/cgconfig.conf | 42 - .../samples/config/cgconfig.sysconfig | 12 - lib/libcgroup-3.1.0/samples/config/cgred.conf | 27 - .../samples/config/cgrules.conf | 10 - .../samples/config/cgsnapshot_allowlist.conf | 48 - .../samples/config/cgsnapshot_denylist.conf | 20 - .../config/invalid_namespace_config.conf | 53 - .../invalid_namespace_mount_config.conf | 59 - .../samples/config/namespace_config.conf | 46 - .../samples/python/Makefile.am | 18 - .../samples/python/Makefile.in | 488 - lib/libcgroup-3.1.0/scripts/Makefile.am | 11 - lib/libcgroup-3.1.0/scripts/Makefile.in | 486 - .../scripts/init.d/cgconfig.in | 221 - lib/libcgroup-3.1.0/scripts/init.d/cgred.in | 170 - lib/libcgroup-3.1.0/src/Makefile.am | 62 - lib/libcgroup-3.1.0/src/Makefile.in | 1281 - lib/libcgroup-3.1.0/src/abstraction-common.c | 286 - lib/libcgroup-3.1.0/src/abstraction-common.h | 119 - lib/libcgroup-3.1.0/src/abstraction-cpu.c | 271 - lib/libcgroup-3.1.0/src/abstraction-cpuset.c | 50 - lib/libcgroup-3.1.0/src/abstraction-map.c | 62 - lib/libcgroup-3.1.0/src/abstraction-map.h | 39 - lib/libcgroup-3.1.0/src/api.c | 6538 ----- lib/libcgroup-3.1.0/src/config.c | 2300 -- lib/libcgroup-3.1.0/src/daemon/Makefile.am | 14 - lib/libcgroup-3.1.0/src/daemon/Makefile.in | 732 - lib/libcgroup-3.1.0/src/daemon/cgrulesengd.c | 1290 - lib/libcgroup-3.1.0/src/daemon/cgrulesengd.h | 122 - lib/libcgroup-3.1.0/src/lex.c | 1851 -- lib/libcgroup-3.1.0/src/lex.l | 45 - lib/libcgroup-3.1.0/src/libcgroup-internal.h | 427 - lib/libcgroup-3.1.0/src/libcgroup.map | 164 - .../src/libcgroup_systemd_idle_thread | Bin 26136 -> 0 bytes .../src/libcgroup_systemd_idle_thread.c | 11 - lib/libcgroup-3.1.0/src/log.c | 92 - lib/libcgroup-3.1.0/src/pam/Makefile.am | 10 - lib/libcgroup-3.1.0/src/pam/Makefile.in | 697 - lib/libcgroup-3.1.0/src/pam/pam_cgroup.c | 153 - lib/libcgroup-3.1.0/src/parse.c | 2061 -- lib/libcgroup-3.1.0/src/parse.h | 112 - lib/libcgroup-3.1.0/src/parse.y | 514 - lib/libcgroup-3.1.0/src/python/Makefile.am | 43 - lib/libcgroup-3.1.0/src/python/Makefile.in | 517 - lib/libcgroup-3.1.0/src/python/cgroup.pxd | 133 - lib/libcgroup-3.1.0/src/python/libcgroup.pyx | 821 - lib/libcgroup-3.1.0/src/python/setup.py | 35 - lib/libcgroup-3.1.0/src/systemd.c | 348 - lib/libcgroup-3.1.0/src/tools/Makefile.am | 75 - lib/libcgroup-3.1.0/src/tools/Makefile.in | 1384 - lib/libcgroup-3.1.0/src/tools/cgclassify.c | 700 - lib/libcgroup-3.1.0/src/tools/cgconfig.c | 196 - lib/libcgroup-3.1.0/src/tools/cgcreate.c | 355 - lib/libcgroup-3.1.0/src/tools/cgdelete.c | 295 - lib/libcgroup-3.1.0/src/tools/cgexec.c | 524 - lib/libcgroup-3.1.0/src/tools/cgget.c | 883 - lib/libcgroup-3.1.0/src/tools/cgset.c | 288 - lib/libcgroup-3.1.0/src/tools/cgsnapshot.c | 853 - lib/libcgroup-3.1.0/src/tools/cgxget.c | 939 - lib/libcgroup-3.1.0/src/tools/cgxset.c | 380 - lib/libcgroup-3.1.0/src/tools/lscgroup.c | 326 - lib/libcgroup-3.1.0/src/tools/lssubsys.c | 282 - lib/libcgroup-3.1.0/src/tools/tools-common.c | 312 - lib/libcgroup-3.1.0/src/tools/tools-common.h | 137 - lib/libcgroup-3.1.0/src/wrapper.c | 833 - lib/libcgroup-3.1.0/tests/Makefile.am | 4 - lib/libcgroup-3.1.0/tests/Makefile.in | 653 - lib/libcgroup-3.1.0/tests/README.md | 5 - .../tests/ftests/001-cgget-basic_cgget_v1.py | 66 - .../ftests/002-cgdelete-recursive_delete.py | 83 - .../tests/ftests/003-cgget-basic_cgget_v2.py | 67 - .../004-cgsnapshot-basic_snapshot_v1.py | 116 - .../005-cgsnapshot-basic_snapshot_v2.py | 79 - .../ftests/006-cgrules-basic_cgrules_v1.py | 104 - .../ftests/007-cgrules-basic_cgrules_v2.py | 96 - .../ftests/008-cgget-multiple_r_flags.py | 104 - .../009-cgget-g_flag_controller_only.py | 191 - .../010-cgget-g_flag_controller_and_cgroup.py | 194 - .../ftests/011-cgget-r_flag_two_cgroups.py | 106 - .../ftests/012-cgget-multiple_r_flags2.py | 107 - .../ftests/013-cgget-multiple_g_flags.py | 225 - .../tests/ftests/014-cgget-a_flag.py | 98 - .../ftests/015-cgget-multiline_r_flag.py | 76 - .../tests/ftests/016-cgget-invalid_options.py | 217 - .../tests/ftests/017-cgconfig-load_file.py | 86 - .../tests/ftests/018-cgconfig-load_dir.py | 109 - .../ftests/019-cgconfig-uidgid_dperm_fperm.py | 136 - .../ftests/020-cgconfig-tasks_perms_owner.py | 135 - .../ftests/021-cgconfig-invalid_options.py | 93 - .../tests/ftests/022-cgset-multiple_r_flag.py | 71 - .../tests/ftests/023-cgset-copy_from.py | 75 - .../ftests/025-cgset-multiple_cgroups.py | 72 - .../026-cgset-multiple_r_multiple_cgroup.py | 75 - .../tests/ftests/027-cgset-invalid_options.py | 170 - .../ftests/029-lssubsys-basic_lssubsys.py | 86 - .../tests/ftests/030-lssubsys-lssubsys_all.py | 92 - .../tests/ftests/031-lscgroup-g_flag.py | 109 - .../ftests/032-lscgroup-multiple_g_flags.py | 124 - .../tests/ftests/033-cgget-no_flags.py | 71 - .../tests/ftests/034-cgexec-basic_cgexec.py | 84 - .../tests/ftests/035-cgset-set_cgroup_type.py | 75 - .../tests/ftests/036-cgset-multi_thread.py | 94 - .../tests/ftests/037-cgxget-cpu_settings.py | 106 - .../ftests/038-cgxget-cpuset_settings.py | 144 - .../tests/ftests/039-pybindings-cgxget.py | 141 - .../tests/ftests/040-pybindings-cgxset.py | 117 - .../ftests/041-pybindings-library_version.py | 67 - .../tests/ftests/042-cgxget-unmappable.py | 70 - .../ftests/043-cgcreate-empty_controller.py | 75 - ...44-pybindings-cgcreate_empty_controller.py | 85 - .../045-pybindings-list_mount_points.py | 69 - .../ftests/046-cgexec-empty_controller.py | 78 - .../047-cgcreate-delete_cgrp_shared_mnt.py | 90 - .../ftests/048-pybindings-get_cgroup_mode.py | 59 - .../ftests/049-sudo-systemd_create_scope.py | 105 - .../050-sudo-systemd_create_scope_w_pid.py | 109 - .../ftests/051-sudo-cgroup_get_cgroup.py | 91 - .../ftests/052-sudo-cgroup_attach_task.py | 114 - .../ftests/053-sudo-cgroup_attach_task_pid.py | 116 - .../tests/ftests/054-sudo-set_uid_gid_v2.py | 89 - .../tests/ftests/055-sudo-set_uid_gid_v1.py | 107 - .../ftests/056-sudo-set_permissions_v2.py | 96 - .../ftests/057-sudo-set_permissions_v1.py | 106 - .../ftests/058-sudo-systemd_create_scope2.py | 165 - .../059-sudo-invalid_systemd_create_scope2.py | 106 - .../ftests/060-sudo-cgconfigparser-systemd.py | 194 - ...-sudo-g_flag_controller_only_systemd-v1.py | 156 - ...-sudo-g_flag_controller_only_systemd-v2.py | 167 - .../tests/ftests/063-sudo-systemd_cgset-v1.py | 137 - .../tests/ftests/064-sudo-systemd_cgset-v2.py | 147 - .../ftests/065-sudo-systemd_cgclassify-v1.py | 195 - .../ftests/066-sudo-systemd_cgclassify-v2.py | 213 - .../ftests/067-sudo-systemd_cgexec-v1.py | 163 - .../ftests/068-sudo-systemd_cgexec-v2.py | 179 - ...069-sudo-systemd_cgxget-cpu-settings-v1.py | 169 - ...070-sudo-systemd_cgxget-cpu-settings-v2.py | 180 - .../071-sudo-set_default_systemd_cgroup.py | 187 - .../072-pybindings-cgroup_get_cgroup.py | 142 - ...ybindings-cgroup_add_all_controllers-v2.py | 100 - ...ybindings-cgroup_add_all_controllers-v1.py | 90 - .../075-pybindings-cgroup_compare_cgroup.py | 197 - .../tests/ftests/076-cgconfig-auto_convert.py | 113 - .../ftests/077-pybindings-cgroup_get_procs.py | 111 - .../ftests/078-sudo-cgcreate_systemd_scope.py | 108 - ...079-sudo-cgcreate_default_systemd_scope.py | 104 - .../tests/ftests/080-kernel-domain_invalid.py | 102 - ...1-pybindings-cgrp_get_curr_ctrl_path-v1.py | 133 - ...2-pybindings-cgrp_get_curr_ctrl_path-v2.py | 134 - .../083-pybindings-helpers_cgroup_mode.py | 79 - .../084-sudo-cgcreate_systemd_scope_pid.py | 141 - .../ftests/085-sudo-cgexec_systemd_scope.py | 160 - .../086-sudo-systemd_cmdline_example.py | 200 - .../tests/ftests/087-sudo-move_pid.py | 91 - .../088-sudo-cgclassify_systemd_scope.py | 185 - ...elete-non-existing-shared-mnt-cgroup-v1.py | 94 - lib/libcgroup-3.1.0/tests/ftests/Makefile.am | 122 - lib/libcgroup-3.1.0/tests/ftests/Makefile.in | 971 - lib/libcgroup-3.1.0/tests/ftests/README.md | 65 - lib/libcgroup-3.1.0/tests/ftests/__init__.py | 0 lib/libcgroup-3.1.0/tests/ftests/cgroup.py | 1199 - lib/libcgroup-3.1.0/tests/ftests/config.py | 58 - lib/libcgroup-3.1.0/tests/ftests/consts.py | 36 - lib/libcgroup-3.1.0/tests/ftests/container.py | 221 - .../tests/ftests/controller.py | 69 - .../tests/ftests/ftests-wrapper.sh | 111 - lib/libcgroup-3.1.0/tests/ftests/ftests.py | 475 - lib/libcgroup-3.1.0/tests/ftests/log.py | 48 - lib/libcgroup-3.1.0/tests/ftests/process.py | 279 - lib/libcgroup-3.1.0/tests/ftests/run.py | 119 - lib/libcgroup-3.1.0/tests/ftests/systemd.py | 76 - lib/libcgroup-3.1.0/tests/ftests/utils.py | 82 - lib/libcgroup-3.1.0/tests/gunit/001-path.cpp | 164 - .../gunit/002-cgroup_parse_rules_options.cpp | 92 - .../003-cg_get_cgroups_from_proc_cgroups.cpp | 162 - .../gunit/004-cgroup_compare_ignore_rule.cpp | 371 - .../005-cgroup_compare_wildcard_procname.cpp | 84 - .../tests/gunit/006-cgroup_get_cgroup.cpp | 259 - .../gunit/007-cgroup_process_v1_mount.cpp | 81 - .../gunit/008-cgroup_process_v2_mount.cpp | 191 - .../gunit/009-cgroup_set_values_recursive.cpp | 123 - .../gunit/010-cgroup_chown_chmod_tasks.cpp | 83 - .../gunit/011-cgroupv2_subtree_control.cpp | 112 - .../tests/gunit/012-cgroup_create_cgroup.cpp | 219 - .../013-cgroup_build_tasks_procs_path.cpp | 149 - .../014-cgroupv2_get_subtree_control.cpp | 157 - .../gunit/015-cgroupv2_controller_enabled.cpp | 172 - .../tests/gunit/016-cgset_parse_r_flag.cpp | 39 - .../tests/gunit/017-API_fuzz_test.cpp | 650 - lib/libcgroup-3.1.0/tests/gunit/Makefile.am | 52 - lib/libcgroup-3.1.0/tests/gunit/Makefile.in | 1141 - lib/libcgroup-3.1.0/tests/gunit/gtest.cpp | 16 - .../tests/gunit/libcgroup_unittest.map | 130 - 316 files changed, 1 insertion(+), 141823 deletions(-) delete mode 100644 lib/libcgroup-3.1.0/.gitignore delete mode 100644 lib/libcgroup-3.1.0/CONTRIBUTING.md delete mode 100644 lib/libcgroup-3.1.0/COPYING delete mode 100644 lib/libcgroup-3.1.0/INSTALL delete mode 100644 lib/libcgroup-3.1.0/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/README delete mode 100644 lib/libcgroup-3.1.0/README_daemon delete mode 100644 lib/libcgroup-3.1.0/README_systemd delete mode 100644 lib/libcgroup-3.1.0/aclocal.m4 delete mode 100755 lib/libcgroup-3.1.0/build-aux/ar-lib delete mode 100755 lib/libcgroup-3.1.0/build-aux/compile delete mode 100755 lib/libcgroup-3.1.0/build-aux/config.guess delete mode 100755 lib/libcgroup-3.1.0/build-aux/config.sub delete mode 100755 lib/libcgroup-3.1.0/build-aux/depcomp delete mode 100755 lib/libcgroup-3.1.0/build-aux/install-sh delete mode 100644 lib/libcgroup-3.1.0/build-aux/ltmain.sh delete mode 100755 lib/libcgroup-3.1.0/build-aux/missing delete mode 100755 lib/libcgroup-3.1.0/build-aux/test-driver delete mode 100755 lib/libcgroup-3.1.0/build-aux/ylwrap delete mode 100644 lib/libcgroup-3.1.0/config.h.in delete mode 100755 lib/libcgroup-3.1.0/configure delete mode 100644 lib/libcgroup-3.1.0/configure.ac delete mode 100644 lib/libcgroup-3.1.0/dist/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/dist/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/dist/libcgroup.spec delete mode 100644 lib/libcgroup-3.1.0/dist/libcgroup.spec.in delete mode 100644 lib/libcgroup-3.1.0/doc/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/doc/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/doc/man/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/doc/man/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgclassify.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgconfig.conf.5 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgconfigparser.8 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgcreate.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgdelete.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgexec.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgget.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgred.conf.5 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgrules.conf.5 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgrulesengd.8 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgset.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgsnapshot.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgxget.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/cgxset.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/lscgroup.1 delete mode 100644 lib/libcgroup-3.1.0/doc/man/lssubsys.1 delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-death-test.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-message.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h.pump delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-printers.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-spi.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-test-part.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-typed-test.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_pred_impl.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_prod.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-port.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-printers.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-death-test-internal.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-filepath.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-internal.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-linked_ptr.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port-arch.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-string.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h.pump delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h delete mode 100644 lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h.pump delete mode 100755 lib/libcgroup-3.1.0/googletest/googletest/libgtest.so delete mode 100755 lib/libcgroup-3.1.0/googletest/googletest/libgtest_main.so delete mode 100644 lib/libcgroup-3.1.0/include/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/include/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/config.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/error.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/groups.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/init.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/init.h.in delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/iterators.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/log.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/systemd.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/tasks.h delete mode 100644 lib/libcgroup-3.1.0/include/libcgroup/tools.h delete mode 100644 lib/libcgroup-3.1.0/libcgroup.doxyfile delete mode 100644 lib/libcgroup-3.1.0/libcgroup.pc.in delete mode 100644 lib/libcgroup-3.1.0/m4/ax_code_coverage.m4 delete mode 100644 lib/libcgroup-3.1.0/m4/libtool.m4 delete mode 100644 lib/libcgroup-3.1.0/m4/ltoptions.m4 delete mode 100644 lib/libcgroup-3.1.0/m4/ltsugar.m4 delete mode 100644 lib/libcgroup-3.1.0/m4/ltversion.m4 delete mode 100644 lib/libcgroup-3.1.0/m4/lt~obsolete.m4 delete mode 100755 lib/libcgroup-3.1.0/myconfigure delete mode 100644 lib/libcgroup-3.1.0/samples/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/samples/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/samples/c/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/samples/c/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/samples/c/create_systemd_scope.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/empty_cgroup_v2.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_all_controller.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_controller.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_mount_point.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_procs.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_setup_mode.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/get_variable_names.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/logger.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/proctest.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/read_stats.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/setuid.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/test_named_hierarchy.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/walk_task.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/walk_test.c delete mode 100644 lib/libcgroup-3.1.0/samples/c/wrapper_test.c delete mode 100644 lib/libcgroup-3.1.0/samples/cmdline/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/samples/cmdline/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/samples/config/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/samples/config/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgconfig.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgconfig.sysconfig delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgred.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgrules.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgsnapshot_allowlist.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/cgsnapshot_denylist.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/invalid_namespace_config.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/invalid_namespace_mount_config.conf delete mode 100644 lib/libcgroup-3.1.0/samples/config/namespace_config.conf delete mode 100644 lib/libcgroup-3.1.0/samples/python/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/samples/python/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/scripts/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/scripts/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/scripts/init.d/cgconfig.in delete mode 100644 lib/libcgroup-3.1.0/scripts/init.d/cgred.in delete mode 100644 lib/libcgroup-3.1.0/src/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/src/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-common.c delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-common.h delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-cpu.c delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-cpuset.c delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-map.c delete mode 100644 lib/libcgroup-3.1.0/src/abstraction-map.h delete mode 100644 lib/libcgroup-3.1.0/src/api.c delete mode 100644 lib/libcgroup-3.1.0/src/config.c delete mode 100644 lib/libcgroup-3.1.0/src/daemon/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/src/daemon/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/src/daemon/cgrulesengd.c delete mode 100644 lib/libcgroup-3.1.0/src/daemon/cgrulesengd.h delete mode 100644 lib/libcgroup-3.1.0/src/lex.c delete mode 100644 lib/libcgroup-3.1.0/src/lex.l delete mode 100644 lib/libcgroup-3.1.0/src/libcgroup-internal.h delete mode 100644 lib/libcgroup-3.1.0/src/libcgroup.map delete mode 100755 lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread delete mode 100644 lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread.c delete mode 100644 lib/libcgroup-3.1.0/src/log.c delete mode 100644 lib/libcgroup-3.1.0/src/pam/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/src/pam/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/src/pam/pam_cgroup.c delete mode 100644 lib/libcgroup-3.1.0/src/parse.c delete mode 100644 lib/libcgroup-3.1.0/src/parse.h delete mode 100644 lib/libcgroup-3.1.0/src/parse.y delete mode 100644 lib/libcgroup-3.1.0/src/python/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/src/python/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/src/python/cgroup.pxd delete mode 100644 lib/libcgroup-3.1.0/src/python/libcgroup.pyx delete mode 100755 lib/libcgroup-3.1.0/src/python/setup.py delete mode 100644 lib/libcgroup-3.1.0/src/systemd.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/src/tools/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgclassify.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgconfig.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgcreate.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgdelete.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgexec.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgget.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgset.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgsnapshot.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgxget.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/cgxset.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/lscgroup.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/lssubsys.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/tools-common.c delete mode 100644 lib/libcgroup-3.1.0/src/tools/tools-common.h delete mode 100644 lib/libcgroup-3.1.0/src/wrapper.c delete mode 100644 lib/libcgroup-3.1.0/tests/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/tests/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/tests/README.md delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/001-cgget-basic_cgget_v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/002-cgdelete-recursive_delete.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/003-cgget-basic_cgget_v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/004-cgsnapshot-basic_snapshot_v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/005-cgsnapshot-basic_snapshot_v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/006-cgrules-basic_cgrules_v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/007-cgrules-basic_cgrules_v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/008-cgget-multiple_r_flags.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/009-cgget-g_flag_controller_only.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/010-cgget-g_flag_controller_and_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/011-cgget-r_flag_two_cgroups.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/012-cgget-multiple_r_flags2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/013-cgget-multiple_g_flags.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/014-cgget-a_flag.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/015-cgget-multiline_r_flag.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/016-cgget-invalid_options.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/017-cgconfig-load_file.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/018-cgconfig-load_dir.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/019-cgconfig-uidgid_dperm_fperm.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/020-cgconfig-tasks_perms_owner.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/021-cgconfig-invalid_options.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/022-cgset-multiple_r_flag.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/023-cgset-copy_from.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/025-cgset-multiple_cgroups.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/026-cgset-multiple_r_multiple_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/027-cgset-invalid_options.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/029-lssubsys-basic_lssubsys.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/030-lssubsys-lssubsys_all.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/031-lscgroup-g_flag.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/032-lscgroup-multiple_g_flags.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/033-cgget-no_flags.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/034-cgexec-basic_cgexec.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/035-cgset-set_cgroup_type.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/036-cgset-multi_thread.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/037-cgxget-cpu_settings.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/038-cgxget-cpuset_settings.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/039-pybindings-cgxget.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/040-pybindings-cgxset.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/041-pybindings-library_version.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/042-cgxget-unmappable.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/043-cgcreate-empty_controller.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/044-pybindings-cgcreate_empty_controller.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/045-pybindings-list_mount_points.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/046-cgexec-empty_controller.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/047-cgcreate-delete_cgrp_shared_mnt.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/048-pybindings-get_cgroup_mode.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/049-sudo-systemd_create_scope.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/050-sudo-systemd_create_scope_w_pid.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/051-sudo-cgroup_get_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/052-sudo-cgroup_attach_task.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/053-sudo-cgroup_attach_task_pid.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/054-sudo-set_uid_gid_v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/055-sudo-set_uid_gid_v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/056-sudo-set_permissions_v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/057-sudo-set_permissions_v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/058-sudo-systemd_create_scope2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/059-sudo-invalid_systemd_create_scope2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/060-sudo-cgconfigparser-systemd.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/061-sudo-g_flag_controller_only_systemd-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/062-sudo-g_flag_controller_only_systemd-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/063-sudo-systemd_cgset-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/064-sudo-systemd_cgset-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/065-sudo-systemd_cgclassify-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/066-sudo-systemd_cgclassify-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/067-sudo-systemd_cgexec-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/068-sudo-systemd_cgexec-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/069-sudo-systemd_cgxget-cpu-settings-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/070-sudo-systemd_cgxget-cpu-settings-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/071-sudo-set_default_systemd_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/072-pybindings-cgroup_get_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/073-pybindings-cgroup_add_all_controllers-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/074-pybindings-cgroup_add_all_controllers-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/075-pybindings-cgroup_compare_cgroup.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/076-cgconfig-auto_convert.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/077-pybindings-cgroup_get_procs.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/078-sudo-cgcreate_systemd_scope.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/079-sudo-cgcreate_default_systemd_scope.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/080-kernel-domain_invalid.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/081-pybindings-cgrp_get_curr_ctrl_path-v1.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/082-pybindings-cgrp_get_curr_ctrl_path-v2.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/083-pybindings-helpers_cgroup_mode.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/084-sudo-cgcreate_systemd_scope_pid.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/085-sudo-cgexec_systemd_scope.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/086-sudo-systemd_cmdline_example.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/087-sudo-move_pid.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/088-sudo-cgclassify_systemd_scope.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/998-cgdelete-non-existing-shared-mnt-cgroup-v1.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/README.md delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/__init__.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/cgroup.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/config.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/consts.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/container.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/controller.py delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/ftests-wrapper.sh delete mode 100755 lib/libcgroup-3.1.0/tests/ftests/ftests.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/log.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/process.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/run.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/systemd.py delete mode 100644 lib/libcgroup-3.1.0/tests/ftests/utils.py delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/001-path.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/002-cgroup_parse_rules_options.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/003-cg_get_cgroups_from_proc_cgroups.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/004-cgroup_compare_ignore_rule.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/005-cgroup_compare_wildcard_procname.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/006-cgroup_get_cgroup.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/007-cgroup_process_v1_mount.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/008-cgroup_process_v2_mount.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/009-cgroup_set_values_recursive.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/010-cgroup_chown_chmod_tasks.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/011-cgroupv2_subtree_control.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/012-cgroup_create_cgroup.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/013-cgroup_build_tasks_procs_path.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/014-cgroupv2_get_subtree_control.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/015-cgroupv2_controller_enabled.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/016-cgset_parse_r_flag.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/017-API_fuzz_test.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/Makefile.am delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/Makefile.in delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/gtest.cpp delete mode 100644 lib/libcgroup-3.1.0/tests/gunit/libcgroup_unittest.map diff --git a/judge/runguard_test/runguard_test.sh b/judge/runguard_test/runguard_test.sh index 11cb753ea3e..db66a916c83 100755 --- a/judge/runguard_test/runguard_test.sh +++ b/judge/runguard_test/runguard_test.sh @@ -232,7 +232,7 @@ test_nprocs() { fi not_expect_stdout 16 not_expect_stdout 31 - expect_stderr "retry: Resource temporarily unavailable" + expect_stderr "Resource temporarily unavailable" } test_meta() { diff --git a/lib/libcgroup-3.1.0/.gitignore b/lib/libcgroup-3.1.0/.gitignore deleted file mode 100644 index 4f13bce0836..00000000000 --- a/lib/libcgroup-3.1.0/.gitignore +++ /dev/null @@ -1,14 +0,0 @@ -**/Makefile - -config.h -config.log -config.status -stamp-h1 - -libtool -libcgroup.pc - -**/.deps/ - -scripts/init.d/cgconfig -scripts/init.d/cgred diff --git a/lib/libcgroup-3.1.0/CONTRIBUTING.md b/lib/libcgroup-3.1.0/CONTRIBUTING.md deleted file mode 100644 index a77aa6d8f41..00000000000 --- a/lib/libcgroup-3.1.0/CONTRIBUTING.md +++ /dev/null @@ -1,184 +0,0 @@ -How to Contribute to the libcgroup Project -=============================================================================== -https://github.com/libcgroup/libcgroup - -This document outlines the steps to help you contribute to the libcgroup project. -As with the libcgroup code itself, the process is a work in progress. -Improvements and suggestions are welcome and encouraged. - -## Interacting with the Community - -> "When you are kind to others, it not only changes you, it changes the -> world." - Harold Kushner - -The libcgroup project strives to be an inclusive and welcoming place. -If you interact with the libcgroup project, we request that you treat others -with dignity and respect. Failure to do so will result in a warning. In -extreme cases, we reserve the right to block the individual from the project. - -Examples of inappropriate behavior includes: profane, abusive, or prejudicial -language directed at another person, vandalism (e.g. GitHub issue/PR "litter"), -or spam. - -## Test Your Code Using Existing Tests - -The libcgroup project utilizes unit and functional tests. These tests must -successfully pass prior to a commit being merged. - -You can run both the unit and functional tests with the following command: - - # make check - -You can invoke only the unit tests with the following commands: - - # cd tests/gunit - # make check - -If there are unit test failures, running the unit tests outside of the -automake framework will provide more information. - - # cd tests/gunit - # ./gtest - -You can invoke only the functional tests with the following commands: - - # cd tests/ftests - # make check - -Note that the functional tests can be run within a container or directly on -your system. For the containerized tests, libcgroup utilizes LXC/LXD -containers. If your system or distro doesn't support LXC/LXD, you can -utilize the continuous integration infrastructure to test your changes. A -successful continuous integration run is required for each pull request. - -Many tests can also be run outside of a container. Use caution with these -tests though, as they will modify your host's cgroup hierarchy. This could -significantly and negatively affect your system. - -We encourage utilizing a VM for libcgroup development work. The continuous -integration suite utilizes the latest Ubuntu LTS. - -To run the containerized tests only: - - # cd tests/ftests - # ./ftests.sh - -To run the non-containerized tests only: - - # cd tests/ftests - # ./ftests-nocontainer.sh - -After the run is complete, the ftests.sh.log and ftests-nocontainer.sh.log -contain the full debug log for each run. - -## Add New Tests for New Functionality - -The libcgroup project utilizes automated tests, code coverage, and continuous -integration to maintain a high level of code quality. Any pull requests that -add functionality or significantly change existing code should include -additional tests to verify the proper operation of the proposed changes. Note -that functional tests are preferred over unit tests. - -The continuous integration tools run the automated tests and automatically -gather code coverage numbers. Pull requests that cause the code coverage -numbers to decrease are strongly discouraged. - -## Explain Your Work - -At the top of every patch you should include a description of the problem you -are trying to solve, how you solved it, and why you chose the solution you -implemented. If you are submitting a bug fix, it is also incredibly helpful -if you can describe/include a reproducer for the problem in the description as -well as instructions on how to test for the bug and verify that it has been -fixed. - -## Sign Your Work - -The sign-off is a simple line at the end of the patch description, which -certifies that you wrote it or otherwise have the right to pass it on as an -open-source patch. The "Developer's Certificate of Origin" pledge is taken -from the Linux Kernel and the rules are pretty simple: - - Developer's Certificate of Origin 1.1 - - By making a contribution to this project, I certify that: - - (a) The contribution was created in whole or in part by me and I - have the right to submit it under the open source license - indicated in the file; or - - (b) The contribution is based upon previous work that, to the best - of my knowledge, is covered under an appropriate open source - license and I have the right under that license to submit that - work with modifications, whether created in whole or in part - by me, under the same open source license (unless I am - permitted to submit under a different license), as indicated - in the file; or - - (c) The contribution was provided directly to me by some other - person who certified (a), (b) or (c) and I have not modified - it. - - (d) I understand and agree that this project and the contribution - are public and that a record of the contribution (including all - personal information I submit with it, including my sign-off) is - maintained indefinitely and may be redistributed consistent with - this project or the open source license(s) involved. - -... then you just add a line to the bottom of your patch description, with -your real name, saying: - - Signed-off-by: Random J Developer - -You can add this to your commit description in `git` with `git commit -s` - -## Submitting Patches - -libcgroup was initially hosted on Sourceforge and at that time only accepted -patches via the mailing list. In 2018, libcgroup was moved to github and now -accepts patches via email or github pull request. Over time the libcgroup -project will likely fully transition to gitub pull requests and issues. - -### Post Your Patches Upstream - -The sections below explain how to contribute via either method. Please read -each step and perform all steps that apply to your chosen contribution method. - -### Submitting via Email - -Depending on how you decided to work with the libcgroup code base and what -tools you are using there are different ways to generate your patch(es). -However, regardless of what tools you use, you should always generate your -patches using the "unified" diff/patch format and the patches should always -apply to the libcgroup source tree using the following command from the top -directory of the libcgroup sources: - - # patch -p1 < changes.patch - -If you are not using git, stacked git (stgit), or some other tool which can -generate patch files for you automatically, you may find the following command -helpful in generating patches, where "libcgroup.orig/" is the unmodified -source code directory and "libcgroup/" is the source code directory with your -changes: - - # diff -purN libcgroup.orig/ libcgroup/ - -When in doubt please generate your patch and try applying it to an unmodified -copy of the libcgroup sources; if it fails for you, it will fail for the rest -of us. - -Finally, you will need to email your patches to the mailing list so they can -be reviewed and potentially merged into the main libcgroup repository. When -sending patches to the mailing list it is important to send your email in text -form, no HTML mail please, and ensure that your email client does not mangle -your patches. It should be possible to save your raw email to disk and apply -it directly to the libcgroup source code; if that fails then you likely have -a problem with your email client. When in doubt try a test first by sending -yourself an email with your patch and attempting to apply the emailed patch to -the libcgrup repository; if it fails for you, it will fail for the rest of -us trying to test your patch and include it in the main libcgroup repository. - -### Submitting via GitHub Pull Requests - -See [this guide](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request) if you've never done this before. - diff --git a/lib/libcgroup-3.1.0/COPYING b/lib/libcgroup-3.1.0/COPYING deleted file mode 100644 index 1bf76215682..00000000000 --- a/lib/libcgroup-3.1.0/COPYING +++ /dev/null @@ -1,510 +0,0 @@ - - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations -below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it -becomes a de-facto standard. To achieve this, non-free programs must -be allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control -compilation and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at least - three years, to give the same user the materials specified in - Subsection 6a, above, for a charge no more than the cost of - performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply, and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License -may add an explicit geographical distribution limitation excluding those -countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms -of the ordinary General Public License). - - To apply these terms, attach the following notices to the library. -It is safest to attach them to the start of each source file to most -effectively convey the exclusion of warranty; and each file should -have at least the "copyright" line and a pointer to where the full -notice is found. - - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library 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 - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or -your school, if any, to sign a "copyright disclaimer" for the library, -if necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James - Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! - - diff --git a/lib/libcgroup-3.1.0/INSTALL b/lib/libcgroup-3.1.0/INSTALL deleted file mode 100644 index d3c5b40a940..00000000000 --- a/lib/libcgroup-3.1.0/INSTALL +++ /dev/null @@ -1,237 +0,0 @@ -Installation Instructions -************************* - -Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, -2006, 2007 Free Software Foundation, Inc. - -This file is free documentation; the Free Software Foundation gives -unlimited permission to copy, distribute and modify it. - -Basic Installation -================== - -Briefly, the shell commands `./configure; make; make install' should -configure, build, and install this package. The following -more-detailed instructions are generic; see the `README' file for -instructions specific to this package. - - The `configure' shell script attempts to guess correct values for -various system-dependent variables used during compilation. It uses -those values to create a `Makefile' in each directory of the package. -It may also create one or more `.h' files containing system-dependent -definitions. Finally, it creates a shell script `config.status' that -you can run in the future to recreate the current configuration, and a -file `config.log' containing compiler output (useful mainly for -debugging `configure'). - - It can also use an optional file (typically called `config.cache' -and enabled with `--cache-file=config.cache' or simply `-C') that saves -the results of its tests to speed up reconfiguring. Caching is -disabled by default to prevent problems with accidental use of stale -cache files. - - If you need to do unusual things to compile the package, please try -to figure out how `configure' could check whether to do them, and mail -diffs or instructions to the address given in the `README' so they can -be considered for the next release. If you are using the cache, and at -some point `config.cache' contains results you don't want to keep, you -may remove or edit it. - - The file `configure.ac' (or `configure.in') is used to create -`configure' by a program called `autoconf'. You need `configure.ac' if -you want to change it or regenerate `configure' using a newer version -of `autoconf'. - -The simplest way to compile this package is: - - 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. - - Running `configure' might take a while. While running, it prints - some messages telling which features it is checking for. - - 2. Type `make' to compile the package. - - 3. Optionally, type `make check' to run any self-tests that come with - the package. - - 4. Type `make install' to install the programs and any data files and - documentation. - - 5. You can remove the program binaries and object files from the - source code directory by typing `make clean'. To also remove the - files that `configure' created (so you can compile the package for - a different kind of computer), type `make distclean'. There is - also a `make maintainer-clean' target, but that is intended mainly - for the package's developers. If you use it, you may have to get - all sorts of other programs in order to regenerate files that came - with the distribution. - - 6. Often, you can also type `make uninstall' to remove the installed - files again. - -Compilers and Options -===================== - -Some systems require unusual options for compilation or linking that the -`configure' script does not know about. Run `./configure --help' for -details on some of the pertinent environment variables. - - You can give `configure' initial values for configuration parameters -by setting variables in the command line or in the environment. Here -is an example: - - ./configure CC=c99 CFLAGS=-g LIBS=-lposix - - *Note Defining Variables::, for more details. - -Compiling For Multiple Architectures -==================================== - -You can compile the package for more than one kind of computer at the -same time, by placing the object files for each architecture in their -own directory. To do this, you can use GNU `make'. `cd' to the -directory where you want the object files and executables to go and run -the `configure' script. `configure' automatically checks for the -source code in the directory that `configure' is in and in `..'. - - With a non-GNU `make', it is safer to compile the package for one -architecture at a time in the source code directory. After you have -installed the package for one architecture, use `make distclean' before -reconfiguring for another architecture. - -Installation Names -================== - -By default, `make install' installs the package's commands under -`/usr/local/bin', include files under `/usr/local/include', etc. You -can specify an installation prefix other than `/usr/local' by giving -`configure' the option `--prefix=PREFIX'. - - You can specify separate installation prefixes for -architecture-specific files and architecture-independent files. If you -pass the option `--exec-prefix=PREFIX' to `configure', the package uses -PREFIX as the prefix for installing programs and libraries. -Documentation and other data files still use the regular prefix. - - In addition, if you use an unusual directory layout you can give -options like `--bindir=DIR' to specify different values for particular -kinds of files. Run `configure --help' for a list of the directories -you can set and what kinds of files go in them. - - If the package supports it, you can cause programs to be installed -with an extra prefix or suffix on their names by giving `configure' the -option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. - -Optional Features -================= - -Some packages pay attention to `--enable-FEATURE' options to -`configure', where FEATURE indicates an optional part of the package. -They may also pay attention to `--with-PACKAGE' options, where PACKAGE -is something like `gnu-as' or `x' (for the X Window System). The -`README' should mention any `--enable-' and `--with-' options that the -package recognizes. - - For packages that use the X Window System, `configure' can usually -find the X include and library files automatically, but if it doesn't, -you can use the `configure' options `--x-includes=DIR' and -`--x-libraries=DIR' to specify their locations. - -Specifying the System Type -========================== - -There may be some features `configure' cannot figure out automatically, -but needs to determine by the type of machine the package will run on. -Usually, assuming the package is built to be run on the _same_ -architectures, `configure' can figure that out, but if it prints a -message saying it cannot guess the machine type, give it the -`--build=TYPE' option. TYPE can either be a short name for the system -type, such as `sun4', or a canonical name which has the form: - - CPU-COMPANY-SYSTEM - -where SYSTEM can have one of these forms: - - OS KERNEL-OS - - See the file `config.sub' for the possible values of each field. If -`config.sub' isn't included in this package, then this package doesn't -need to know the machine type. - - If you are _building_ compiler tools for cross-compiling, you should -use the option `--target=TYPE' to select the type of system they will -produce code for. - - If you want to _use_ a cross compiler, that generates code for a -platform different from the build platform, you should specify the -"host" platform (i.e., that on which the generated programs will -eventually be run) with `--host=TYPE'. - -Sharing Defaults -================ - -If you want to set default values for `configure' scripts to share, you -can create a site shell script called `config.site' that gives default -values for variables like `CC', `cache_file', and `prefix'. -`configure' looks for `PREFIX/share/config.site' if it exists, then -`PREFIX/etc/config.site' if it exists. Or, you can set the -`CONFIG_SITE' environment variable to the location of the site script. -A warning: not all `configure' scripts look for a site script. - -Defining Variables -================== - -Variables not defined in a site shell script can be set in the -environment passed to `configure'. However, some packages may run -configure again during the build, and the customized values of these -variables may be lost. In order to avoid this problem, you should set -them in the `configure' command line, using `VAR=value'. For example: - - ./configure CC=/usr/local2/bin/gcc - -causes the specified `gcc' to be used as the C compiler (unless it is -overridden in the site shell script). - -Unfortunately, this technique does not work for `CONFIG_SHELL' due to -an Autoconf bug. Until the bug is fixed you can use this workaround: - - CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash - -`configure' Invocation -====================== - -`configure' recognizes the following options to control how it operates. - -`--help' -`-h' - Print a summary of the options to `configure', and exit. - -`--version' -`-V' - Print the version of Autoconf used to generate the `configure' - script, and exit. - -`--cache-file=FILE' - Enable the cache: use and save the results of the tests in FILE, - traditionally `config.cache'. FILE defaults to `/dev/null' to - disable caching. - -`--config-cache' -`-C' - Alias for `--cache-file=config.cache'. - -`--quiet' -`--silent' -`-q' - Do not print messages saying which checks are being made. To - suppress all normal output, redirect it to `/dev/null' (any error - messages will still be shown). - -`--srcdir=DIR' - Look for the package's source code in directory DIR. Usually - `configure' can determine that directory automatically. - -`configure' also accepts some other, not widely useful, options. Run -`configure --help' for more details. - diff --git a/lib/libcgroup-3.1.0/Makefile.am b/lib/libcgroup-3.1.0/Makefile.am deleted file mode 100644 index 277e7402209..00000000000 --- a/lib/libcgroup-3.1.0/Makefile.am +++ /dev/null @@ -1,13 +0,0 @@ -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS= -I m4 -DIST_SUBDIRS = dist doc include scripts src tests samples -SUBDIRS = $(DIST_SUBDIRS) - -EXTRA_DIST = README_daemon libcgroup.doxyfile README_systemd CONTRIBUTING.md - -AM_DISTCHECK_CONFIGURE_FLAGS = --sysconfdir=/etc --localstatedir=/var \ - --enable-opaque-hierarchy="name=systemd" \ - --enable-python - -pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = libcgroup.pc diff --git a/lib/libcgroup-3.1.0/Makefile.in b/lib/libcgroup-3.1.0/Makefile.in deleted file mode 100644 index c6c20ad7869..00000000000 --- a/lib/libcgroup-3.1.0/Makefile.in +++ /dev/null @@ -1,937 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = . -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ - $(am__configure_deps) $(am__DIST_COMMON) -am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ - configure.lineno config.status.lineno -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = config.h -CONFIG_CLEAN_FILES = scripts/init.d/cgconfig scripts/init.d/cgred \ - include/libcgroup/init.h libcgroup.pc -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(pkgconfigdir)" -DATA = $(pkgconfig_DATA) -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - cscope distdir distdir-am dist dist-all distcheck -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) \ - config.h.in -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \ - $(srcdir)/libcgroup.pc.in $(top_srcdir)/build-aux/ar-lib \ - $(top_srcdir)/build-aux/compile \ - $(top_srcdir)/build-aux/config.guess \ - $(top_srcdir)/build-aux/config.sub \ - $(top_srcdir)/build-aux/install-sh \ - $(top_srcdir)/build-aux/ltmain.sh \ - $(top_srcdir)/build-aux/missing \ - $(top_srcdir)/include/libcgroup/init.h.in \ - $(top_srcdir)/scripts/init.d/cgconfig.in \ - $(top_srcdir)/scripts/init.d/cgred.in COPYING INSTALL README \ - build-aux/ar-lib build-aux/compile build-aux/config.guess \ - build-aux/config.sub build-aux/depcomp build-aux/install-sh \ - build-aux/ltmain.sh build-aux/missing build-aux/ylwrap -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -distdir = $(PACKAGE)-$(VERSION) -top_distdir = $(distdir) -am__remove_distdir = \ - if test -d "$(distdir)"; then \ - find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -rf "$(distdir)" \ - || { sleep 5 && rm -rf "$(distdir)"; }; \ - else :; fi -am__post_remove_distdir = $(am__remove_distdir) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 -GZIP_ENV = --best -DIST_TARGETS = dist-bzip2 dist-gzip -# Exists only to be overridden by the user if desired. -AM_DISTCHECK_DVI_TARGET = dvi -distuninstallcheck_listfiles = find . -type f -print -am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ - | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' -distcleancheck_listfiles = find . -type f -print -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AUTOMAKE_OPTIONS = foreign -ACLOCAL_AMFLAGS = -I m4 -DIST_SUBDIRS = dist doc include scripts src tests samples -SUBDIRS = $(DIST_SUBDIRS) -EXTRA_DIST = README_daemon libcgroup.doxyfile README_systemd CONTRIBUTING.md -AM_DISTCHECK_CONFIGURE_FLAGS = --sysconfdir=/etc --localstatedir=/var \ - --enable-opaque-hierarchy="name=systemd" \ - --enable-python - -pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = libcgroup.pc -all: config.h - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -am--refresh: Makefile - @: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ - $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - echo ' $(SHELL) ./config.status'; \ - $(SHELL) ./config.status;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - $(SHELL) ./config.status --recheck - -$(top_srcdir)/configure: $(am__configure_deps) - $(am__cd) $(srcdir) && $(AUTOCONF) -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) -$(am__aclocal_m4_deps): - -config.h: stamp-h1 - @test -f $@ || rm -f stamp-h1 - @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1 - -stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status - @rm -f stamp-h1 - cd $(top_builddir) && $(SHELL) ./config.status config.h -$(srcdir)/config.h.in: $(am__configure_deps) - ($(am__cd) $(top_srcdir) && $(AUTOHEADER)) - rm -f stamp-h1 - touch $@ - -distclean-hdr: - -rm -f config.h stamp-h1 -scripts/init.d/cgconfig: $(top_builddir)/config.status $(top_srcdir)/scripts/init.d/cgconfig.in - cd $(top_builddir) && $(SHELL) ./config.status $@ -scripts/init.d/cgred: $(top_builddir)/config.status $(top_srcdir)/scripts/init.d/cgred.in - cd $(top_builddir) && $(SHELL) ./config.status $@ -include/libcgroup/init.h: $(top_builddir)/config.status $(top_srcdir)/include/libcgroup/init.h.in - cd $(top_builddir) && $(SHELL) ./config.status $@ -libcgroup.pc: $(top_builddir)/config.status $(srcdir)/libcgroup.pc.in - cd $(top_builddir) && $(SHELL) ./config.status $@ - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -distclean-libtool: - -rm -f libtool config.lt -install-pkgconfigDATA: $(pkgconfig_DATA) - @$(NORMAL_INSTALL) - @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \ - fi; \ - for p in $$list; do \ - if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; \ - done | $(am__base_list) | \ - while read files; do \ - echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \ - $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \ - done - -uninstall-pkgconfigDATA: - @$(NORMAL_UNINSTALL) - @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ - files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ - dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscope: cscope.files - test ! -s cscope.files \ - || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) -clean-cscope: - -rm -f cscope.files -cscope.files: clean-cscope cscopelist -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -rm -f cscope.out cscope.in.out cscope.po.out cscope.files -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done - -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -755 \ - -exec chmod u+rwx,go+rx {} \; -o \ - ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ - ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ - || chmod -R a+r "$(distdir)" -dist-gzip: distdir - tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz - $(am__post_remove_distdir) -dist-bzip2: distdir - tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 - $(am__post_remove_distdir) - -dist-lzip: distdir - tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz - $(am__post_remove_distdir) - -dist-xz: distdir - tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz - $(am__post_remove_distdir) - -dist-zstd: distdir - tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst - $(am__post_remove_distdir) - -dist-tarZ: distdir - @echo WARNING: "Support for distribution archives compressed with" \ - "legacy program 'compress' is deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z - $(am__post_remove_distdir) - -dist-shar: distdir - @echo WARNING: "Support for shar distribution archives is" \ - "deprecated." >&2 - @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 - shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz - $(am__post_remove_distdir) - -dist-zip: distdir - -rm -f $(distdir).zip - zip -rq $(distdir).zip $(distdir) - $(am__post_remove_distdir) - -dist dist-all: - $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' - $(am__post_remove_distdir) - -# This target untars the dist file and tries a VPATH configuration. Then -# it guarantees that the distribution is self-contained by making another -# tarfile. -distcheck: dist - case '$(DIST_ARCHIVES)' in \ - *.tar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\ - *.tar.bz2*) \ - bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ - *.tar.lz*) \ - lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ - *.tar.xz*) \ - xz -dc $(distdir).tar.xz | $(am__untar) ;;\ - *.tar.Z*) \ - uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ - *.shar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\ - *.zip*) \ - unzip $(distdir).zip ;;\ - *.tar.zst*) \ - zstd -dc $(distdir).tar.zst | $(am__untar) ;;\ - esac - chmod -R a-w $(distdir) - chmod u+w $(distdir) - mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst - chmod a-w $(distdir) - test -d $(distdir)/_build || exit 0; \ - dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ - && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ - && am__cwd=`pwd` \ - && $(am__cd) $(distdir)/_build/sub \ - && ../../configure \ - $(AM_DISTCHECK_CONFIGURE_FLAGS) \ - $(DISTCHECK_CONFIGURE_FLAGS) \ - --srcdir=../.. --prefix="$$dc_install_base" \ - && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \ - && $(MAKE) $(AM_MAKEFLAGS) check \ - && $(MAKE) $(AM_MAKEFLAGS) install \ - && $(MAKE) $(AM_MAKEFLAGS) installcheck \ - && $(MAKE) $(AM_MAKEFLAGS) uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ - distuninstallcheck \ - && chmod -R a-w "$$dc_install_base" \ - && ({ \ - (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ - && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ - distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ - } || { rm -rf "$$dc_destdir"; exit 1; }) \ - && rm -rf "$$dc_destdir" \ - && $(MAKE) $(AM_MAKEFLAGS) dist \ - && rm -rf $(DIST_ARCHIVES) \ - && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ - && cd "$$am__cwd" \ - || exit 1 - $(am__post_remove_distdir) - @(echo "$(distdir) archives ready for distribution: "; \ - list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ - sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' -distuninstallcheck: - @test -n '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: trying to run $@ with an empty' \ - '$$(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - $(am__cd) '$(distuninstallcheck_dir)' || { \ - echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ - exit 1; \ - }; \ - test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left after uninstall:" ; \ - if test -n "$(DESTDIR)"; then \ - echo " (check DESTDIR support)"; \ - fi ; \ - $(distuninstallcheck_listfiles) ; \ - exit 1; } >&2 -distcleancheck: distclean - @if test '$(srcdir)' = . ; then \ - echo "ERROR: distcleancheck can only run from a VPATH build" ; \ - exit 1 ; \ - fi - @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ - || { echo "ERROR: files left in build directory after distclean:" ; \ - $(distcleancheck_listfiles) ; \ - exit 1; } >&2 -check-am: all-am -check: check-recursive -all-am: Makefile $(DATA) config.h -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(pkgconfigdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-hdr \ - distclean-libtool distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: install-pkgconfigDATA - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f $(am__CONFIG_DISTCLEAN_FILES) - -rm -rf $(top_srcdir)/autom4te.cache - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-pkgconfigDATA - -.MAKE: $(am__recursive_targets) all install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--refresh check check-am clean clean-cscope clean-generic \ - clean-libtool cscope cscopelist-am ctags ctags-am dist \ - dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \ - dist-xz dist-zip dist-zstd distcheck distclean \ - distclean-generic distclean-hdr distclean-libtool \ - distclean-tags distcleancheck distdir distuninstallcheck dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man install-pdf \ - install-pdf-am install-pkgconfigDATA install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - installdirs-am maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-pkgconfigDATA - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/README b/lib/libcgroup-3.1.0/README deleted file mode 100644 index 882c9ad22a1..00000000000 --- a/lib/libcgroup-3.1.0/README +++ /dev/null @@ -1,183 +0,0 @@ -Design -======== - -After cgroup system has taken shape, its time to have some basic tools -in user space which can enable a user to use the resource management -functionality effectively. - -One of the needed functionality is rule based placement of a task. In general, -there can be either uid or gid or exec based rules. Admin/root will -control/enforce uid/gid based rules and exec based rules can be defined by -user in a config file residing in user's home dir and fully controlled by user. - -uid/gid based rules will be defined in /etc/cgrules.conf config file and -this file will be managed by root. - -Basic idea is that to begin with provide facility to implement rules -based on uid and gid. So a hierarchy might look like as follows. - - /mnt/cgroup - | | - gid1 gid2 - | | - uid1 uid2 - | | - proj1 proj2 - - -Admin will write rules to control the resources among users. Then users -can manage their own cgroup at their own (proj1 and proj2) and control -the resources as they want. - -Following are the few methods using which tasks can be placed in right -cgroups. - -- Use pam_cgroup PAM plugin which will make sure users are placed in right - cgroup at login time and any tasks launch after login, will continue to run - in user's cgroup. - -- Use command line tool "cgexec" to launch the task in right cgroup. - -- Modify the program and use libcgroup provided APIs for placing a task - in right cgroup before doing exec(). - -- Use "cgclassify" tool to classify a already running task. - -- May be, a user space daemon can also be implemented which will listen to - kernel events and place the task in right group based on the rules. - This method involves few concerns. - - - Reliability of netlink socket. Messages can be dropped. - - Change the netlink with a cgroup controller which exports the - events. - - - Delay incurred since the event took place and task was actually placed - in right cgroup. - - - daemon will interfere with container's tasks which is not desired. - -HOWTO -===== - -Section 1: ----------- -To use "cgexec" to place the task in right cgroup. - -- make cgexec -- Run a task using cgexec. Following is the cgexec syntax. - - cgexec [-g :] command [arguments] - - Note: Cgroup controllers and path are optional. If user does not know the - right cgroup, cgexec will automatically place the task in right - cgroup based on /etc/cgrules.conf - -Example: - cgexec -g *:test1 ls - cgexec -g cpu,memory:test1 ls -l - cgexec -g cpu,memory:test1 -g swap:test2 ls -l - -Section 2 ---------- -To use "cgclassify" to place task in right cgroup. - -- make cgclassify -- Pick a task's pid to be classified, and run - cgclassify - -Example: --------- - cgclassify 2140 4325 - - Note: After classification check out whether tasks 2140 and 4325 - are in the right cgroup or not (Based on rules in /etc/cgrules.conf) - -Section 3: ----------- -To use a pam plugin which will automatically place the task in right -cgroup upon login. - -- Build pam_cgroup.so - make pam_cgroup.so -- Copy pam_cgroup.so to /lib/security/ -- Edit /etc/pam.d/su to make use of pam_cgroup.so session module upon - execution of su. - -example: - Add following line at the end of /etc/pam.d/su file - -session optional pam_cgroup.so - -- Now launch a shell for a user "xyz" using su and the resulting shell - should be running in the cgroup designated for the user as specified - by cgrules.conf - - ex. "su test1" - -Try similar things with other services like sshd. - -Note: pam_cgroup.so moves the service providing process in the right cgroup - and not the process which will be launched later. Due to parent child - relationship, yet to be forked/execed process will launch in right - group. - -Ex. Lets say user root does "su test1". In this case process "su" is the - one providing service (launching a shell) for user "test1". pam_cgroup.so - will move process "su" to the user "test1"'s cgroup (Decided by the uid - and gid of "test1"). Now once su forks/execs a shell for user test1, - final shell is effectively running in the cgroup it should have been - running based on /etc/cgrules.conf for user test1. - - -Section 4: ----------- -To use cgrulesengd which will move a task to right cgroup based on -rules in /etc/cgrules.conf do following. - -- build and install latest libcgroup.so -- build cgrulesengd - make cgrulesengd -- specify some uid/gid based rules in /etc/cgrules.conf -- Mount some controllers and create an hierarchy of cgroups (matching - your rules). -- Run cgrulesengd. - - ./cgrulesengd -- Launch some task or login as a user to the system. Daemon should automatically - place the task in right cgroup. - -FAQ -=== -Q. Why admin should not control "exec" based rules. -A. Unix file system provides access control only based on uid/gid. So - even if admin starts putting tasks based on uid/gid, it can't enforce - it. For example, consider following scenario. - - Lets say an admin creates following cgroup hierarchy. - - /container - | | - database browser - | | | | - user1 user2 user1 user2 - - Now admin wants to run all the database jobs under /container/database/ - and all the firefox jobs under /container/browser/. Based on which user - launched it, jobs should go in either user1 or user2 dir. - - Now assume that database subdir has to more cpu resources as compared to - browser subdir. Then a user, say user2, can always move his browser job - also to /container/database/user2 dir to get more cpu resources and - admin will not be able to control that. - - [Note: user2 will control what tasks can be added in /container/database/user2 - and will control what further subdirs can be created under user2 dir. Root - should not restrict the control to root only for practical purposes. Its - something like that till /container/database, admin controls the resources - and below that how resources are further subdivided among various projects - should be controlled by respective user]. - -In the light of above, it seems to make more sense that admin should enforce -rules only based on uid and gid. Probably later we can have a per user exec -based rules config file (~/.cgrules.conf), which can be parsed by cgrulesengd -and then jobs launched by user will be placed in right cgroup based on -combination of rules in /etc/cgrules.conf and ~/cgrules.conf. diff --git a/lib/libcgroup-3.1.0/README_daemon b/lib/libcgroup-3.1.0/README_daemon deleted file mode 100644 index 25f0d55075d..00000000000 --- a/lib/libcgroup-3.1.0/README_daemon +++ /dev/null @@ -1,182 +0,0 @@ -DESCRIPTION -=========== -The CGroup Rules Engine Daemon is a tool that will automatically place tasks -into the correct cgroup based on UID/GID events from the kernel. It will not -automatically classify tasks that are already running, but it will classify -any new tasks, and any tasks which change their UID/GID. Note that we use -the euid and egid, not the ruid and rgid. - -Unlike other tools, cgrulesengd caches the rules configuration in a data -structure (it's actually just a FIFO linked list) so that it doesn't need to -parse the configuration file more than once. This should be much faster than -parsing the rules for each UID/GID event. Eventually, this caching logic -should be part of libcgroup, so that any other program can take advantage of it -(and so that all programs are using the same table). The configuration can -be reloaded without stopping the daemon (more information below). - -WHY A DAEMON? -============= -A daemon is easy to use, and allows an administrator to ensure that all tasks -are classified into the correct cgroups without constantly monitoring the -system. The daemon is transparent to the users, and does not require any -modifications to existing userspace programs. Finally, the daemon can be -started and stopped at any time, including at boot time with other services. -Thus, sytem administrators can decide not to use the daemon if they choose. - -Most importantly, some programs create new users and/or run scripts, -threads, etc. as those users using suexec(). This call does not go through -PAM, so these scripts would continue running in the same cgroup as the parent -program. This behavior is likely not ideal, and the daemon would solve this -problem. - -Apache does this. Apache creates a user called 'apache' and uses setuid() to -launch tasks as that user. This does not go through PAM, so without a daemon, -these tasks would continue to run in the 'root' cgroup rather than in the -'apache' or 'webserver' cgroup. The daemon fixes this problem by catching the -setuid() call and moving the tasks into the correct cgroup. - -We would ask Apache to modify their software to interface with libcgroup, but -this solution is less than optimal because a lot of userspace software would -have to be changed, and some authors might intentionally not interact with -libcgroup, which could create an exploit. The daemon is a simple, transparent -solution. - -USING THE DAEMON -================ -The daemon can be used as a service with the cgred script, which is shipped -as scripts/init.d/cgred. This script should be installed as /etc/init.d/cgred -and used like any other service. To start the daemon, - /etc/init.d/cgred start -To stop it, - /etc/init.d/cgred stop -The restart (stop,start), condrestart (same as restart, but only if the daemon -was already started), and status (print whether the daemon is started or -stopped) commands are also supported. An additional command, "reload", allows -you to reload the configuration file without stopping the daemon. - /etc/init.d/cgred reload -The cgred script automatically loads configuration from /etc/sysconfig/cgred.conf, -which is shipped as samples/cgred.conf. See that file for more information. - -If you choose not to run the daemon as a service, the following options are -currently supported: - --nodaemon Do not run as a daemon - --nolog Write log output to stdout instead of a log file - --config [FILE] Read rules configuration from FILE instead of - /etc/cgrules.conf - -You can ask the daemon to reload the rules configuration by sending it SIGUSR2. -The easiest way to do this is with the 'kill' command: - kill -s SIGUSR2 [PID] - -You can ask the daemon to reload the templates configuration by sending it -SIGUSR1. The easiest way to do this is with the 'kill' command: - kill -s SIGUSR1 [PID] - -TESTING -======= -The program setuid (found in tests/setuid.c) can help you test the daemon. By -default, this program attempts to change its UID to root and then idles until -you kill it. You can change the default behavior to use a different UID, or -you can uncomment the second block of code to instead attempt to change the -GID. - -In order to make sure that everything works, I used the following rules: - sjo cpu default - cgtest cpu cgtest - % memory default - @cgroup cpu,memory cgtest - peter cpu test1 - % memory test2 - @root * default - * * default - -The users 'sjo' and 'cgtest' were normal users. 'peter' is not a user on the -system. The group 'cgroup' is a group containing sjo,root,cgtest as members, -and the group 'root' contains only root. The cgroups 'default' and 'cgtest' -exist, while 'test1' and 'test2' do not. Currently, the daemon does not check -for the existance of 'test1', though this would be easier to do once the -parsing and caching logic is moved into libcgroup. - -I ran the following tests, all of which were successful: - - set UID to sjo (should move cpu controller into default) - - set UID to root (should move cpu,memory controllers into cgtest) - - set UID to cgtest (should move cpu controller into cgtest, memory - controller into default) - - set GID to root (should move all controllers into default) - - set GID to cgroup (should move cpu, memory into cgtest) - - set GID to users (should move all controllers into default) - -The parsing logic will skip the 'peter' rule as well as its multi-line -components (in this case "% memory test2"), because the user does not exist. -This should work for group rules, too. Attempting to setuid() or setgid() to a -user/group that doesn't exist will just return an error and not generate a -kernel event of the PROC_EVENT_UID or PROC_EVENT_GID type, so the daemon won't -do anything for it. - -CONCERNS/ISSUES -=============== - - Netlink can be unreliable, and the daemon might miss an event if the buffer - is full. One possible solution is to have one or two files that the kernel - can queue UID/GID changes in, and have the daemon read those files whenever - they are updated. From testing, this does not actually appear to be a real - problem, but it could become one with faster machines. - - The daemon does not care for namespaces at all, which can cause conflicts - with containers. If a user places his tasks into exec-based cgroups (such - as 'network' and 'development'), the daemon will not realize this and will - simply place them into the user's cgroup (so, sjo/ instead of sjo/network/). - -CHANGELOG -========= -V9: - - Updated documentation, because it was very old and incorrect. - - Reverted the changes to cgexec and cgclassify. - - New API function: cgroup_change_cgroup_uid_gid_flags(). - - Deprecated cgroup_change_cgroup_uid_gid(). - - Rewrote some of the rule matching and execution logic in api.c to be - faster, and easier to read. - - Changes all negative return values to positive values. As a side effect, - cgroup_parse_rules() now returns -1 when we get a match and we are using - non-cached rules. - - Changes CGROUP_FUSECACHE to CGFLAG_USECACHE. - - Flags are now enumerated (cgflags), instead of #defines. - -V8: - - Moved the event-handling logic back into the daemon, where it should be. - - Changed cgroup_parse_rules() to work with cached rules or non-cached rules. - The other parsing function is no longer needed, and should be deprecated. - - Non-cached rules now work with the same structs as cached rules. - - Modified cgroup_change_cgroup_uid_gid() with a new 'flags' parameter. - Currently, the only flag is "CGROUP_FUSECACHE" to use the cached rules logic - (or not). - - Added cgroup_rules_loaded() boolean, to check whether the cached rules have - been loaded yet, and cgroup_init_rules_cache() to load them. - - Modified cgexec and cgclassify to work with the new - cgroup_change_cgroup_uid_gid(). - -V7: - - Moved parsing and caching logic into libcgroup. - - Added locking mechanisms around the list of rules. - - Cleaned up #includes in cgrulesegnd.[h,c]. - - Added notification if netlink receive queue overflows. - - Added logic to catch SIGINT in addition to SIGTERM. - - New API functions: - - cgroup_free_rule(struct cgroup_rule*) - - cgroup_free_rule_list(struct cgroup_rule_list*) - - cgroup_parse_rules(void) - - cgroup_print_rules_config(FILE*) - - cgroup_reload_cached_rules(void) - - cgroup_change_cgroup_event(struct proc_event*, int, FILE*) - -V6: - - Wrote new parsing logic, which is cleaner and simpler. - - Added cgred script to enable using the daemon as a service. - - Wrote caching logic to cache rules table. - - Added the ability to force a reload of the rules table with SIGUSR2 signal. - - Added two structures to libcgroup: cgre_rule and cgre_rules_list - - New API function: cgroup_reload_cached_rules, which reloads the rules table. - - Added logging capabilities (default log is /root/cgrulesengd.conf) - -TODO -==== - - Find a way to replace Netlink, or at least clean up that code. - - Find a solution to the namespace problem. diff --git a/lib/libcgroup-3.1.0/README_systemd b/lib/libcgroup-3.1.0/README_systemd deleted file mode 100644 index ac53b9909cb..00000000000 --- a/lib/libcgroup-3.1.0/README_systemd +++ /dev/null @@ -1,69 +0,0 @@ -Integration with systemd -======================== - -systemd is a system and service manager for Linux, compatible with SysV -and LSB init scripts. systemd heavily uses control groups to manage and control -services. - -Most of the libcgroup tools and APIs can be safely used on systems with systemd -without any problems. This document attempts to describe the configuration of -systemd and libcgroup so they can safely co-exist and mutually benefit each -other. - -References -========== -[1] http://www.freedesktop.org/wiki/Software/systemd -Systemd home page. - -[2] http://www.freedesktop.org/wiki/Software/systemd/PaxControlGroups -This is the most useful document describing systemd expectations on applications -(incl. libcgroup tools). - - -Compilation -=========== -As stated in [2], libcgroup should not interact with the 'name=systemd' -hierarchy. Compile libcgroup with the --enable-opaque-hierarchy configure option -to do so: - -./configure --enable-opaque-hierarchy=name=systemd - -Consequently, the 'name=systemd' hierarchy will not be visible to libcgroup and -all of its tools. For example, the lscgroup command will not list systemd -cgroups. - -Start-up and services -==================== - -Systemd automatically mounts all available controllers on system boot ('cpu' and -'cpuacct' together in one hierarchy by default) and can automatically put -service processes into control groups with configured parameters — by default, -each service is automatically put into the 'cpu,cpuacct:/system/$service_name' -control group. The System Administrator has full control of parameters in each -control group and of which controllers are used. Consult systemd -documentation, mainly systemd.conf(5) and systemd.exec(5) man pages, for -details. - -In the vast majority of use cases, this behavior is sufficient and libcgroup -does not need to be used. - -For specific use cases, e.g. when a different tree of control groups is needed, -libcgroup provides cgconfig service. This service can create arbitrary control -group hierarchies. In this case, follow these steps: - -1. Set 'DefaultControllers=' in /etc/systemd/system.conf so that systemd does -not create control groups for services automatically. - -2. Prepare /etc/cgconfig.conf and enable the cgconfig service. The service will -parse the /etc/cgconfig.conf file during machine boot and create all control -groups which are defined in it. The service automatically sets '+t' ("sticky") -bit on the tasks files as recommended in [2]. - -3. For each service that should start in a specific control group, add the -following lines into its unit file: - After=cgconfig.service - ControlGroup= - -This ensures the service is started only after cgconfig creates the necessary -hierarchy for it. It also tells systemd which control group it should use to -start the service. diff --git a/lib/libcgroup-3.1.0/aclocal.m4 b/lib/libcgroup-3.1.0/aclocal.m4 deleted file mode 100644 index 30fb4607f90..00000000000 --- a/lib/libcgroup-3.1.0/aclocal.m4 +++ /dev/null @@ -1,1578 +0,0 @@ -# generated automatically by aclocal 1.16.5 -*- Autoconf -*- - -# Copyright (C) 1996-2021 Free Software Foundation, Inc. - -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],, -[m4_warning([this file was generated for autoconf 2.71. -You have another version of autoconf. It may work, but is not guaranteed to. -If you have problems, you may need to regenerate the build system entirely. -To do so, use the procedure documented by the package, typically 'autoreconf'.])]) - -# Copyright (C) 2002-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_AUTOMAKE_VERSION(VERSION) -# ---------------------------- -# Automake X.Y traces this macro to ensure aclocal.m4 has been -# generated from the m4 files accompanying Automake X.Y. -# (This private macro should not be called outside this file.) -AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.16' -dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to -dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.16.5], [], - [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl -]) - -# _AM_AUTOCONF_VERSION(VERSION) -# ----------------------------- -# aclocal traces this macro to find the Autoconf version. -# This is a private macro too. Using m4_define simplifies -# the logic in aclocal, which can simply ignore this definition. -m4_define([_AM_AUTOCONF_VERSION], []) - -# AM_SET_CURRENT_AUTOMAKE_VERSION -# ------------------------------- -# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. -# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. -AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.16.5])dnl -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) - -# Copyright (C) 2011-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_AR([ACT-IF-FAIL]) -# ------------------------- -# Try to determine the archiver interface, and trigger the ar-lib wrapper -# if it is needed. If the detection of archiver interface fails, run -# ACT-IF-FAIL (default is to abort configure with a proper error message). -AC_DEFUN([AM_PROG_AR], -[AC_BEFORE([$0], [LT_INIT])dnl -AC_BEFORE([$0], [AC_PROG_LIBTOOL])dnl -AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([ar-lib])dnl -AC_CHECK_TOOLS([AR], [ar lib "link -lib"], [false]) -: ${AR=ar} - -AC_CACHE_CHECK([the archiver ($AR) interface], [am_cv_ar_interface], - [AC_LANG_PUSH([C]) - am_cv_ar_interface=ar - AC_COMPILE_IFELSE([AC_LANG_SOURCE([[int some_variable = 0;]])], - [am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&AS_MESSAGE_LOG_FD' - AC_TRY_EVAL([am_ar_try]) - if test "$ac_status" -eq 0; then - am_cv_ar_interface=ar - else - am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&AS_MESSAGE_LOG_FD' - AC_TRY_EVAL([am_ar_try]) - if test "$ac_status" -eq 0; then - am_cv_ar_interface=lib - else - am_cv_ar_interface=unknown - fi - fi - rm -f conftest.lib libconftest.a - ]) - AC_LANG_POP([C])]) - -case $am_cv_ar_interface in -ar) - ;; -lib) - # Microsoft lib, so override with the ar-lib wrapper script. - # FIXME: It is wrong to rewrite AR. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__AR in this case, - # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something - # similar. - AR="$am_aux_dir/ar-lib $AR" - ;; -unknown) - m4_default([$1], - [AC_MSG_ERROR([could not determine $AR interface])]) - ;; -esac -AC_SUBST([AR])dnl -]) - -# AM_AUX_DIR_EXPAND -*- Autoconf -*- - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to -# '$srcdir', '$srcdir/..', or '$srcdir/../..'. -# -# Of course, Automake must honor this variable whenever it calls a -# tool from the auxiliary directory. The problem is that $srcdir (and -# therefore $ac_aux_dir as well) can be either absolute or relative, -# depending on how configure is run. This is pretty annoying, since -# it makes $ac_aux_dir quite unusable in subdirectories: in the top -# source directory, any form will work fine, but in subdirectories a -# relative path needs to be adjusted first. -# -# $ac_aux_dir/missing -# fails when called from a subdirectory if $ac_aux_dir is relative -# $top_srcdir/$ac_aux_dir/missing -# fails if $ac_aux_dir is absolute, -# fails when called from a subdirectory in a VPATH build with -# a relative $ac_aux_dir -# -# The reason of the latter failure is that $top_srcdir and $ac_aux_dir -# are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is '.', but things will broke when you -# start a VPATH build or use an absolute $srcdir. -# -# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, -# iff we strip the leading $srcdir from $ac_aux_dir. That would be: -# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` -# and then we would define $MISSING as -# MISSING="\${SHELL} $am_aux_dir/missing" -# This will work as long as MISSING is not called from configure, because -# unfortunately $(top_srcdir) has no meaning in configure. -# However there are other variables, like CC, which are often used in -# configure, and could therefore not use this "fixed" $ac_aux_dir. -# -# Another solution, used here, is to always expand $ac_aux_dir to an -# absolute PATH. The drawback is that using absolute paths prevent a -# configured tree to be moved without reconfiguration. - -AC_DEFUN([AM_AUX_DIR_EXPAND], -[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl -# Expand $ac_aux_dir to an absolute path. -am_aux_dir=`cd "$ac_aux_dir" && pwd` -]) - -# AM_CONDITIONAL -*- Autoconf -*- - -# Copyright (C) 1997-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_CONDITIONAL(NAME, SHELL-CONDITION) -# ------------------------------------- -# Define a conditional. -AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ([2.52])dnl - m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl -AC_SUBST([$1_TRUE])dnl -AC_SUBST([$1_FALSE])dnl -_AM_SUBST_NOTMAKE([$1_TRUE])dnl -_AM_SUBST_NOTMAKE([$1_FALSE])dnl -m4_define([_AM_COND_VALUE_$1], [$2])dnl -if $2; then - $1_TRUE= - $1_FALSE='#' -else - $1_TRUE='#' - $1_FALSE= -fi -AC_CONFIG_COMMANDS_PRE( -[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then - AC_MSG_ERROR([[conditional "$1" was never defined. -Usually this means the macro was only invoked conditionally.]]) -fi])]) - -# Copyright (C) 1999-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - - -# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be -# written in clear, in which case automake, when reading aclocal.m4, -# will think it sees a *use*, and therefore will trigger all it's -# C support machinery. Also note that it means that autoscan, seeing -# CC etc. in the Makefile, will ask for an AC_PROG_CC use... - - -# _AM_DEPENDENCIES(NAME) -# ---------------------- -# See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". -# We try a few techniques and use that to set a single cache variable. -# -# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was -# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular -# dependency, and given that the user is not expected to run this macro, -# just rely on AC_PROG_CC. -AC_DEFUN([_AM_DEPENDENCIES], -[AC_REQUIRE([AM_SET_DEPDIR])dnl -AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl -AC_REQUIRE([AM_MAKE_INCLUDE])dnl -AC_REQUIRE([AM_DEP_TRACK])dnl - -m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], - [$1], [CXX], [depcc="$CXX" am_compiler_list=], - [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], - [$1], [UPC], [depcc="$UPC" am_compiler_list=], - [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) - -AC_CACHE_CHECK([dependency style of $depcc], - [am_cv_$1_dependencies_compiler_type], -[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_$1_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` - fi - am__universal=false - m4_case([$1], [CC], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac], - [CXX], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac]) - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_$1_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_$1_dependencies_compiler_type=none -fi -]) -AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) -AM_CONDITIONAL([am__fastdep$1], [ - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) -]) - - -# AM_SET_DEPDIR -# ------------- -# Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES. -AC_DEFUN([AM_SET_DEPDIR], -[AC_REQUIRE([AM_SET_LEADING_DOT])dnl -AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl -]) - - -# AM_DEP_TRACK -# ------------ -AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE([dependency-tracking], [dnl -AS_HELP_STRING( - [--enable-dependency-tracking], - [do not reject slow dependency extractors]) -AS_HELP_STRING( - [--disable-dependency-tracking], - [speeds up one-time build])]) -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' - am__nodep='_no' -fi -AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) -AC_SUBST([AMDEPBACKSLASH])dnl -_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl -AC_SUBST([am__nodep])dnl -_AM_SUBST_NOTMAKE([am__nodep])dnl -]) - -# Generate code to set up dependency tracking. -*- Autoconf -*- - -# Copyright (C) 1999-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# _AM_OUTPUT_DEPENDENCY_COMMANDS -# ------------------------------ -AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], -[{ - # Older Autoconf quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - # TODO: see whether this extra hack can be removed once we start - # requiring Autoconf 2.70 or later. - AS_CASE([$CONFIG_FILES], - [*\'*], [eval set x "$CONFIG_FILES"], - [*], [set x $CONFIG_FILES]) - shift - # Used to flag and report bootstrapping failures. - am_rc=0 - for am_mf - do - # Strip MF so we end up with the name of the file. - am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile which includes - # dependency-tracking related rules and includes. - # Grep'ing the whole file directly is not great: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ - || continue - am_dirpart=`AS_DIRNAME(["$am_mf"])` - am_filepart=`AS_BASENAME(["$am_mf"])` - AM_RUN_LOG([cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles]) || am_rc=$? - done - if test $am_rc -ne 0; then - AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. If GNU make was not used, consider - re-running the configure script with MAKE="gmake" (or whatever is - necessary). You can also try re-running configure with the - '--disable-dependency-tracking' option to at least be able to build - the package (albeit without support for automatic dependency tracking).]) - fi - AS_UNSET([am_dirpart]) - AS_UNSET([am_filepart]) - AS_UNSET([am_mf]) - AS_UNSET([am_rc]) - rm -f conftest-deps.mk -} -])# _AM_OUTPUT_DEPENDENCY_COMMANDS - - -# AM_OUTPUT_DEPENDENCY_COMMANDS -# ----------------------------- -# This macro should only be invoked once -- use via AC_REQUIRE. -# -# This code is only required when automatic dependency tracking is enabled. -# This creates each '.Po' and '.Plo' makefile fragment that we'll need in -# order to bootstrap the dependency handling code. -AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], -[AC_CONFIG_COMMANDS([depfiles], - [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], - [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) - -# Do all the work for Automake. -*- Autoconf -*- - -# Copyright (C) 1996-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This macro actually does too much. Some checks are only needed if -# your package does certain things. But this isn't really a big deal. - -dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. -m4_define([AC_PROG_CC], -m4_defn([AC_PROG_CC]) -[_AM_PROG_CC_C_O -]) - -# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) -# AM_INIT_AUTOMAKE([OPTIONS]) -# ----------------------------------------------- -# The call with PACKAGE and VERSION arguments is the old style -# call (pre autoconf-2.50), which is being phased out. PACKAGE -# and VERSION should now be passed to AC_INIT and removed from -# the call to AM_INIT_AUTOMAKE. -# We support both call styles for the transition. After -# the next Automake release, Autoconf can make the AC_INIT -# arguments mandatory, and then we can depend on a new Autoconf -# release and drop the old call support. -AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.65])dnl -m4_ifdef([_$0_ALREADY_INIT], - [m4_fatal([$0 expanded multiple times -]m4_defn([_$0_ALREADY_INIT]))], - [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl -dnl Autoconf wants to disallow AM_ names. We explicitly allow -dnl the ones we care about. -m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl -AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl -AC_REQUIRE([AC_PROG_INSTALL])dnl -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi -AC_SUBST([CYGPATH_W]) - -# Define the identity of the package. -dnl Distinguish between old-style and new-style calls. -m4_ifval([$2], -[AC_DIAGNOSE([obsolete], - [$0: two- and three-arguments forms are deprecated.]) -m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl - AC_SUBST([PACKAGE], [$1])dnl - AC_SUBST([VERSION], [$2])], -[_AM_SET_OPTIONS([$1])dnl -dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if( - m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]), - [ok:ok],, - [m4_fatal([AC_INIT should be called with package and version arguments])])dnl - AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl - AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl - -_AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) - AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl - -# Some tools Automake needs. -AC_REQUIRE([AM_SANITY_CHECK])dnl -AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) -AM_MISSING_PROG([AUTOCONF], [autoconf]) -AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) -AM_MISSING_PROG([AUTOHEADER], [autoheader]) -AM_MISSING_PROG([MAKEINFO], [makeinfo]) -AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -# For better backward compatibility. To be removed once Automake 1.9.x -# dies out for good. For more background, see: -# -# -AC_SUBST([mkdir_p], ['$(MKDIR_P)']) -# We need awk for the "check" target (and possibly the TAP driver). The -# system "awk" is bad on some platforms. -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([AC_PROG_MAKE_SET])dnl -AC_REQUIRE([AM_SET_LEADING_DOT])dnl -_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], - [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], - [_AM_PROG_TAR([v7])])]) -_AM_IF_OPTION([no-dependencies],, -[AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES([CC])], - [m4_define([AC_PROG_CC], - m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl -AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES([CXX])], - [m4_define([AC_PROG_CXX], - m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl -AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES([OBJC])], - [m4_define([AC_PROG_OBJC], - m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl -AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], - [_AM_DEPENDENCIES([OBJCXX])], - [m4_define([AC_PROG_OBJCXX], - m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl -]) -# Variables for tags utilities; see am/tags.am -if test -z "$CTAGS"; then - CTAGS=ctags -fi -AC_SUBST([CTAGS]) -if test -z "$ETAGS"; then - ETAGS=etags -fi -AC_SUBST([ETAGS]) -if test -z "$CSCOPE"; then - CSCOPE=cscope -fi -AC_SUBST([CSCOPE]) - -AC_REQUIRE([AM_SILENT_RULES])dnl -dnl The testsuite driver may need to know about EXEEXT, so add the -dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This -dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. -AC_CONFIG_COMMANDS_PRE(dnl -[m4_provide_if([_AM_COMPILER_EXEEXT], - [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl - -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! - -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: - -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. - -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. - -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . - -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. - -END - AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) - fi -fi -dnl The trailing newline in this macro's definition is deliberate, for -dnl backward compatibility and to allow trailing 'dnl'-style comments -dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. -]) - -dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not -dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further -dnl mangled by Autoconf and run in a shell conditional statement. -m4_define([_AC_COMPILER_EXEEXT], -m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) - -# When config.status generates a header, we must update the stamp-h file. -# This file resides in the same directory as the config header -# that is generated. The stamp files are numbered to have different names. - -# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the -# loop where config.status creates the headers, so we can generate -# our stamp files there. -AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], -[# Compute $1's index in $config_headers. -_am_arg=$1 -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_INSTALL_SH -# ------------------ -# Define $install_sh. -AC_DEFUN([AM_PROG_INSTALL_SH], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi -AC_SUBST([install_sh])]) - -# Copyright (C) 2003-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# Check whether the underlying file-system supports filenames -# with a leading dot. For instance MS-DOS doesn't. -AC_DEFUN([AM_SET_LEADING_DOT], -[rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null -AC_SUBST([am__leading_dot])]) - -# Copyright (C) 1998-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_LEX -# ----------- -# Autoconf leaves LEX=: if lex or flex can't be found. Change that to a -# "missing" invocation, for better error output. -AC_DEFUN([AM_PROG_LEX], -[AC_PREREQ([2.50])dnl -AC_REQUIRE([AM_MISSING_HAS_RUN])dnl -AC_REQUIRE([AC_PROG_LEX])dnl -if test "$LEX" = :; then - LEX=${am_missing_run}flex -fi]) - -# Check to see how 'make' treats includes. -*- Autoconf -*- - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_MAKE_INCLUDE() -# ----------------- -# Check whether make has an 'include' directive that can support all -# the idioms we need for our automatic dependency tracking code. -AC_DEFUN([AM_MAKE_INCLUDE], -[AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) -cat > confinc.mk << 'END' -am__doit: - @echo this is the am__doit target >confinc.out -.PHONY: am__doit -END -am__include="#" -am__quote= -# BSD make does it like this. -echo '.include "confinc.mk" # ignored' > confmf.BSD -# Other make implementations (GNU, Solaris 10, AIX) do it like this. -echo 'include confinc.mk # ignored' > confmf.GNU -_am_result=no -for s in GNU BSD; do - AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) - AS_CASE([$?:`cat confinc.out 2>/dev/null`], - ['0:this is the am__doit target'], - [AS_CASE([$s], - [BSD], [am__include='.include' am__quote='"'], - [am__include='include' am__quote=''])]) - if test "$am__include" != "#"; then - _am_result="yes ($s style)" - break - fi -done -rm -f confinc.* confmf.* -AC_MSG_RESULT([${_am_result}]) -AC_SUBST([am__include])]) -AC_SUBST([am__quote])]) - -# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- - -# Copyright (C) 1997-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_MISSING_PROG(NAME, PROGRAM) -# ------------------------------ -AC_DEFUN([AM_MISSING_PROG], -[AC_REQUIRE([AM_MISSING_HAS_RUN]) -$1=${$1-"${am_missing_run}$2"} -AC_SUBST($1)]) - -# AM_MISSING_HAS_RUN -# ------------------ -# Define MISSING if not defined so far and test if it is modern enough. -# If it is, set am_missing_run to use it, otherwise, to nothing. -AC_DEFUN([AM_MISSING_HAS_RUN], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([missing])dnl -if test x"${MISSING+set}" != xset; then - MISSING="\${SHELL} '$am_aux_dir/missing'" -fi -# Use eval to expand $SHELL -if eval "$MISSING --is-lightweight"; then - am_missing_run="$MISSING " -else - am_missing_run= - AC_MSG_WARN(['missing' script is too old or missing]) -fi -]) - -# Helper functions for option handling. -*- Autoconf -*- - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# _AM_MANGLE_OPTION(NAME) -# ----------------------- -AC_DEFUN([_AM_MANGLE_OPTION], -[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) - -# _AM_SET_OPTION(NAME) -# -------------------- -# Set option NAME. Presently that only means defining a flag for this option. -AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) - -# _AM_SET_OPTIONS(OPTIONS) -# ------------------------ -# OPTIONS is a space-separated list of Automake options. -AC_DEFUN([_AM_SET_OPTIONS], -[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) - -# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) -# ------------------------------------------- -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -AC_DEFUN([_AM_IF_OPTION], -[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) - -# Copyright (C) 1999-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# _AM_PROG_CC_C_O -# --------------- -# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC -# to automatically call this. -AC_DEFUN([_AM_PROG_CC_C_O], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([compile])dnl -AC_LANG_PUSH([C])dnl -AC_CACHE_CHECK( - [whether $CC understands -c and -o together], - [am_cv_prog_cc_c_o], - [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) - # Make sure it works both with $CC and with simple cc. - # Following AC_PROG_CC_C_O, we do the test twice because some - # compilers refuse to overwrite an existing .o file with -o, - # though they will create one. - am_cv_prog_cc_c_o=yes - for am_i in 1 2; do - if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ - && test -f conftest2.$ac_objext; then - : OK - else - am_cv_prog_cc_c_o=no - break - fi - done - rm -f core conftest* - unset am_i]) -if test "$am_cv_prog_cc_c_o" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -AC_LANG_POP([C])]) - -# For backward compatibility. -AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) - -# Copyright (C) 1999-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - - -# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) -# --------------------------------------------------------------------------- -# Adds support for distributing Python modules and packages. To -# install modules, copy them to $(pythondir), using the python_PYTHON -# automake variable. To install a package with the same name as the -# automake package, install to $(pkgpythondir), or use the -# pkgpython_PYTHON automake variable. -# -# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as -# locations to install python extension modules (shared libraries). -# Another macro is required to find the appropriate flags to compile -# extension modules. -# -# If your package is configured with a different prefix to python, -# users will have to add the install directory to the PYTHONPATH -# environment variable, or create a .pth file (see the python -# documentation for details). -# -# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will -# cause an error if the version of python installed on the system -# doesn't meet the requirement. MINIMUM-VERSION should consist of -# numbers and dots only. -AC_DEFUN([AM_PATH_PYTHON], - [ - dnl Find a Python interpreter. Python versions prior to 2.0 are not - dnl supported. (2.0 was released on October 16, 2000). - m4_define_default([_AM_PYTHON_INTERPRETER_LIST], -[python python2 python3 dnl - python3.9 python3.8 python3.7 python3.6 python3.5 python3.4 python3.3 dnl - python3.2 python3.1 python3.0 dnl - python2.7 python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 dnl - python2.0]) - - AC_ARG_VAR([PYTHON], [the Python interpreter]) - - m4_if([$1],[],[ - dnl No version check is needed. - # Find any Python interpreter. - if test -z "$PYTHON"; then - AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :) - fi - am_display_PYTHON=python - ], [ - dnl A version check is needed. - if test -n "$PYTHON"; then - # If the user set $PYTHON, use it and don't search something else. - AC_MSG_CHECKING([whether $PYTHON version is >= $1]) - AM_PYTHON_CHECK_VERSION([$PYTHON], [$1], - [AC_MSG_RESULT([yes])], - [AC_MSG_RESULT([no]) - AC_MSG_ERROR([Python interpreter is too old])]) - am_display_PYTHON=$PYTHON - else - # Otherwise, try each interpreter until we find one that satisfies - # VERSION. - AC_CACHE_CHECK([for a Python interpreter with version >= $1], - [am_cv_pathless_PYTHON],[ - for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do - test "$am_cv_pathless_PYTHON" = none && break - AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break]) - done]) - # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON. - if test "$am_cv_pathless_PYTHON" = none; then - PYTHON=: - else - AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON]) - fi - am_display_PYTHON=$am_cv_pathless_PYTHON - fi - ]) - - if test "$PYTHON" = :; then - dnl Run any user-specified action, or abort. - m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])]) - else - - dnl Query Python for its version number. Although site.py simply uses - dnl sys.version[:3], printing that failed with Python 3.10, since the - dnl trailing zero was eliminated. So now we output just the major - dnl and minor version numbers, as numbers. Apparently the tertiary - dnl version is not of interest. - dnl - AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version], - [am_cv_python_version=`$PYTHON -c "import sys; print ('%u.%u' % sys.version_info[[:2]])"`]) - AC_SUBST([PYTHON_VERSION], [$am_cv_python_version]) - - dnl At times, e.g., when building shared libraries, you may want - dnl to know which OS platform Python thinks this is. - dnl - AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform], - [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`]) - AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform]) - - dnl emacs-page - dnl If --with-python-sys-prefix is given, use the values of sys.prefix - dnl and sys.exec_prefix for the corresponding values of PYTHON_PREFIX - dnl and PYTHON_EXEC_PREFIX. Otherwise, use the GNU ${prefix} and - dnl ${exec_prefix} variables. - dnl - dnl The two are made distinct variables so they can be overridden if - dnl need be, although general consensus is that you shouldn't need - dnl this separation. - dnl - dnl Also allow directly setting the prefixes via configure options, - dnl overriding any default. - dnl - if test "x$prefix" = xNONE; then - am__usable_prefix=$ac_default_prefix - else - am__usable_prefix=$prefix - fi - - # Allow user to request using sys.* values from Python, - # instead of the GNU $prefix values. - AC_ARG_WITH([python-sys-prefix], - [AS_HELP_STRING([--with-python-sys-prefix], - [use Python's sys.prefix and sys.exec_prefix values])], - [am_use_python_sys=:], - [am_use_python_sys=false]) - - # Allow user to override whatever the default Python prefix is. - AC_ARG_WITH([python_prefix], - [AS_HELP_STRING([--with-python_prefix], - [override the default PYTHON_PREFIX])], - [am_python_prefix_subst=$withval - am_cv_python_prefix=$withval - AC_MSG_CHECKING([for explicit $am_display_PYTHON prefix]) - AC_MSG_RESULT([$am_cv_python_prefix])], - [ - if $am_use_python_sys; then - # using python sys.prefix value, not GNU - AC_CACHE_CHECK([for python default $am_display_PYTHON prefix], - [am_cv_python_prefix], - [am_cv_python_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.prefix)"`]) - - dnl If sys.prefix is a subdir of $prefix, replace the literal value of - dnl $prefix with a variable reference so it can be overridden. - case $am_cv_python_prefix in - $am__usable_prefix*) - am__strip_prefix=`echo "$am__usable_prefix" | sed 's|.|.|g'` - am_python_prefix_subst=`echo "$am_cv_python_prefix" | sed "s,^$am__strip_prefix,\\${prefix},"` - ;; - *) - am_python_prefix_subst=$am_cv_python_prefix - ;; - esac - else # using GNU prefix value, not python sys.prefix - am_python_prefix_subst='${prefix}' - am_python_prefix=$am_python_prefix_subst - AC_MSG_CHECKING([for GNU default $am_display_PYTHON prefix]) - AC_MSG_RESULT([$am_python_prefix]) - fi]) - # Substituting python_prefix_subst value. - AC_SUBST([PYTHON_PREFIX], [$am_python_prefix_subst]) - - # emacs-page Now do it all over again for Python exec_prefix, but with yet - # another conditional: fall back to regular prefix if that was specified. - AC_ARG_WITH([python_exec_prefix], - [AS_HELP_STRING([--with-python_exec_prefix], - [override the default PYTHON_EXEC_PREFIX])], - [am_python_exec_prefix_subst=$withval - am_cv_python_exec_prefix=$withval - AC_MSG_CHECKING([for explicit $am_display_PYTHON exec_prefix]) - AC_MSG_RESULT([$am_cv_python_exec_prefix])], - [ - # no explicit --with-python_exec_prefix, but if - # --with-python_prefix was given, use its value for python_exec_prefix too. - AS_IF([test -n "$with_python_prefix"], - [am_python_exec_prefix_subst=$with_python_prefix - am_cv_python_exec_prefix=$with_python_prefix - AC_MSG_CHECKING([for python_prefix-given $am_display_PYTHON exec_prefix]) - AC_MSG_RESULT([$am_cv_python_exec_prefix])], - [ - # Set am__usable_exec_prefix whether using GNU or Python values, - # since we use that variable for pyexecdir. - if test "x$exec_prefix" = xNONE; then - am__usable_exec_prefix=$am__usable_prefix - else - am__usable_exec_prefix=$exec_prefix - fi - # - if $am_use_python_sys; then # using python sys.exec_prefix, not GNU - AC_CACHE_CHECK([for python default $am_display_PYTHON exec_prefix], - [am_cv_python_exec_prefix], - [am_cv_python_exec_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.exec_prefix)"`]) - dnl If sys.exec_prefix is a subdir of $exec_prefix, replace the - dnl literal value of $exec_prefix with a variable reference so it can - dnl be overridden. - case $am_cv_python_exec_prefix in - $am__usable_exec_prefix*) - am__strip_prefix=`echo "$am__usable_exec_prefix" | sed 's|.|.|g'` - am_python_exec_prefix_subst=`echo "$am_cv_python_exec_prefix" | sed "s,^$am__strip_prefix,\\${exec_prefix},"` - ;; - *) - am_python_exec_prefix_subst=$am_cv_python_exec_prefix - ;; - esac - else # using GNU $exec_prefix, not python sys.exec_prefix - am_python_exec_prefix_subst='${exec_prefix}' - am_python_exec_prefix=$am_python_exec_prefix_subst - AC_MSG_CHECKING([for GNU default $am_display_PYTHON exec_prefix]) - AC_MSG_RESULT([$am_python_exec_prefix]) - fi])]) - # Substituting python_exec_prefix_subst. - AC_SUBST([PYTHON_EXEC_PREFIX], [$am_python_exec_prefix_subst]) - - # Factor out some code duplication into this shell variable. - am_python_setup_sysconfig="\ -import sys -# Prefer sysconfig over distutils.sysconfig, for better compatibility -# with python 3.x. See automake bug#10227. -try: - import sysconfig -except ImportError: - can_use_sysconfig = 0 -else: - can_use_sysconfig = 1 -# Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs: -# -try: - from platform import python_implementation - if python_implementation() == 'CPython' and sys.version[[:3]] == '2.7': - can_use_sysconfig = 0 -except ImportError: - pass" - - dnl emacs-page Set up 4 directories: - - dnl 1. pythondir: where to install python scripts. This is the - dnl site-packages directory, not the python standard library - dnl directory like in previous automake betas. This behavior - dnl is more consistent with lispdir.m4 for example. - dnl Query distutils for this directory. - dnl - AC_CACHE_CHECK([for $am_display_PYTHON script directory (pythondir)], - [am_cv_python_pythondir], - [if test "x$am_cv_python_prefix" = x; then - am_py_prefix=$am__usable_prefix - else - am_py_prefix=$am_cv_python_prefix - fi - am_cv_python_pythondir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix') -sys.stdout.write(sitedir)"` - # - case $am_cv_python_pythondir in - $am_py_prefix*) - am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'` - am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,\\${PYTHON_PREFIX},"` - ;; - *) - case $am_py_prefix in - /usr|/System*) ;; - *) am_cv_python_pythondir="\${PYTHON_PREFIX}/lib/python$PYTHON_VERSION/site-packages" - ;; - esac - ;; - esac - ]) - AC_SUBST([pythondir], [$am_cv_python_pythondir]) - - dnl 2. pkgpythondir: $PACKAGE directory under pythondir. Was - dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is - dnl more consistent with the rest of automake. - dnl - AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE]) - - dnl 3. pyexecdir: directory for installing python extension modules - dnl (shared libraries). - dnl Query distutils for this directory. - dnl - AC_CACHE_CHECK([for $am_display_PYTHON extension module directory (pyexecdir)], - [am_cv_python_pyexecdir], - [if test "x$am_cv_python_exec_prefix" = x; then - am_py_exec_prefix=$am__usable_exec_prefix - else - am_py_exec_prefix=$am_cv_python_exec_prefix - fi - am_cv_python_pyexecdir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_exec_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_exec_prefix') -sys.stdout.write(sitedir)"` - # - case $am_cv_python_pyexecdir in - $am_py_exec_prefix*) - am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'` - am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,\\${PYTHON_EXEC_PREFIX},"` - ;; - *) - case $am_py_exec_prefix in - /usr|/System*) ;; - *) am_cv_python_pyexecdir="\${PYTHON_EXEC_PREFIX}/lib/python$PYTHON_VERSION/site-packages" - ;; - esac - ;; - esac - ]) - AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir]) - - dnl 4. pkgpyexecdir: $(pyexecdir)/$(PACKAGE) - dnl - AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE]) - - dnl Run any user-specified action. - $2 - fi -]) - - -# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE]) -# --------------------------------------------------------------------------- -# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION. -# Run ACTION-IF-FALSE otherwise. -# This test uses sys.hexversion instead of the string equivalent (first -# word of sys.version), in order to cope with versions such as 2.2c1. -# This supports Python 2.0 or higher. (2.0 was released on October 16, 2000). -AC_DEFUN([AM_PYTHON_CHECK_VERSION], - [prog="import sys -# split strings by '.' and convert to numeric. Append some zeros -# because we need at least 4 digits for the hex conversion. -# map returns an iterator in Python 3.0 and a list in 2.x -minver = list(map(int, '$2'.split('.'))) + [[0, 0, 0]] -minverhex = 0 -# xrange is not present in Python 3.0 and range returns an iterator -for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[[i]] -sys.exit(sys.hexversion < minverhex)" - AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])]) - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_RUN_LOG(COMMAND) -# ------------------- -# Run COMMAND, save the exit status in ac_status, and log it. -# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) -AC_DEFUN([AM_RUN_LOG], -[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD - ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - (exit $ac_status); }]) - -# Check to make sure that the build environment is sane. -*- Autoconf -*- - -# Copyright (C) 1996-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_SANITY_CHECK -# --------------- -AC_DEFUN([AM_SANITY_CHECK], -[AC_MSG_CHECKING([whether build environment is sane]) -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[[\\\"\#\$\&\'\`$am_lf]]*) - AC_MSG_ERROR([unsafe absolute working directory name]);; -esac -case $srcdir in - *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; -esac - -# Do 'set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken - alias in your environment]) - fi - if test "$[2]" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$[2]" = conftest.file - ) -then - # Ok. - : -else - AC_MSG_ERROR([newly created file is older than distributed files! -Check your system clock]) -fi -AC_MSG_RESULT([yes]) -# If we didn't sleep, we still need to ensure time stamps of config.status and -# generated files are strictly newer. -am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & - am_sleep_pid=$! -fi -AC_CONFIG_COMMANDS_PRE( - [AC_MSG_CHECKING([that generated files are newer than configure]) - if test -n "$am_sleep_pid"; then - # Hide warnings about reused PIDs. - wait $am_sleep_pid 2>/dev/null - fi - AC_MSG_RESULT([done])]) -rm -f conftest.file -]) - -# Copyright (C) 2009-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_SILENT_RULES([DEFAULT]) -# -------------------------- -# Enable less verbose build rules; with the default set to DEFAULT -# ("yes" being less verbose, "no" or empty being verbose). -AC_DEFUN([AM_SILENT_RULES], -[AC_ARG_ENABLE([silent-rules], [dnl -AS_HELP_STRING( - [--enable-silent-rules], - [less verbose build output (undo: "make V=1")]) -AS_HELP_STRING( - [--disable-silent-rules], - [verbose build output (undo: "make V=0")])dnl -]) -case $enable_silent_rules in @%:@ ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; -esac -dnl -dnl A few 'make' implementations (e.g., NonStop OS and NextStep) -dnl do not support nested variable expansions. -dnl See automake bug#9928 and bug#10237. -am_make=${MAKE-make} -AC_CACHE_CHECK([whether $am_make supports nested variables], - [am_cv_make_support_nested_variables], - [if AS_ECHO([['TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi]) -if test $am_cv_make_support_nested_variables = yes; then - dnl Using '$V' instead of '$(V)' breaks IRIX make. - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AC_SUBST([AM_V])dnl -AM_SUBST_NOTMAKE([AM_V])dnl -AC_SUBST([AM_DEFAULT_V])dnl -AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl -AC_SUBST([AM_DEFAULT_VERBOSITY])dnl -AM_BACKSLASH='\' -AC_SUBST([AM_BACKSLASH])dnl -_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl -]) - -# Copyright (C) 2001-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# AM_PROG_INSTALL_STRIP -# --------------------- -# One issue with vendor 'install' (even GNU) is that you can't -# specify the program used to strip binaries. This is especially -# annoying in cross-compiling environments, where the build's strip -# is unlikely to handle the host's binaries. -# Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in "make install-strip", and initialize -# STRIPPROG with the value of the STRIP variable (set by the user). -AC_DEFUN([AM_PROG_INSTALL_STRIP], -[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using 'strip' when the user -# run "make install-strip". However 'strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the 'STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. -if test "$cross_compiling" != no; then - AC_CHECK_TOOL([STRIP], [strip], :) -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" -AC_SUBST([INSTALL_STRIP_PROGRAM])]) - -# Copyright (C) 2006-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# _AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- -# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. -# This macro is traced by Automake. -AC_DEFUN([_AM_SUBST_NOTMAKE]) - -# AM_SUBST_NOTMAKE(VARIABLE) -# -------------------------- -# Public sister of _AM_SUBST_NOTMAKE. -AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) - -# Check how to create a tarball. -*- Autoconf -*- - -# Copyright (C) 2004-2021 Free Software Foundation, Inc. -# -# This file is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# _AM_PROG_TAR(FORMAT) -# -------------------- -# Check how to create a tarball in format FORMAT. -# FORMAT should be one of 'v7', 'ustar', or 'pax'. -# -# Substitute a variable $(am__tar) that is a command -# writing to stdout a FORMAT-tarball containing the directory -# $tardir. -# tardir=directory && $(am__tar) > result.tar -# -# Substitute a variable $(am__untar) that extract such -# a tarball read from stdin. -# $(am__untar) < result.tar -# -AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. Yes, it's still used -# in the wild :-( We should find a proper way to deprecate it ... -AC_SUBST([AMTAR], ['$${TAR-tar}']) - -# We'll loop over all known methods to create a tar archive until one works. -_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' - -m4_if([$1], [v7], - [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], - - [m4_case([$1], - [ustar], - [# The POSIX 1988 'ustar' format is defined with fixed-size fields. - # There is notably a 21 bits limit for the UID and the GID. In fact, - # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 - # and bug#13588). - am_max_uid=2097151 # 2^21 - 1 - am_max_gid=$am_max_uid - # The $UID and $GID variables are not portable, so we need to resort - # to the POSIX-mandated id(1) utility. Errors in the 'id' calls - # below are definitely unexpected, so allow the users to see them - # (that is, avoid stderr redirection). - am_uid=`id -u || echo unknown` - am_gid=`id -g || echo unknown` - AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) - if test $am_uid -le $am_max_uid; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - _am_tools=none - fi - AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) - if test $am_gid -le $am_max_gid; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - _am_tools=none - fi], - - [pax], - [], - - [m4_fatal([Unknown tar format])]) - - AC_MSG_CHECKING([how to create a $1 tar archive]) - - # Go ahead even if we have the value already cached. We do so because we - # need to set the values for the 'am__tar' and 'am__untar' variables. - _am_tools=${am_cv_prog_tar_$1-$_am_tools} - - for _am_tool in $_am_tools; do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac - - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break - - # tar/untar a dummy directory, and stop if the command works. - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) - rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi - done - rm -rf conftest.dir - - AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) - AC_MSG_RESULT([$am_cv_prog_tar_$1])]) - -AC_SUBST([am__tar]) -AC_SUBST([am__untar]) -]) # _AM_PROG_TAR - -m4_include([m4/ax_code_coverage.m4]) -m4_include([m4/libtool.m4]) -m4_include([m4/ltoptions.m4]) -m4_include([m4/ltsugar.m4]) -m4_include([m4/ltversion.m4]) -m4_include([m4/lt~obsolete.m4]) diff --git a/lib/libcgroup-3.1.0/build-aux/ar-lib b/lib/libcgroup-3.1.0/build-aux/ar-lib deleted file mode 100755 index c349042c3fa..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/ar-lib +++ /dev/null @@ -1,271 +0,0 @@ -#! /bin/sh -# Wrapper for Microsoft lib.exe - -me=ar-lib -scriptversion=2019-07-04.01; # UTC - -# Copyright (C) 2010-2021 Free Software Foundation, Inc. -# Written by Peter Rosin . -# -# 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, or (at your option) -# any later version. -# -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - - -# func_error message -func_error () -{ - echo "$me: $1" 1>&2 - exit 1 -} - -file_conv= - -# func_file_conv build_file -# Convert a $build file to $host form and store it in $file -# Currently only supports Windows hosts. -func_file_conv () -{ - file=$1 - case $file in - / | /[!/]*) # absolute file, and not a UNC file - if test -z "$file_conv"; then - # lazily determine how to convert abs files - case `uname -s` in - MINGW*) - file_conv=mingw - ;; - CYGWIN* | MSYS*) - file_conv=cygwin - ;; - *) - file_conv=wine - ;; - esac - fi - case $file_conv in - mingw) - file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` - ;; - cygwin | msys) - file=`cygpath -m "$file" || echo "$file"` - ;; - wine) - file=`winepath -w "$file" || echo "$file"` - ;; - esac - ;; - esac -} - -# func_at_file at_file operation archive -# Iterate over all members in AT_FILE performing OPERATION on ARCHIVE -# for each of them. -# When interpreting the content of the @FILE, do NOT use func_file_conv, -# since the user would need to supply preconverted file names to -# binutils ar, at least for MinGW. -func_at_file () -{ - operation=$2 - archive=$3 - at_file_contents=`cat "$1"` - eval set x "$at_file_contents" - shift - - for member - do - $AR -NOLOGO $operation:"$member" "$archive" || exit $? - done -} - -case $1 in - '') - func_error "no command. Try '$0 --help' for more information." - ;; - -h | --h*) - cat <. -# -# 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, or (at your option) -# any later version. -# -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -nl=' -' - -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent tools from complaining about whitespace usage. -IFS=" "" $nl" - -file_conv= - -# func_file_conv build_file lazy -# Convert a $build file to $host form and store it in $file -# Currently only supports Windows hosts. If the determined conversion -# type is listed in (the comma separated) LAZY, no conversion will -# take place. -func_file_conv () -{ - file=$1 - case $file in - / | /[!/]*) # absolute file, and not a UNC file - if test -z "$file_conv"; then - # lazily determine how to convert abs files - case `uname -s` in - MINGW*) - file_conv=mingw - ;; - CYGWIN* | MSYS*) - file_conv=cygwin - ;; - *) - file_conv=wine - ;; - esac - fi - case $file_conv/,$2, in - *,$file_conv,*) - ;; - mingw/*) - file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` - ;; - cygwin/* | msys/*) - file=`cygpath -m "$file" || echo "$file"` - ;; - wine/*) - file=`winepath -w "$file" || echo "$file"` - ;; - esac - ;; - esac -} - -# func_cl_dashL linkdir -# Make cl look for libraries in LINKDIR -func_cl_dashL () -{ - func_file_conv "$1" - if test -z "$lib_path"; then - lib_path=$file - else - lib_path="$lib_path;$file" - fi - linker_opts="$linker_opts -LIBPATH:$file" -} - -# func_cl_dashl library -# Do a library search-path lookup for cl -func_cl_dashl () -{ - lib=$1 - found=no - save_IFS=$IFS - IFS=';' - for dir in $lib_path $LIB - do - IFS=$save_IFS - if $shared && test -f "$dir/$lib.dll.lib"; then - found=yes - lib=$dir/$lib.dll.lib - break - fi - if test -f "$dir/$lib.lib"; then - found=yes - lib=$dir/$lib.lib - break - fi - if test -f "$dir/lib$lib.a"; then - found=yes - lib=$dir/lib$lib.a - break - fi - done - IFS=$save_IFS - - if test "$found" != yes; then - lib=$lib.lib - fi -} - -# func_cl_wrapper cl arg... -# Adjust compile command to suit cl -func_cl_wrapper () -{ - # Assume a capable shell - lib_path= - shared=: - linker_opts= - for arg - do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - eat=1 - case $2 in - *.o | *.[oO][bB][jJ]) - func_file_conv "$2" - set x "$@" -Fo"$file" - shift - ;; - *) - func_file_conv "$2" - set x "$@" -Fe"$file" - shift - ;; - esac - ;; - -I) - eat=1 - func_file_conv "$2" mingw - set x "$@" -I"$file" - shift - ;; - -I*) - func_file_conv "${1#-I}" mingw - set x "$@" -I"$file" - shift - ;; - -l) - eat=1 - func_cl_dashl "$2" - set x "$@" "$lib" - shift - ;; - -l*) - func_cl_dashl "${1#-l}" - set x "$@" "$lib" - shift - ;; - -L) - eat=1 - func_cl_dashL "$2" - ;; - -L*) - func_cl_dashL "${1#-L}" - ;; - -static) - shared=false - ;; - -Wl,*) - arg=${1#-Wl,} - save_ifs="$IFS"; IFS=',' - for flag in $arg; do - IFS="$save_ifs" - linker_opts="$linker_opts $flag" - done - IFS="$save_ifs" - ;; - -Xlinker) - eat=1 - linker_opts="$linker_opts $2" - ;; - -*) - set x "$@" "$1" - shift - ;; - *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) - func_file_conv "$1" - set x "$@" -Tp"$file" - shift - ;; - *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) - func_file_conv "$1" mingw - set x "$@" "$file" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift - done - if test -n "$linker_opts"; then - linker_opts="-link$linker_opts" - fi - exec "$@" $linker_opts - exit 1 -} - -eat= - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: compile [--help] [--version] PROGRAM [ARGS] - -Wrapper for compilers which do not understand '-c -o'. -Remove '-o dest.o' from ARGS, run PROGRAM with the remaining -arguments, and rename the output as expected. - -If you are trying to build a whole package this is not the -right script to run: please start by reading the file 'INSTALL'. - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "compile $scriptversion" - exit $? - ;; - cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \ - icl | *[/\\]icl | icl.exe | *[/\\]icl.exe ) - func_cl_wrapper "$@" # Doesn't return... - ;; -esac - -ofile= -cfile= - -for arg -do - if test -n "$eat"; then - eat= - else - case $1 in - -o) - # configure might choose to run compile as 'compile cc -o foo foo.c'. - # So we strip '-o arg' only if arg is an object. - eat=1 - case $2 in - *.o | *.obj) - ofile=$2 - ;; - *) - set x "$@" -o "$2" - shift - ;; - esac - ;; - *.c) - cfile=$1 - set x "$@" "$1" - shift - ;; - *) - set x "$@" "$1" - shift - ;; - esac - fi - shift -done - -if test -z "$ofile" || test -z "$cfile"; then - # If no '-o' option was seen then we might have been invoked from a - # pattern rule where we don't need one. That is ok -- this is a - # normal compilation that the losing compiler can handle. If no - # '.c' file was seen then we are probably linking. That is also - # ok. - exec "$@" -fi - -# Name of file we expect compiler to create. -cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` - -# Create the lock directory. -# Note: use '[/\\:.-]' here to ensure that we don't use the same name -# that we are using for the .o file. Also, base the name on the expected -# object file name, since that is what matters with a parallel build. -lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d -while true; do - if mkdir "$lockdir" >/dev/null 2>&1; then - break - fi - sleep 1 -done -# FIXME: race condition here if user kills between mkdir and trap. -trap "rmdir '$lockdir'; exit 1" 1 2 15 - -# Run the compile. -"$@" -ret=$? - -if test -f "$cofile"; then - test "$cofile" = "$ofile" || mv "$cofile" "$ofile" -elif test -f "${cofile}bj"; then - test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" -fi - -rmdir "$lockdir" -exit $ret - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/config.guess b/lib/libcgroup-3.1.0/build-aux/config.guess deleted file mode 100755 index c7f17e8fb97..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/config.guess +++ /dev/null @@ -1,1768 +0,0 @@ -#!/usr/bin/sh -# Attempt to guess a canonical system name. -# Copyright 1992-2022 Free Software Foundation, Inc. - -# shellcheck disable=SC2006,SC2268 # see below for rationale - -timestamp='2022-05-25' - -# This file 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 3 of the License, or -# (at your option) any later version. -# -# 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, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). -# -# Originally written by Per Bothner; maintained since 2000 by Ben Elliston. -# -# You can get the latest version of this script from: -# https://git.savannah.gnu.org/cgit/config.git/plain/config.guess -# -# Please send patches to . - - -# The "shellcheck disable" line above the timestamp inhibits complaints -# about features and limitations of the classic Bourne shell that were -# superseded or lifted in POSIX. However, this script identifies a wide -# variety of pre-POSIX systems that do not have POSIX shells at all, and -# even some reasonably current systems (Solaris 10 as case-in-point) still -# have a pre-POSIX /bin/sh. - - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] - -Output the configuration name of the system \`$me' is run on. - -Options: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.guess ($timestamp) - -Originally written by Per Bothner. -Copyright 1992-2022 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" >&2 - exit 1 ;; - * ) - break ;; - esac -done - -if test $# != 0; then - echo "$me: too many arguments$help" >&2 - exit 1 -fi - -# Just in case it came from the environment. -GUESS= - -# CC_FOR_BUILD -- compiler used by this script. Note that the use of a -# compiler to aid in system detection is discouraged as it requires -# temporary files to be created and, as you can see below, it is a -# headache to deal with in a portable fashion. - -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. - -# Portable tmp directory creation inspired by the Autoconf team. - -tmp= -# shellcheck disable=SC2172 -trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15 - -set_cc_for_build() { - # prevent multiple calls if $tmp is already set - test "$tmp" && return 0 - : "${TMPDIR=/tmp}" - # shellcheck disable=SC2039,SC3028 - { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || - { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || - { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || - { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } - dummy=$tmp/dummy - case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in - ,,) echo "int x;" > "$dummy.c" - for driver in cc gcc c89 c99 ; do - if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then - CC_FOR_BUILD=$driver - break - fi - done - if test x"$CC_FOR_BUILD" = x ; then - CC_FOR_BUILD=no_compiler_found - fi - ;; - ,,*) CC_FOR_BUILD=$CC ;; - ,*,*) CC_FOR_BUILD=$HOST_CC ;; - esac -} - -# This is needed to find uname on a Pyramid OSx when run in the BSD universe. -# (ghazi@noc.rutgers.edu 1994-08-24) -if test -f /.attbin/uname ; then - PATH=$PATH:/.attbin ; export PATH -fi - -UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown -UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown -UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown - -case $UNAME_SYSTEM in -Linux|GNU|GNU/*) - LIBC=unknown - - set_cc_for_build - cat <<-EOF > "$dummy.c" - #include - #if defined(__UCLIBC__) - LIBC=uclibc - #elif defined(__dietlibc__) - LIBC=dietlibc - #elif defined(__GLIBC__) - LIBC=gnu - #else - #include - /* First heuristic to detect musl libc. */ - #ifdef __DEFINED_va_list - LIBC=musl - #endif - #endif - EOF - cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` - eval "$cc_set_libc" - - # Second heuristic to detect musl libc. - if [ "$LIBC" = unknown ] && - command -v ldd >/dev/null && - ldd --version 2>&1 | grep -q ^musl; then - LIBC=musl - fi - - # If the system lacks a compiler, then just pick glibc. - # We could probably try harder. - if [ "$LIBC" = unknown ]; then - LIBC=gnu - fi - ;; -esac - -# Note: order is significant - the case branches are not exclusive. - -case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in - *:NetBSD:*:*) - # NetBSD (nbsd) targets should (where applicable) match one or - # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, - # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently - # switched to ELF, *-*-netbsd* would select the old - # object file format. This provides both forward - # compatibility and a consistent mechanism for selecting the - # object file format. - # - # Note: NetBSD doesn't particularly care about the vendor - # portion of the name. We always set it to "unknown". - UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ - /sbin/sysctl -n hw.machine_arch 2>/dev/null || \ - /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \ - echo unknown)` - case $UNAME_MACHINE_ARCH in - aarch64eb) machine=aarch64_be-unknown ;; - armeb) machine=armeb-unknown ;; - arm*) machine=arm-unknown ;; - sh3el) machine=shl-unknown ;; - sh3eb) machine=sh-unknown ;; - sh5el) machine=sh5le-unknown ;; - earmv*) - arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` - endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` - machine=${arch}${endian}-unknown - ;; - *) machine=$UNAME_MACHINE_ARCH-unknown ;; - esac - # The Operating System including object format, if it has switched - # to ELF recently (or will in the future) and ABI. - case $UNAME_MACHINE_ARCH in - earm*) - os=netbsdelf - ;; - arm*|i386|m68k|ns32k|sh3*|sparc|vax) - set_cc_for_build - if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ELF__ - then - # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). - # Return netbsd for either. FIX? - os=netbsd - else - os=netbsdelf - fi - ;; - *) - os=netbsd - ;; - esac - # Determine ABI tags. - case $UNAME_MACHINE_ARCH in - earm*) - expr='s/^earmv[0-9]/-eabi/;s/eb$//' - abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` - ;; - esac - # The OS release - # Debian GNU/NetBSD machines have a different userland, and - # thus, need a distinct triplet. However, they do not need - # kernel version information, so it can be replaced with a - # suitable tag, in the style of linux-gnu. - case $UNAME_VERSION in - Debian*) - release='-gnu' - ;; - *) - release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` - ;; - esac - # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: - # contains redundant information, the shorter form: - # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - GUESS=$machine-${os}${release}${abi-} - ;; - *:Bitrig:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE - ;; - *:OpenBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE - ;; - *:SecBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'` - GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE - ;; - *:LibertyBSD:*:*) - UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` - GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE - ;; - *:MidnightBSD:*:*) - GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE - ;; - *:ekkoBSD:*:*) - GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE - ;; - *:SolidBSD:*:*) - GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE - ;; - *:OS108:*:*) - GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE - ;; - macppc:MirBSD:*:*) - GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE - ;; - *:MirBSD:*:*) - GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE - ;; - *:Sortix:*:*) - GUESS=$UNAME_MACHINE-unknown-sortix - ;; - *:Twizzler:*:*) - GUESS=$UNAME_MACHINE-unknown-twizzler - ;; - *:Redox:*:*) - GUESS=$UNAME_MACHINE-unknown-redox - ;; - mips:OSF1:*.*) - GUESS=mips-dec-osf1 - ;; - alpha:OSF1:*:*) - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - trap '' 0 - case $UNAME_RELEASE in - *4.0) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` - ;; - *5.*) - UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` - ;; - esac - # According to Compaq, /usr/sbin/psrinfo has been available on - # OSF/1 and Tru64 systems produced since 1995. I hope that - # covers most systems running today. This code pipes the CPU - # types through head -n 1, so we only detect the type of CPU 0. - ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` - case $ALPHA_CPU_TYPE in - "EV4 (21064)") - UNAME_MACHINE=alpha ;; - "EV4.5 (21064)") - UNAME_MACHINE=alpha ;; - "LCA4 (21066/21068)") - UNAME_MACHINE=alpha ;; - "EV5 (21164)") - UNAME_MACHINE=alphaev5 ;; - "EV5.6 (21164A)") - UNAME_MACHINE=alphaev56 ;; - "EV5.6 (21164PC)") - UNAME_MACHINE=alphapca56 ;; - "EV5.7 (21164PC)") - UNAME_MACHINE=alphapca57 ;; - "EV6 (21264)") - UNAME_MACHINE=alphaev6 ;; - "EV6.7 (21264A)") - UNAME_MACHINE=alphaev67 ;; - "EV6.8CB (21264C)") - UNAME_MACHINE=alphaev68 ;; - "EV6.8AL (21264B)") - UNAME_MACHINE=alphaev68 ;; - "EV6.8CX (21264D)") - UNAME_MACHINE=alphaev68 ;; - "EV6.9A (21264/EV69A)") - UNAME_MACHINE=alphaev69 ;; - "EV7 (21364)") - UNAME_MACHINE=alphaev7 ;; - "EV7.9 (21364A)") - UNAME_MACHINE=alphaev79 ;; - esac - # A Pn.n version is a patched version. - # A Vn.n version is a released version. - # A Tn.n version is a released field test version. - # A Xn.n version is an unreleased experimental baselevel. - # 1.2 uses "1.2" for uname -r. - OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` - GUESS=$UNAME_MACHINE-dec-osf$OSF_REL - ;; - Amiga*:UNIX_System_V:4.0:*) - GUESS=m68k-unknown-sysv4 - ;; - *:[Aa]miga[Oo][Ss]:*:*) - GUESS=$UNAME_MACHINE-unknown-amigaos - ;; - *:[Mm]orph[Oo][Ss]:*:*) - GUESS=$UNAME_MACHINE-unknown-morphos - ;; - *:OS/390:*:*) - GUESS=i370-ibm-openedition - ;; - *:z/VM:*:*) - GUESS=s390-ibm-zvmoe - ;; - *:OS400:*:*) - GUESS=powerpc-ibm-os400 - ;; - arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - GUESS=arm-acorn-riscix$UNAME_RELEASE - ;; - arm*:riscos:*:*|arm*:RISCOS:*:*) - GUESS=arm-unknown-riscos - ;; - SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - GUESS=hppa1.1-hitachi-hiuxmpp - ;; - Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) - # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - case `(/bin/universe) 2>/dev/null` in - att) GUESS=pyramid-pyramid-sysv3 ;; - *) GUESS=pyramid-pyramid-bsd ;; - esac - ;; - NILE*:*:*:dcosx) - GUESS=pyramid-pyramid-svr4 - ;; - DRS?6000:unix:4.0:6*) - GUESS=sparc-icl-nx6 - ;; - DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) - case `/usr/bin/uname -p` in - sparc) GUESS=sparc-icl-nx7 ;; - esac - ;; - s390x:SunOS:*:*) - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL - ;; - sun4H:SunOS:5.*:*) - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=sparc-hal-solaris2$SUN_REL - ;; - sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=sparc-sun-solaris2$SUN_REL - ;; - i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - GUESS=i386-pc-auroraux$UNAME_RELEASE - ;; - i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - set_cc_for_build - SUN_ARCH=i386 - # If there is a compiler, see if it is configured for 64-bit objects. - # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. - # This test works for both compilers. - if test "$CC_FOR_BUILD" != no_compiler_found; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -m64 -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - SUN_ARCH=x86_64 - fi - fi - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=$SUN_ARCH-pc-solaris2$SUN_REL - ;; - sun4*:SunOS:6*:*) - # According to config.sub, this is the proper way to canonicalize - # SunOS6. Hard to guess exactly what SunOS6 will be like, but - # it's likely to be more like Solaris than SunOS4. - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=sparc-sun-solaris3$SUN_REL - ;; - sun4*:SunOS:*:*) - case `/usr/bin/arch -k` in - Series*|S4*) - UNAME_RELEASE=`uname -v` - ;; - esac - # Japanese Language versions have a version number like `4.1.3-JL'. - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` - GUESS=sparc-sun-sunos$SUN_REL - ;; - sun3*:SunOS:*:*) - GUESS=m68k-sun-sunos$UNAME_RELEASE - ;; - sun*:*:4.2BSD:*) - UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` - test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 - case `/bin/arch` in - sun3) - GUESS=m68k-sun-sunos$UNAME_RELEASE - ;; - sun4) - GUESS=sparc-sun-sunos$UNAME_RELEASE - ;; - esac - ;; - aushp:SunOS:*:*) - GUESS=sparc-auspex-sunos$UNAME_RELEASE - ;; - # The situation for MiNT is a little confusing. The machine name - # can be virtually everything (everything which is not - # "atarist" or "atariste" at least should have a processor - # > m68000). The system name ranges from "MiNT" over "FreeMiNT" - # to the lowercase version "mint" (or "freemint"). Finally - # the system name "TOS" denotes a system which is actually not - # MiNT. But MiNT is downward compatible to TOS, so this should - # be no problem. - atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - GUESS=m68k-atari-mint$UNAME_RELEASE - ;; - atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - GUESS=m68k-atari-mint$UNAME_RELEASE - ;; - *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - GUESS=m68k-atari-mint$UNAME_RELEASE - ;; - milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - GUESS=m68k-milan-mint$UNAME_RELEASE - ;; - hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - GUESS=m68k-hades-mint$UNAME_RELEASE - ;; - *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - GUESS=m68k-unknown-mint$UNAME_RELEASE - ;; - m68k:machten:*:*) - GUESS=m68k-apple-machten$UNAME_RELEASE - ;; - powerpc:machten:*:*) - GUESS=powerpc-apple-machten$UNAME_RELEASE - ;; - RISC*:Mach:*:*) - GUESS=mips-dec-mach_bsd4.3 - ;; - RISC*:ULTRIX:*:*) - GUESS=mips-dec-ultrix$UNAME_RELEASE - ;; - VAX*:ULTRIX*:*:*) - GUESS=vax-dec-ultrix$UNAME_RELEASE - ;; - 2020:CLIX:*:* | 2430:CLIX:*:*) - GUESS=clipper-intergraph-clix$UNAME_RELEASE - ;; - mips:*:*:UMIPS | mips:*:*:RISCos) - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" -#ifdef __cplusplus -#include /* for printf() prototype */ - int main (int argc, char *argv[]) { -#else - int main (argc, argv) int argc; char *argv[]; { -#endif - #if defined (host_mips) && defined (MIPSEB) - #if defined (SYSTYPE_SYSV) - printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_SVR4) - printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); - #endif - #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) - printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); - #endif - #endif - exit (-1); - } -EOF - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && - dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && - SYSTEM_NAME=`"$dummy" "$dummyarg"` && - { echo "$SYSTEM_NAME"; exit; } - GUESS=mips-mips-riscos$UNAME_RELEASE - ;; - Motorola:PowerMAX_OS:*:*) - GUESS=powerpc-motorola-powermax - ;; - Motorola:*:4.3:PL8-*) - GUESS=powerpc-harris-powermax - ;; - Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - GUESS=powerpc-harris-powermax - ;; - Night_Hawk:Power_UNIX:*:*) - GUESS=powerpc-harris-powerunix - ;; - m88k:CX/UX:7*:*) - GUESS=m88k-harris-cxux7 - ;; - m88k:*:4*:R4*) - GUESS=m88k-motorola-sysv4 - ;; - m88k:*:3*:R3*) - GUESS=m88k-motorola-sysv3 - ;; - AViiON:dgux:*:*) - # DG/UX returns AViiON for all architectures - UNAME_PROCESSOR=`/usr/bin/uname -p` - if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 - then - if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ - test "$TARGET_BINARY_INTERFACE"x = x - then - GUESS=m88k-dg-dgux$UNAME_RELEASE - else - GUESS=m88k-dg-dguxbcs$UNAME_RELEASE - fi - else - GUESS=i586-dg-dgux$UNAME_RELEASE - fi - ;; - M88*:DolphinOS:*:*) # DolphinOS (SVR3) - GUESS=m88k-dolphin-sysv3 - ;; - M88*:*:R3*:*) - # Delta 88k system running SVR3 - GUESS=m88k-motorola-sysv3 - ;; - XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - GUESS=m88k-tektronix-sysv3 - ;; - Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - GUESS=m68k-tektronix-bsd - ;; - *:IRIX*:*:*) - IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'` - GUESS=mips-sgi-irix$IRIX_REL - ;; - ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id - ;; # Note that: echo "'`uname -s`'" gives 'AIX ' - i*86:AIX:*:*) - GUESS=i386-ibm-aix - ;; - ia64:AIX:*:*) - if test -x /usr/bin/oslevel ; then - IBM_REV=`/usr/bin/oslevel` - else - IBM_REV=$UNAME_VERSION.$UNAME_RELEASE - fi - GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV - ;; - *:AIX:2:3) - if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" - #include - - main() - { - if (!__power_pc()) - exit(1); - puts("powerpc-ibm-aix3.2.5"); - exit(0); - } -EOF - if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` - then - GUESS=$SYSTEM_NAME - else - GUESS=rs6000-ibm-aix3.2.5 - fi - elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - GUESS=rs6000-ibm-aix3.2.4 - else - GUESS=rs6000-ibm-aix3.2 - fi - ;; - *:AIX:*:[4567]) - IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` - if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then - IBM_ARCH=rs6000 - else - IBM_ARCH=powerpc - fi - if test -x /usr/bin/lslpp ; then - IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \ - awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` - else - IBM_REV=$UNAME_VERSION.$UNAME_RELEASE - fi - GUESS=$IBM_ARCH-ibm-aix$IBM_REV - ;; - *:AIX:*:*) - GUESS=rs6000-ibm-aix - ;; - ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) - GUESS=romp-ibm-bsd4.4 - ;; - ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to - ;; # report: romp-ibm BSD 4.3 - *:BOSX:*:*) - GUESS=rs6000-bull-bosx - ;; - DPX/2?00:B.O.S.:*:*) - GUESS=m68k-bull-sysv3 - ;; - 9000/[34]??:4.3bsd:1.*:*) - GUESS=m68k-hp-bsd - ;; - hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - GUESS=m68k-hp-bsd4.4 - ;; - 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` - case $UNAME_MACHINE in - 9000/31?) HP_ARCH=m68000 ;; - 9000/[34]??) HP_ARCH=m68k ;; - 9000/[678][0-9][0-9]) - if test -x /usr/bin/getconf; then - sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` - sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case $sc_cpu_version in - 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 - 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 - 532) # CPU_PA_RISC2_0 - case $sc_kernel_bits in - 32) HP_ARCH=hppa2.0n ;; - 64) HP_ARCH=hppa2.0w ;; - '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 - esac ;; - esac - fi - if test "$HP_ARCH" = ""; then - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" - - #define _HPUX_SOURCE - #include - #include - - int main () - { - #if defined(_SC_KERNEL_BITS) - long bits = sysconf(_SC_KERNEL_BITS); - #endif - long cpu = sysconf (_SC_CPU_VERSION); - - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1"); break; - case CPU_PA_RISC2_0: - #if defined(_SC_KERNEL_BITS) - switch (bits) - { - case 64: puts ("hppa2.0w"); break; - case 32: puts ("hppa2.0n"); break; - default: puts ("hppa2.0"); break; - } break; - #else /* !defined(_SC_KERNEL_BITS) */ - puts ("hppa2.0"); break; - #endif - default: puts ("hppa1.0"); break; - } - exit (0); - } -EOF - (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` - test -z "$HP_ARCH" && HP_ARCH=hppa - fi ;; - esac - if test "$HP_ARCH" = hppa2.0w - then - set_cc_for_build - - # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating - # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler - # generating 64-bit code. GNU and HP use different nomenclature: - # - # $ CC_FOR_BUILD=cc ./config.guess - # => hppa2.0w-hp-hpux11.23 - # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess - # => hppa64-hp-hpux11.23 - - if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | - grep -q __LP64__ - then - HP_ARCH=hppa2.0w - else - HP_ARCH=hppa64 - fi - fi - GUESS=$HP_ARCH-hp-hpux$HPUX_REV - ;; - ia64:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` - GUESS=ia64-hp-hpux$HPUX_REV - ;; - 3050*:HI-UX:*:*) - set_cc_for_build - sed 's/^ //' << EOF > "$dummy.c" - #include - int - main () - { - long cpu = sysconf (_SC_CPU_VERSION); - /* The order matters, because CPU_IS_HP_MC68K erroneously returns - true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct - results, however. */ - if (CPU_IS_PA_RISC (cpu)) - { - switch (cpu) - { - case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; - case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; - case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; - default: puts ("hppa-hitachi-hiuxwe2"); break; - } - } - else if (CPU_IS_HP_MC68K (cpu)) - puts ("m68k-hitachi-hiuxwe2"); - else puts ("unknown-hitachi-hiuxwe2"); - exit (0); - } -EOF - $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && - { echo "$SYSTEM_NAME"; exit; } - GUESS=unknown-hitachi-hiuxwe2 - ;; - 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) - GUESS=hppa1.1-hp-bsd - ;; - 9000/8??:4.3bsd:*:*) - GUESS=hppa1.0-hp-bsd - ;; - *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - GUESS=hppa1.0-hp-mpeix - ;; - hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) - GUESS=hppa1.1-hp-osf - ;; - hp8??:OSF1:*:*) - GUESS=hppa1.0-hp-osf - ;; - i*86:OSF1:*:*) - if test -x /usr/sbin/sysversion ; then - GUESS=$UNAME_MACHINE-unknown-osf1mk - else - GUESS=$UNAME_MACHINE-unknown-osf1 - fi - ;; - parisc*:Lites*:*:*) - GUESS=hppa1.1-hp-lites - ;; - C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - GUESS=c1-convex-bsd - ;; - C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) - if getsysinfo -f scalar_acc - then echo c32-convex-bsd - else echo c2-convex-bsd - fi - exit ;; - C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - GUESS=c34-convex-bsd - ;; - C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - GUESS=c38-convex-bsd - ;; - C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - GUESS=c4-convex-bsd - ;; - CRAY*Y-MP:*:*:*) - CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` - GUESS=ymp-cray-unicos$CRAY_REL - ;; - CRAY*[A-Z]90:*:*:*) - echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ - | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ - -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ - -e 's/\.[^.]*$/.X/' - exit ;; - CRAY*TS:*:*:*) - CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` - GUESS=t90-cray-unicos$CRAY_REL - ;; - CRAY*T3E:*:*:*) - CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` - GUESS=alphaev5-cray-unicosmk$CRAY_REL - ;; - CRAY*SV1:*:*:*) - CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` - GUESS=sv1-cray-unicos$CRAY_REL - ;; - *:UNICOS/mp:*:*) - CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` - GUESS=craynv-cray-unicosmp$CRAY_REL - ;; - F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) - FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` - GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} - ;; - 5000:UNIX_System_V:4.*:*) - FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` - FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` - GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} - ;; - i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE - ;; - sparc*:BSD/OS:*:*) - GUESS=sparc-unknown-bsdi$UNAME_RELEASE - ;; - *:BSD/OS:*:*) - GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE - ;; - arm:FreeBSD:*:*) - UNAME_PROCESSOR=`uname -p` - set_cc_for_build - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` - GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi - else - FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` - GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf - fi - ;; - *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` - case $UNAME_PROCESSOR in - amd64) - UNAME_PROCESSOR=x86_64 ;; - i386) - UNAME_PROCESSOR=i586 ;; - esac - FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` - GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL - ;; - i*:CYGWIN*:*) - GUESS=$UNAME_MACHINE-pc-cygwin - ;; - *:MINGW64*:*) - GUESS=$UNAME_MACHINE-pc-mingw64 - ;; - *:MINGW*:*) - GUESS=$UNAME_MACHINE-pc-mingw32 - ;; - *:MSYS*:*) - GUESS=$UNAME_MACHINE-pc-msys - ;; - i*:PW*:*) - GUESS=$UNAME_MACHINE-pc-pw32 - ;; - *:SerenityOS:*:*) - GUESS=$UNAME_MACHINE-pc-serenity - ;; - *:Interix*:*) - case $UNAME_MACHINE in - x86) - GUESS=i586-pc-interix$UNAME_RELEASE - ;; - authenticamd | genuineintel | EM64T) - GUESS=x86_64-unknown-interix$UNAME_RELEASE - ;; - IA64) - GUESS=ia64-unknown-interix$UNAME_RELEASE - ;; - esac ;; - i*:UWIN*:*) - GUESS=$UNAME_MACHINE-pc-uwin - ;; - amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - GUESS=x86_64-pc-cygwin - ;; - prep*:SunOS:5.*:*) - SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` - GUESS=powerpcle-unknown-solaris2$SUN_REL - ;; - *:GNU:*:*) - # the GNU system - GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'` - GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'` - GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL - ;; - *:GNU/*:*:*) - # other systems with GNU libc and userland - GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"` - GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` - GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC - ;; - *:Minix:*:*) - GUESS=$UNAME_MACHINE-unknown-minix - ;; - aarch64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - aarch64_be:Linux:*:*) - UNAME_MACHINE=aarch64_be - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in - EV5) UNAME_MACHINE=alphaev5 ;; - EV56) UNAME_MACHINE=alphaev56 ;; - PCA56) UNAME_MACHINE=alphapca56 ;; - PCA57) UNAME_MACHINE=alphapca56 ;; - EV6) UNAME_MACHINE=alphaev6 ;; - EV67) UNAME_MACHINE=alphaev67 ;; - EV68*) UNAME_MACHINE=alphaev68 ;; - esac - objdump --private-headers /bin/sh | grep -q ld.so.1 - if test "$?" = 0 ; then LIBC=gnulibc1 ; fi - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - arm*:Linux:*:*) - set_cc_for_build - if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_EABI__ - then - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - else - if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ - | grep -q __ARM_PCS_VFP - then - GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi - else - GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf - fi - fi - ;; - avr32*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - cris:Linux:*:*) - GUESS=$UNAME_MACHINE-axis-linux-$LIBC - ;; - crisv32:Linux:*:*) - GUESS=$UNAME_MACHINE-axis-linux-$LIBC - ;; - e2k:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - frv:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - hexagon:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - i*86:Linux:*:*) - GUESS=$UNAME_MACHINE-pc-linux-$LIBC - ;; - ia64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - k1om:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - loongarch32:Linux:*:* | loongarch64:Linux:*:* | loongarchx32:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - m32r*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - m68*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - mips:Linux:*:* | mips64:Linux:*:*) - set_cc_for_build - IS_GLIBC=0 - test x"${LIBC}" = xgnu && IS_GLIBC=1 - sed 's/^ //' << EOF > "$dummy.c" - #undef CPU - #undef mips - #undef mipsel - #undef mips64 - #undef mips64el - #if ${IS_GLIBC} && defined(_ABI64) - LIBCABI=gnuabi64 - #else - #if ${IS_GLIBC} && defined(_ABIN32) - LIBCABI=gnuabin32 - #else - LIBCABI=${LIBC} - #endif - #endif - - #if ${IS_GLIBC} && defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 - CPU=mipsisa64r6 - #else - #if ${IS_GLIBC} && !defined(__mips64) && defined(__mips_isa_rev) && __mips_isa_rev>=6 - CPU=mipsisa32r6 - #else - #if defined(__mips64) - CPU=mips64 - #else - CPU=mips - #endif - #endif - #endif - - #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) - MIPS_ENDIAN=el - #else - #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) - MIPS_ENDIAN= - #else - MIPS_ENDIAN= - #endif - #endif -EOF - cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'` - eval "$cc_set_vars" - test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } - ;; - mips64el:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - openrisc*:Linux:*:*) - GUESS=or1k-unknown-linux-$LIBC - ;; - or32:Linux:*:* | or1k*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - padre:Linux:*:*) - GUESS=sparc-unknown-linux-$LIBC - ;; - parisc64:Linux:*:* | hppa64:Linux:*:*) - GUESS=hppa64-unknown-linux-$LIBC - ;; - parisc:Linux:*:* | hppa:Linux:*:*) - # Look for CPU level - case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;; - PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;; - *) GUESS=hppa-unknown-linux-$LIBC ;; - esac - ;; - ppc64:Linux:*:*) - GUESS=powerpc64-unknown-linux-$LIBC - ;; - ppc:Linux:*:*) - GUESS=powerpc-unknown-linux-$LIBC - ;; - ppc64le:Linux:*:*) - GUESS=powerpc64le-unknown-linux-$LIBC - ;; - ppcle:Linux:*:*) - GUESS=powerpcle-unknown-linux-$LIBC - ;; - riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - s390:Linux:*:* | s390x:Linux:*:*) - GUESS=$UNAME_MACHINE-ibm-linux-$LIBC - ;; - sh64*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - sh*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - sparc:Linux:*:* | sparc64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - tile*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - vax:Linux:*:*) - GUESS=$UNAME_MACHINE-dec-linux-$LIBC - ;; - x86_64:Linux:*:*) - set_cc_for_build - CPU=$UNAME_MACHINE - LIBCABI=$LIBC - if test "$CC_FOR_BUILD" != no_compiler_found; then - ABI=64 - sed 's/^ //' << EOF > "$dummy.c" - #ifdef __i386__ - ABI=x86 - #else - #ifdef __ILP32__ - ABI=x32 - #endif - #endif -EOF - cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` - eval "$cc_set_abi" - case $ABI in - x86) CPU=i686 ;; - x32) LIBCABI=${LIBC}x32 ;; - esac - fi - GUESS=$CPU-pc-linux-$LIBCABI - ;; - xtensa*:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC - ;; - i*86:DYNIX/ptx:4*:*) - # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. - # earlier versions are messed up and put the nodename in both - # sysname and nodename. - GUESS=i386-sequent-sysv4 - ;; - i*86:UNIX_SV:4.2MP:2.*) - # Unixware is an offshoot of SVR4, but it has its own version - # number series starting with 2... - # I am not positive that other SVR4 systems won't match this, - # I just have to hope. -- rms. - # Use sysv4.2uw... so that sysv4* matches it. - GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION - ;; - i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility - # is probably installed. - GUESS=$UNAME_MACHINE-pc-os2-emx - ;; - i*86:XTS-300:*:STOP) - GUESS=$UNAME_MACHINE-unknown-stop - ;; - i*86:atheos:*:*) - GUESS=$UNAME_MACHINE-unknown-atheos - ;; - i*86:syllable:*:*) - GUESS=$UNAME_MACHINE-pc-syllable - ;; - i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - GUESS=i386-unknown-lynxos$UNAME_RELEASE - ;; - i*86:*DOS:*:*) - GUESS=$UNAME_MACHINE-pc-msdosdjgpp - ;; - i*86:*:4.*:*) - UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` - if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL - else - GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL - fi - ;; - i*86:*:5:[678]*) - # UnixWare 7.x, OpenUNIX and OpenServer 6. - case `/bin/uname -X | grep "^Machine"` in - *486*) UNAME_MACHINE=i486 ;; - *Pentium) UNAME_MACHINE=i586 ;; - *Pent*|*Celeron) UNAME_MACHINE=i686 ;; - esac - GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} - ;; - i*86:*:3.2:*) - if test -f /usr/options/cb.name; then - UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then - UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` - (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 - (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ - && UNAME_MACHINE=i586 - (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ - && UNAME_MACHINE=i686 - (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ - && UNAME_MACHINE=i686 - GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL - else - GUESS=$UNAME_MACHINE-pc-sysv32 - fi - ;; - pc:*:*:*) - # Left here for compatibility: - # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i586. - # Note: whatever this is, it MUST be the same as what config.sub - # prints for the "djgpp" host, or else GDB configure will decide that - # this is a cross-build. - GUESS=i586-pc-msdosdjgpp - ;; - Intel:Mach:3*:*) - GUESS=i386-pc-mach3 - ;; - paragon:*:*:*) - GUESS=i860-intel-osf1 - ;; - i860:*:4.*:*) # i860-SVR4 - if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4 - else # Add other i860-SVR4 vendors below as they are discovered. - GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4 - fi - ;; - mini*:CTIX:SYS*5:*) - # "miniframe" - GUESS=m68010-convergent-sysv - ;; - mc68k:UNIX:SYSTEM5:3.51m) - GUESS=m68k-convergent-sysv - ;; - M680?0:D-NIX:5.3:*) - GUESS=m68k-diab-dnix - ;; - M68*:*:R3V[5678]*:*) - test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; - 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) - OS_REL='' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; - 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4; exit; } ;; - NCR*:*:4.2:* | MPRAS*:*:4.2:*) - OS_REL='.3' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } - /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; - m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - GUESS=m68k-unknown-lynxos$UNAME_RELEASE - ;; - mc68030:UNIX_System_V:4.*:*) - GUESS=m68k-atari-sysv4 - ;; - TSUNAMI:LynxOS:2.*:*) - GUESS=sparc-unknown-lynxos$UNAME_RELEASE - ;; - rs6000:LynxOS:2.*:*) - GUESS=rs6000-unknown-lynxos$UNAME_RELEASE - ;; - PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - GUESS=powerpc-unknown-lynxos$UNAME_RELEASE - ;; - SM[BE]S:UNIX_SV:*:*) - GUESS=mips-dde-sysv$UNAME_RELEASE - ;; - RM*:ReliantUNIX-*:*:*) - GUESS=mips-sni-sysv4 - ;; - RM*:SINIX-*:*:*) - GUESS=mips-sni-sysv4 - ;; - *:SINIX-*:*:*) - if uname -p 2>/dev/null >/dev/null ; then - UNAME_MACHINE=`(uname -p) 2>/dev/null` - GUESS=$UNAME_MACHINE-sni-sysv4 - else - GUESS=ns32k-sni-sysv - fi - ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort - # says - GUESS=i586-unisys-sysv4 - ;; - *:UNIX_System_V:4*:FTX*) - # From Gerald Hewes . - # How about differentiating between stratus architectures? -djm - GUESS=hppa1.1-stratus-sysv4 - ;; - *:*:*:FTX*) - # From seanf@swdc.stratus.com. - GUESS=i860-stratus-sysv4 - ;; - i*86:VOS:*:*) - # From Paul.Green@stratus.com. - GUESS=$UNAME_MACHINE-stratus-vos - ;; - *:VOS:*:*) - # From Paul.Green@stratus.com. - GUESS=hppa1.1-stratus-vos - ;; - mc68*:A/UX:*:*) - GUESS=m68k-apple-aux$UNAME_RELEASE - ;; - news*:NEWS-OS:6*:*) - GUESS=mips-sony-newsos6 - ;; - R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) - if test -d /usr/nec; then - GUESS=mips-nec-sysv$UNAME_RELEASE - else - GUESS=mips-unknown-sysv$UNAME_RELEASE - fi - ;; - BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - GUESS=powerpc-be-beos - ;; - BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - GUESS=powerpc-apple-beos - ;; - BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - GUESS=i586-pc-beos - ;; - BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - GUESS=i586-pc-haiku - ;; - ppc:Haiku:*:*) # Haiku running on Apple PowerPC - GUESS=powerpc-apple-haiku - ;; - *:Haiku:*:*) # Haiku modern gcc (not bound by BeOS compat) - GUESS=$UNAME_MACHINE-unknown-haiku - ;; - SX-4:SUPER-UX:*:*) - GUESS=sx4-nec-superux$UNAME_RELEASE - ;; - SX-5:SUPER-UX:*:*) - GUESS=sx5-nec-superux$UNAME_RELEASE - ;; - SX-6:SUPER-UX:*:*) - GUESS=sx6-nec-superux$UNAME_RELEASE - ;; - SX-7:SUPER-UX:*:*) - GUESS=sx7-nec-superux$UNAME_RELEASE - ;; - SX-8:SUPER-UX:*:*) - GUESS=sx8-nec-superux$UNAME_RELEASE - ;; - SX-8R:SUPER-UX:*:*) - GUESS=sx8r-nec-superux$UNAME_RELEASE - ;; - SX-ACE:SUPER-UX:*:*) - GUESS=sxace-nec-superux$UNAME_RELEASE - ;; - Power*:Rhapsody:*:*) - GUESS=powerpc-apple-rhapsody$UNAME_RELEASE - ;; - *:Rhapsody:*:*) - GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE - ;; - arm64:Darwin:*:*) - GUESS=aarch64-apple-darwin$UNAME_RELEASE - ;; - *:Darwin:*:*) - UNAME_PROCESSOR=`uname -p` - case $UNAME_PROCESSOR in - unknown) UNAME_PROCESSOR=powerpc ;; - esac - if command -v xcode-select > /dev/null 2> /dev/null && \ - ! xcode-select --print-path > /dev/null 2> /dev/null ; then - # Avoid executing cc if there is no toolchain installed as - # cc will be a stub that puts up a graphical alert - # prompting the user to install developer tools. - CC_FOR_BUILD=no_compiler_found - else - set_cc_for_build - fi - if test "$CC_FOR_BUILD" != no_compiler_found; then - if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - case $UNAME_PROCESSOR in - i386) UNAME_PROCESSOR=x86_64 ;; - powerpc) UNAME_PROCESSOR=powerpc64 ;; - esac - fi - # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc - if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_PPC >/dev/null - then - UNAME_PROCESSOR=powerpc - fi - elif test "$UNAME_PROCESSOR" = i386 ; then - # uname -m returns i386 or x86_64 - UNAME_PROCESSOR=$UNAME_MACHINE - fi - GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE - ;; - *:procnto*:*:* | *:QNX:[0123456789]*:*) - UNAME_PROCESSOR=`uname -p` - if test "$UNAME_PROCESSOR" = x86; then - UNAME_PROCESSOR=i386 - UNAME_MACHINE=pc - fi - GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE - ;; - *:QNX:*:4*) - GUESS=i386-pc-qnx - ;; - NEO-*:NONSTOP_KERNEL:*:*) - GUESS=neo-tandem-nsk$UNAME_RELEASE - ;; - NSE-*:NONSTOP_KERNEL:*:*) - GUESS=nse-tandem-nsk$UNAME_RELEASE - ;; - NSR-*:NONSTOP_KERNEL:*:*) - GUESS=nsr-tandem-nsk$UNAME_RELEASE - ;; - NSV-*:NONSTOP_KERNEL:*:*) - GUESS=nsv-tandem-nsk$UNAME_RELEASE - ;; - NSX-*:NONSTOP_KERNEL:*:*) - GUESS=nsx-tandem-nsk$UNAME_RELEASE - ;; - *:NonStop-UX:*:*) - GUESS=mips-compaq-nonstopux - ;; - BS2000:POSIX*:*:*) - GUESS=bs2000-siemens-sysv - ;; - DS/*:UNIX_System_V:*:*) - GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE - ;; - *:Plan9:*:*) - # "uname -m" is not consistent, so use $cputype instead. 386 - # is converted to i386 for consistency with other x86 - # operating systems. - if test "${cputype-}" = 386; then - UNAME_MACHINE=i386 - elif test "x${cputype-}" != x; then - UNAME_MACHINE=$cputype - fi - GUESS=$UNAME_MACHINE-unknown-plan9 - ;; - *:TOPS-10:*:*) - GUESS=pdp10-unknown-tops10 - ;; - *:TENEX:*:*) - GUESS=pdp10-unknown-tenex - ;; - KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - GUESS=pdp10-dec-tops20 - ;; - XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - GUESS=pdp10-xkl-tops20 - ;; - *:TOPS-20:*:*) - GUESS=pdp10-unknown-tops20 - ;; - *:ITS:*:*) - GUESS=pdp10-unknown-its - ;; - SEI:*:*:SEIUX) - GUESS=mips-sei-seiux$UNAME_RELEASE - ;; - *:DragonFly:*:*) - DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` - GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL - ;; - *:*VMS:*:*) - UNAME_MACHINE=`(uname -p) 2>/dev/null` - case $UNAME_MACHINE in - A*) GUESS=alpha-dec-vms ;; - I*) GUESS=ia64-dec-vms ;; - V*) GUESS=vax-dec-vms ;; - esac ;; - *:XENIX:*:SysV) - GUESS=i386-pc-xenix - ;; - i*86:skyos:*:*) - SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'` - GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL - ;; - i*86:rdos:*:*) - GUESS=$UNAME_MACHINE-pc-rdos - ;; - i*86:Fiwix:*:*) - GUESS=$UNAME_MACHINE-pc-fiwix - ;; - *:AROS:*:*) - GUESS=$UNAME_MACHINE-unknown-aros - ;; - x86_64:VMkernel:*:*) - GUESS=$UNAME_MACHINE-unknown-esx - ;; - amd64:Isilon\ OneFS:*:*) - GUESS=x86_64-unknown-onefs - ;; - *:Unleashed:*:*) - GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE - ;; -esac - -# Do we have a guess based on uname results? -if test "x$GUESS" != x; then - echo "$GUESS" - exit -fi - -# No uname command or uname output not recognized. -set_cc_for_build -cat > "$dummy.c" < -#include -#endif -#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) -#if defined (vax) || defined (__vax) || defined (__vax__) || defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) -#include -#if defined(_SIZE_T_) || defined(SIGLOST) -#include -#endif -#endif -#endif -main () -{ -#if defined (sony) -#if defined (MIPSEB) - /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, - I don't know.... */ - printf ("mips-sony-bsd\n"); exit (0); -#else -#include - printf ("m68k-sony-newsos%s\n", -#ifdef NEWSOS4 - "4" -#else - "" -#endif - ); exit (0); -#endif -#endif - -#if defined (NeXT) -#if !defined (__ARCHITECTURE__) -#define __ARCHITECTURE__ "m68k" -#endif - int version; - version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; - if (version < 4) - printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); - else - printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); - exit (0); -#endif - -#if defined (MULTIMAX) || defined (n16) -#if defined (UMAXV) - printf ("ns32k-encore-sysv\n"); exit (0); -#else -#if defined (CMU) - printf ("ns32k-encore-mach\n"); exit (0); -#else - printf ("ns32k-encore-bsd\n"); exit (0); -#endif -#endif -#endif - -#if defined (__386BSD__) - printf ("i386-pc-bsd\n"); exit (0); -#endif - -#if defined (sequent) -#if defined (i386) - printf ("i386-sequent-dynix\n"); exit (0); -#endif -#if defined (ns32000) - printf ("ns32k-sequent-dynix\n"); exit (0); -#endif -#endif - -#if defined (_SEQUENT_) - struct utsname un; - - uname(&un); - if (strncmp(un.version, "V2", 2) == 0) { - printf ("i386-sequent-ptx2\n"); exit (0); - } - if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ - printf ("i386-sequent-ptx1\n"); exit (0); - } - printf ("i386-sequent-ptx\n"); exit (0); -#endif - -#if defined (vax) -#if !defined (ultrix) -#include -#if defined (BSD) -#if BSD == 43 - printf ("vax-dec-bsd4.3\n"); exit (0); -#else -#if BSD == 199006 - printf ("vax-dec-bsd4.3reno\n"); exit (0); -#else - printf ("vax-dec-bsd\n"); exit (0); -#endif -#endif -#else - printf ("vax-dec-bsd\n"); exit (0); -#endif -#else -#if defined(_SIZE_T_) || defined(SIGLOST) - struct utsname un; - uname (&un); - printf ("vax-dec-ultrix%s\n", un.release); exit (0); -#else - printf ("vax-dec-ultrix\n"); exit (0); -#endif -#endif -#endif -#if defined(ultrix) || defined(_ultrix) || defined(__ultrix) || defined(__ultrix__) -#if defined(mips) || defined(__mips) || defined(__mips__) || defined(MIPS) || defined(__MIPS__) -#if defined(_SIZE_T_) || defined(SIGLOST) - struct utsname *un; - uname (&un); - printf ("mips-dec-ultrix%s\n", un.release); exit (0); -#else - printf ("mips-dec-ultrix\n"); exit (0); -#endif -#endif -#endif - -#if defined (alliant) && defined (i860) - printf ("i860-alliant-bsd\n"); exit (0); -#endif - - exit (1); -} -EOF - -$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` && - { echo "$SYSTEM_NAME"; exit; } - -# Apollos put the system type in the environment. -test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; } - -echo "$0: unable to guess system type" >&2 - -case $UNAME_MACHINE:$UNAME_SYSTEM in - mips:Linux | mips64:Linux) - # If we got here on MIPS GNU/Linux, output extra information. - cat >&2 <&2 <&2 </dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null` - -hostinfo = `(hostinfo) 2>/dev/null` -/bin/universe = `(/bin/universe) 2>/dev/null` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` -/bin/arch = `(/bin/arch) 2>/dev/null` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` - -UNAME_MACHINE = "$UNAME_MACHINE" -UNAME_RELEASE = "$UNAME_RELEASE" -UNAME_SYSTEM = "$UNAME_SYSTEM" -UNAME_VERSION = "$UNAME_VERSION" -EOF -fi - -exit 1 - -# Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/config.sub b/lib/libcgroup-3.1.0/build-aux/config.sub deleted file mode 100755 index b41da55df45..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/config.sub +++ /dev/null @@ -1,1890 +0,0 @@ -#!/usr/bin/sh -# Configuration validation subroutine script. -# Copyright 1992-2022 Free Software Foundation, Inc. - -# shellcheck disable=SC2006,SC2268 # see below for rationale - -timestamp='2022-01-03' - -# This file 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 3 of the License, or -# (at your option) any later version. -# -# 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, see . -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that -# program. This Exception is an additional permission under section 7 -# of the GNU General Public License, version 3 ("GPLv3"). - - -# Please send patches to . -# -# Configuration subroutine to validate and canonicalize a configuration type. -# Supply the specified configuration type as an argument. -# If it is invalid, we print an error message on stderr and exit with code 1. -# Otherwise, we print the canonical config type on stdout and succeed. - -# You can get the latest version of this script from: -# https://git.savannah.gnu.org/cgit/config.git/plain/config.sub - -# This file is supposed to be the same for all GNU packages -# and recognize all the CPU types, system types and aliases -# that are meaningful with *any* GNU software. -# Each package is responsible for reporting which valid configurations -# it does not support. The user should be able to distinguish -# a failure to support a valid configuration from a meaningless -# configuration. - -# The goal of this file is to map all the various variations of a given -# machine specification into a single specification in the form: -# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM -# or in some cases, the newer four-part form: -# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM -# It is wrong to echo any other type of specification. - -# The "shellcheck disable" line above the timestamp inhibits complaints -# about features and limitations of the classic Bourne shell that were -# superseded or lifted in POSIX. However, this script identifies a wide -# variety of pre-POSIX systems that do not have POSIX shells at all, and -# even some reasonably current systems (Solaris 10 as case-in-point) still -# have a pre-POSIX /bin/sh. - -me=`echo "$0" | sed -e 's,.*/,,'` - -usage="\ -Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS - -Canonicalize a configuration name. - -Options: - -h, --help print this help, then exit - -t, --time-stamp print date of last modification, then exit - -v, --version print version number, then exit - -Report bugs and patches to ." - -version="\ -GNU config.sub ($timestamp) - -Copyright 1992-2022 Free Software Foundation, Inc. - -This is free software; see the source for copying conditions. There is NO -warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." - -help=" -Try \`$me --help' for more information." - -# Parse command line -while test $# -gt 0 ; do - case $1 in - --time-stamp | --time* | -t ) - echo "$timestamp" ; exit ;; - --version | -v ) - echo "$version" ; exit ;; - --help | --h* | -h ) - echo "$usage"; exit ;; - -- ) # Stop option processing - shift; break ;; - - ) # Use stdin as input. - break ;; - -* ) - echo "$me: invalid option $1$help" >&2 - exit 1 ;; - - *local*) - # First pass through any local machine types. - echo "$1" - exit ;; - - * ) - break ;; - esac -done - -case $# in - 0) echo "$me: missing argument$help" >&2 - exit 1;; - 1) ;; - *) echo "$me: too many arguments$help" >&2 - exit 1;; -esac - -# Split fields of configuration type -# shellcheck disable=SC2162 -saved_IFS=$IFS -IFS="-" read field1 field2 field3 field4 <&2 - exit 1 - ;; - *-*-*-*) - basic_machine=$field1-$field2 - basic_os=$field3-$field4 - ;; - *-*-*) - # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two - # parts - maybe_os=$field2-$field3 - case $maybe_os in - nto-qnx* | linux-* | uclinux-uclibc* \ - | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ - | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ - | storm-chaos* | os2-emx* | rtmk-nova*) - basic_machine=$field1 - basic_os=$maybe_os - ;; - android-linux) - basic_machine=$field1-unknown - basic_os=linux-android - ;; - *) - basic_machine=$field1-$field2 - basic_os=$field3 - ;; - esac - ;; - *-*) - # A lone config we happen to match not fitting any pattern - case $field1-$field2 in - decstation-3100) - basic_machine=mips-dec - basic_os= - ;; - *-*) - # Second component is usually, but not always the OS - case $field2 in - # Prevent following clause from handling this valid os - sun*os*) - basic_machine=$field1 - basic_os=$field2 - ;; - zephyr*) - basic_machine=$field1-unknown - basic_os=$field2 - ;; - # Manufacturers - dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ - | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ - | unicom* | ibm* | next | hp | isi* | apollo | altos* \ - | convergent* | ncr* | news | 32* | 3600* | 3100* \ - | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ - | ultra | tti* | harris | dolphin | highlevel | gould \ - | cbm | ns | masscomp | apple | axis | knuth | cray \ - | microblaze* | sim | cisco \ - | oki | wec | wrs | winbond) - basic_machine=$field1-$field2 - basic_os= - ;; - *) - basic_machine=$field1 - basic_os=$field2 - ;; - esac - ;; - esac - ;; - *) - # Convert single-component short-hands not valid as part of - # multi-component configurations. - case $field1 in - 386bsd) - basic_machine=i386-pc - basic_os=bsd - ;; - a29khif) - basic_machine=a29k-amd - basic_os=udi - ;; - adobe68k) - basic_machine=m68010-adobe - basic_os=scout - ;; - alliant) - basic_machine=fx80-alliant - basic_os= - ;; - altos | altos3068) - basic_machine=m68k-altos - basic_os= - ;; - am29k) - basic_machine=a29k-none - basic_os=bsd - ;; - amdahl) - basic_machine=580-amdahl - basic_os=sysv - ;; - amiga) - basic_machine=m68k-unknown - basic_os= - ;; - amigaos | amigados) - basic_machine=m68k-unknown - basic_os=amigaos - ;; - amigaunix | amix) - basic_machine=m68k-unknown - basic_os=sysv4 - ;; - apollo68) - basic_machine=m68k-apollo - basic_os=sysv - ;; - apollo68bsd) - basic_machine=m68k-apollo - basic_os=bsd - ;; - aros) - basic_machine=i386-pc - basic_os=aros - ;; - aux) - basic_machine=m68k-apple - basic_os=aux - ;; - balance) - basic_machine=ns32k-sequent - basic_os=dynix - ;; - blackfin) - basic_machine=bfin-unknown - basic_os=linux - ;; - cegcc) - basic_machine=arm-unknown - basic_os=cegcc - ;; - convex-c1) - basic_machine=c1-convex - basic_os=bsd - ;; - convex-c2) - basic_machine=c2-convex - basic_os=bsd - ;; - convex-c32) - basic_machine=c32-convex - basic_os=bsd - ;; - convex-c34) - basic_machine=c34-convex - basic_os=bsd - ;; - convex-c38) - basic_machine=c38-convex - basic_os=bsd - ;; - cray) - basic_machine=j90-cray - basic_os=unicos - ;; - crds | unos) - basic_machine=m68k-crds - basic_os= - ;; - da30) - basic_machine=m68k-da30 - basic_os= - ;; - decstation | pmax | pmin | dec3100 | decstatn) - basic_machine=mips-dec - basic_os= - ;; - delta88) - basic_machine=m88k-motorola - basic_os=sysv3 - ;; - dicos) - basic_machine=i686-pc - basic_os=dicos - ;; - djgpp) - basic_machine=i586-pc - basic_os=msdosdjgpp - ;; - ebmon29k) - basic_machine=a29k-amd - basic_os=ebmon - ;; - es1800 | OSE68k | ose68k | ose | OSE) - basic_machine=m68k-ericsson - basic_os=ose - ;; - gmicro) - basic_machine=tron-gmicro - basic_os=sysv - ;; - go32) - basic_machine=i386-pc - basic_os=go32 - ;; - h8300hms) - basic_machine=h8300-hitachi - basic_os=hms - ;; - h8300xray) - basic_machine=h8300-hitachi - basic_os=xray - ;; - h8500hms) - basic_machine=h8500-hitachi - basic_os=hms - ;; - harris) - basic_machine=m88k-harris - basic_os=sysv3 - ;; - hp300 | hp300hpux) - basic_machine=m68k-hp - basic_os=hpux - ;; - hp300bsd) - basic_machine=m68k-hp - basic_os=bsd - ;; - hppaosf) - basic_machine=hppa1.1-hp - basic_os=osf - ;; - hppro) - basic_machine=hppa1.1-hp - basic_os=proelf - ;; - i386mach) - basic_machine=i386-mach - basic_os=mach - ;; - isi68 | isi) - basic_machine=m68k-isi - basic_os=sysv - ;; - m68knommu) - basic_machine=m68k-unknown - basic_os=linux - ;; - magnum | m3230) - basic_machine=mips-mips - basic_os=sysv - ;; - merlin) - basic_machine=ns32k-utek - basic_os=sysv - ;; - mingw64) - basic_machine=x86_64-pc - basic_os=mingw64 - ;; - mingw32) - basic_machine=i686-pc - basic_os=mingw32 - ;; - mingw32ce) - basic_machine=arm-unknown - basic_os=mingw32ce - ;; - monitor) - basic_machine=m68k-rom68k - basic_os=coff - ;; - morphos) - basic_machine=powerpc-unknown - basic_os=morphos - ;; - moxiebox) - basic_machine=moxie-unknown - basic_os=moxiebox - ;; - msdos) - basic_machine=i386-pc - basic_os=msdos - ;; - msys) - basic_machine=i686-pc - basic_os=msys - ;; - mvs) - basic_machine=i370-ibm - basic_os=mvs - ;; - nacl) - basic_machine=le32-unknown - basic_os=nacl - ;; - ncr3000) - basic_machine=i486-ncr - basic_os=sysv4 - ;; - netbsd386) - basic_machine=i386-pc - basic_os=netbsd - ;; - netwinder) - basic_machine=armv4l-rebel - basic_os=linux - ;; - news | news700 | news800 | news900) - basic_machine=m68k-sony - basic_os=newsos - ;; - news1000) - basic_machine=m68030-sony - basic_os=newsos - ;; - necv70) - basic_machine=v70-nec - basic_os=sysv - ;; - nh3000) - basic_machine=m68k-harris - basic_os=cxux - ;; - nh[45]000) - basic_machine=m88k-harris - basic_os=cxux - ;; - nindy960) - basic_machine=i960-intel - basic_os=nindy - ;; - mon960) - basic_machine=i960-intel - basic_os=mon960 - ;; - nonstopux) - basic_machine=mips-compaq - basic_os=nonstopux - ;; - os400) - basic_machine=powerpc-ibm - basic_os=os400 - ;; - OSE68000 | ose68000) - basic_machine=m68000-ericsson - basic_os=ose - ;; - os68k) - basic_machine=m68k-none - basic_os=os68k - ;; - paragon) - basic_machine=i860-intel - basic_os=osf - ;; - parisc) - basic_machine=hppa-unknown - basic_os=linux - ;; - psp) - basic_machine=mipsallegrexel-sony - basic_os=psp - ;; - pw32) - basic_machine=i586-unknown - basic_os=pw32 - ;; - rdos | rdos64) - basic_machine=x86_64-pc - basic_os=rdos - ;; - rdos32) - basic_machine=i386-pc - basic_os=rdos - ;; - rom68k) - basic_machine=m68k-rom68k - basic_os=coff - ;; - sa29200) - basic_machine=a29k-amd - basic_os=udi - ;; - sei) - basic_machine=mips-sei - basic_os=seiux - ;; - sequent) - basic_machine=i386-sequent - basic_os= - ;; - sps7) - basic_machine=m68k-bull - basic_os=sysv2 - ;; - st2000) - basic_machine=m68k-tandem - basic_os= - ;; - stratus) - basic_machine=i860-stratus - basic_os=sysv4 - ;; - sun2) - basic_machine=m68000-sun - basic_os= - ;; - sun2os3) - basic_machine=m68000-sun - basic_os=sunos3 - ;; - sun2os4) - basic_machine=m68000-sun - basic_os=sunos4 - ;; - sun3) - basic_machine=m68k-sun - basic_os= - ;; - sun3os3) - basic_machine=m68k-sun - basic_os=sunos3 - ;; - sun3os4) - basic_machine=m68k-sun - basic_os=sunos4 - ;; - sun4) - basic_machine=sparc-sun - basic_os= - ;; - sun4os3) - basic_machine=sparc-sun - basic_os=sunos3 - ;; - sun4os4) - basic_machine=sparc-sun - basic_os=sunos4 - ;; - sun4sol2) - basic_machine=sparc-sun - basic_os=solaris2 - ;; - sun386 | sun386i | roadrunner) - basic_machine=i386-sun - basic_os= - ;; - sv1) - basic_machine=sv1-cray - basic_os=unicos - ;; - symmetry) - basic_machine=i386-sequent - basic_os=dynix - ;; - t3e) - basic_machine=alphaev5-cray - basic_os=unicos - ;; - t90) - basic_machine=t90-cray - basic_os=unicos - ;; - toad1) - basic_machine=pdp10-xkl - basic_os=tops20 - ;; - tpf) - basic_machine=s390x-ibm - basic_os=tpf - ;; - udi29k) - basic_machine=a29k-amd - basic_os=udi - ;; - ultra3) - basic_machine=a29k-nyu - basic_os=sym1 - ;; - v810 | necv810) - basic_machine=v810-nec - basic_os=none - ;; - vaxv) - basic_machine=vax-dec - basic_os=sysv - ;; - vms) - basic_machine=vax-dec - basic_os=vms - ;; - vsta) - basic_machine=i386-pc - basic_os=vsta - ;; - vxworks960) - basic_machine=i960-wrs - basic_os=vxworks - ;; - vxworks68) - basic_machine=m68k-wrs - basic_os=vxworks - ;; - vxworks29k) - basic_machine=a29k-wrs - basic_os=vxworks - ;; - xbox) - basic_machine=i686-pc - basic_os=mingw32 - ;; - ymp) - basic_machine=ymp-cray - basic_os=unicos - ;; - *) - basic_machine=$1 - basic_os= - ;; - esac - ;; -esac - -# Decode 1-component or ad-hoc basic machines -case $basic_machine in - # Here we handle the default manufacturer of certain CPU types. It is in - # some cases the only manufacturer, in others, it is the most popular. - w89k) - cpu=hppa1.1 - vendor=winbond - ;; - op50n) - cpu=hppa1.1 - vendor=oki - ;; - op60c) - cpu=hppa1.1 - vendor=oki - ;; - ibm*) - cpu=i370 - vendor=ibm - ;; - orion105) - cpu=clipper - vendor=highlevel - ;; - mac | mpw | mac-mpw) - cpu=m68k - vendor=apple - ;; - pmac | pmac-mpw) - cpu=powerpc - vendor=apple - ;; - - # Recognize the various machine names and aliases which stand - # for a CPU type and a company and sometimes even an OS. - 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) - cpu=m68000 - vendor=att - ;; - 3b*) - cpu=we32k - vendor=att - ;; - bluegene*) - cpu=powerpc - vendor=ibm - basic_os=cnk - ;; - decsystem10* | dec10*) - cpu=pdp10 - vendor=dec - basic_os=tops10 - ;; - decsystem20* | dec20*) - cpu=pdp10 - vendor=dec - basic_os=tops20 - ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) - cpu=m68k - vendor=motorola - ;; - dpx2*) - cpu=m68k - vendor=bull - basic_os=sysv3 - ;; - encore | umax | mmax) - cpu=ns32k - vendor=encore - ;; - elxsi) - cpu=elxsi - vendor=elxsi - basic_os=${basic_os:-bsd} - ;; - fx2800) - cpu=i860 - vendor=alliant - ;; - genix) - cpu=ns32k - vendor=ns - ;; - h3050r* | hiux*) - cpu=hppa1.1 - vendor=hitachi - basic_os=hiuxwe2 - ;; - hp3k9[0-9][0-9] | hp9[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - hp9k2[0-9][0-9] | hp9k31[0-9]) - cpu=m68000 - vendor=hp - ;; - hp9k3[2-9][0-9]) - cpu=m68k - vendor=hp - ;; - hp9k6[0-9][0-9] | hp6[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - hp9k7[0-79][0-9] | hp7[0-79][0-9]) - cpu=hppa1.1 - vendor=hp - ;; - hp9k78[0-9] | hp78[0-9]) - # FIXME: really hppa2.0-hp - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) - # FIXME: really hppa2.0-hp - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[0-9][13679] | hp8[0-9][13679]) - cpu=hppa1.1 - vendor=hp - ;; - hp9k8[0-9][0-9] | hp8[0-9][0-9]) - cpu=hppa1.0 - vendor=hp - ;; - i*86v32) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - basic_os=sysv32 - ;; - i*86v4*) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - basic_os=sysv4 - ;; - i*86v) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - basic_os=sysv - ;; - i*86sol2) - cpu=`echo "$1" | sed -e 's/86.*/86/'` - vendor=pc - basic_os=solaris2 - ;; - j90 | j90-cray) - cpu=j90 - vendor=cray - basic_os=${basic_os:-unicos} - ;; - iris | iris4d) - cpu=mips - vendor=sgi - case $basic_os in - irix*) - ;; - *) - basic_os=irix4 - ;; - esac - ;; - miniframe) - cpu=m68000 - vendor=convergent - ;; - *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) - cpu=m68k - vendor=atari - basic_os=mint - ;; - news-3600 | risc-news) - cpu=mips - vendor=sony - basic_os=newsos - ;; - next | m*-next) - cpu=m68k - vendor=next - case $basic_os in - openstep*) - ;; - nextstep*) - ;; - ns2*) - basic_os=nextstep2 - ;; - *) - basic_os=nextstep3 - ;; - esac - ;; - np1) - cpu=np1 - vendor=gould - ;; - op50n-* | op60c-*) - cpu=hppa1.1 - vendor=oki - basic_os=proelf - ;; - pa-hitachi) - cpu=hppa1.1 - vendor=hitachi - basic_os=hiuxwe2 - ;; - pbd) - cpu=sparc - vendor=tti - ;; - pbb) - cpu=m68k - vendor=tti - ;; - pc532) - cpu=ns32k - vendor=pc532 - ;; - pn) - cpu=pn - vendor=gould - ;; - power) - cpu=power - vendor=ibm - ;; - ps2) - cpu=i386 - vendor=ibm - ;; - rm[46]00) - cpu=mips - vendor=siemens - ;; - rtpc | rtpc-*) - cpu=romp - vendor=ibm - ;; - sde) - cpu=mipsisa32 - vendor=sde - basic_os=${basic_os:-elf} - ;; - simso-wrs) - cpu=sparclite - vendor=wrs - basic_os=vxworks - ;; - tower | tower-32) - cpu=m68k - vendor=ncr - ;; - vpp*|vx|vx-*) - cpu=f301 - vendor=fujitsu - ;; - w65) - cpu=w65 - vendor=wdc - ;; - w89k-*) - cpu=hppa1.1 - vendor=winbond - basic_os=proelf - ;; - none) - cpu=none - vendor=none - ;; - leon|leon[3-9]) - cpu=sparc - vendor=$basic_machine - ;; - leon-*|leon[3-9]-*) - cpu=sparc - vendor=`echo "$basic_machine" | sed 's/-.*//'` - ;; - - *-*) - # shellcheck disable=SC2162 - saved_IFS=$IFS - IFS="-" read cpu vendor <&2 - exit 1 - ;; - esac - ;; -esac - -# Here we canonicalize certain aliases for manufacturers. -case $vendor in - digital*) - vendor=dec - ;; - commodore*) - vendor=cbm - ;; - *) - ;; -esac - -# Decode manufacturer-specific aliases for certain operating systems. - -if test x$basic_os != x -then - -# First recognize some ad-hoc cases, or perhaps split kernel-os, or else just -# set os. -case $basic_os in - gnu/linux*) - kernel=linux - os=`echo "$basic_os" | sed -e 's|gnu/linux|gnu|'` - ;; - os2-emx) - kernel=os2 - os=`echo "$basic_os" | sed -e 's|os2-emx|emx|'` - ;; - nto-qnx*) - kernel=nto - os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'` - ;; - *-*) - # shellcheck disable=SC2162 - saved_IFS=$IFS - IFS="-" read kernel os <&2 - exit 1 - ;; -esac - -# As a final step for OS-related things, validate the OS-kernel combination -# (given a valid OS), if there is a kernel. -case $kernel-$os in - linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* \ - | linux-musl* | linux-relibc* | linux-uclibc* ) - ;; - uclinux-uclibc* ) - ;; - -dietlibc* | -newlib* | -musl* | -relibc* | -uclibc* ) - # These are just libc implementations, not actual OSes, and thus - # require a kernel. - echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2 - exit 1 - ;; - kfreebsd*-gnu* | kopensolaris*-gnu*) - ;; - vxworks-simlinux | vxworks-simwindows | vxworks-spe) - ;; - nto-qnx*) - ;; - os2-emx) - ;; - *-eabi* | *-gnueabi*) - ;; - -*) - # Blank kernel with real OS is always fine. - ;; - *-*) - echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2 - exit 1 - ;; -esac - -# Here we handle the case where we know the os, and the CPU type, but not the -# manufacturer. We pick the logical manufacturer. -case $vendor in - unknown) - case $cpu-$os in - *-riscix*) - vendor=acorn - ;; - *-sunos*) - vendor=sun - ;; - *-cnk* | *-aix*) - vendor=ibm - ;; - *-beos*) - vendor=be - ;; - *-hpux*) - vendor=hp - ;; - *-mpeix*) - vendor=hp - ;; - *-hiux*) - vendor=hitachi - ;; - *-unos*) - vendor=crds - ;; - *-dgux*) - vendor=dg - ;; - *-luna*) - vendor=omron - ;; - *-genix*) - vendor=ns - ;; - *-clix*) - vendor=intergraph - ;; - *-mvs* | *-opened*) - vendor=ibm - ;; - *-os400*) - vendor=ibm - ;; - s390-* | s390x-*) - vendor=ibm - ;; - *-ptx*) - vendor=sequent - ;; - *-tpf*) - vendor=ibm - ;; - *-vxsim* | *-vxworks* | *-windiss*) - vendor=wrs - ;; - *-aux*) - vendor=apple - ;; - *-hms*) - vendor=hitachi - ;; - *-mpw* | *-macos*) - vendor=apple - ;; - *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*) - vendor=atari - ;; - *-vos*) - vendor=stratus - ;; - esac - ;; -esac - -echo "$cpu-$vendor-${kernel:+$kernel-}$os" -exit - -# Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" -# time-stamp-end: "'" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/depcomp b/lib/libcgroup-3.1.0/build-aux/depcomp deleted file mode 100755 index 715e34311ed..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/depcomp +++ /dev/null @@ -1,791 +0,0 @@ -#! /bin/sh -# depcomp - compile a program generating dependencies as side-effects - -scriptversion=2018-03-07.03; # UTC - -# Copyright (C) 1999-2021 Free Software Foundation, Inc. - -# 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, or (at your option) -# any later version. - -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# Originally written by Alexandre Oliva . - -case $1 in - '') - echo "$0: No command. Try '$0 --help' for more information." 1>&2 - exit 1; - ;; - -h | --h*) - cat <<\EOF -Usage: depcomp [--help] [--version] PROGRAM [ARGS] - -Run PROGRAMS ARGS to compile a file, generating dependencies -as side-effects. - -Environment variables: - depmode Dependency tracking mode. - source Source file read by 'PROGRAMS ARGS'. - object Object file output by 'PROGRAMS ARGS'. - DEPDIR directory where to store dependencies. - depfile Dependency file to output. - tmpdepfile Temporary file to use when outputting dependencies. - libtool Whether libtool is used (yes/no). - -Report bugs to . -EOF - exit $? - ;; - -v | --v*) - echo "depcomp $scriptversion" - exit $? - ;; -esac - -# Get the directory component of the given path, and save it in the -# global variables '$dir'. Note that this directory component will -# be either empty or ending with a '/' character. This is deliberate. -set_dir_from () -{ - case $1 in - */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; - *) dir=;; - esac -} - -# Get the suffix-stripped basename of the given path, and save it the -# global variable '$base'. -set_base_from () -{ - base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` -} - -# If no dependency file was actually created by the compiler invocation, -# we still have to create a dummy depfile, to avoid errors with the -# Makefile "include basename.Plo" scheme. -make_dummy_depfile () -{ - echo "#dummy" > "$depfile" -} - -# Factor out some common post-processing of the generated depfile. -# Requires the auxiliary global variable '$tmpdepfile' to be set. -aix_post_process_depfile () -{ - # If the compiler actually managed to produce a dependency file, - # post-process it. - if test -f "$tmpdepfile"; then - # Each line is of the form 'foo.o: dependency.h'. - # Do two passes, one to just change these to - # $object: dependency.h - # and one to simply output - # dependency.h: - # which is needed to avoid the deleted-header problem. - { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" - sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" - } > "$depfile" - rm -f "$tmpdepfile" - else - make_dummy_depfile - fi -} - -# A tabulation character. -tab=' ' -# A newline character. -nl=' -' -# Character ranges might be problematic outside the C locale. -# These definitions help. -upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ -lower=abcdefghijklmnopqrstuvwxyz -digits=0123456789 -alpha=${upper}${lower} - -if test -z "$depmode" || test -z "$source" || test -z "$object"; then - echo "depcomp: Variables source, object and depmode must be set" 1>&2 - exit 1 -fi - -# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. -depfile=${depfile-`echo "$object" | - sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} -tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} - -rm -f "$tmpdepfile" - -# Avoid interferences from the environment. -gccflag= dashmflag= - -# Some modes work just like other modes, but use different flags. We -# parameterize here, but still list the modes in the big case below, -# to make depend.m4 easier to write. Note that we *cannot* use a case -# here, because this file can only contain one case statement. -if test "$depmode" = hp; then - # HP compiler uses -M and no extra arg. - gccflag=-M - depmode=gcc -fi - -if test "$depmode" = dashXmstdout; then - # This is just like dashmstdout with a different argument. - dashmflag=-xM - depmode=dashmstdout -fi - -cygpath_u="cygpath -u -f -" -if test "$depmode" = msvcmsys; then - # This is just like msvisualcpp but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvisualcpp -fi - -if test "$depmode" = msvc7msys; then - # This is just like msvc7 but w/o cygpath translation. - # Just convert the backslash-escaped backslashes to single forward - # slashes to satisfy depend.m4 - cygpath_u='sed s,\\\\,/,g' - depmode=msvc7 -fi - -if test "$depmode" = xlc; then - # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. - gccflag=-qmakedep=gcc,-MF - depmode=gcc -fi - -case "$depmode" in -gcc3) -## gcc 3 implements dependency tracking that does exactly what -## we want. Yay! Note: for some reason libtool 1.4 doesn't like -## it if -MD -MP comes after the -MF stuff. Hmm. -## Unfortunately, FreeBSD c89 acceptance of flags depends upon -## the command line argument order; so add the flags where they -## appear in depend2.am. Note that the slowdown incurred here -## affects only configure: in makefiles, %FASTDEP% shortcuts this. - for arg - do - case $arg in - -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; - *) set fnord "$@" "$arg" ;; - esac - shift # fnord - shift # $arg - done - "$@" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - mv "$tmpdepfile" "$depfile" - ;; - -gcc) -## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. -## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. -## (see the conditional assignment to $gccflag above). -## There are various ways to get dependency output from gcc. Here's -## why we pick this rather obscure method: -## - Don't want to use -MD because we'd like the dependencies to end -## up in a subdir. Having to rename by hand is ugly. -## (We might end up doing this anyway to support other compilers.) -## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like -## -MM, not -M (despite what the docs say). Also, it might not be -## supported by the other compilers which use the 'gcc' depmode. -## - Using -M directly means running the compiler twice (even worse -## than renaming). - if test -z "$gccflag"; then - gccflag=-MD, - fi - "$@" -Wp,"$gccflag$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The second -e expression handles DOS-style file names with drive - # letters. - sed -e 's/^[^:]*: / /' \ - -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" -## This next piece of magic avoids the "deleted header file" problem. -## The problem is that when a header file which appears in a .P file -## is deleted, the dependency causes make to die (because there is -## typically no way to rebuild the header). We avoid this by adding -## dummy dependencies for each header file. Too bad gcc doesn't do -## this for us directly. -## Some versions of gcc put a space before the ':'. On the theory -## that the space means something, we add a space to the output as -## well. hp depmode also adds that space, but also prefixes the VPATH -## to the object. Take care to not repeat it in the output. -## Some versions of the HPUX 10.20 sed can't process this invocation -## correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -sgi) - if test "$libtool" = yes; then - "$@" "-Wp,-MDupdate,$tmpdepfile" - else - "$@" -MDupdate "$tmpdepfile" - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - - if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files - echo "$object : \\" > "$depfile" - # Clip off the initial element (the dependent). Don't try to be - # clever and replace this with sed code, as IRIX sed won't handle - # lines with more than a fixed number of characters (4096 in - # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; - # the IRIX cc adds comments like '#:fec' to the end of the - # dependency line. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ - | tr "$nl" ' ' >> "$depfile" - echo >> "$depfile" - # The second pass generates a dummy entry for each header file. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ - >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" - ;; - -xlc) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -aix) - # The C for AIX Compiler uses -M and outputs the dependencies - # in a .u file. In older versions, this file always lives in the - # current directory. Also, the AIX compiler puts '$object:' at the - # start of each line; $object doesn't have directory information. - # Version 6 uses the directory in both cases. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.u - tmpdepfile2=$base.u - tmpdepfile3=$dir.libs/$base.u - "$@" -Wc,-M - else - tmpdepfile1=$dir$base.u - tmpdepfile2=$dir$base.u - tmpdepfile3=$dir$base.u - "$@" -M - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - aix_post_process_depfile - ;; - -tcc) - # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 - # FIXME: That version still under development at the moment of writing. - # Make that this statement remains true also for stable, released - # versions. - # It will wrap lines (doesn't matter whether long or short) with a - # trailing '\', as in: - # - # foo.o : \ - # foo.c \ - # foo.h \ - # - # It will put a trailing '\' even on the last line, and will use leading - # spaces rather than leading tabs (at least since its commit 0394caf7 - # "Emit spaces for -MD"). - "$@" -MD -MF "$tmpdepfile" - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. - # We have to change lines of the first kind to '$object: \'. - sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" - # And for each line of the second kind, we have to emit a 'dep.h:' - # dummy dependency, to avoid the deleted-header problem. - sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" - rm -f "$tmpdepfile" - ;; - -## The order of this option in the case statement is important, since the -## shell code in configure will try each of these formats in the order -## listed in this file. A plain '-MD' option would be understood by many -## compilers, so we must ensure this comes after the gcc and icc options. -pgcc) - # Portland's C compiler understands '-MD'. - # Will always output deps to 'file.d' where file is the root name of the - # source file under compilation, even if file resides in a subdirectory. - # The object file name does not affect the name of the '.d' file. - # pgcc 10.2 will output - # foo.o: sub/foo.c sub/foo.h - # and will wrap long lines using '\' : - # foo.o: sub/foo.c ... \ - # sub/foo.h ... \ - # ... - set_dir_from "$object" - # Use the source, not the object, to determine the base name, since - # that's sadly what pgcc will do too. - set_base_from "$source" - tmpdepfile=$base.d - - # For projects that build the same source file twice into different object - # files, the pgcc approach of using the *source* file root name can cause - # problems in parallel builds. Use a locking strategy to avoid stomping on - # the same $tmpdepfile. - lockdir=$base.d-lock - trap " - echo '$0: caught signal, cleaning up...' >&2 - rmdir '$lockdir' - exit 1 - " 1 2 13 15 - numtries=100 - i=$numtries - while test $i -gt 0; do - # mkdir is a portable test-and-set. - if mkdir "$lockdir" 2>/dev/null; then - # This process acquired the lock. - "$@" -MD - stat=$? - # Release the lock. - rmdir "$lockdir" - break - else - # If the lock is being held by a different process, wait - # until the winning process is done or we timeout. - while test -d "$lockdir" && test $i -gt 0; do - sleep 1 - i=`expr $i - 1` - done - fi - i=`expr $i - 1` - done - trap - 1 2 13 15 - if test $i -le 0; then - echo "$0: failed to acquire lock after $numtries attempts" >&2 - echo "$0: check lockdir '$lockdir'" >&2 - exit 1 - fi - - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - # Each line is of the form `foo.o: dependent.h', - # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. - # Do two passes, one to just change these to - # `$object: dependent.h' and one to simply `dependent.h:'. - sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -hp2) - # The "hp" stanza above does not work with aCC (C++) and HP's ia64 - # compilers, which have integrated preprocessors. The correct option - # to use with these is +Maked; it writes dependencies to a file named - # 'foo.d', which lands next to the object file, wherever that - # happens to be. - # Much of this is similar to the tru64 case; see comments there. - set_dir_from "$object" - set_base_from "$object" - if test "$libtool" = yes; then - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir.libs/$base.d - "$@" -Wc,+Maked - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - "$@" +Maked - fi - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" - do - test -f "$tmpdepfile" && break - done - if test -f "$tmpdepfile"; then - sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" - # Add 'dependent.h:' lines. - sed -ne '2,${ - s/^ *// - s/ \\*$// - s/$/:/ - p - }' "$tmpdepfile" >> "$depfile" - else - make_dummy_depfile - fi - rm -f "$tmpdepfile" "$tmpdepfile2" - ;; - -tru64) - # The Tru64 compiler uses -MD to generate dependencies as a side - # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. - # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put - # dependencies in 'foo.d' instead, so we check for that too. - # Subdirectories are respected. - set_dir_from "$object" - set_base_from "$object" - - if test "$libtool" = yes; then - # Libtool generates 2 separate objects for the 2 libraries. These - # two compilations output dependencies in $dir.libs/$base.o.d and - # in $dir$base.o.d. We have to check for both files, because - # one of the two compilations can be disabled. We should prefer - # $dir$base.o.d over $dir.libs/$base.o.d because the latter is - # automatically cleaned when .libs/ is deleted, while ignoring - # the former would cause a distcleancheck panic. - tmpdepfile1=$dir$base.o.d # libtool 1.5 - tmpdepfile2=$dir.libs/$base.o.d # Likewise. - tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 - "$@" -Wc,-MD - else - tmpdepfile1=$dir$base.d - tmpdepfile2=$dir$base.d - tmpdepfile3=$dir$base.d - "$@" -MD - fi - - stat=$? - if test $stat -ne 0; then - rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - exit $stat - fi - - for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" - do - test -f "$tmpdepfile" && break - done - # Same post-processing that is required for AIX mode. - aix_post_process_depfile - ;; - -msvc7) - if test "$libtool" = yes; then - showIncludes=-Wc,-showIncludes - else - showIncludes=-showIncludes - fi - "$@" $showIncludes > "$tmpdepfile" - stat=$? - grep -v '^Note: including file: ' "$tmpdepfile" - if test $stat -ne 0; then - rm -f "$tmpdepfile" - exit $stat - fi - rm -f "$depfile" - echo "$object : \\" > "$depfile" - # The first sed program below extracts the file names and escapes - # backslashes for cygpath. The second sed program outputs the file - # name when reading, but also accumulates all include files in the - # hold buffer in order to output them again at the end. This only - # works with sed implementations that can handle large buffers. - sed < "$tmpdepfile" -n ' -/^Note: including file: *\(.*\)/ { - s//\1/ - s/\\/\\\\/g - p -}' | $cygpath_u | sort -u | sed -n ' -s/ /\\ /g -s/\(.*\)/'"$tab"'\1 \\/p -s/.\(.*\) \\/\1:/ -H -$ { - s/.*/'"$tab"'/ - G - p -}' >> "$depfile" - echo >> "$depfile" # make sure the fragment doesn't end with a backslash - rm -f "$tmpdepfile" - ;; - -msvc7msys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -#nosideeffect) - # This comment above is used by automake to tell side-effect - # dependency tracking mechanisms from slower ones. - -dashmstdout) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout, regardless of -o. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - test -z "$dashmflag" && dashmflag=-M - # Require at least two characters before searching for ':' - # in the target name. This is to cope with DOS-style filenames: - # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. - "$@" $dashmflag | - sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" - rm -f "$depfile" - cat < "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process this sed invocation - # correctly. Breaking it into two sed invocations is a workaround. - tr ' ' "$nl" < "$tmpdepfile" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -dashXmstdout) - # This case only exists to satisfy depend.m4. It is never actually - # run, as this mode is specially recognized in the preamble. - exit 1 - ;; - -makedepend) - "$@" || exit $? - # Remove any Libtool call - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - # X makedepend - shift - cleared=no eat=no - for arg - do - case $cleared in - no) - set ""; shift - cleared=yes ;; - esac - if test $eat = yes; then - eat=no - continue - fi - case "$arg" in - -D*|-I*) - set fnord "$@" "$arg"; shift ;; - # Strip any option that makedepend may not understand. Remove - # the object too, otherwise makedepend will parse it as a source file. - -arch) - eat=yes ;; - -*|$object) - ;; - *) - set fnord "$@" "$arg"; shift ;; - esac - done - obj_suffix=`echo "$object" | sed 's/^.*\././'` - touch "$tmpdepfile" - ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" - rm -f "$depfile" - # makedepend may prepend the VPATH from the source file name to the object. - # No need to regex-escape $object, excess matching of '.' is harmless. - sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" - # Some versions of the HPUX 10.20 sed can't process the last invocation - # correctly. Breaking it into two sed invocations is a workaround. - sed '1,2d' "$tmpdepfile" \ - | tr ' ' "$nl" \ - | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ - | sed -e 's/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" "$tmpdepfile".bak - ;; - -cpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - # Remove '-o $object'. - IFS=" " - for arg - do - case $arg in - -o) - shift - ;; - $object) - shift - ;; - *) - set fnord "$@" "$arg" - shift # fnord - shift # $arg - ;; - esac - done - - "$@" -E \ - | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ - | sed '$ s: \\$::' > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - cat < "$tmpdepfile" >> "$depfile" - sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvisualcpp) - # Important note: in order to support this mode, a compiler *must* - # always write the preprocessed file to stdout. - "$@" || exit $? - - # Remove the call to Libtool. - if test "$libtool" = yes; then - while test "X$1" != 'X--mode=compile'; do - shift - done - shift - fi - - IFS=" " - for arg - do - case "$arg" in - -o) - shift - ;; - $object) - shift - ;; - "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") - set fnord "$@" - shift - shift - ;; - *) - set fnord "$@" "$arg" - shift - shift - ;; - esac - done - "$@" -E 2>/dev/null | - sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" - rm -f "$depfile" - echo "$object : \\" > "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" - echo "$tab" >> "$depfile" - sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" - rm -f "$tmpdepfile" - ;; - -msvcmsys) - # This case exists only to let depend.m4 do its work. It works by - # looking at the text of this script. This case will never be run, - # since it is checked for above. - exit 1 - ;; - -none) - exec "$@" - ;; - -*) - echo "Unknown depmode $depmode" 1>&2 - exit 1 - ;; -esac - -exit 0 - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/install-sh b/lib/libcgroup-3.1.0/build-aux/install-sh deleted file mode 100755 index ec298b53740..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/install-sh +++ /dev/null @@ -1,541 +0,0 @@ -#!/bin/sh -# install - install a program, script, or datafile - -scriptversion=2020-11-14.01; # UTC - -# This originates from X11R5 (mit/util/scripts/install.sh), which was -# later released in X11R6 (xc/config/util/install.sh) with the -# following copyright and license. -# -# Copyright (C) 1994 X Consortium -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- -# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -# -# Except as contained in this notice, the name of the X Consortium shall not -# be used in advertising or otherwise to promote the sale, use or other deal- -# ings in this Software without prior written authorization from the X Consor- -# tium. -# -# -# FSF changes to this file are in the public domain. -# -# Calling this script install-sh is preferred over install.sh, to prevent -# 'make' implicit rules from creating a file called install from it -# when there is no Makefile. -# -# This script is compatible with the BSD install script, but was written -# from scratch. - -tab=' ' -nl=' -' -IFS=" $tab$nl" - -# Set DOITPROG to "echo" to test this script. - -doit=${DOITPROG-} -doit_exec=${doit:-exec} - -# Put in absolute file names if you don't have them in your path; -# or use environment vars. - -chgrpprog=${CHGRPPROG-chgrp} -chmodprog=${CHMODPROG-chmod} -chownprog=${CHOWNPROG-chown} -cmpprog=${CMPPROG-cmp} -cpprog=${CPPROG-cp} -mkdirprog=${MKDIRPROG-mkdir} -mvprog=${MVPROG-mv} -rmprog=${RMPROG-rm} -stripprog=${STRIPPROG-strip} - -posix_mkdir= - -# Desired mode of installed file. -mode=0755 - -# Create dirs (including intermediate dirs) using mode 755. -# This is like GNU 'install' as of coreutils 8.32 (2020). -mkdir_umask=22 - -backupsuffix= -chgrpcmd= -chmodcmd=$chmodprog -chowncmd= -mvcmd=$mvprog -rmcmd="$rmprog -f" -stripcmd= - -src= -dst= -dir_arg= -dst_arg= - -copy_on_change=false -is_target_a_directory=possibly - -usage="\ -Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE - or: $0 [OPTION]... SRCFILES... DIRECTORY - or: $0 [OPTION]... -t DIRECTORY SRCFILES... - or: $0 [OPTION]... -d DIRECTORIES... - -In the 1st form, copy SRCFILE to DSTFILE. -In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. -In the 4th, create DIRECTORIES. - -Options: - --help display this help and exit. - --version display version info and exit. - - -c (ignored) - -C install only if different (preserve data modification time) - -d create directories instead of installing files. - -g GROUP $chgrpprog installed files to GROUP. - -m MODE $chmodprog installed files to MODE. - -o USER $chownprog installed files to USER. - -p pass -p to $cpprog. - -s $stripprog installed files. - -S SUFFIX attempt to back up existing files, with suffix SUFFIX. - -t DIRECTORY install into DIRECTORY. - -T report an error if DSTFILE is a directory. - -Environment variables override the default commands: - CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG - RMPROG STRIPPROG - -By default, rm is invoked with -f; when overridden with RMPROG, -it's up to you to specify -f if you want it. - -If -S is not specified, no backups are attempted. - -Email bug reports to bug-automake@gnu.org. -Automake home page: https://www.gnu.org/software/automake/ -" - -while test $# -ne 0; do - case $1 in - -c) ;; - - -C) copy_on_change=true;; - - -d) dir_arg=true;; - - -g) chgrpcmd="$chgrpprog $2" - shift;; - - --help) echo "$usage"; exit $?;; - - -m) mode=$2 - case $mode in - *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*) - echo "$0: invalid mode: $mode" >&2 - exit 1;; - esac - shift;; - - -o) chowncmd="$chownprog $2" - shift;; - - -p) cpprog="$cpprog -p";; - - -s) stripcmd=$stripprog;; - - -S) backupsuffix="$2" - shift;; - - -t) - is_target_a_directory=always - dst_arg=$2 - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - shift;; - - -T) is_target_a_directory=never;; - - --version) echo "$0 $scriptversion"; exit $?;; - - --) shift - break;; - - -*) echo "$0: invalid option: $1" >&2 - exit 1;; - - *) break;; - esac - shift -done - -# We allow the use of options -d and -T together, by making -d -# take the precedence; this is for compatibility with GNU install. - -if test -n "$dir_arg"; then - if test -n "$dst_arg"; then - echo "$0: target directory not allowed when installing a directory." >&2 - exit 1 - fi -fi - -if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then - # When -d is used, all remaining arguments are directories to create. - # When -t is used, the destination is already specified. - # Otherwise, the last argument is the destination. Remove it from $@. - for arg - do - if test -n "$dst_arg"; then - # $@ is not empty: it contains at least $arg. - set fnord "$@" "$dst_arg" - shift # fnord - fi - shift # arg - dst_arg=$arg - # Protect names problematic for 'test' and other utilities. - case $dst_arg in - -* | [=\(\)!]) dst_arg=./$dst_arg;; - esac - done -fi - -if test $# -eq 0; then - if test -z "$dir_arg"; then - echo "$0: no input file specified." >&2 - exit 1 - fi - # It's OK to call 'install-sh -d' without argument. - # This can happen when creating conditional directories. - exit 0 -fi - -if test -z "$dir_arg"; then - if test $# -gt 1 || test "$is_target_a_directory" = always; then - if test ! -d "$dst_arg"; then - echo "$0: $dst_arg: Is not a directory." >&2 - exit 1 - fi - fi -fi - -if test -z "$dir_arg"; then - do_exit='(exit $ret); exit $ret' - trap "ret=129; $do_exit" 1 - trap "ret=130; $do_exit" 2 - trap "ret=141; $do_exit" 13 - trap "ret=143; $do_exit" 15 - - # Set umask so as not to create temps with too-generous modes. - # However, 'strip' requires both read and write access to temps. - case $mode in - # Optimize common cases. - *644) cp_umask=133;; - *755) cp_umask=22;; - - *[0-7]) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw='% 200' - fi - cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; - *) - if test -z "$stripcmd"; then - u_plus_rw= - else - u_plus_rw=,u+rw - fi - cp_umask=$mode$u_plus_rw;; - esac -fi - -for src -do - # Protect names problematic for 'test' and other utilities. - case $src in - -* | [=\(\)!]) src=./$src;; - esac - - if test -n "$dir_arg"; then - dst=$src - dstdir=$dst - test -d "$dstdir" - dstdir_status=$? - # Don't chown directories that already exist. - if test $dstdir_status = 0; then - chowncmd="" - fi - else - - # Waiting for this to be detected by the "$cpprog $src $dsttmp" command - # might cause directories to be created, which would be especially bad - # if $src (and thus $dsttmp) contains '*'. - if test ! -f "$src" && test ! -d "$src"; then - echo "$0: $src does not exist." >&2 - exit 1 - fi - - if test -z "$dst_arg"; then - echo "$0: no destination specified." >&2 - exit 1 - fi - dst=$dst_arg - - # If destination is a directory, append the input filename. - if test -d "$dst"; then - if test "$is_target_a_directory" = never; then - echo "$0: $dst_arg: Is a directory" >&2 - exit 1 - fi - dstdir=$dst - dstbase=`basename "$src"` - case $dst in - */) dst=$dst$dstbase;; - *) dst=$dst/$dstbase;; - esac - dstdir_status=0 - else - dstdir=`dirname "$dst"` - test -d "$dstdir" - dstdir_status=$? - fi - fi - - case $dstdir in - */) dstdirslash=$dstdir;; - *) dstdirslash=$dstdir/;; - esac - - obsolete_mkdir_used=false - - if test $dstdir_status != 0; then - case $posix_mkdir in - '') - # With -d, create the new directory with the user-specified mode. - # Otherwise, rely on $mkdir_umask. - if test -n "$dir_arg"; then - mkdir_mode=-m$mode - else - mkdir_mode= - fi - - posix_mkdir=false - # The $RANDOM variable is not portable (e.g., dash). Use it - # here however when possible just to lower collision chance. - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - - trap ' - ret=$? - rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null - exit $ret - ' 0 - - # Because "mkdir -p" follows existing symlinks and we likely work - # directly in world-writeable /tmp, make sure that the '$tmpdir' - # directory is successfully created first before we actually test - # 'mkdir -p'. - if (umask $mkdir_umask && - $mkdirprog $mkdir_mode "$tmpdir" && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 - then - if test -z "$dir_arg" || { - # Check for POSIX incompatibilities with -m. - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or - # other-writable bit of parent directory when it shouldn't. - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. - test_tmpdir="$tmpdir/a" - ls_ld_tmpdir=`ls -ld "$test_tmpdir"` - case $ls_ld_tmpdir in - d????-?r-*) different_mode=700;; - d????-?--*) different_mode=755;; - *) false;; - esac && - $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" - } - } - then posix_mkdir=: - fi - rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" - else - # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null - fi - trap '' 0;; - esac - - if - $posix_mkdir && ( - umask $mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" - ) - then : - else - - # mkdir does not conform to POSIX, - # or it failed possibly due to a race condition. Create the - # directory the slow way, step by step, checking for races as we go. - - case $dstdir in - /*) prefix='/';; - [-=\(\)!]*) prefix='./';; - *) prefix='';; - esac - - oIFS=$IFS - IFS=/ - set -f - set fnord $dstdir - shift - set +f - IFS=$oIFS - - prefixes= - - for d - do - test X"$d" = X && continue - - prefix=$prefix$d - if test -d "$prefix"; then - prefixes= - else - if $posix_mkdir; then - (umask $mkdir_umask && - $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break - # Don't fail if two instances are running concurrently. - test -d "$prefix" || exit 1 - else - case $prefix in - *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; - *) qprefix=$prefix;; - esac - prefixes="$prefixes '$qprefix'" - fi - fi - prefix=$prefix/ - done - - if test -n "$prefixes"; then - # Don't fail if two instances are running concurrently. - (umask $mkdir_umask && - eval "\$doit_exec \$mkdirprog $prefixes") || - test -d "$dstdir" || exit 1 - obsolete_mkdir_used=true - fi - fi - fi - - if test -n "$dir_arg"; then - { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && - { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || - test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 - else - - # Make a couple of temp file names in the proper directory. - dsttmp=${dstdirslash}_inst.$$_ - rmtmp=${dstdirslash}_rm.$$_ - - # Trap to clean up those temp files at exit. - trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 - - # Copy the file name to the temp name. - (umask $cp_umask && - { test -z "$stripcmd" || { - # Create $dsttmp read-write so that cp doesn't create it read-only, - # which would cause strip to fail. - if test -z "$doit"; then - : >"$dsttmp" # No need to fork-exec 'touch'. - else - $doit touch "$dsttmp" - fi - } - } && - $doit_exec $cpprog "$src" "$dsttmp") && - - # and set any options; do chmod last to preserve setuid bits. - # - # If any of these fail, we abort the whole thing. If we want to - # ignore errors from any of these, just make sure not to ignore - # errors from the above "$doit $cpprog $src $dsttmp" command. - # - { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && - { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && - { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && - { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && - - # If -C, don't bother to copy if it wouldn't change the file. - if $copy_on_change && - old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && - new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && - set -f && - set X $old && old=:$2:$4:$5:$6 && - set X $new && new=:$2:$4:$5:$6 && - set +f && - test "$old" = "$new" && - $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 - then - rm -f "$dsttmp" - else - # If $backupsuffix is set, and the file being installed - # already exists, attempt a backup. Don't worry if it fails, - # e.g., if mv doesn't support -f. - if test -n "$backupsuffix" && test -f "$dst"; then - $doit $mvcmd -f "$dst" "$dst$backupsuffix" 2>/dev/null - fi - - # Rename the file to the real destination. - $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || - - # The rename failed, perhaps because mv can't rename something else - # to itself, or perhaps because mv is so ancient that it does not - # support -f. - { - # Now remove or move aside any old file at destination location. - # We try this two ways since rm can't unlink itself on some - # systems and the destination file might be busy for other - # reasons. In this case, the final cleanup might fail but the new - # file should still install successfully. - { - test ! -f "$dst" || - $doit $rmcmd "$dst" 2>/dev/null || - { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && - { $doit $rmcmd "$rmtmp" 2>/dev/null; :; } - } || - { echo "$0: cannot unlink or rename $dst" >&2 - (exit 1); exit 1 - } - } && - - # Now rename the file to the real destination. - $doit $mvcmd "$dsttmp" "$dst" - } - fi || exit 1 - - trap '' 0 - fi -done - -# Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/ltmain.sh b/lib/libcgroup-3.1.0/build-aux/ltmain.sh deleted file mode 100644 index 49fcad1365c..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/ltmain.sh +++ /dev/null @@ -1,11429 +0,0 @@ -#! /usr/bin/env sh -## DO NOT EDIT - This file generated from ./build-aux/ltmain.in -## by inline-source v2019-02-19.15 - -# libtool (GNU libtool) 2.4.7 -# Provide generalized library-building support services. -# Written by Gordon Matzigkeit , 1996 - -# Copyright (C) 1996-2019, 2021-2022 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool 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. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool 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, see . - - -PROGRAM=libtool -PACKAGE=libtool -VERSION=2.4.7 -package_revision=2.4.7 - - -## ------ ## -## Usage. ## -## ------ ## - -# Run './libtool --help' for help with using this script from the -# command line. - - -## ------------------------------- ## -## User overridable command paths. ## -## ------------------------------- ## - -# After configure completes, it has a better idea of some of the -# shell tools we need than the defaults used by the functions shared -# with bootstrap, so set those here where they can still be over- -# ridden by the user, but otherwise take precedence. - -: ${AUTOCONF="autoconf"} -: ${AUTOMAKE="automake"} - - -## -------------------------- ## -## Source external libraries. ## -## -------------------------- ## - -# Much of our low-level functionality needs to be sourced from external -# libraries, which are installed to $pkgauxdir. - -# Set a version string for this script. -scriptversion=2019-02-19.15; # UTC - -# General shell script boiler plate, and helper functions. -# Written by Gary V. Vaughan, 2004 - -# This is free software. There is NO warranty; not even for -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -# -# Copyright (C) 2004-2019, 2021 Bootstrap Authors -# -# This file is dual licensed under the terms of the MIT license -# , and GPL version 2 or later -# . You must apply one of -# these licenses when using or redistributing this software or any of -# the files within it. See the URLs above, or the file `LICENSE` -# included in the Bootstrap distribution for the full license texts. - -# Please report bugs or propose patches to: -# - - -## ------ ## -## Usage. ## -## ------ ## - -# Evaluate this file near the top of your script to gain access to -# the functions and variables defined here: -# -# . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh -# -# If you need to override any of the default environment variable -# settings, do that before evaluating this file. - - -## -------------------- ## -## Shell normalisation. ## -## -------------------- ## - -# Some shells need a little help to be as Bourne compatible as possible. -# Before doing anything else, make sure all that help has been provided! - -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac -fi - -# NLS nuisances: We save the old values in case they are required later. -_G_user_locale= -_G_safe_locale= -for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES -do - eval "if test set = \"\${$_G_var+set}\"; then - save_$_G_var=\$$_G_var - $_G_var=C - export $_G_var - _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\" - _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" - fi" -done -# These NLS vars are set unconditionally (bootstrap issue #24). Unset those -# in case the environment reset is needed later and the $save_* variant is not -# defined (see the code above). -LC_ALL=C -LANGUAGE=C -export LANGUAGE LC_ALL - -# Make sure IFS has a sensible default -sp=' ' -nl=' -' -IFS="$sp $nl" - -# There are apparently some retarded systems that use ';' as a PATH separator! -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# func_unset VAR -# -------------- -# Portably unset VAR. -# In some shells, an 'unset VAR' statement leaves a non-zero return -# status if VAR is already unset, which might be problematic if the -# statement is used at the end of a function (thus poisoning its return -# value) or when 'set -e' is active (causing even a spurious abort of -# the script in this case). -func_unset () -{ - { eval $1=; (eval unset $1) >/dev/null 2>&1 && eval unset $1 || : ; } -} - - -# Make sure CDPATH doesn't cause `cd` commands to output the target dir. -func_unset CDPATH - -# Make sure ${,E,F}GREP behave sanely. -func_unset GREP_OPTIONS - - -## ------------------------- ## -## Locate command utilities. ## -## ------------------------- ## - - -# func_executable_p FILE -# ---------------------- -# Check that FILE is an executable regular file. -func_executable_p () -{ - test -f "$1" && test -x "$1" -} - - -# func_path_progs PROGS_LIST CHECK_FUNC [PATH] -# -------------------------------------------- -# Search for either a program that responds to --version with output -# containing "GNU", or else returned by CHECK_FUNC otherwise, by -# trying all the directories in PATH with each of the elements of -# PROGS_LIST. -# -# CHECK_FUNC should accept the path to a candidate program, and -# set $func_check_prog_result if it truncates its output less than -# $_G_path_prog_max characters. -func_path_progs () -{ - _G_progs_list=$1 - _G_check_func=$2 - _G_PATH=${3-"$PATH"} - - _G_path_prog_max=0 - _G_path_prog_found=false - _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:} - for _G_dir in $_G_PATH; do - IFS=$_G_save_IFS - test -z "$_G_dir" && _G_dir=. - for _G_prog_name in $_G_progs_list; do - for _exeext in '' .EXE; do - _G_path_prog=$_G_dir/$_G_prog_name$_exeext - func_executable_p "$_G_path_prog" || continue - case `"$_G_path_prog" --version 2>&1` in - *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;; - *) $_G_check_func $_G_path_prog - func_path_progs_result=$func_check_prog_result - ;; - esac - $_G_path_prog_found && break 3 - done - done - done - IFS=$_G_save_IFS - test -z "$func_path_progs_result" && { - echo "no acceptable sed could be found in \$PATH" >&2 - exit 1 - } -} - - -# We want to be able to use the functions in this file before configure -# has figured out where the best binaries are kept, which means we have -# to search for them ourselves - except when the results are already set -# where we skip the searches. - -# Unless the user overrides by setting SED, search the path for either GNU -# sed, or the sed that truncates its output the least. -test -z "$SED" && { - _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for _G_i in 1 2 3 4 5 6 7; do - _G_sed_script=$_G_sed_script$nl$_G_sed_script - done - echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed - _G_sed_script= - - func_check_prog_sed () - { - _G_path_prog=$1 - - _G_count=0 - printf 0123456789 >conftest.in - while : - do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo '' >> conftest.nl - "$_G_path_prog" -f conftest.sed conftest.out 2>/dev/null || break - diff conftest.out conftest.nl >/dev/null 2>&1 || break - _G_count=`expr $_G_count + 1` - if test "$_G_count" -gt "$_G_path_prog_max"; then - # Best one so far, save it but keep looking for a better one - func_check_prog_result=$_G_path_prog - _G_path_prog_max=$_G_count - fi - # 10*(2^10) chars as input seems more than enough - test 10 -lt "$_G_count" && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out - } - - func_path_progs "sed gsed" func_check_prog_sed "$PATH:/usr/xpg4/bin" - rm -f conftest.sed - SED=$func_path_progs_result -} - - -# Unless the user overrides by setting GREP, search the path for either GNU -# grep, or the grep that truncates its output the least. -test -z "$GREP" && { - func_check_prog_grep () - { - _G_path_prog=$1 - - _G_count=0 - _G_path_prog_max=0 - printf 0123456789 >conftest.in - while : - do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo 'GREP' >> conftest.nl - "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' conftest.out 2>/dev/null || break - diff conftest.out conftest.nl >/dev/null 2>&1 || break - _G_count=`expr $_G_count + 1` - if test "$_G_count" -gt "$_G_path_prog_max"; then - # Best one so far, save it but keep looking for a better one - func_check_prog_result=$_G_path_prog - _G_path_prog_max=$_G_count - fi - # 10*(2^10) chars as input seems more than enough - test 10 -lt "$_G_count" && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out - } - - func_path_progs "grep ggrep" func_check_prog_grep "$PATH:/usr/xpg4/bin" - GREP=$func_path_progs_result -} - - -## ------------------------------- ## -## User overridable command paths. ## -## ------------------------------- ## - -# All uppercase variable names are used for environment variables. These -# variables can be overridden by the user before calling a script that -# uses them if a suitable command of that name is not already available -# in the command search PATH. - -: ${CP="cp -f"} -: ${ECHO="printf %s\n"} -: ${EGREP="$GREP -E"} -: ${FGREP="$GREP -F"} -: ${LN_S="ln -s"} -: ${MAKE="make"} -: ${MKDIR="mkdir"} -: ${MV="mv -f"} -: ${RM="rm -f"} -: ${SHELL="${CONFIG_SHELL-/bin/sh}"} - - -## -------------------- ## -## Useful sed snippets. ## -## -------------------- ## - -sed_dirname='s|/[^/]*$||' -sed_basename='s|^.*/||' - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='s|\([`"$\\]\)|\\\1|g' - -# Same as above, but do not quote variable references. -sed_double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution that turns a string into a regex matching for the -# string literally. -sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g' - -# Sed substitution that converts a w32 file name or path -# that contains forward slashes, into one that contains -# (escaped) backslashes. A very naive implementation. -sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - -# Re-'\' parameter expansions in output of sed_double_quote_subst that -# were '\'-ed in input to the same. If an odd number of '\' preceded a -# '$' in input to sed_double_quote_subst, that '$' was protected from -# expansion. Since each input '\' is now two '\'s, look for any number -# of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'. -_G_bs='\\' -_G_bs2='\\\\' -_G_bs4='\\\\\\\\' -_G_dollar='\$' -sed_double_backslash="\ - s/$_G_bs4/&\\ -/g - s/^$_G_bs2$_G_dollar/$_G_bs&/ - s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g - s/\n//g" - -# require_check_ifs_backslash -# --------------------------- -# Check if we can use backslash as IFS='\' separator, and set -# $check_ifs_backshlash_broken to ':' or 'false'. -require_check_ifs_backslash=func_require_check_ifs_backslash -func_require_check_ifs_backslash () -{ - _G_save_IFS=$IFS - IFS='\' - _G_check_ifs_backshlash='a\\b' - for _G_i in $_G_check_ifs_backshlash - do - case $_G_i in - a) - check_ifs_backshlash_broken=false - ;; - '') - break - ;; - *) - check_ifs_backshlash_broken=: - break - ;; - esac - done - IFS=$_G_save_IFS - require_check_ifs_backslash=: -} - - -## ----------------- ## -## Global variables. ## -## ----------------- ## - -# Except for the global variables explicitly listed below, the following -# functions in the '^func_' namespace, and the '^require_' namespace -# variables initialised in the 'Resource management' section, sourcing -# this file will not pollute your global namespace with anything -# else. There's no portable way to scope variables in Bourne shell -# though, so actually running these functions will sometimes place -# results into a variable named after the function, and often use -# temporary variables in the '^_G_' namespace. If you are careful to -# avoid using those namespaces casually in your sourcing script, things -# should continue to work as you expect. And, of course, you can freely -# overwrite any of the functions or variables defined here before -# calling anything to customize them. - -EXIT_SUCCESS=0 -EXIT_FAILURE=1 -EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. -EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. - -# Allow overriding, eg assuming that you follow the convention of -# putting '$debug_cmd' at the start of all your functions, you can get -# bash to show function call trace with: -# -# debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name -debug_cmd=${debug_cmd-":"} -exit_cmd=: - -# By convention, finish your script with: -# -# exit $exit_status -# -# so that you can set exit_status to non-zero if you want to indicate -# something went wrong during execution without actually bailing out at -# the point of failure. -exit_status=$EXIT_SUCCESS - -# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh -# is ksh but when the shell is invoked as "sh" and the current value of -# the _XPG environment variable is not equal to 1 (one), the special -# positional parameter $0, within a function call, is the name of the -# function. -progpath=$0 - -# The name of this program. -progname=`$ECHO "$progpath" |$SED "$sed_basename"` - -# Make sure we have an absolute progpath for reexecution: -case $progpath in - [\\/]*|[A-Za-z]:\\*) ;; - *[\\/]*) - progdir=`$ECHO "$progpath" |$SED "$sed_dirname"` - progdir=`cd "$progdir" && pwd` - progpath=$progdir/$progname - ;; - *) - _G_IFS=$IFS - IFS=${PATH_SEPARATOR-:} - for progdir in $PATH; do - IFS=$_G_IFS - test -x "$progdir/$progname" && break - done - IFS=$_G_IFS - test -n "$progdir" || progdir=`pwd` - progpath=$progdir/$progname - ;; -esac - - -## ----------------- ## -## Standard options. ## -## ----------------- ## - -# The following options affect the operation of the functions defined -# below, and should be set appropriately depending on run-time para- -# meters passed on the command line. - -opt_dry_run=false -opt_quiet=false -opt_verbose=false - -# Categories 'all' and 'none' are always available. Append any others -# you will pass as the first argument to func_warning from your own -# code. -warning_categories= - -# By default, display warnings according to 'opt_warning_types'. Set -# 'warning_func' to ':' to elide all warnings, or func_fatal_error to -# treat the next displayed warning as a fatal error. -warning_func=func_warn_and_continue - -# Set to 'all' to display all warnings, 'none' to suppress all -# warnings, or a space delimited list of some subset of -# 'warning_categories' to display only the listed warnings. -opt_warning_types=all - - -## -------------------- ## -## Resource management. ## -## -------------------- ## - -# This section contains definitions for functions that each ensure a -# particular resource (a file, or a non-empty configuration variable for -# example) is available, and if appropriate to extract default values -# from pertinent package files. Call them using their associated -# 'require_*' variable to ensure that they are executed, at most, once. -# -# It's entirely deliberate that calling these functions can set -# variables that don't obey the namespace limitations obeyed by the rest -# of this file, in order that that they be as useful as possible to -# callers. - - -# require_term_colors -# ------------------- -# Allow display of bold text on terminals that support it. -require_term_colors=func_require_term_colors -func_require_term_colors () -{ - $debug_cmd - - test -t 1 && { - # COLORTERM and USE_ANSI_COLORS environment variables take - # precedence, because most terminfo databases neglect to describe - # whether color sequences are supported. - test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"} - - if test 1 = "$USE_ANSI_COLORS"; then - # Standard ANSI escape sequences - tc_reset='' - tc_bold=''; tc_standout='' - tc_red=''; tc_green='' - tc_blue=''; tc_cyan='' - else - # Otherwise trust the terminfo database after all. - test -n "`tput sgr0 2>/dev/null`" && { - tc_reset=`tput sgr0` - test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold` - tc_standout=$tc_bold - test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso` - test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1` - test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2` - test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4` - test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5` - } - fi - } - - require_term_colors=: -} - - -## ----------------- ## -## Function library. ## -## ----------------- ## - -# This section contains a variety of useful functions to call in your -# scripts. Take note of the portable wrappers for features provided by -# some modern shells, which will fall back to slower equivalents on -# less featureful shells. - - -# func_append VAR VALUE -# --------------------- -# Append VALUE onto the existing contents of VAR. - - # We should try to minimise forks, especially on Windows where they are - # unreasonably slow, so skip the feature probes when bash or zsh are - # being used: - if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then - : ${_G_HAVE_ARITH_OP="yes"} - : ${_G_HAVE_XSI_OPS="yes"} - # The += operator was introduced in bash 3.1 - case $BASH_VERSION in - [12].* | 3.0 | 3.0*) ;; - *) - : ${_G_HAVE_PLUSEQ_OP="yes"} - ;; - esac - fi - - # _G_HAVE_PLUSEQ_OP - # Can be empty, in which case the shell is probed, "yes" if += is - # useable or anything else if it does not work. - test -z "$_G_HAVE_PLUSEQ_OP" \ - && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ - && _G_HAVE_PLUSEQ_OP=yes - -if test yes = "$_G_HAVE_PLUSEQ_OP" -then - # This is an XSI compatible shell, allowing a faster implementation... - eval 'func_append () - { - $debug_cmd - - eval "$1+=\$2" - }' -else - # ...otherwise fall back to using expr, which is often a shell builtin. - func_append () - { - $debug_cmd - - eval "$1=\$$1\$2" - } -fi - - -# func_append_quoted VAR VALUE -# ---------------------------- -# Quote VALUE and append to the end of shell variable VAR, separated -# by a space. -if test yes = "$_G_HAVE_PLUSEQ_OP"; then - eval 'func_append_quoted () - { - $debug_cmd - - func_quote_arg pretty "$2" - eval "$1+=\\ \$func_quote_arg_result" - }' -else - func_append_quoted () - { - $debug_cmd - - func_quote_arg pretty "$2" - eval "$1=\$$1\\ \$func_quote_arg_result" - } -fi - - -# func_append_uniq VAR VALUE -# -------------------------- -# Append unique VALUE onto the existing contents of VAR, assuming -# entries are delimited by the first character of VALUE. For example: -# -# func_append_uniq options " --another-option option-argument" -# -# will only append to $options if " --another-option option-argument " -# is not already present somewhere in $options already (note spaces at -# each end implied by leading space in second argument). -func_append_uniq () -{ - $debug_cmd - - eval _G_current_value='`$ECHO $'$1'`' - _G_delim=`expr "$2" : '\(.\)'` - - case $_G_delim$_G_current_value$_G_delim in - *"$2$_G_delim"*) ;; - *) func_append "$@" ;; - esac -} - - -# func_arith TERM... -# ------------------ -# Set func_arith_result to the result of evaluating TERMs. - test -z "$_G_HAVE_ARITH_OP" \ - && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \ - && _G_HAVE_ARITH_OP=yes - -if test yes = "$_G_HAVE_ARITH_OP"; then - eval 'func_arith () - { - $debug_cmd - - func_arith_result=$(( $* )) - }' -else - func_arith () - { - $debug_cmd - - func_arith_result=`expr "$@"` - } -fi - - -# func_basename FILE -# ------------------ -# Set func_basename_result to FILE with everything up to and including -# the last / stripped. -if test yes = "$_G_HAVE_XSI_OPS"; then - # If this shell supports suffix pattern removal, then use it to avoid - # forking. Hide the definitions single quotes in case the shell chokes - # on unsupported syntax... - _b='func_basename_result=${1##*/}' - _d='case $1 in - */*) func_dirname_result=${1%/*}$2 ;; - * ) func_dirname_result=$3 ;; - esac' - -else - # ...otherwise fall back to using sed. - _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`' - _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"` - if test "X$func_dirname_result" = "X$1"; then - func_dirname_result=$3 - else - func_append func_dirname_result "$2" - fi' -fi - -eval 'func_basename () -{ - $debug_cmd - - '"$_b"' -}' - - -# func_dirname FILE APPEND NONDIR_REPLACEMENT -# ------------------------------------------- -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -eval 'func_dirname () -{ - $debug_cmd - - '"$_d"' -}' - - -# func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT -# -------------------------------------------------------- -# Perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# For efficiency, we do not delegate to the functions above but instead -# duplicate the functionality here. -eval 'func_dirname_and_basename () -{ - $debug_cmd - - '"$_b"' - '"$_d"' -}' - - -# func_echo ARG... -# ---------------- -# Echo program name prefixed message. -func_echo () -{ - $debug_cmd - - _G_message=$* - - func_echo_IFS=$IFS - IFS=$nl - for _G_line in $_G_message; do - IFS=$func_echo_IFS - $ECHO "$progname: $_G_line" - done - IFS=$func_echo_IFS -} - - -# func_echo_all ARG... -# -------------------- -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - - -# func_echo_infix_1 INFIX ARG... -# ------------------------------ -# Echo program name, followed by INFIX on the first line, with any -# additional lines not showing INFIX. -func_echo_infix_1 () -{ - $debug_cmd - - $require_term_colors - - _G_infix=$1; shift - _G_indent=$_G_infix - _G_prefix="$progname: $_G_infix: " - _G_message=$* - - # Strip color escape sequences before counting printable length - for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan" - do - test -n "$_G_tc" && { - _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"` - _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"` - } - done - _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes - - func_echo_infix_1_IFS=$IFS - IFS=$nl - for _G_line in $_G_message; do - IFS=$func_echo_infix_1_IFS - $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2 - _G_prefix=$_G_indent - done - IFS=$func_echo_infix_1_IFS -} - - -# func_error ARG... -# ----------------- -# Echo program name prefixed message to standard error. -func_error () -{ - $debug_cmd - - $require_term_colors - - func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2 -} - - -# func_fatal_error ARG... -# ----------------------- -# Echo program name prefixed message to standard error, and exit. -func_fatal_error () -{ - $debug_cmd - - func_error "$*" - exit $EXIT_FAILURE -} - - -# func_grep EXPRESSION FILENAME -# ----------------------------- -# Check whether EXPRESSION matches any line of FILENAME, without output. -func_grep () -{ - $debug_cmd - - $GREP "$1" "$2" >/dev/null 2>&1 -} - - -# func_len STRING -# --------------- -# Set func_len_result to the length of STRING. STRING may not -# start with a hyphen. - test -z "$_G_HAVE_XSI_OPS" \ - && (eval 'x=a/b/c; - test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ - && _G_HAVE_XSI_OPS=yes - -if test yes = "$_G_HAVE_XSI_OPS"; then - eval 'func_len () - { - $debug_cmd - - func_len_result=${#1} - }' -else - func_len () - { - $debug_cmd - - func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` - } -fi - - -# func_mkdir_p DIRECTORY-PATH -# --------------------------- -# Make sure the entire path to DIRECTORY-PATH is available. -func_mkdir_p () -{ - $debug_cmd - - _G_directory_path=$1 - _G_dir_list= - - if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then - - # Protect directory names starting with '-' - case $_G_directory_path in - -*) _G_directory_path=./$_G_directory_path ;; - esac - - # While some portion of DIR does not yet exist... - while test ! -d "$_G_directory_path"; do - # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. - _G_dir_list=$_G_directory_path:$_G_dir_list - - # If the last portion added has no slash in it, the list is done - case $_G_directory_path in */*) ;; *) break ;; esac - - # ...otherwise throw away the child directory and loop - _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"` - done - _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'` - - func_mkdir_p_IFS=$IFS; IFS=: - for _G_dir in $_G_dir_list; do - IFS=$func_mkdir_p_IFS - # mkdir can fail with a 'File exist' error if two processes - # try to create one of the directories concurrently. Don't - # stop in that case! - $MKDIR "$_G_dir" 2>/dev/null || : - done - IFS=$func_mkdir_p_IFS - - # Bail out if we (or some other process) failed to create a directory. - test -d "$_G_directory_path" || \ - func_fatal_error "Failed to create '$1'" - fi -} - - -# func_mktempdir [BASENAME] -# ------------------------- -# Make a temporary directory that won't clash with other running -# libtool processes, and avoids race conditions if possible. If -# given, BASENAME is the basename for that directory. -func_mktempdir () -{ - $debug_cmd - - _G_template=${TMPDIR-/tmp}/${1-$progname} - - if test : = "$opt_dry_run"; then - # Return a directory name, but don't create it in dry-run mode - _G_tmpdir=$_G_template-$$ - else - - # If mktemp works, use that first and foremost - _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null` - - if test ! -d "$_G_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - _G_tmpdir=$_G_template-${RANDOM-0}$$ - - func_mktempdir_umask=`umask` - umask 0077 - $MKDIR "$_G_tmpdir" - umask $func_mktempdir_umask - fi - - # If we're not in dry-run mode, bomb out on failure - test -d "$_G_tmpdir" || \ - func_fatal_error "cannot create temporary directory '$_G_tmpdir'" - fi - - $ECHO "$_G_tmpdir" -} - - -# func_normal_abspath PATH -# ------------------------ -# Remove doubled-up and trailing slashes, "." path components, -# and cancel out any ".." path components in PATH after making -# it an absolute path. -func_normal_abspath () -{ - $debug_cmd - - # These SED scripts presuppose an absolute path with a trailing slash. - _G_pathcar='s|^/\([^/]*\).*$|\1|' - _G_pathcdr='s|^/[^/]*||' - _G_removedotparts=':dotsl - s|/\./|/|g - t dotsl - s|/\.$|/|' - _G_collapseslashes='s|/\{1,\}|/|g' - _G_finalslash='s|/*$|/|' - - # Start from root dir and reassemble the path. - func_normal_abspath_result= - func_normal_abspath_tpath=$1 - func_normal_abspath_altnamespace= - case $func_normal_abspath_tpath in - "") - # Empty path, that just means $cwd. - func_stripname '' '/' "`pwd`" - func_normal_abspath_result=$func_stripname_result - return - ;; - # The next three entries are used to spot a run of precisely - # two leading slashes without using negated character classes; - # we take advantage of case's first-match behaviour. - ///*) - # Unusual form of absolute path, do nothing. - ;; - //*) - # Not necessarily an ordinary path; POSIX reserves leading '//' - # and for example Cygwin uses it to access remote file shares - # over CIFS/SMB, so we conserve a leading double slash if found. - func_normal_abspath_altnamespace=/ - ;; - /*) - # Absolute path, do nothing. - ;; - *) - # Relative path, prepend $cwd. - func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath - ;; - esac - - # Cancel out all the simple stuff to save iterations. We also want - # the path to end with a slash for ease of parsing, so make sure - # there is one (and only one) here. - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"` - while :; do - # Processed it all yet? - if test / = "$func_normal_abspath_tpath"; then - # If we ascended to the root using ".." the result may be empty now. - if test -z "$func_normal_abspath_result"; then - func_normal_abspath_result=/ - fi - break - fi - func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$_G_pathcar"` - func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ - -e "$_G_pathcdr"` - # Figure out what to do with it - case $func_normal_abspath_tcomponent in - "") - # Trailing empty path component, ignore it. - ;; - ..) - # Parent dir; strip last assembled component from result. - func_dirname "$func_normal_abspath_result" - func_normal_abspath_result=$func_dirname_result - ;; - *) - # Actual path component, append it. - func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" - ;; - esac - done - # Restore leading double-slash if one was found on entry. - func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result -} - - -# func_notquiet ARG... -# -------------------- -# Echo program name prefixed message only when not in quiet mode. -func_notquiet () -{ - $debug_cmd - - $opt_quiet || func_echo ${1+"$@"} - - # A bug in bash halts the script if the last line of a function - # fails when set -e is in force, so we need another command to - # work around that: - : -} - - -# func_relative_path SRCDIR DSTDIR -# -------------------------------- -# Set func_relative_path_result to the relative path from SRCDIR to DSTDIR. -func_relative_path () -{ - $debug_cmd - - func_relative_path_result= - func_normal_abspath "$1" - func_relative_path_tlibdir=$func_normal_abspath_result - func_normal_abspath "$2" - func_relative_path_tbindir=$func_normal_abspath_result - - # Ascend the tree starting from libdir - while :; do - # check if we have found a prefix of bindir - case $func_relative_path_tbindir in - $func_relative_path_tlibdir) - # found an exact match - func_relative_path_tcancelled= - break - ;; - $func_relative_path_tlibdir*) - # found a matching prefix - func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" - func_relative_path_tcancelled=$func_stripname_result - if test -z "$func_relative_path_result"; then - func_relative_path_result=. - fi - break - ;; - *) - func_dirname $func_relative_path_tlibdir - func_relative_path_tlibdir=$func_dirname_result - if test -z "$func_relative_path_tlibdir"; then - # Have to descend all the way to the root! - func_relative_path_result=../$func_relative_path_result - func_relative_path_tcancelled=$func_relative_path_tbindir - break - fi - func_relative_path_result=../$func_relative_path_result - ;; - esac - done - - # Now calculate path; take care to avoid doubling-up slashes. - func_stripname '' '/' "$func_relative_path_result" - func_relative_path_result=$func_stripname_result - func_stripname '/' '/' "$func_relative_path_tcancelled" - if test -n "$func_stripname_result"; then - func_append func_relative_path_result "/$func_stripname_result" - fi - - # Normalisation. If bindir is libdir, return '.' else relative path. - if test -n "$func_relative_path_result"; then - func_stripname './' '' "$func_relative_path_result" - func_relative_path_result=$func_stripname_result - fi - - test -n "$func_relative_path_result" || func_relative_path_result=. - - : -} - - -# func_quote_portable EVAL ARG -# ---------------------------- -# Internal function to portably implement func_quote_arg. Note that we still -# keep attention to performance here so we as much as possible try to avoid -# calling sed binary (so far O(N) complexity as long as func_append is O(1)). -func_quote_portable () -{ - $debug_cmd - - $require_check_ifs_backslash - - func_quote_portable_result=$2 - - # one-time-loop (easy break) - while true - do - if $1; then - func_quote_portable_result=`$ECHO "$2" | $SED \ - -e "$sed_double_quote_subst" -e "$sed_double_backslash"` - break - fi - - # Quote for eval. - case $func_quote_portable_result in - *[\\\`\"\$]*) - # Fallback to sed for $func_check_bs_ifs_broken=:, or when the string - # contains the shell wildcard characters. - case $check_ifs_backshlash_broken$func_quote_portable_result in - :*|*[\[\*\?]*) - func_quote_portable_result=`$ECHO "$func_quote_portable_result" \ - | $SED "$sed_quote_subst"` - break - ;; - esac - - func_quote_portable_old_IFS=$IFS - for _G_char in '\' '`' '"' '$' - do - # STATE($1) PREV($2) SEPARATOR($3) - set start "" "" - func_quote_portable_result=dummy"$_G_char$func_quote_portable_result$_G_char"dummy - IFS=$_G_char - for _G_part in $func_quote_portable_result - do - case $1 in - quote) - func_append func_quote_portable_result "$3$2" - set quote "$_G_part" "\\$_G_char" - ;; - start) - set first "" "" - func_quote_portable_result= - ;; - first) - set quote "$_G_part" "" - ;; - esac - done - done - IFS=$func_quote_portable_old_IFS - ;; - *) ;; - esac - break - done - - func_quote_portable_unquoted_result=$func_quote_portable_result - case $func_quote_portable_result in - # double-quote args containing shell metacharacters to delay - # word splitting, command substitution and variable expansion - # for a subsequent eval. - # many bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - func_quote_portable_result=\"$func_quote_portable_result\" - ;; - esac -} - - -# func_quotefast_eval ARG -# ----------------------- -# Quote one ARG (internal). This is equivalent to 'func_quote_arg eval ARG', -# but optimized for speed. Result is stored in $func_quotefast_eval. -if test xyes = `(x=; printf -v x %q yes; echo x"$x") 2>/dev/null`; then - printf -v _GL_test_printf_tilde %q '~' - if test '\~' = "$_GL_test_printf_tilde"; then - func_quotefast_eval () - { - printf -v func_quotefast_eval_result %q "$1" - } - else - # Broken older Bash implementations. Make those faster too if possible. - func_quotefast_eval () - { - case $1 in - '~'*) - func_quote_portable false "$1" - func_quotefast_eval_result=$func_quote_portable_result - ;; - *) - printf -v func_quotefast_eval_result %q "$1" - ;; - esac - } - fi -else - func_quotefast_eval () - { - func_quote_portable false "$1" - func_quotefast_eval_result=$func_quote_portable_result - } -fi - - -# func_quote_arg MODEs ARG -# ------------------------ -# Quote one ARG to be evaled later. MODEs argument may contain zero or more -# specifiers listed below separated by ',' character. This function returns two -# values: -# i) func_quote_arg_result -# double-quoted (when needed), suitable for a subsequent eval -# ii) func_quote_arg_unquoted_result -# has all characters that are still active within double -# quotes backslashified. Available only if 'unquoted' is specified. -# -# Available modes: -# ---------------- -# 'eval' (default) -# - escape shell special characters -# 'expand' -# - the same as 'eval'; but do not quote variable references -# 'pretty' -# - request aesthetic output, i.e. '"a b"' instead of 'a\ b'. This might -# be used later in func_quote to get output like: 'echo "a b"' instead -# of 'echo a\ b'. This is slower than default on some shells. -# 'unquoted' -# - produce also $func_quote_arg_unquoted_result which does not contain -# wrapping double-quotes. -# -# Examples for 'func_quote_arg pretty,unquoted string': -# -# string | *_result | *_unquoted_result -# ------------+-----------------------+------------------- -# " | \" | \" -# a b | "a b" | a b -# "a b" | "\"a b\"" | \"a b\" -# * | "*" | * -# z="${x-$y}" | "z=\"\${x-\$y}\"" | z=\"\${x-\$y}\" -# -# Examples for 'func_quote_arg pretty,unquoted,expand string': -# -# string | *_result | *_unquoted_result -# --------------+---------------------+-------------------- -# z="${x-$y}" | "z=\"${x-$y}\"" | z=\"${x-$y}\" -func_quote_arg () -{ - _G_quote_expand=false - case ,$1, in - *,expand,*) - _G_quote_expand=: - ;; - esac - - case ,$1, in - *,pretty,*|*,expand,*|*,unquoted,*) - func_quote_portable $_G_quote_expand "$2" - func_quote_arg_result=$func_quote_portable_result - func_quote_arg_unquoted_result=$func_quote_portable_unquoted_result - ;; - *) - # Faster quote-for-eval for some shells. - func_quotefast_eval "$2" - func_quote_arg_result=$func_quotefast_eval_result - ;; - esac -} - - -# func_quote MODEs ARGs... -# ------------------------ -# Quote all ARGs to be evaled later and join them into single command. See -# func_quote_arg's description for more info. -func_quote () -{ - $debug_cmd - _G_func_quote_mode=$1 ; shift - func_quote_result= - while test 0 -lt $#; do - func_quote_arg "$_G_func_quote_mode" "$1" - if test -n "$func_quote_result"; then - func_append func_quote_result " $func_quote_arg_result" - else - func_append func_quote_result "$func_quote_arg_result" - fi - shift - done -} - - -# func_stripname PREFIX SUFFIX NAME -# --------------------------------- -# strip PREFIX and SUFFIX from NAME, and store in func_stripname_result. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -if test yes = "$_G_HAVE_XSI_OPS"; then - eval 'func_stripname () - { - $debug_cmd - - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary variable first. - func_stripname_result=$3 - func_stripname_result=${func_stripname_result#"$1"} - func_stripname_result=${func_stripname_result%"$2"} - }' -else - func_stripname () - { - $debug_cmd - - case $2 in - .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;; - *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;; - esac - } -fi - - -# func_show_eval CMD [FAIL_EXP] -# ----------------------------- -# Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. -func_show_eval () -{ - $debug_cmd - - _G_cmd=$1 - _G_fail_exp=${2-':'} - - func_quote_arg pretty,expand "$_G_cmd" - eval "func_notquiet $func_quote_arg_result" - - $opt_dry_run || { - eval "$_G_cmd" - _G_status=$? - if test 0 -ne "$_G_status"; then - eval "(exit $_G_status); $_G_fail_exp" - fi - } -} - - -# func_show_eval_locale CMD [FAIL_EXP] -# ------------------------------------ -# Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. Use the saved locale for evaluation. -func_show_eval_locale () -{ - $debug_cmd - - _G_cmd=$1 - _G_fail_exp=${2-':'} - - $opt_quiet || { - func_quote_arg expand,pretty "$_G_cmd" - eval "func_echo $func_quote_arg_result" - } - - $opt_dry_run || { - eval "$_G_user_locale - $_G_cmd" - _G_status=$? - eval "$_G_safe_locale" - if test 0 -ne "$_G_status"; then - eval "(exit $_G_status); $_G_fail_exp" - fi - } -} - - -# func_tr_sh -# ---------- -# Turn $1 into a string suitable for a shell variable name. -# Result is stored in $func_tr_sh_result. All characters -# not in the set a-zA-Z0-9_ are replaced with '_'. Further, -# if $1 begins with a digit, a '_' is prepended as well. -func_tr_sh () -{ - $debug_cmd - - case $1 in - [0-9]* | *[!a-zA-Z0-9_]*) - func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'` - ;; - * ) - func_tr_sh_result=$1 - ;; - esac -} - - -# func_verbose ARG... -# ------------------- -# Echo program name prefixed message in verbose mode only. -func_verbose () -{ - $debug_cmd - - $opt_verbose && func_echo "$*" - - : -} - - -# func_warn_and_continue ARG... -# ----------------------------- -# Echo program name prefixed warning message to standard error. -func_warn_and_continue () -{ - $debug_cmd - - $require_term_colors - - func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2 -} - - -# func_warning CATEGORY ARG... -# ---------------------------- -# Echo program name prefixed warning message to standard error. Warning -# messages can be filtered according to CATEGORY, where this function -# elides messages where CATEGORY is not listed in the global variable -# 'opt_warning_types'. -func_warning () -{ - $debug_cmd - - # CATEGORY must be in the warning_categories list! - case " $warning_categories " in - *" $1 "*) ;; - *) func_internal_error "invalid warning category '$1'" ;; - esac - - _G_category=$1 - shift - - case " $opt_warning_types " in - *" $_G_category "*) $warning_func ${1+"$@"} ;; - esac -} - - -# func_sort_ver VER1 VER2 -# ----------------------- -# 'sort -V' is not generally available. -# Note this deviates from the version comparison in automake -# in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a -# but this should suffice as we won't be specifying old -# version formats or redundant trailing .0 in bootstrap.conf. -# If we did want full compatibility then we should probably -# use m4_version_compare from autoconf. -func_sort_ver () -{ - $debug_cmd - - printf '%s\n%s\n' "$1" "$2" \ - | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n -} - -# func_lt_ver PREV CURR -# --------------------- -# Return true if PREV and CURR are in the correct order according to -# func_sort_ver, otherwise false. Use it like this: -# -# func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..." -func_lt_ver () -{ - $debug_cmd - - test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q` -} - - -# Local variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" -# time-stamp-time-zone: "UTC" -# End: -#! /bin/sh - -# A portable, pluggable option parser for Bourne shell. -# Written by Gary V. Vaughan, 2010 - -# This is free software. There is NO warranty; not even for -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -# -# Copyright (C) 2010-2019, 2021 Bootstrap Authors -# -# This file is dual licensed under the terms of the MIT license -# , and GPL version 2 or later -# . You must apply one of -# these licenses when using or redistributing this software or any of -# the files within it. See the URLs above, or the file `LICENSE` -# included in the Bootstrap distribution for the full license texts. - -# Please report bugs or propose patches to: -# - -# Set a version string for this script. -scriptversion=2019-02-19.15; # UTC - - -## ------ ## -## Usage. ## -## ------ ## - -# This file is a library for parsing options in your shell scripts along -# with assorted other useful supporting features that you can make use -# of too. -# -# For the simplest scripts you might need only: -# -# #!/bin/sh -# . relative/path/to/funclib.sh -# . relative/path/to/options-parser -# scriptversion=1.0 -# func_options ${1+"$@"} -# eval set dummy "$func_options_result"; shift -# ...rest of your script... -# -# In order for the '--version' option to work, you will need to have a -# suitably formatted comment like the one at the top of this file -# starting with '# Written by ' and ending with '# Copyright'. -# -# For '-h' and '--help' to work, you will also need a one line -# description of your script's purpose in a comment directly above the -# '# Written by ' line, like the one at the top of this file. -# -# The default options also support '--debug', which will turn on shell -# execution tracing (see the comment above debug_cmd below for another -# use), and '--verbose' and the func_verbose function to allow your script -# to display verbose messages only when your user has specified -# '--verbose'. -# -# After sourcing this file, you can plug in processing for additional -# options by amending the variables from the 'Configuration' section -# below, and following the instructions in the 'Option parsing' -# section further down. - -## -------------- ## -## Configuration. ## -## -------------- ## - -# You should override these variables in your script after sourcing this -# file so that they reflect the customisations you have added to the -# option parser. - -# The usage line for option parsing errors and the start of '-h' and -# '--help' output messages. You can embed shell variables for delayed -# expansion at the time the message is displayed, but you will need to -# quote other shell meta-characters carefully to prevent them being -# expanded when the contents are evaled. -usage='$progpath [OPTION]...' - -# Short help message in response to '-h' and '--help'. Add to this or -# override it after sourcing this library to reflect the full set of -# options your script accepts. -usage_message="\ - --debug enable verbose shell tracing - -W, --warnings=CATEGORY - report the warnings falling in CATEGORY [all] - -v, --verbose verbosely report processing - --version print version information and exit - -h, --help print short or long help message and exit -" - -# Additional text appended to 'usage_message' in response to '--help'. -long_help_message=" -Warning categories include: - 'all' show all warnings - 'none' turn off all the warnings - 'error' warnings are treated as fatal errors" - -# Help message printed before fatal option parsing errors. -fatal_help="Try '\$progname --help' for more information." - - - -## ------------------------- ## -## Hook function management. ## -## ------------------------- ## - -# This section contains functions for adding, removing, and running hooks -# in the main code. A hook is just a list of function names that can be -# run in order later on. - -# func_hookable FUNC_NAME -# ----------------------- -# Declare that FUNC_NAME will run hooks added with -# 'func_add_hook FUNC_NAME ...'. -func_hookable () -{ - $debug_cmd - - func_append hookable_fns " $1" -} - - -# func_add_hook FUNC_NAME HOOK_FUNC -# --------------------------------- -# Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must -# first have been declared "hookable" by a call to 'func_hookable'. -func_add_hook () -{ - $debug_cmd - - case " $hookable_fns " in - *" $1 "*) ;; - *) func_fatal_error "'$1' does not accept hook functions." ;; - esac - - eval func_append ${1}_hooks '" $2"' -} - - -# func_remove_hook FUNC_NAME HOOK_FUNC -# ------------------------------------ -# Remove HOOK_FUNC from the list of hook functions to be called by -# FUNC_NAME. -func_remove_hook () -{ - $debug_cmd - - eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`' -} - - -# func_propagate_result FUNC_NAME_A FUNC_NAME_B -# --------------------------------------------- -# If the *_result variable of FUNC_NAME_A _is set_, assign its value to -# *_result variable of FUNC_NAME_B. -func_propagate_result () -{ - $debug_cmd - - func_propagate_result_result=: - if eval "test \"\${${1}_result+set}\" = set" - then - eval "${2}_result=\$${1}_result" - else - func_propagate_result_result=false - fi -} - - -# func_run_hooks FUNC_NAME [ARG]... -# --------------------------------- -# Run all hook functions registered to FUNC_NAME. -# It's assumed that the list of hook functions contains nothing more -# than a whitespace-delimited list of legal shell function names, and -# no effort is wasted trying to catch shell meta-characters or preserve -# whitespace. -func_run_hooks () -{ - $debug_cmd - - case " $hookable_fns " in - *" $1 "*) ;; - *) func_fatal_error "'$1' does not support hook functions." ;; - esac - - eval _G_hook_fns=\$$1_hooks; shift - - for _G_hook in $_G_hook_fns; do - func_unset "${_G_hook}_result" - eval $_G_hook '${1+"$@"}' - func_propagate_result $_G_hook func_run_hooks - if $func_propagate_result_result; then - eval set dummy "$func_run_hooks_result"; shift - fi - done -} - - - -## --------------- ## -## Option parsing. ## -## --------------- ## - -# In order to add your own option parsing hooks, you must accept the -# full positional parameter list from your hook function. You may remove -# or edit any options that you action, and then pass back the remaining -# unprocessed options in '_result', escaped -# suitably for 'eval'. -# -# The '_result' variable is automatically unset -# before your hook gets called; for best performance, only set the -# *_result variable when necessary (i.e. don't call the 'func_quote' -# function unnecessarily because it can be an expensive operation on some -# machines). -# -# Like this: -# -# my_options_prep () -# { -# $debug_cmd -# -# # Extend the existing usage message. -# usage_message=$usage_message' -# -s, --silent don'\''t print informational messages -# ' -# # No change in '$@' (ignored completely by this hook). Leave -# # my_options_prep_result variable intact. -# } -# func_add_hook func_options_prep my_options_prep -# -# -# my_silent_option () -# { -# $debug_cmd -# -# args_changed=false -# -# # Note that, for efficiency, we parse as many options as we can -# # recognise in a loop before passing the remainder back to the -# # caller on the first unrecognised argument we encounter. -# while test $# -gt 0; do -# opt=$1; shift -# case $opt in -# --silent|-s) opt_silent=: -# args_changed=: -# ;; -# # Separate non-argument short options: -# -s*) func_split_short_opt "$_G_opt" -# set dummy "$func_split_short_opt_name" \ -# "-$func_split_short_opt_arg" ${1+"$@"} -# shift -# args_changed=: -# ;; -# *) # Make sure the first unrecognised option "$_G_opt" -# # is added back to "$@" in case we need it later, -# # if $args_changed was set to 'true'. -# set dummy "$_G_opt" ${1+"$@"}; shift; break ;; -# esac -# done -# -# # Only call 'func_quote' here if we processed at least one argument. -# if $args_changed; then -# func_quote eval ${1+"$@"} -# my_silent_option_result=$func_quote_result -# fi -# } -# func_add_hook func_parse_options my_silent_option -# -# -# my_option_validation () -# { -# $debug_cmd -# -# $opt_silent && $opt_verbose && func_fatal_help "\ -# '--silent' and '--verbose' options are mutually exclusive." -# } -# func_add_hook func_validate_options my_option_validation -# -# You'll also need to manually amend $usage_message to reflect the extra -# options you parse. It's preferable to append if you can, so that -# multiple option parsing hooks can be added safely. - - -# func_options_finish [ARG]... -# ---------------------------- -# Finishing the option parse loop (call 'func_options' hooks ATM). -func_options_finish () -{ - $debug_cmd - - func_run_hooks func_options ${1+"$@"} - func_propagate_result func_run_hooks func_options_finish -} - - -# func_options [ARG]... -# --------------------- -# All the functions called inside func_options are hookable. See the -# individual implementations for details. -func_hookable func_options -func_options () -{ - $debug_cmd - - _G_options_quoted=false - - for my_func in options_prep parse_options validate_options options_finish - do - func_unset func_${my_func}_result - func_unset func_run_hooks_result - eval func_$my_func '${1+"$@"}' - func_propagate_result func_$my_func func_options - if $func_propagate_result_result; then - eval set dummy "$func_options_result"; shift - _G_options_quoted=: - fi - done - - $_G_options_quoted || { - # As we (func_options) are top-level options-parser function and - # nobody quoted "$@" for us yet, we need to do it explicitly for - # caller. - func_quote eval ${1+"$@"} - func_options_result=$func_quote_result - } -} - - -# func_options_prep [ARG]... -# -------------------------- -# All initialisations required before starting the option parse loop. -# Note that when calling hook functions, we pass through the list of -# positional parameters. If a hook function modifies that list, and -# needs to propagate that back to rest of this script, then the complete -# modified list must be put in 'func_run_hooks_result' before returning. -func_hookable func_options_prep -func_options_prep () -{ - $debug_cmd - - # Option defaults: - opt_verbose=false - opt_warning_types= - - func_run_hooks func_options_prep ${1+"$@"} - func_propagate_result func_run_hooks func_options_prep -} - - -# func_parse_options [ARG]... -# --------------------------- -# The main option parsing loop. -func_hookable func_parse_options -func_parse_options () -{ - $debug_cmd - - _G_parse_options_requote=false - # this just eases exit handling - while test $# -gt 0; do - # Defer to hook functions for initial option parsing, so they - # get priority in the event of reusing an option name. - func_run_hooks func_parse_options ${1+"$@"} - func_propagate_result func_run_hooks func_parse_options - if $func_propagate_result_result; then - eval set dummy "$func_parse_options_result"; shift - # Even though we may have changed "$@", we passed the "$@" array - # down into the hook and it quoted it for us (because we are in - # this if-branch). No need to quote it again. - _G_parse_options_requote=false - fi - - # Break out of the loop if we already parsed every option. - test $# -gt 0 || break - - # We expect that one of the options parsed in this function matches - # and thus we remove _G_opt from "$@" and need to re-quote. - _G_match_parse_options=: - _G_opt=$1 - shift - case $_G_opt in - --debug|-x) debug_cmd='set -x' - func_echo "enabling shell trace mode" >&2 - $debug_cmd - ;; - - --no-warnings|--no-warning|--no-warn) - set dummy --warnings none ${1+"$@"} - shift - ;; - - --warnings|--warning|-W) - if test $# = 0 && func_missing_arg $_G_opt; then - _G_parse_options_requote=: - break - fi - case " $warning_categories $1" in - *" $1 "*) - # trailing space prevents matching last $1 above - func_append_uniq opt_warning_types " $1" - ;; - *all) - opt_warning_types=$warning_categories - ;; - *none) - opt_warning_types=none - warning_func=: - ;; - *error) - opt_warning_types=$warning_categories - warning_func=func_fatal_error - ;; - *) - func_fatal_error \ - "unsupported warning category: '$1'" - ;; - esac - shift - ;; - - --verbose|-v) opt_verbose=: ;; - --version) func_version ;; - -\?|-h) func_usage ;; - --help) func_help ;; - - # Separate optargs to long options (plugins may need this): - --*=*) func_split_equals "$_G_opt" - set dummy "$func_split_equals_lhs" \ - "$func_split_equals_rhs" ${1+"$@"} - shift - ;; - - # Separate optargs to short options: - -W*) - func_split_short_opt "$_G_opt" - set dummy "$func_split_short_opt_name" \ - "$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - - # Separate non-argument short options: - -\?*|-h*|-v*|-x*) - func_split_short_opt "$_G_opt" - set dummy "$func_split_short_opt_name" \ - "-$func_split_short_opt_arg" ${1+"$@"} - shift - ;; - - --) _G_parse_options_requote=: ; break ;; - -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; - *) set dummy "$_G_opt" ${1+"$@"}; shift - _G_match_parse_options=false - break - ;; - esac - - if $_G_match_parse_options; then - _G_parse_options_requote=: - fi - done - - if $_G_parse_options_requote; then - # save modified positional parameters for caller - func_quote eval ${1+"$@"} - func_parse_options_result=$func_quote_result - fi -} - - -# func_validate_options [ARG]... -# ------------------------------ -# Perform any sanity checks on option settings and/or unconsumed -# arguments. -func_hookable func_validate_options -func_validate_options () -{ - $debug_cmd - - # Display all warnings if -W was not given. - test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" - - func_run_hooks func_validate_options ${1+"$@"} - func_propagate_result func_run_hooks func_validate_options - - # Bail if the options were screwed! - $exit_cmd $EXIT_FAILURE -} - - - -## ----------------- ## -## Helper functions. ## -## ----------------- ## - -# This section contains the helper functions used by the rest of the -# hookable option parser framework in ascii-betical order. - - -# func_fatal_help ARG... -# ---------------------- -# Echo program name prefixed message to standard error, followed by -# a help hint, and exit. -func_fatal_help () -{ - $debug_cmd - - eval \$ECHO \""Usage: $usage"\" - eval \$ECHO \""$fatal_help"\" - func_error ${1+"$@"} - exit $EXIT_FAILURE -} - - -# func_help -# --------- -# Echo long help message to standard output and exit. -func_help () -{ - $debug_cmd - - func_usage_message - $ECHO "$long_help_message" - exit 0 -} - - -# func_missing_arg ARGNAME -# ------------------------ -# Echo program name prefixed message to standard error and set global -# exit_cmd. -func_missing_arg () -{ - $debug_cmd - - func_error "Missing argument for '$1'." - exit_cmd=exit -} - - -# func_split_equals STRING -# ------------------------ -# Set func_split_equals_lhs and func_split_equals_rhs shell variables -# after splitting STRING at the '=' sign. -test -z "$_G_HAVE_XSI_OPS" \ - && (eval 'x=a/b/c; - test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ - && _G_HAVE_XSI_OPS=yes - -if test yes = "$_G_HAVE_XSI_OPS" -then - # This is an XSI compatible shell, allowing a faster implementation... - eval 'func_split_equals () - { - $debug_cmd - - func_split_equals_lhs=${1%%=*} - func_split_equals_rhs=${1#*=} - if test "x$func_split_equals_lhs" = "x$1"; then - func_split_equals_rhs= - fi - }' -else - # ...otherwise fall back to using expr, which is often a shell builtin. - func_split_equals () - { - $debug_cmd - - func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` - func_split_equals_rhs= - test "x$func_split_equals_lhs=" = "x$1" \ - || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` - } -fi #func_split_equals - - -# func_split_short_opt SHORTOPT -# ----------------------------- -# Set func_split_short_opt_name and func_split_short_opt_arg shell -# variables after splitting SHORTOPT after the 2nd character. -if test yes = "$_G_HAVE_XSI_OPS" -then - # This is an XSI compatible shell, allowing a faster implementation... - eval 'func_split_short_opt () - { - $debug_cmd - - func_split_short_opt_arg=${1#??} - func_split_short_opt_name=${1%"$func_split_short_opt_arg"} - }' -else - # ...otherwise fall back to using expr, which is often a shell builtin. - func_split_short_opt () - { - $debug_cmd - - func_split_short_opt_name=`expr "x$1" : 'x\(-.\)'` - func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` - } -fi #func_split_short_opt - - -# func_usage -# ---------- -# Echo short help message to standard output and exit. -func_usage () -{ - $debug_cmd - - func_usage_message - $ECHO "Run '$progname --help |${PAGER-more}' for full usage" - exit 0 -} - - -# func_usage_message -# ------------------ -# Echo short help message to standard output. -func_usage_message () -{ - $debug_cmd - - eval \$ECHO \""Usage: $usage"\" - echo - $SED -n 's|^# || - /^Written by/{ - x;p;x - } - h - /^Written by/q' < "$progpath" - echo - eval \$ECHO \""$usage_message"\" -} - - -# func_version -# ------------ -# Echo version message to standard output and exit. -# The version message is extracted from the calling file's header -# comments, with leading '# ' stripped: -# 1. First display the progname and version -# 2. Followed by the header comment line matching /^# Written by / -# 3. Then a blank line followed by the first following line matching -# /^# Copyright / -# 4. Immediately followed by any lines between the previous matches, -# except lines preceding the intervening completely blank line. -# For example, see the header comments of this file. -func_version () -{ - $debug_cmd - - printf '%s\n' "$progname $scriptversion" - $SED -n ' - /^# Written by /!b - s|^# ||; p; n - - :fwd2blnk - /./ { - n - b fwd2blnk - } - p; n - - :holdwrnt - s|^# || - s|^# *$|| - /^Copyright /!{ - /./H - n - b holdwrnt - } - - s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| - G - s|\(\n\)\n*|\1|g - p; q' < "$progpath" - - exit $? -} - - -# Local variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-pattern: "30/scriptversion=%:y-%02m-%02d.%02H; # UTC" -# time-stamp-time-zone: "UTC" -# End: - -# Set a version string. -scriptversion='(GNU libtool) 2.4.7' - - -# func_echo ARG... -# ---------------- -# Libtool also displays the current mode in messages, so override -# funclib.sh func_echo with this custom definition. -func_echo () -{ - $debug_cmd - - _G_message=$* - - func_echo_IFS=$IFS - IFS=$nl - for _G_line in $_G_message; do - IFS=$func_echo_IFS - $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line" - done - IFS=$func_echo_IFS -} - - -# func_warning ARG... -# ------------------- -# Libtool warnings are not categorized, so override funclib.sh -# func_warning with this simpler definition. -func_warning () -{ - $debug_cmd - - $warning_func ${1+"$@"} -} - - -## ---------------- ## -## Options parsing. ## -## ---------------- ## - -# Hook in the functions to make sure our own options are parsed during -# the option parsing loop. - -usage='$progpath [OPTION]... [MODE-ARG]...' - -# Short help message in response to '-h'. -usage_message="Options: - --config show all configuration variables - --debug enable verbose shell tracing - -n, --dry-run display commands without modifying any files - --features display basic configuration information and exit - --mode=MODE use operation mode MODE - --no-warnings equivalent to '-Wnone' - --preserve-dup-deps don't remove duplicate dependency libraries - --quiet, --silent don't print informational messages - --tag=TAG use configuration variables from tag TAG - -v, --verbose print more informational messages than default - --version print version information - -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] - -h, --help, --help-all print short, long, or detailed help message -" - -# Additional text appended to 'usage_message' in response to '--help'. -func_help () -{ - $debug_cmd - - func_usage_message - $ECHO "$long_help_message - -MODE must be one of the following: - - clean remove files from the build directory - compile compile a source file into a libtool object - execute automatically set library path, then run a program - finish complete the installation of libtool libraries - install install libraries or executables - link create a library or an executable - uninstall remove libraries from an installed directory - -MODE-ARGS vary depending on the MODE. When passed as first option, -'--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that. -Try '$progname --help --mode=MODE' for a more detailed description of MODE. - -When reporting a bug, please describe a test case to reproduce it and -include the following information: - - host-triplet: $host - shell: $SHELL - compiler: $LTCC - compiler flags: $LTCFLAGS - linker: $LD (gnu? $with_gnu_ld) - version: $progname (GNU libtool) 2.4.7 - automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` - autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` - -Report bugs to . -GNU libtool home page: . -General help using GNU software: ." - exit 0 -} - - -# func_lo2o OBJECT-NAME -# --------------------- -# Transform OBJECT-NAME from a '.lo' suffix to the platform specific -# object suffix. - -lo2o=s/\\.lo\$/.$objext/ -o2lo=s/\\.$objext\$/.lo/ - -if test yes = "$_G_HAVE_XSI_OPS"; then - eval 'func_lo2o () - { - case $1 in - *.lo) func_lo2o_result=${1%.lo}.$objext ;; - * ) func_lo2o_result=$1 ;; - esac - }' - - # func_xform LIBOBJ-OR-SOURCE - # --------------------------- - # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise) - # suffix to a '.lo' libtool-object suffix. - eval 'func_xform () - { - func_xform_result=${1%.*}.lo - }' -else - # ...otherwise fall back to using sed. - func_lo2o () - { - func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"` - } - - func_xform () - { - func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'` - } -fi - - -# func_fatal_configuration ARG... -# ------------------------------- -# Echo program name prefixed message to standard error, followed by -# a configuration failure hint, and exit. -func_fatal_configuration () -{ - func_fatal_error ${1+"$@"} \ - "See the $PACKAGE documentation for more information." \ - "Fatal configuration error." -} - - -# func_config -# ----------- -# Display the configuration for all the tags in this script. -func_config () -{ - re_begincf='^# ### BEGIN LIBTOOL' - re_endcf='^# ### END LIBTOOL' - - # Default configuration. - $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" - - # Now print the configurations for the tags. - for tagname in $taglist; do - $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" - done - - exit $? -} - - -# func_features -# ------------- -# Display the features supported by this script. -func_features () -{ - echo "host: $host" - if test yes = "$build_libtool_libs"; then - echo "enable shared libraries" - else - echo "disable shared libraries" - fi - if test yes = "$build_old_libs"; then - echo "enable static libraries" - else - echo "disable static libraries" - fi - - exit $? -} - - -# func_enable_tag TAGNAME -# ----------------------- -# Verify that TAGNAME is valid, and either flag an error and exit, or -# enable the TAGNAME tag. We also add TAGNAME to the global $taglist -# variable here. -func_enable_tag () -{ - # Global variable: - tagname=$1 - - re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" - re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" - sed_extractcf=/$re_begincf/,/$re_endcf/p - - # Validate tagname. - case $tagname in - *[!-_A-Za-z0-9,/]*) - func_fatal_error "invalid tag name: $tagname" - ;; - esac - - # Don't test for the "default" C tag, as we know it's - # there but not specially marked. - case $tagname in - CC) ;; - *) - if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then - taglist="$taglist $tagname" - - # Evaluate the configuration. Be careful to quote the path - # and the sed script, to avoid splitting on whitespace, but - # also don't use non-portable quotes within backquotes within - # quotes we have to do it in 2 steps: - extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` - eval "$extractedcf" - else - func_error "ignoring unknown tag $tagname" - fi - ;; - esac -} - - -# func_check_version_match -# ------------------------ -# Ensure that we are using m4 macros, and libtool script from the same -# release of libtool. -func_check_version_match () -{ - if test "$package_revision" != "$macro_revision"; then - if test "$VERSION" != "$macro_version"; then - if test -z "$macro_version"; then - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from an older release. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - fi - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, -$progname: but the definition of this LT_INIT comes from revision $macro_revision. -$progname: You should recreate aclocal.m4 with macros from revision $package_revision -$progname: of $PACKAGE $VERSION and run autoconf again. -_LT_EOF - fi - - exit $EXIT_MISMATCH - fi -} - - -# libtool_options_prep [ARG]... -# ----------------------------- -# Preparation for options parsed by libtool. -libtool_options_prep () -{ - $debug_mode - - # Option defaults: - opt_config=false - opt_dlopen= - opt_dry_run=false - opt_help=false - opt_mode= - opt_preserve_dup_deps=false - opt_quiet=false - - nonopt= - preserve_args= - - _G_rc_lt_options_prep=: - - # Shorthand for --mode=foo, only valid as the first argument - case $1 in - clean|clea|cle|cl) - shift; set dummy --mode clean ${1+"$@"}; shift - ;; - compile|compil|compi|comp|com|co|c) - shift; set dummy --mode compile ${1+"$@"}; shift - ;; - execute|execut|execu|exec|exe|ex|e) - shift; set dummy --mode execute ${1+"$@"}; shift - ;; - finish|finis|fini|fin|fi|f) - shift; set dummy --mode finish ${1+"$@"}; shift - ;; - install|instal|insta|inst|ins|in|i) - shift; set dummy --mode install ${1+"$@"}; shift - ;; - link|lin|li|l) - shift; set dummy --mode link ${1+"$@"}; shift - ;; - uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) - shift; set dummy --mode uninstall ${1+"$@"}; shift - ;; - *) - _G_rc_lt_options_prep=false - ;; - esac - - if $_G_rc_lt_options_prep; then - # Pass back the list of options. - func_quote eval ${1+"$@"} - libtool_options_prep_result=$func_quote_result - fi -} -func_add_hook func_options_prep libtool_options_prep - - -# libtool_parse_options [ARG]... -# --------------------------------- -# Provide handling for libtool specific options. -libtool_parse_options () -{ - $debug_cmd - - _G_rc_lt_parse_options=false - - # Perform our own loop to consume as many options as possible in - # each iteration. - while test $# -gt 0; do - _G_match_lt_parse_options=: - _G_opt=$1 - shift - case $_G_opt in - --dry-run|--dryrun|-n) - opt_dry_run=: - ;; - - --config) func_config ;; - - --dlopen|-dlopen) - opt_dlopen="${opt_dlopen+$opt_dlopen -}$1" - shift - ;; - - --preserve-dup-deps) - opt_preserve_dup_deps=: ;; - - --features) func_features ;; - - --finish) set dummy --mode finish ${1+"$@"}; shift ;; - - --help) opt_help=: ;; - - --help-all) opt_help=': help-all' ;; - - --mode) test $# = 0 && func_missing_arg $_G_opt && break - opt_mode=$1 - case $1 in - # Valid mode arguments: - clean|compile|execute|finish|install|link|relink|uninstall) ;; - - # Catch anything else as an error - *) func_error "invalid argument for $_G_opt" - exit_cmd=exit - break - ;; - esac - shift - ;; - - --no-silent|--no-quiet) - opt_quiet=false - func_append preserve_args " $_G_opt" - ;; - - --no-warnings|--no-warning|--no-warn) - opt_warning=false - func_append preserve_args " $_G_opt" - ;; - - --no-verbose) - opt_verbose=false - func_append preserve_args " $_G_opt" - ;; - - --silent|--quiet) - opt_quiet=: - opt_verbose=false - func_append preserve_args " $_G_opt" - ;; - - --tag) test $# = 0 && func_missing_arg $_G_opt && break - opt_tag=$1 - func_append preserve_args " $_G_opt $1" - func_enable_tag "$1" - shift - ;; - - --verbose|-v) opt_quiet=false - opt_verbose=: - func_append preserve_args " $_G_opt" - ;; - - # An option not handled by this hook function: - *) set dummy "$_G_opt" ${1+"$@"} ; shift - _G_match_lt_parse_options=false - break - ;; - esac - $_G_match_lt_parse_options && _G_rc_lt_parse_options=: - done - - if $_G_rc_lt_parse_options; then - # save modified positional parameters for caller - func_quote eval ${1+"$@"} - libtool_parse_options_result=$func_quote_result - fi -} -func_add_hook func_parse_options libtool_parse_options - - - -# libtool_validate_options [ARG]... -# --------------------------------- -# Perform any sanity checks on option settings and/or unconsumed -# arguments. -libtool_validate_options () -{ - # save first non-option argument - if test 0 -lt $#; then - nonopt=$1 - shift - fi - - # preserve --debug - test : = "$debug_cmd" || func_append preserve_args " --debug" - - # Keeping compiler generated duplicates in $postdeps and $predeps is not - # harmful, and is necessary in a majority of systems that use it to satisfy - # symbol dependencies. - opt_duplicate_compiler_generated_deps=: - - $opt_help || { - # Sanity checks first: - func_check_version_match - - test yes != "$build_libtool_libs" \ - && test yes != "$build_old_libs" \ - && func_fatal_configuration "not configured to build any kind of library" - - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" - - # Only execute mode is allowed to have -dlopen flags. - if test -n "$opt_dlopen" && test execute != "$opt_mode"; then - func_error "unrecognized option '-dlopen'" - $ECHO "$help" 1>&2 - exit $EXIT_FAILURE - fi - - # Change the help message to a mode-specific one. - generic_help=$help - help="Try '$progname --help --mode=$opt_mode' for more information." - } - - # Pass back the unparsed argument list - func_quote eval ${1+"$@"} - libtool_validate_options_result=$func_quote_result -} -func_add_hook func_validate_options libtool_validate_options - - -# Process options as early as possible so that --help and --version -# can return quickly. -func_options ${1+"$@"} -eval set dummy "$func_options_result"; shift - - - -## ----------- ## -## Main. ## -## ----------- ## - -magic='%%%MAGIC variable%%%' -magic_exe='%%%MAGIC EXE variable%%%' - -# Global variables. -extracted_archives= -extracted_serial=0 - -# If this variable is set in any of the actions, the command in it -# will be execed at the end. This prevents here-documents from being -# left over by shells. -exec_cmd= - - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' -} - -# func_generated_by_libtool -# True iff stdin has been generated by Libtool. This function is only -# a basic sanity check; it will hardly flush out determined imposters. -func_generated_by_libtool_p () -{ - $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 -} - -# func_lalib_p file -# True iff FILE is a libtool '.la' library or '.lo' object file. -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_lalib_p () -{ - test -f "$1" && - $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p -} - -# func_lalib_unsafe_p file -# True iff FILE is a libtool '.la' library or '.lo' object file. -# This function implements the same check as func_lalib_p without -# resorting to external programs. To this end, it redirects stdin and -# closes it afterwards, without saving the original file descriptor. -# As a safety measure, use it only where a negative result would be -# fatal anyway. Works if 'file' does not exist. -func_lalib_unsafe_p () -{ - lalib_p=no - if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then - for lalib_p_l in 1 2 3 4 - do - read lalib_p_line - case $lalib_p_line in - \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; - esac - done - exec 0<&5 5<&- - fi - test yes = "$lalib_p" -} - -# func_ltwrapper_script_p file -# True iff FILE is a libtool wrapper script -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_script_p () -{ - test -f "$1" && - $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p -} - -# func_ltwrapper_executable_p file -# True iff FILE is a libtool wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_executable_p () -{ - func_ltwrapper_exec_suffix= - case $1 in - *.exe) ;; - *) func_ltwrapper_exec_suffix=.exe ;; - esac - $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 -} - -# func_ltwrapper_scriptname file -# Assumes file is an ltwrapper_executable -# uses $file to determine the appropriate filename for a -# temporary ltwrapper_script. -func_ltwrapper_scriptname () -{ - func_dirname_and_basename "$1" "" "." - func_stripname '' '.exe' "$func_basename_result" - func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper -} - -# func_ltwrapper_p file -# True iff FILE is a libtool wrapper script or wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_p () -{ - func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" -} - - -# func_execute_cmds commands fail_cmd -# Execute tilde-delimited COMMANDS. -# If FAIL_CMD is given, eval that upon failure. -# FAIL_CMD may read-access the current command in variable CMD! -func_execute_cmds () -{ - $debug_cmd - - save_ifs=$IFS; IFS='~' - for cmd in $1; do - IFS=$sp$nl - eval cmd=\"$cmd\" - IFS=$save_ifs - func_show_eval "$cmd" "${2-:}" - done - IFS=$save_ifs -} - - -# func_source file -# Source FILE, adding directory component if necessary. -# Note that it is not necessary on cygwin/mingw to append a dot to -# FILE even if both FILE and FILE.exe exist: automatic-append-.exe -# behavior happens only for exec(3), not for open(2)! Also, sourcing -# 'FILE.' does not work on cygwin managed mounts. -func_source () -{ - $debug_cmd - - case $1 in - */* | *\\*) . "$1" ;; - *) . "./$1" ;; - esac -} - - -# func_resolve_sysroot PATH -# Replace a leading = in PATH with a sysroot. Store the result into -# func_resolve_sysroot_result -func_resolve_sysroot () -{ - func_resolve_sysroot_result=$1 - case $func_resolve_sysroot_result in - =*) - func_stripname '=' '' "$func_resolve_sysroot_result" - func_resolve_sysroot_result=$lt_sysroot$func_stripname_result - ;; - esac -} - -# func_replace_sysroot PATH -# If PATH begins with the sysroot, replace it with = and -# store the result into func_replace_sysroot_result. -func_replace_sysroot () -{ - case $lt_sysroot:$1 in - ?*:"$lt_sysroot"*) - func_stripname "$lt_sysroot" '' "$1" - func_replace_sysroot_result='='$func_stripname_result - ;; - *) - # Including no sysroot. - func_replace_sysroot_result=$1 - ;; - esac -} - -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () -{ - $debug_cmd - - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. - *) - for z in $available_tags; do - if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - func_append_quoted CC_quoted "$arg" - done - CC_expanded=`func_echo_all $CC` - CC_quoted_expanded=`func_echo_all $CC_quoted` - case "$@ " in - " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ - " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - func_echo "unable to infer tagged configuration" - func_fatal_error "specify a tag with '--tag'" -# else -# func_verbose "using $tagname tagged configuration" - fi - ;; - esac - fi -} - - - -# func_write_libtool_object output_name pic_name nonpic_name -# Create a libtool object file (analogous to a ".la" file), -# but don't create it if we're doing a dry run. -func_write_libtool_object () -{ - write_libobj=$1 - if test yes = "$build_libtool_libs"; then - write_lobj=\'$2\' - else - write_lobj=none - fi - - if test yes = "$build_old_libs"; then - write_oldobj=\'$3\' - else - write_oldobj=none - fi - - $opt_dry_run || { - cat >${write_libobj}T </dev/null` - if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then - func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | - $SED -e "$sed_naive_backslashify"` - else - func_convert_core_file_wine_to_w32_result= - fi - fi -} -# end: func_convert_core_file_wine_to_w32 - - -# func_convert_core_path_wine_to_w32 ARG -# Helper function used by path conversion functions when $build is *nix, and -# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly -# configured wine environment available, with the winepath program in $build's -# $PATH. Assumes ARG has no leading or trailing path separator characters. -# -# ARG is path to be converted from $build format to win32. -# Result is available in $func_convert_core_path_wine_to_w32_result. -# Unconvertible file (directory) names in ARG are skipped; if no directory names -# are convertible, then the result may be empty. -func_convert_core_path_wine_to_w32 () -{ - $debug_cmd - - # unfortunately, winepath doesn't convert paths, only file names - func_convert_core_path_wine_to_w32_result= - if test -n "$1"; then - oldIFS=$IFS - IFS=: - for func_convert_core_path_wine_to_w32_f in $1; do - IFS=$oldIFS - func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" - if test -n "$func_convert_core_file_wine_to_w32_result"; then - if test -z "$func_convert_core_path_wine_to_w32_result"; then - func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result - else - func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" - fi - fi - done - IFS=$oldIFS - fi -} -# end: func_convert_core_path_wine_to_w32 - - -# func_cygpath ARGS... -# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when -# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) -# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or -# (2), returns the Cygwin file name or path in func_cygpath_result (input -# file name or path is assumed to be in w32 format, as previously converted -# from $build's *nix or MSYS format). In case (3), returns the w32 file name -# or path in func_cygpath_result (input file name or path is assumed to be in -# Cygwin format). Returns an empty string on error. -# -# ARGS are passed to cygpath, with the last one being the file name or path to -# be converted. -# -# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH -# environment variable; do not put it in $PATH. -func_cygpath () -{ - $debug_cmd - - if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then - func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` - if test "$?" -ne 0; then - # on failure, ensure result is empty - func_cygpath_result= - fi - else - func_cygpath_result= - func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'" - fi -} -#end: func_cygpath - - -# func_convert_core_msys_to_w32 ARG -# Convert file name or path ARG from MSYS format to w32 format. Return -# result in func_convert_core_msys_to_w32_result. -func_convert_core_msys_to_w32 () -{ - $debug_cmd - - # awkward: cmd appends spaces to result - func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | - $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"` -} -#end: func_convert_core_msys_to_w32 - - -# func_convert_file_check ARG1 ARG2 -# Verify that ARG1 (a file name in $build format) was converted to $host -# format in ARG2. Otherwise, emit an error message, but continue (resetting -# func_to_host_file_result to ARG1). -func_convert_file_check () -{ - $debug_cmd - - if test -z "$2" && test -n "$1"; then - func_error "Could not determine host file name corresponding to" - func_error " '$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback: - func_to_host_file_result=$1 - fi -} -# end func_convert_file_check - - -# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH -# Verify that FROM_PATH (a path in $build format) was converted to $host -# format in TO_PATH. Otherwise, emit an error message, but continue, resetting -# func_to_host_file_result to a simplistic fallback value (see below). -func_convert_path_check () -{ - $debug_cmd - - if test -z "$4" && test -n "$3"; then - func_error "Could not determine the host path corresponding to" - func_error " '$3'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback. This is a deliberately simplistic "conversion" and - # should not be "improved". See libtool.info. - if test "x$1" != "x$2"; then - lt_replace_pathsep_chars="s|$1|$2|g" - func_to_host_path_result=`echo "$3" | - $SED -e "$lt_replace_pathsep_chars"` - else - func_to_host_path_result=$3 - fi - fi -} -# end func_convert_path_check - - -# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG -# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT -# and appending REPL if ORIG matches BACKPAT. -func_convert_path_front_back_pathsep () -{ - $debug_cmd - - case $4 in - $1 ) func_to_host_path_result=$3$func_to_host_path_result - ;; - esac - case $4 in - $2 ) func_append func_to_host_path_result "$3" - ;; - esac -} -# end func_convert_path_front_back_pathsep - - -################################################## -# $build to $host FILE NAME CONVERSION FUNCTIONS # -################################################## -# invoked via '$to_host_file_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# Result will be available in $func_to_host_file_result. - - -# func_to_host_file ARG -# Converts the file name ARG from $build format to $host format. Return result -# in func_to_host_file_result. -func_to_host_file () -{ - $debug_cmd - - $to_host_file_cmd "$1" -} -# end func_to_host_file - - -# func_to_tool_file ARG LAZY -# converts the file name ARG from $build format to toolchain format. Return -# result in func_to_tool_file_result. If the conversion in use is listed -# in (the comma separated) LAZY, no conversion takes place. -func_to_tool_file () -{ - $debug_cmd - - case ,$2, in - *,"$to_tool_file_cmd",*) - func_to_tool_file_result=$1 - ;; - *) - $to_tool_file_cmd "$1" - func_to_tool_file_result=$func_to_host_file_result - ;; - esac -} -# end func_to_tool_file - - -# func_convert_file_noop ARG -# Copy ARG to func_to_host_file_result. -func_convert_file_noop () -{ - func_to_host_file_result=$1 -} -# end func_convert_file_noop - - -# func_convert_file_msys_to_w32 ARG -# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_file_result. -func_convert_file_msys_to_w32 () -{ - $debug_cmd - - func_to_host_file_result=$1 - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_to_host_file_result=$func_convert_core_msys_to_w32_result - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_w32 - - -# func_convert_file_cygwin_to_w32 ARG -# Convert file name ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_file_cygwin_to_w32 () -{ - $debug_cmd - - func_to_host_file_result=$1 - if test -n "$1"; then - # because $build is cygwin, we call "the" cygpath in $PATH; no need to use - # LT_CYGPATH in this case. - func_to_host_file_result=`cygpath -m "$1"` - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_cygwin_to_w32 - - -# func_convert_file_nix_to_w32 ARG -# Convert file name ARG from *nix to w32 format. Requires a wine environment -# and a working winepath. Returns result in func_to_host_file_result. -func_convert_file_nix_to_w32 () -{ - $debug_cmd - - func_to_host_file_result=$1 - if test -n "$1"; then - func_convert_core_file_wine_to_w32 "$1" - func_to_host_file_result=$func_convert_core_file_wine_to_w32_result - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_w32 - - -# func_convert_file_msys_to_cygwin ARG -# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_file_msys_to_cygwin () -{ - $debug_cmd - - func_to_host_file_result=$1 - if test -n "$1"; then - func_convert_core_msys_to_w32 "$1" - func_cygpath -u "$func_convert_core_msys_to_w32_result" - func_to_host_file_result=$func_cygpath_result - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_msys_to_cygwin - - -# func_convert_file_nix_to_cygwin ARG -# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed -# in a wine environment, working winepath, and LT_CYGPATH set. Returns result -# in func_to_host_file_result. -func_convert_file_nix_to_cygwin () -{ - $debug_cmd - - func_to_host_file_result=$1 - if test -n "$1"; then - # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. - func_convert_core_file_wine_to_w32 "$1" - func_cygpath -u "$func_convert_core_file_wine_to_w32_result" - func_to_host_file_result=$func_cygpath_result - fi - func_convert_file_check "$1" "$func_to_host_file_result" -} -# end func_convert_file_nix_to_cygwin - - -############################################# -# $build to $host PATH CONVERSION FUNCTIONS # -############################################# -# invoked via '$to_host_path_cmd ARG' -# -# In each case, ARG is the path to be converted from $build to $host format. -# The result will be available in $func_to_host_path_result. -# -# Path separators are also converted from $build format to $host format. If -# ARG begins or ends with a path separator character, it is preserved (but -# converted to $host format) on output. -# -# All path conversion functions are named using the following convention: -# file name conversion function : func_convert_file_X_to_Y () -# path conversion function : func_convert_path_X_to_Y () -# where, for any given $build/$host combination the 'X_to_Y' value is the -# same. If conversion functions are added for new $build/$host combinations, -# the two new functions must follow this pattern, or func_init_to_host_path_cmd -# will break. - - -# func_init_to_host_path_cmd -# Ensures that function "pointer" variable $to_host_path_cmd is set to the -# appropriate value, based on the value of $to_host_file_cmd. -to_host_path_cmd= -func_init_to_host_path_cmd () -{ - $debug_cmd - - if test -z "$to_host_path_cmd"; then - func_stripname 'func_convert_file_' '' "$to_host_file_cmd" - to_host_path_cmd=func_convert_path_$func_stripname_result - fi -} - - -# func_to_host_path ARG -# Converts the path ARG from $build format to $host format. Return result -# in func_to_host_path_result. -func_to_host_path () -{ - $debug_cmd - - func_init_to_host_path_cmd - $to_host_path_cmd "$1" -} -# end func_to_host_path - - -# func_convert_path_noop ARG -# Copy ARG to func_to_host_path_result. -func_convert_path_noop () -{ - func_to_host_path_result=$1 -} -# end func_convert_path_noop - - -# func_convert_path_msys_to_w32 ARG -# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic -# conversion to w32 is not available inside the cwrapper. Returns result in -# func_to_host_path_result. -func_convert_path_msys_to_w32 () -{ - $debug_cmd - - func_to_host_path_result=$1 - if test -n "$1"; then - # Remove leading and trailing path separator characters from ARG. MSYS - # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; - # and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result=$func_convert_core_msys_to_w32_result - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_msys_to_w32 - - -# func_convert_path_cygwin_to_w32 ARG -# Convert path ARG from Cygwin to w32 format. Returns result in -# func_to_host_file_result. -func_convert_path_cygwin_to_w32 () -{ - $debug_cmd - - func_to_host_path_result=$1 - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_cygwin_to_w32 - - -# func_convert_path_nix_to_w32 ARG -# Convert path ARG from *nix to w32 format. Requires a wine environment and -# a working winepath. Returns result in func_to_host_file_result. -func_convert_path_nix_to_w32 () -{ - $debug_cmd - - func_to_host_path_result=$1 - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_to_host_path_result=$func_convert_core_path_wine_to_w32_result - func_convert_path_check : ";" \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" - fi -} -# end func_convert_path_nix_to_w32 - - -# func_convert_path_msys_to_cygwin ARG -# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. -# Returns result in func_to_host_file_result. -func_convert_path_msys_to_cygwin () -{ - $debug_cmd - - func_to_host_path_result=$1 - if test -n "$1"; then - # See func_convert_path_msys_to_w32: - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_msys_to_w32_result" - func_to_host_path_result=$func_cygpath_result - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_msys_to_cygwin - - -# func_convert_path_nix_to_cygwin ARG -# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a -# a wine environment, working winepath, and LT_CYGPATH set. Returns result in -# func_to_host_file_result. -func_convert_path_nix_to_cygwin () -{ - $debug_cmd - - func_to_host_path_result=$1 - if test -n "$1"; then - # Remove leading and trailing path separator characters from - # ARG. msys behavior is inconsistent here, cygpath turns them - # into '.;' and ';.', and winepath ignores them completely. - func_stripname : : "$1" - func_to_host_path_tmp1=$func_stripname_result - func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" - func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" - func_to_host_path_result=$func_cygpath_result - func_convert_path_check : : \ - "$func_to_host_path_tmp1" "$func_to_host_path_result" - func_convert_path_front_back_pathsep ":*" "*:" : "$1" - fi -} -# end func_convert_path_nix_to_cygwin - - -# func_dll_def_p FILE -# True iff FILE is a Windows DLL '.def' file. -# Keep in sync with _LT_DLL_DEF_P in libtool.m4 -func_dll_def_p () -{ - $debug_cmd - - func_dll_def_p_tmp=`$SED -n \ - -e 's/^[ ]*//' \ - -e '/^\(;.*\)*$/d' \ - -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \ - -e q \ - "$1"` - test DEF = "$func_dll_def_p_tmp" -} - - -# func_mode_compile arg... -func_mode_compile () -{ - $debug_cmd - - # Get the compilation command and the source file. - base_compile= - srcfile=$nonopt # always keep a non-empty value in "srcfile" - suppress_opt=yes - suppress_output= - arg_mode=normal - libobj= - later= - pie_flag= - - for arg - do - case $arg_mode in - arg ) - # do not "continue". Instead, add this to base_compile - lastarg=$arg - arg_mode=normal - ;; - - target ) - libobj=$arg - arg_mode=normal - continue - ;; - - normal ) - # Accept any command-line options. - case $arg in - -o) - test -n "$libobj" && \ - func_fatal_error "you cannot specify '-o' more than once" - arg_mode=target - continue - ;; - - -pie | -fpie | -fPIE) - func_append pie_flag " $arg" - continue - ;; - - -shared | -static | -prefer-pic | -prefer-non-pic) - func_append later " $arg" - continue - ;; - - -no-suppress) - suppress_opt=no - continue - ;; - - -Xcompiler) - arg_mode=arg # the next one goes into the "base_compile" arg list - continue # The current "srcfile" will either be retained or - ;; # replaced later. I would guess that would be a bug. - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - lastarg= - save_ifs=$IFS; IFS=, - for arg in $args; do - IFS=$save_ifs - func_append_quoted lastarg "$arg" - done - IFS=$save_ifs - func_stripname ' ' '' "$lastarg" - lastarg=$func_stripname_result - - # Add the arguments to base_compile. - func_append base_compile " $lastarg" - continue - ;; - - *) - # Accept the current argument as the source file. - # The previous "srcfile" becomes the current argument. - # - lastarg=$srcfile - srcfile=$arg - ;; - esac # case $arg - ;; - esac # case $arg_mode - - # Aesthetically quote the previous argument. - func_append_quoted base_compile "$lastarg" - done # for arg - - case $arg_mode in - arg) - func_fatal_error "you must specify an argument for -Xcompile" - ;; - target) - func_fatal_error "you must specify a target with '-o'" - ;; - *) - # Get the name of the library object. - test -z "$libobj" && { - func_basename "$srcfile" - libobj=$func_basename_result - } - ;; - esac - - # Recognize several different file suffixes. - # If the user specifies -o file.o, it is replaced with file.lo - case $libobj in - *.[cCFSifmso] | \ - *.ada | *.adb | *.ads | *.asm | \ - *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ - *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) - func_xform "$libobj" - libobj=$func_xform_result - ;; - esac - - case $libobj in - *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; - *) - func_fatal_error "cannot determine name of library object from '$libobj'" - ;; - esac - - func_infer_tag $base_compile - - for arg in $later; do - case $arg in - -shared) - test yes = "$build_libtool_libs" \ - || func_fatal_configuration "cannot build a shared library" - build_old_libs=no - continue - ;; - - -static) - build_libtool_libs=no - build_old_libs=yes - continue - ;; - - -prefer-pic) - pic_mode=yes - continue - ;; - - -prefer-non-pic) - pic_mode=no - continue - ;; - esac - done - - func_quote_arg pretty "$libobj" - test "X$libobj" != "X$func_quote_arg_result" \ - && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && func_warning "libobj name '$libobj' may not contain shell special characters." - func_dirname_and_basename "$obj" "/" "" - objname=$func_basename_result - xdir=$func_dirname_result - lobj=$xdir$objdir/$objname - - test -z "$base_compile" && \ - func_fatal_help "you must specify a compilation command" - - # Delete any leftover library objects. - if test yes = "$build_old_libs"; then - removelist="$obj $lobj $libobj ${libobj}T" - else - removelist="$lobj $libobj ${libobj}T" - fi - - # On Cygwin there's no "real" PIC flag so we must build both object types - case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) - pic_mode=default - ;; - esac - if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then - # non-PIC code in shared libraries is not supported - pic_mode=default - fi - - # Calculate the filename of the output object if compiler does - # not support -o with -c - if test no = "$compiler_c_o"; then - output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext - lockfile=$output_obj.lock - else - output_obj= - need_locks=no - lockfile= - fi - - # Lock this critical section if it is needed - # We use this script file to make the link, it avoids creating a new file - if test yes = "$need_locks"; then - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - elif test warn = "$need_locks"; then - if test -f "$lockfile"; then - $ECHO "\ -*** ERROR, $lockfile exists and contains: -`cat $lockfile 2>/dev/null` - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support '-c' and '-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - func_append removelist " $output_obj" - $ECHO "$srcfile" > "$lockfile" - fi - - $opt_dry_run || $RM $removelist - func_append removelist " $lockfile" - trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - - func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 - srcfile=$func_to_tool_file_result - func_quote_arg pretty "$srcfile" - qsrcfile=$func_quote_arg_result - - # Only build a PIC object if we are building libtool libraries. - if test yes = "$build_libtool_libs"; then - # Without this assignment, base_compile gets emptied. - fbsd_hideous_sh_bug=$base_compile - - if test no != "$pic_mode"; then - command="$base_compile $qsrcfile $pic_flag" - else - # Don't build PIC code - command="$base_compile $qsrcfile" - fi - - func_mkdir_p "$xdir$objdir" - - if test -z "$output_obj"; then - # Place PIC objects in $objdir - func_append command " -o $lobj" - fi - - func_show_eval_locale "$command" \ - 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' - - if test warn = "$need_locks" && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support '-c' and '-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed, then go on to compile the next one - if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - func_show_eval '$MV "$output_obj" "$lobj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - - # Allow error messages only from the first compilation. - if test yes = "$suppress_opt"; then - suppress_output=' >/dev/null 2>&1' - fi - fi - - # Only build a position-dependent object if we build old libraries. - if test yes = "$build_old_libs"; then - if test yes != "$pic_mode"; then - # Don't build PIC code - command="$base_compile $qsrcfile$pie_flag" - else - command="$base_compile $qsrcfile $pic_flag" - fi - if test yes = "$compiler_c_o"; then - func_append command " -o $obj" - fi - - # Suppress compiler output if we already did a PIC compilation. - func_append command "$suppress_output" - func_show_eval_locale "$command" \ - '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' - - if test warn = "$need_locks" && - test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then - $ECHO "\ -*** ERROR, $lockfile contains: -`cat $lockfile 2>/dev/null` - -but it should contain: -$srcfile - -This indicates that another process is trying to use the same -temporary object file, and libtool could not work around it because -your compiler does not support '-c' and '-o' together. If you -repeat this compilation, it may succeed, by chance, but you had better -avoid parallel builds (make -j) in this platform, or get a better -compiler." - - $opt_dry_run || $RM $removelist - exit $EXIT_FAILURE - fi - - # Just move the object if needed - if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - func_show_eval '$MV "$output_obj" "$obj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' - fi - fi - - $opt_dry_run || { - func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" - - # Unlock the critical section if it was locked - if test no != "$need_locks"; then - removelist=$lockfile - $RM "$lockfile" - fi - } - - exit $EXIT_SUCCESS -} - -$opt_help || { - test compile = "$opt_mode" && func_mode_compile ${1+"$@"} -} - -func_mode_help () -{ - # We need to display help for each of the modes. - case $opt_mode in - "") - # Generic help is extracted from the usage comments - # at the start of this file. - func_help - ;; - - clean) - $ECHO \ -"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... - -Remove files from the build directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed -to RM. - -If FILE is a libtool library, object or program, all the files associated -with it are deleted. Otherwise, only FILE itself is deleted using RM." - ;; - - compile) - $ECHO \ -"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE - -Compile a source file into a libtool library object. - -This mode accepts the following additional options: - - -o OUTPUT-FILE set the output file name to OUTPUT-FILE - -no-suppress do not suppress compiler output for multiple passes - -prefer-pic try to build PIC objects only - -prefer-non-pic try to build non-PIC objects only - -shared do not build a '.o' file suitable for static linking - -static only build a '.o' file suitable for static linking - -Wc,FLAG - -Xcompiler FLAG pass FLAG directly to the compiler - -COMPILE-COMMAND is a command to be used in creating a 'standard' object file -from the given SOURCEFILE. - -The output file name is determined by removing the directory component from -SOURCEFILE, then substituting the C source code suffix '.c' with the -library object suffix, '.lo'." - ;; - - execute) - $ECHO \ -"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... - -Automatically set library path, then run a program. - -This mode accepts the following additional options: - - -dlopen FILE add the directory containing FILE to the library path - -This mode sets the library path environment variable according to '-dlopen' -flags. - -If any of the ARGS are libtool executable wrappers, then they are translated -into their corresponding uninstalled binary, and any of their required library -directories are added to the library path. - -Then, COMMAND is executed, with ARGS as arguments." - ;; - - finish) - $ECHO \ -"Usage: $progname [OPTION]... --mode=finish [LIBDIR]... - -Complete the installation of libtool libraries. - -Each LIBDIR is a directory that contains libtool libraries. - -The commands that this mode executes may require superuser privileges. Use -the '--dry-run' option if you just want to see what would be executed." - ;; - - install) - $ECHO \ -"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... - -Install executables or libraries. - -INSTALL-COMMAND is the installation command. The first component should be -either the 'install' or 'cp' program. - -The following components of INSTALL-COMMAND are treated specially: - - -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation - -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; - - link) - $ECHO \ -"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... - -Link object files or libraries together to form another library, or to -create an executable program. - -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. - -The following components of LINK-COMMAND are treated specially: - - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -bindir BINDIR specify path to binaries directory (for systems where - libraries must be found in the PATH setting at runtime) - -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE use a list of object files found in FILE to specify objects - -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes) - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -shared only do dynamic linking of libtool libraries - -shrext SUFFIX override the standard shared library file extension - -static do not do any dynamic linking of uninstalled libtool libraries - -static-libtool-libs - do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -weak LIBNAME declare that the target provides the LIBNAME interface - -Wc,FLAG - -Xcompiler FLAG pass linker-specific FLAG directly to the compiler - -Wa,FLAG - -Xassembler FLAG pass linker-specific FLAG directly to the assembler - -Wl,FLAG - -Xlinker FLAG pass linker-specific FLAG directly to the linker - -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) - -All other options (arguments beginning with '-') are ignored. - -Every other argument is treated as a filename. Files ending in '.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in '.la', then a libtool library is created, -only library objects ('.lo' files) may be specified, and '-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created -using 'ar' and 'ranlib', or on Windows using 'lib'. - -If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file -is created, otherwise an executable program is created." - ;; - - uninstall) - $ECHO \ -"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... - -Remove libraries from an installation directory. - -RM is the name of the program to use to delete files associated with each FILE -(typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed -to RM. - -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; - - *) - func_fatal_help "invalid operation mode '$opt_mode'" - ;; - esac - - echo - $ECHO "Try '$progname --help' for more information about other modes." -} - -# Now that we've collected a possible --mode arg, show help if necessary -if $opt_help; then - if test : = "$opt_help"; then - func_mode_help - else - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - func_mode_help - done - } | $SED -n '1p; 2,$s/^Usage:/ or: /p' - { - func_help noexit - for opt_mode in compile link execute install finish uninstall clean; do - echo - func_mode_help - done - } | - $SED '1d - /^When reporting/,/^Report/{ - H - d - } - $x - /information about other modes/d - /more detailed .*MODE/d - s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' - fi - exit $? -fi - - -# func_mode_execute arg... -func_mode_execute () -{ - $debug_cmd - - # The first argument is the command name. - cmd=$nonopt - test -z "$cmd" && \ - func_fatal_help "you must specify a COMMAND" - - # Handle -dlopen flags immediately. - for file in $opt_dlopen; do - test -f "$file" \ - || func_fatal_help "'$file' is not a file" - - dir= - case $file in - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "'$lib' is not a valid libtool archive" - - # Read the libtool library. - dlname= - library_names= - func_source "$file" - - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && \ - func_warning "'$file' was not linked with '-export-dynamic'" - continue - fi - - func_dirname "$file" "" "." - dir=$func_dirname_result - - if test -f "$dir/$objdir/$dlname"; then - func_append dir "/$objdir" - else - if test ! -f "$dir/$dlname"; then - func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'" - fi - fi - ;; - - *.lo) - # Just add the directory containing the .lo file. - func_dirname "$file" "" "." - dir=$func_dirname_result - ;; - - *) - func_warning "'-dlopen' is ignored for non-libtool libraries and objects" - continue - ;; - esac - - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir=$absdir - - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done - - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic=$magic - - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -* | *.la | *.lo ) ;; - *) - # Do a test to see if this is really a libtool program. - if func_ltwrapper_script_p "$file"; then - func_source "$file" - # Transform arg to wrapped name. - file=$progdir/$program - elif func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - func_source "$func_ltwrapper_scriptname_result" - # Transform arg to wrapped name. - file=$progdir/$program - fi - ;; - esac - # Quote arguments (to preserve shell metacharacters). - func_append_quoted args "$file" - done - - if $opt_dry_run; then - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - echo "export $shlibpath_var" - fi - $ECHO "$cmd$args" - exit $EXIT_SUCCESS - else - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi - - # Restore saved environment variables - for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES - do - eval "if test \"\${save_$lt_var+set}\" = set; then - $lt_var=\$save_$lt_var; export $lt_var - else - $lt_unset $lt_var - fi" - done - - # Now prepare to actually exec the command. - exec_cmd=\$cmd$args - fi -} - -test execute = "$opt_mode" && func_mode_execute ${1+"$@"} - - -# func_mode_finish arg... -func_mode_finish () -{ - $debug_cmd - - libs= - libdirs= - admincmds= - - for opt in "$nonopt" ${1+"$@"} - do - if test -d "$opt"; then - func_append libdirs " $opt" - - elif test -f "$opt"; then - if func_lalib_unsafe_p "$opt"; then - func_append libs " $opt" - else - func_warning "'$opt' is not a valid libtool archive" - fi - - else - func_fatal_error "invalid argument '$opt'" - fi - done - - if test -n "$libs"; then - if test -n "$lt_sysroot"; then - sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` - sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" - else - sysroot_cmd= - fi - - # Remove sysroot references - if $opt_dry_run; then - for lib in $libs; do - echo "removing references to $lt_sysroot and '=' prefixes from $lib" - done - else - tmpdir=`func_mktempdir` - for lib in $libs; do - $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ - > $tmpdir/tmp-la - mv -f $tmpdir/tmp-la $lib - done - ${RM}r "$tmpdir" - fi - fi - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - func_execute_cmds "$finish_cmds" 'admincmds="$admincmds -'"$cmd"'"' - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || func_append admincmds " - $cmds" - fi - done - fi - - # Exit here if they wanted silent mode. - $opt_quiet && exit $EXIT_SUCCESS - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - echo "----------------------------------------------------------------------" - echo "Libraries have been installed in:" - for libdir in $libdirs; do - $ECHO " $libdir" - done - echo - echo "If you ever happen to want to link against installed libraries" - echo "in a given directory, LIBDIR, you must either use libtool, and" - echo "specify the full pathname of the library, or use the '-LLIBDIR'" - echo "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - echo " - add LIBDIR to the '$shlibpath_var' environment variable" - echo " during execution" - fi - if test -n "$runpath_var"; then - echo " - add LIBDIR to the '$runpath_var' environment variable" - echo " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" - - $ECHO " - use the '$flag' linker flag" - fi - if test -n "$admincmds"; then - $ECHO " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'" - fi - echo - - echo "See any operating system documentation about shared libraries for" - case $host in - solaris2.[6789]|solaris2.1[0-9]) - echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" - echo "pages." - ;; - *) - echo "more information, such as the ld(1) and ld.so(8) manual pages." - ;; - esac - echo "----------------------------------------------------------------------" - fi - exit $EXIT_SUCCESS -} - -test finish = "$opt_mode" && func_mode_finish ${1+"$@"} - - -# func_mode_install arg... -func_mode_install () -{ - $debug_cmd - - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" || - # Allow the use of GNU shtool's install command. - case $nonopt in *shtool*) :;; *) false;; esac - then - # Aesthetically quote it. - func_quote_arg pretty "$nonopt" - install_prog="$func_quote_arg_result " - arg=$1 - shift - else - install_prog= - arg=$nonopt - fi - - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - func_quote_arg pretty "$arg" - func_append install_prog "$func_quote_arg_result" - install_shared_prog=$install_prog - case " $install_prog " in - *[\\\ /]cp\ *) install_cp=: ;; - *) install_cp=false ;; - esac - - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=false - stripme= - no_mode=: - for arg - do - arg2= - if test -n "$dest"; then - func_append files " $dest" - dest=$arg - continue - fi - - case $arg in - -d) isdir=: ;; - -f) - if $install_cp; then :; else - prev=$arg - fi - ;; - -g | -m | -o) - prev=$arg - ;; - -s) - stripme=" -s" - continue - ;; - -*) - ;; - *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - if test X-m = "X$prev" && test -n "$install_override_mode"; then - arg2=$install_override_mode - no_mode=false - fi - prev= - else - dest=$arg - continue - fi - ;; - esac - - # Aesthetically quote the argument. - func_quote_arg pretty "$arg" - func_append install_prog " $func_quote_arg_result" - if test -n "$arg2"; then - func_quote_arg pretty "$arg2" - fi - func_append install_shared_prog " $func_quote_arg_result" - done - - test -z "$install_prog" && \ - func_fatal_help "you must specify an install program" - - test -n "$prev" && \ - func_fatal_help "the '$prev' option requires an argument" - - if test -n "$install_override_mode" && $no_mode; then - if $install_cp; then :; else - func_quote_arg pretty "$install_override_mode" - func_append install_shared_prog " -m $func_quote_arg_result" - fi - fi - - if test -z "$files"; then - if test -z "$dest"; then - func_fatal_help "no file or destination specified" - else - func_fatal_help "you must specify a destination" - fi - fi - - # Strip any trailing slash from the destination. - func_stripname '' '/' "$dest" - dest=$func_stripname_result - - # Check to see that the destination is a directory. - test -d "$dest" && isdir=: - if $isdir; then - destdir=$dest - destname= - else - func_dirname_and_basename "$dest" "" "." - destdir=$func_dirname_result - destname=$func_basename_result - - # Not a directory, so check to see that there is only one file specified. - set dummy $files; shift - test "$#" -gt 1 && \ - func_fatal_help "'$dest' is not a directory" - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - func_fatal_help "'$destdir' must be an absolute directory name" - ;; - esac - done - ;; - esac - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic=$magic - - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do - - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - func_append staticlibs " $file" - ;; - - *.la) - func_resolve_sysroot "$file" - file=$func_resolve_sysroot_result - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "'$file' is not a valid libtool archive" - - library_names= - old_library= - relink_command= - func_source "$file" - - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in - *" $libdir "*) ;; - *) func_append current_libdirs " $libdir" ;; - esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in - *" $libdir "*) ;; - *) func_append future_libdirs " $libdir" ;; - esac - fi - - func_dirname "$file" "/" "" - dir=$func_dirname_result - func_append dir "$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` - - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - test "$inst_prefix_dir" = "$destdir" && \ - func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir" - - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` - fi - - func_warning "relinking '$file'" - func_show_eval "$relink_command" \ - 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"' - fi - - # See the names of the shared library. - set dummy $library_names; shift - if test -n "$1"; then - realname=$1 - shift - - srcname=$realname - test -n "$relink_command" && srcname=${realname}T - - # Install the shared library and build the symlinks. - func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ - 'exit $?' - tstripme=$stripme - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - case $realname in - *.dll.a) - tstripme= - ;; - esac - ;; - os2*) - case $realname in - *_dll.a) - tstripme= - ;; - esac - ;; - esac - if test -n "$tstripme" && test -n "$striplib"; then - func_show_eval "$striplib $destdir/$realname" 'exit $?' - fi - - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try 'ln -sf' first, because the 'ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - test "$linkname" != "$realname" \ - && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" - done - fi - - # Do each command in the postinstall commands. - lib=$destdir/$realname - func_execute_cmds "$postinstall_cmds" 'exit $?' - fi - - # Install the pseudo-library for information purposes. - func_basename "$file" - name=$func_basename_result - instname=$dir/${name}i - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' - - # Maybe install the static library, too. - test -n "$old_library" && func_append staticlibs " $dir/$old_library" - ;; - - *.lo) - # Install (i.e. copy) a libtool object. - - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile=$destdir/$destname - else - func_basename "$file" - destfile=$func_basename_result - destfile=$destdir/$destfile - fi - - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - func_lo2o "$destfile" - staticdest=$func_lo2o_result - ;; - *.$objext) - staticdest=$destfile - destfile= - ;; - *) - func_fatal_help "cannot copy a libtool object to '$destfile'" - ;; - esac - - # Install the libtool object if requested. - test -n "$destfile" && \ - func_show_eval "$install_prog $file $destfile" 'exit $?' - - # Install the old object if enabled. - if test yes = "$build_old_libs"; then - # Deduce the name of the old-style object file. - func_lo2o "$file" - staticobj=$func_lo2o_result - func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' - fi - exit $EXIT_SUCCESS - ;; - - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile=$destdir/$destname - else - func_basename "$file" - destfile=$func_basename_result - destfile=$destdir/$destfile - fi - - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext= - case $file in - *.exe) - if test ! -f "$file"; then - func_stripname '' '.exe' "$file" - file=$func_stripname_result - stripped_ext=.exe - fi - ;; - esac - - # Do a test to see if this is really a libtool program. - case $host in - *cygwin* | *mingw*) - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - wrapper=$func_ltwrapper_scriptname_result - else - func_stripname '' '.exe' "$file" - wrapper=$func_stripname_result - fi - ;; - *) - wrapper=$file - ;; - esac - if func_ltwrapper_script_p "$wrapper"; then - notinst_deplibs= - relink_command= - - func_source "$wrapper" - - # Check the variables that should have been set. - test -z "$generated_by_libtool_version" && \ - func_fatal_error "invalid libtool wrapper script '$wrapper'" - - finalize=: - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - func_source "$lib" - fi - libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'` - if test -n "$libdir" && test ! -f "$libfile"; then - func_warning "'$lib' has not been installed in '$libdir'" - finalize=false - fi - done - - relink_command= - func_source "$wrapper" - - outputname= - if test no = "$fast_install" && test -n "$relink_command"; then - $opt_dry_run || { - if $finalize; then - tmpdir=`func_mktempdir` - func_basename "$file$stripped_ext" - file=$func_basename_result - outputname=$tmpdir/$file - # Replace the output file specification. - relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` - - $opt_quiet || { - func_quote_arg expand,pretty "$relink_command" - eval "func_echo $func_quote_arg_result" - } - if eval "$relink_command"; then : - else - func_error "error: relink '$file' with the above command before installing it" - $opt_dry_run || ${RM}r "$tmpdir" - continue - fi - file=$outputname - else - func_warning "cannot relink '$file'" - fi - } - else - # Install the binary that we compiled earlier. - file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` - fi - fi - - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - func_stripname '' '.exe' "$destfile" - destfile=$func_stripname_result - ;; - esac - ;; - esac - func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' - $opt_dry_run || if test -n "$outputname"; then - ${RM}r "$tmpdir" - fi - ;; - esac - done - - for file in $staticlibs; do - func_basename "$file" - name=$func_basename_result - - # Set up the ranlib parameters. - oldlib=$destdir/$name - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - - func_show_eval "$install_prog \$file \$oldlib" 'exit $?' - - if test -n "$stripme" && test -n "$old_striplib"; then - func_show_eval "$old_striplib $tool_oldlib" 'exit $?' - fi - - # Do each command in the postinstall commands. - func_execute_cmds "$old_postinstall_cmds" 'exit $?' - done - - test -n "$future_libdirs" && \ - func_warning "remember to run '$progname --finish$future_libdirs'" - - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - $opt_dry_run && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs' - else - exit $EXIT_SUCCESS - fi -} - -test install = "$opt_mode" && func_mode_install ${1+"$@"} - - -# func_generate_dlsyms outputname originator pic_p -# Extract symbols from dlprefiles and create ${outputname}S.o with -# a dlpreopen symbol table. -func_generate_dlsyms () -{ - $debug_cmd - - my_outputname=$1 - my_originator=$2 - my_pic_p=${3-false} - my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'` - my_dlsyms= - - if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - my_dlsyms=${my_outputname}S.c - else - func_error "not configured to extract global symbols from dlpreopened files" - fi - fi - - if test -n "$my_dlsyms"; then - case $my_dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist=$output_objdir/$my_outputname.nm - - func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - - # Parse the name list into a source file. - func_verbose "creating $output_objdir/$my_dlsyms" - - $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ -/* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */ -/* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */ - -#ifdef __cplusplus -extern \"C\" { -#endif - -#if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) -#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" -#endif - -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE -/* DATA imports from DLLs on WIN32 can't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined __osf__ -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -#define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) - -/* External symbol declarations for the compiler. */\ -" - - if test yes = "$dlself"; then - func_verbose "generating symbol list for '$output'" - - $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` - for progfile in $progfiles; do - func_to_tool_file "$progfile" func_convert_file_msys_to_w32 - func_verbose "extracting global C symbols from '$func_to_tool_file_result'" - $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $opt_dry_run || { - eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - if test -n "$export_symbols_regex"; then - $opt_dry_run || { - eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols=$output_objdir/$outputname.exp - $opt_dry_run || { - $RM $export_symbols - eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - } - else - $opt_dry_run || { - eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - } - fi - fi - - for dlprefile in $dlprefiles; do - func_verbose "extracting global C symbols from '$dlprefile'" - func_basename "$dlprefile" - name=$func_basename_result - case $host in - *cygwin* | *mingw* | *cegcc* ) - # if an import library, we need to obtain dlname - if func_win32_import_lib_p "$dlprefile"; then - func_tr_sh "$dlprefile" - eval "curr_lafile=\$libfile_$func_tr_sh_result" - dlprefile_dlbasename= - if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then - # Use subshell, to avoid clobbering current variable values - dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` - if test -n "$dlprefile_dlname"; then - func_basename "$dlprefile_dlname" - dlprefile_dlbasename=$func_basename_result - else - # no lafile. user explicitly requested -dlpreopen . - $sharedlib_from_linklib_cmd "$dlprefile" - dlprefile_dlbasename=$sharedlib_from_linklib_result - fi - fi - $opt_dry_run || { - if test -n "$dlprefile_dlbasename"; then - eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' - else - func_warning "Could not compute DLL name from $name" - eval '$ECHO ": $name " >> "$nlist"' - fi - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | - $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" - } - else # not an import lib - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - fi - ;; - *) - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - ;; - esac - done - - $opt_dry_run || { - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $MV "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if $GREP -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - $GREP -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' - else - echo '/* NONE */' >> "$output_objdir/$my_dlsyms" - fi - - func_show_eval '$RM "${nlist}I"' - if test -n "$global_symbol_to_import"; then - eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I' - fi - - echo >> "$output_objdir/$my_dlsyms" "\ - -/* The mapping between symbol names and symbols. */ -typedef struct { - const char *name; - void *address; -} lt_dlsymlist; -extern LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[];\ -" - - if test -s "$nlist"I; then - echo >> "$output_objdir/$my_dlsyms" "\ -static void lt_syminit(void) -{ - LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols; - for (; symbol->name; ++symbol) - {" - $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms" - echo >> "$output_objdir/$my_dlsyms" "\ - } -}" - fi - echo >> "$output_objdir/$my_dlsyms" "\ -LT_DLSYM_CONST lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[] = -{ {\"$my_originator\", (void *) 0}," - - if test -s "$nlist"I; then - echo >> "$output_objdir/$my_dlsyms" "\ - {\"@INIT@\", (void *) <_syminit}," - fi - - case $need_lib_prefix in - no) - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - *) - eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - esac - echo >> "$output_objdir/$my_dlsyms" "\ - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_${my_prefix}_LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif\ -" - } # !$opt_dry_run - - pic_flag_for_symtable= - case "$compile_command " in - *" -static "*) ;; - *) - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; - *-*-hpux*) - pic_flag_for_symtable=" $pic_flag" ;; - *) - $my_pic_p && pic_flag_for_symtable=" $pic_flag" - ;; - esac - ;; - esac - symtab_cflags= - for arg in $LTCFLAGS; do - case $arg in - -pie | -fpie | -fPIE) ;; - *) func_append symtab_cflags " $arg" ;; - esac - done - - # Now compile the dynamic symbol file. - func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - - # Clean up the generated files. - func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"' - - # Transform the symbol file into the correct name. - symfileobj=$output_objdir/${my_outputname}S.$objext - case $host in - *cygwin* | *mingw* | *cegcc* ) - if test -f "$output_objdir/$my_outputname.def"; then - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - else - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - fi - ;; - *) - compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` - ;; - esac - ;; - *) - func_fatal_error "unknown suffix for '$my_dlsyms'" - ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. - - # Nullify the symbol file. - compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` - finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` - fi -} - -# func_cygming_gnu_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is a GNU/binutils-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_gnu_implib_p () -{ - $debug_cmd - - func_to_tool_file "$1" func_convert_file_msys_to_w32 - func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` - test -n "$func_cygming_gnu_implib_tmp" -} - -# func_cygming_ms_implib_p ARG -# This predicate returns with zero status (TRUE) if -# ARG is an MS-style import library. Returns -# with nonzero status (FALSE) otherwise. -func_cygming_ms_implib_p () -{ - $debug_cmd - - func_to_tool_file "$1" func_convert_file_msys_to_w32 - func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` - test -n "$func_cygming_ms_implib_tmp" -} - -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -# Despite the name, also deal with 64 bit binaries. -func_win32_libid () -{ - $debug_cmd - - win32_libid_type=unknown - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then - case $nm_interface in - "MS dumpbin") - if func_cygming_ms_implib_p "$1" || - func_cygming_gnu_implib_p "$1" - then - win32_nmres=import - else - win32_nmres= - fi - ;; - *) - func_to_tool_file "$1" func_convert_file_msys_to_w32 - win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | - $SED -n -e ' - 1,100{ - / I /{ - s|.*|import| - p - q - } - }'` - ;; - esac - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; - esac - ;; - esac - $ECHO "$win32_libid_type" -} - -# func_cygming_dll_for_implib ARG -# -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib () -{ - $debug_cmd - - sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` -} - -# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs -# -# The is the core of a fallback implementation of a -# platform-specific function to extract the name of the -# DLL associated with the specified import library LIBNAME. -# -# SECTION_NAME is either .idata$6 or .idata$7, depending -# on the platform and compiler that created the implib. -# -# Echos the name of the DLL associated with the -# specified import library. -func_cygming_dll_for_implib_fallback_core () -{ - $debug_cmd - - match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` - $OBJDUMP -s --section "$1" "$2" 2>/dev/null | - $SED '/^Contents of section '"$match_literal"':/{ - # Place marker at beginning of archive member dllname section - s/.*/====MARK====/ - p - d - } - # These lines can sometimes be longer than 43 characters, but - # are always uninteresting - /:[ ]*file format pe[i]\{,1\}-/d - /^In archive [^:]*:/d - # Ensure marker is printed - /^====MARK====/p - # Remove all lines with less than 43 characters - /^.\{43\}/!d - # From remaining lines, remove first 43 characters - s/^.\{43\}//' | - $SED -n ' - # Join marker and all lines until next marker into a single line - /^====MARK====/ b para - H - $ b para - b - :para - x - s/\n//g - # Remove the marker - s/^====MARK====// - # Remove trailing dots and whitespace - s/[\. \t]*$// - # Print - /./p' | - # we now have a list, one entry per line, of the stringified - # contents of the appropriate section of all members of the - # archive that possess that section. Heuristic: eliminate - # all those that have a first or second character that is - # a '.' (that is, objdump's representation of an unprintable - # character.) This should work for all archives with less than - # 0x302f exports -- but will fail for DLLs whose name actually - # begins with a literal '.' or a single character followed by - # a '.'. - # - # Of those that remain, print the first one. - $SED -e '/^\./d;/^.\./d;q' -} - -# func_cygming_dll_for_implib_fallback ARG -# Platform-specific function to extract the -# name of the DLL associated with the specified -# import library ARG. -# -# This fallback implementation is for use when $DLLTOOL -# does not support the --identify-strict option. -# Invoked by eval'ing the libtool variable -# $sharedlib_from_linklib_cmd -# Result is available in the variable -# $sharedlib_from_linklib_result -func_cygming_dll_for_implib_fallback () -{ - $debug_cmd - - if func_cygming_gnu_implib_p "$1"; then - # binutils import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` - elif func_cygming_ms_implib_p "$1"; then - # ms-generated import library - sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` - else - # unknown - sharedlib_from_linklib_result= - fi -} - - -# func_extract_an_archive dir oldlib -func_extract_an_archive () -{ - $debug_cmd - - f_ex_an_ar_dir=$1; shift - f_ex_an_ar_oldlib=$1 - if test yes = "$lock_old_archive_extraction"; then - lockfile=$f_ex_an_ar_oldlib.lock - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" - sleep 2 - done - fi - func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ - 'stat=$?; rm -f "$lockfile"; exit $stat' - if test yes = "$lock_old_archive_extraction"; then - $opt_dry_run || rm -f "$lockfile" - fi - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" - fi -} - - -# func_extract_archives gentop oldlib ... -func_extract_archives () -{ - $debug_cmd - - my_gentop=$1; shift - my_oldlibs=${1+"$@"} - my_oldobjs= - my_xlib= - my_xabs= - my_xdir= - - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - func_basename "$my_xlib" - my_xlib=$func_basename_result - my_xlib_u=$my_xlib - while :; do - case " $extracted_archives " in - *" $my_xlib_u "*) - func_arith $extracted_serial + 1 - extracted_serial=$func_arith_result - my_xlib_u=lt$extracted_serial-$my_xlib ;; - *) break ;; - esac - done - extracted_archives="$extracted_archives $my_xlib_u" - my_xdir=$my_gentop/$my_xlib_u - - func_mkdir_p "$my_xdir" - - case $host in - *-darwin*) - func_verbose "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - $opt_dry_run || { - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - func_basename "$darwin_archive" - darwin_base_archive=$func_basename_result - darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` - if test -n "$darwin_arches"; then - darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches; do - func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch" - $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive" - cd "unfat-$$/$darwin_base_archive-$darwin_arch" - func_extract_an_archive "`pwd`" "$darwin_base_archive" - cd "$darwin_curdir" - $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" - done # $darwin_arches - ## Okay now we've a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` - $LIPO -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - $RM -rf unfat-$$ - cd "$darwin_orig_dir" - else - cd $darwin_orig_dir - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - } # !$opt_dry_run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` - done - - func_extract_archives_result=$my_oldobjs -} - - -# func_emit_wrapper [arg=no] -# -# Emit a libtool wrapper script on stdout. -# Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw -# wrapper executable. Must ONLY be called from within -# func_mode_link because it depends on a number of variables -# set therein. -# -# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR -# variable will take. If 'yes', then the emitted script -# will assume that the directory where it is stored is -# the $objdir directory. This is a cygwin/mingw-specific -# behavior. -func_emit_wrapper () -{ - func_emit_wrapper_arg1=${1-no} - - $ECHO "\ -#! $SHELL - -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM (GNU $PACKAGE) $VERSION -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='$sed_quote_subst' - -# Be Bourne compatible -if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -relink_command=\"$relink_command\" - -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variables: - generated_by_libtool_version='$macro_version' - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$ECHO are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - file=\"\$0\"" - - func_quote_arg pretty "$ECHO" - qECHO=$func_quote_arg_result - $ECHO "\ - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - ECHO=$qECHO - fi - -# Very basic option parsing. These options are (a) specific to -# the libtool wrapper, (b) are identical between the wrapper -# /script/ and the wrapper /executable/ that is used only on -# windows platforms, and (c) all begin with the string "--lt-" -# (application programs are unlikely to have options that match -# this pattern). -# -# There are only two supported options: --lt-debug and -# --lt-dump-script. There is, deliberately, no --lt-help. -# -# The first argument to this parsing function should be the -# script's $0 value, followed by "$@". -lt_option_debug= -func_parse_lt_options () -{ - lt_script_arg0=\$0 - shift - for lt_opt - do - case \"\$lt_opt\" in - --lt-debug) lt_option_debug=1 ;; - --lt-dump-script) - lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` - test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. - lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` - cat \"\$lt_dump_D/\$lt_dump_F\" - exit 0 - ;; - --lt-*) - \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 - exit 1 - ;; - esac - done - - # Print the debug banner immediately: - if test -n \"\$lt_option_debug\"; then - echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2 - fi -} - -# Used when --lt-debug. Prints its arguments to stdout -# (redirection is the responsibility of the caller) -func_lt_dump_args () -{ - lt_dump_args_N=1; - for lt_arg - do - \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\" - lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` - done -} - -# Core function for launching the target application -func_exec_program_core () -{ -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $ECHO "\ - if test -n \"\$lt_option_debug\"; then - \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2 - func_lt_dump_args \${1+\"\$@\"} 1>&2 - fi - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" - ;; - esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 -} - -# A function to encapsulate launching the target application -# Strips options in the --lt-* namespace from \$@ and -# launches target application with the remaining arguments. -func_exec_program () -{ - case \" \$* \" in - *\\ --lt-*) - for lt_wr_arg - do - case \$lt_wr_arg in - --lt-*) ;; - *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; - esac - shift - done ;; - esac - func_exec_program_core \${1+\"\$@\"} -} - - # Parse options - func_parse_lt_options \"\$0\" \${1+\"\$@\"} - - # Find the directory that this script lives in. - thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. - - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` - - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi - - file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` - done - - # Usually 'no', except on cygwin/mingw when embedded into - # the cwrapper. - WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 - if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then - # special case for '.' - if test \"\$thisdir\" = \".\"; then - thisdir=\`pwd\` - fi - # remove .libs from thisdir - case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; - $objdir ) thisdir=. ;; - esac - fi - - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" - - if test yes = "$fast_install"; then - $ECHO "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" - - if test ! -f \"\$progdir/\$program\" || - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then - - file=\"\$\$-\$program\" - - if test ! -d \"\$progdir\"; then - $MKDIR \"\$progdir\" - else - $RM \"\$progdir/\$file\" - fi" - - $ECHO "\ - - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - \$ECHO \"\$relink_command_output\" >&2 - $RM \"\$progdir/\$file\" - exit 1 - fi - fi - - $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $RM \"\$progdir/\$program\"; - $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $RM \"\$progdir/\$file\" - fi" - else - $ECHO "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" - fi - - $ECHO "\ - - if test -f \"\$progdir/\$program\"; then" - - # fixup the dll searchpath if we need to. - # - # Fix the DLL searchpath if we need to. Do this before prepending - # to shlibpath, because on Windows, both are PATH and uninstalled - # libraries must come first. - if test -n "$dllsearchpath"; then - $ECHO "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" - fi - - # Export our shlibpath_var if we have one. - if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $ECHO "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` - - export $shlibpath_var -" - fi - - $ECHO "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. - func_exec_program \${1+\"\$@\"} - fi - else - # The program doesn't exist. - \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2 - \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 - \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 - exit 1 - fi -fi\ -" -} - - -# func_emit_cwrapperexe_src -# emit the source code for a wrapper executable on stdout -# Must ONLY be called from within func_mode_link because -# it depends on a number of variable set therein. -func_emit_cwrapperexe_src () -{ - cat < -#include -#ifdef _MSC_VER -# include -# include -# include -#else -# include -# include -# ifdef __CYGWIN__ -# include -# endif -#endif -#include -#include -#include -#include -#include -#include -#include -#include - -#define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) - -/* declarations of non-ANSI functions */ -#if defined __MINGW32__ -# ifdef __STRICT_ANSI__ -int _putenv (const char *); -# endif -#elif defined __CYGWIN__ -# ifdef __STRICT_ANSI__ -char *realpath (const char *, char *); -int putenv (char *); -int setenv (const char *, const char *, int); -# endif -/* #elif defined other_platform || defined ... */ -#endif - -/* portability defines, excluding path handling macros */ -#if defined _MSC_VER -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -# define S_IXUSR _S_IEXEC -#elif defined __MINGW32__ -# define setmode _setmode -# define stat _stat -# define chmod _chmod -# define getcwd _getcwd -# define putenv _putenv -#elif defined __CYGWIN__ -# define HAVE_SETENV -# define FOPEN_WB "wb" -/* #elif defined other platforms ... */ -#endif - -#if defined PATH_MAX -# define LT_PATHMAX PATH_MAX -#elif defined MAXPATHLEN -# define LT_PATHMAX MAXPATHLEN -#else -# define LT_PATHMAX 1024 -#endif - -#ifndef S_IXOTH -# define S_IXOTH 0 -#endif -#ifndef S_IXGRP -# define S_IXGRP 0 -#endif - -/* path handling portability macros */ -#ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' -#endif - -#if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \ - defined __OS2__ -# define HAVE_DOS_BASED_FILE_SYSTEM -# define FOPEN_WB "wb" -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif -#endif - -#ifndef DIR_SEPARATOR_2 -# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) -#else /* DIR_SEPARATOR_2 */ -# define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) -#endif /* DIR_SEPARATOR_2 */ - -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ - -#ifndef FOPEN_WB -# define FOPEN_WB "w" -#endif -#ifndef _O_BINARY -# define _O_BINARY 0 -#endif - -#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) -#define XFREE(stale) do { \ - if (stale) { free (stale); stale = 0; } \ -} while (0) - -#if defined LT_DEBUGWRAPPER -static int lt_debug = 1; -#else -static int lt_debug = 0; -#endif - -const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ - -void *xmalloc (size_t num); -char *xstrdup (const char *string); -const char *base_name (const char *name); -char *find_executable (const char *wrapper); -char *chase_symlinks (const char *pathspec); -int make_executable (const char *path); -int check_executable (const char *path); -char *strendzap (char *str, const char *pat); -void lt_debugprintf (const char *file, int line, const char *fmt, ...); -void lt_fatal (const char *file, int line, const char *message, ...); -static const char *nonnull (const char *s); -static const char *nonempty (const char *s); -void lt_setenv (const char *name, const char *value); -char *lt_extend_str (const char *orig_value, const char *add, int to_end); -void lt_update_exe_path (const char *name, const char *value); -void lt_update_lib_path (const char *name, const char *value); -char **prepare_spawn (char **argv); -void lt_dump_script (FILE *f); -EOF - - cat <= 0) - && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) - return 1; - else - return 0; -} - -int -make_executable (const char *path) -{ - int rval = 0; - struct stat st; - - lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", - nonempty (path)); - if ((!path) || (!*path)) - return 0; - - if (stat (path, &st) >= 0) - { - rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); - } - return rval; -} - -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise - Does not chase symlinks, even on platforms that support them. -*/ -char * -find_executable (const char *wrapper) -{ - int has_slash = 0; - const char *p; - const char *p_next; - /* static buffer for getcwd */ - char tmp[LT_PATHMAX + 1]; - size_t tmp_len; - char *concat_name; - - lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", - nonempty (wrapper)); - - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; - - /* Absolute path? */ -#if defined HAVE_DOS_BASED_FILE_SYSTEM - if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } -#if defined HAVE_DOS_BASED_FILE_SYSTEM - } -#endif - - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char *path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char *q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR (*q)) - break; - p_len = (size_t) (q - p); - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = - XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = - XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", - nonnull (strerror (errno))); - tmp_len = strlen (tmp); - concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - return NULL; -} - -char * -chase_symlinks (const char *pathspec) -{ -#ifndef S_ISLNK - return xstrdup (pathspec); -#else - char buf[LT_PATHMAX]; - struct stat s; - char *tmp_pathspec = xstrdup (pathspec); - char *p; - int has_symlinks = 0; - while (strlen (tmp_pathspec) && !has_symlinks) - { - lt_debugprintf (__FILE__, __LINE__, - "checking path component for symlinks: %s\n", - tmp_pathspec); - if (lstat (tmp_pathspec, &s) == 0) - { - if (S_ISLNK (s.st_mode) != 0) - { - has_symlinks = 1; - break; - } - - /* search backwards for last DIR_SEPARATOR */ - p = tmp_pathspec + strlen (tmp_pathspec) - 1; - while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - p--; - if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - { - /* no more DIR_SEPARATORS left */ - break; - } - *p = '\0'; - } - else - { - lt_fatal (__FILE__, __LINE__, - "error accessing file \"%s\": %s", - tmp_pathspec, nonnull (strerror (errno))); - } - } - XFREE (tmp_pathspec); - - if (!has_symlinks) - { - return xstrdup (pathspec); - } - - tmp_pathspec = realpath (pathspec, buf); - if (tmp_pathspec == 0) - { - lt_fatal (__FILE__, __LINE__, - "could not follow symlinks for %s", pathspec); - } - return xstrdup (tmp_pathspec); -#endif -} - -char * -strendzap (char *str, const char *pat) -{ - size_t len, patlen; - - assert (str != NULL); - assert (pat != NULL); - - len = strlen (str); - patlen = strlen (pat); - - if (patlen <= len) - { - str += len - patlen; - if (STREQ (str, pat)) - *str = '\0'; - } - return str; -} - -void -lt_debugprintf (const char *file, int line, const char *fmt, ...) -{ - va_list args; - if (lt_debug) - { - (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); - va_start (args, fmt); - (void) vfprintf (stderr, fmt, args); - va_end (args); - } -} - -static void -lt_error_core (int exit_status, const char *file, - int line, const char *mode, - const char *message, va_list ap) -{ - fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); - vfprintf (stderr, message, ap); - fprintf (stderr, ".\n"); - - if (exit_status >= 0) - exit (exit_status); -} - -void -lt_fatal (const char *file, int line, const char *message, ...) -{ - va_list ap; - va_start (ap, message); - lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); - va_end (ap); -} - -static const char * -nonnull (const char *s) -{ - return s ? s : "(null)"; -} - -static const char * -nonempty (const char *s) -{ - return (s && !*s) ? "(empty)" : nonnull (s); -} - -void -lt_setenv (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_setenv) setting '%s' to '%s'\n", - nonnull (name), nonnull (value)); - { -#ifdef HAVE_SETENV - /* always make a copy, for consistency with !HAVE_SETENV */ - char *str = xstrdup (value); - setenv (name, str, 1); -#else - size_t len = strlen (name) + 1 + strlen (value) + 1; - char *str = XMALLOC (char, len); - sprintf (str, "%s=%s", name, value); - if (putenv (str) != EXIT_SUCCESS) - { - XFREE (str); - } -#endif - } -} - -char * -lt_extend_str (const char *orig_value, const char *add, int to_end) -{ - char *new_value; - if (orig_value && *orig_value) - { - size_t orig_value_len = strlen (orig_value); - size_t add_len = strlen (add); - new_value = XMALLOC (char, add_len + orig_value_len + 1); - if (to_end) - { - strcpy (new_value, orig_value); - strcpy (new_value + orig_value_len, add); - } - else - { - strcpy (new_value, add); - strcpy (new_value + add_len, orig_value); - } - } - else - { - new_value = xstrdup (add); - } - return new_value; -} - -void -lt_update_exe_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - /* some systems can't cope with a ':'-terminated path #' */ - size_t len = strlen (new_value); - while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1])) - { - new_value[--len] = '\0'; - } - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -void -lt_update_lib_path (const char *name, const char *value) -{ - lt_debugprintf (__FILE__, __LINE__, - "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", - nonnull (name), nonnull (value)); - - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - } -} - -EOF - case $host_os in - mingw*) - cat <<"EOF" - -/* Prepares an argument vector before calling spawn(). - Note that spawn() does not by itself call the command interpreter - (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : - ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); - GetVersionEx(&v); - v.dwPlatformId == VER_PLATFORM_WIN32_NT; - }) ? "cmd.exe" : "command.com"). - Instead it simply concatenates the arguments, separated by ' ', and calls - CreateProcess(). We must quote the arguments since Win32 CreateProcess() - interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a - special way: - - Space and tab are interpreted as delimiters. They are not treated as - delimiters if they are surrounded by double quotes: "...". - - Unescaped double quotes are removed from the input. Their only effect is - that within double quotes, space and tab are treated like normal - characters. - - Backslashes not followed by double quotes are not special. - - But 2*n+1 backslashes followed by a double quote become - n backslashes followed by a double quote (n >= 0): - \" -> " - \\\" -> \" - \\\\\" -> \\" - */ -#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" -#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" -char ** -prepare_spawn (char **argv) -{ - size_t argc; - char **new_argv; - size_t i; - - /* Count number of arguments. */ - for (argc = 0; argv[argc] != NULL; argc++) - ; - - /* Allocate new argument vector. */ - new_argv = XMALLOC (char *, argc + 1); - - /* Put quoted arguments into the new argument vector. */ - for (i = 0; i < argc; i++) - { - const char *string = argv[i]; - - if (string[0] == '\0') - new_argv[i] = xstrdup ("\"\""); - else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) - { - int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); - size_t length; - unsigned int backslashes; - const char *s; - char *quoted_string; - char *p; - - length = 0; - backslashes = 0; - if (quote_around) - length++; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - length += backslashes + 1; - length++; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - length += backslashes + 1; - - quoted_string = XMALLOC (char, length + 1); - - p = quoted_string; - backslashes = 0; - if (quote_around) - *p++ = '"'; - for (s = string; *s != '\0'; s++) - { - char c = *s; - if (c == '"') - { - unsigned int j; - for (j = backslashes + 1; j > 0; j--) - *p++ = '\\'; - } - *p++ = c; - if (c == '\\') - backslashes++; - else - backslashes = 0; - } - if (quote_around) - { - unsigned int j; - for (j = backslashes; j > 0; j--) - *p++ = '\\'; - *p++ = '"'; - } - *p = '\0'; - - new_argv[i] = quoted_string; - } - else - new_argv[i] = (char *) string; - } - new_argv[argc] = NULL; - - return new_argv; -} -EOF - ;; - esac - - cat <<"EOF" -void lt_dump_script (FILE* f) -{ -EOF - func_emit_wrapper yes | - $SED -n -e ' -s/^\(.\{79\}\)\(..*\)/\1\ -\2/ -h -s/\([\\"]\)/\\\1/g -s/$/\\n/ -s/\([^\n]*\).*/ fputs ("\1", f);/p -g -D' - cat <<"EOF" -} -EOF -} -# end: func_emit_cwrapperexe_src - -# func_win32_import_lib_p ARG -# True if ARG is an import lib, as indicated by $file_magic_cmd -func_win32_import_lib_p () -{ - $debug_cmd - - case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in - *import*) : ;; - *) false ;; - esac -} - -# func_suncc_cstd_abi -# !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!! -# Several compiler flags select an ABI that is incompatible with the -# Cstd library. Avoid specifying it if any are in CXXFLAGS. -func_suncc_cstd_abi () -{ - $debug_cmd - - case " $compile_command " in - *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*) - suncc_use_cstd_abi=no - ;; - *) - suncc_use_cstd_abi=yes - ;; - esac -} - -# func_mode_link arg... -func_mode_link () -{ - $debug_cmd - - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - # It is impossible to link a dll without this setting, and - # we shouldn't force the makefile maintainer to figure out - # what system we are compiling for in order to pass an extra - # flag for every libtool invocation. - # allow_undefined=no - - # FIXME: Unfortunately, there are problems with the above when trying - # to make a dll that has undefined symbols, in which case not - # even a static library is built. For now, we need to specify - # -no-undefined on the libtool link line when we can be certain - # that all symbols are satisfied, otherwise we get a static library. - allow_undefined=yes - ;; - *) - allow_undefined=yes - ;; - esac - libtool_args=$nonopt - base_compile="$nonopt $@" - compile_command=$nonopt - finalize_command=$nonopt - - compile_rpath= - finalize_rpath= - compile_shlibpath= - finalize_shlibpath= - convenience= - old_convenience= - deplibs= - old_deplibs= - compiler_flags= - linker_flags= - dllsearchpath= - lib_search_path=`pwd` - inst_prefix_dir= - new_inherited_linker_flags= - - avoid_version=no - bindir= - dlfiles= - dlprefiles= - dlself=no - export_dynamic=no - export_symbols= - export_symbols_regex= - generated= - libobjs= - ltlibs= - module=no - no_install=no - objs= - os2dllname= - non_pic_objects= - precious_files_regex= - prefer_static_libs=no - preload=false - prev= - prevarg= - release= - rpath= - xrpath= - perm_rpath= - temp_rpath= - thread_safe=no - vinfo= - vinfo_number=no - weak_libs= - single_module=$wl-single_module - func_infer_tag $base_compile - - # We need to know -static, to get the right output filenames. - for arg - do - case $arg in - -shared) - test yes != "$build_libtool_libs" \ - && func_fatal_configuration "cannot build a shared library" - build_old_libs=no - break - ;; - -all-static | -static | -static-libtool-libs) - case $arg in - -all-static) - if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then - func_warning "complete static linking is impossible in this configuration" - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - -static) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=built - ;; - -static-libtool-libs) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - esac - build_libtool_libs=no - build_old_libs=yes - break - ;; - esac - done - - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes - - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg=$1 - shift - func_quote_arg pretty,unquoted "$arg" - qarg=$func_quote_arg_unquoted_result - func_append libtool_args " $func_quote_arg_result" - - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - func_append compile_command " @OUTPUT@" - func_append finalize_command " @OUTPUT@" - ;; - esac - - case $prev in - bindir) - bindir=$arg - prev= - continue - ;; - dlfiles|dlprefiles) - $preload || { - # Add the symbol object into the linking commands. - func_append compile_command " @SYMFILE@" - func_append finalize_command " @SYMFILE@" - preload=: - } - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test no = "$dlself"; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test dlprefiles = "$prev"; then - dlself=yes - elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test dlfiles = "$prev"; then - func_append dlfiles " $arg" - else - func_append dlprefiles " $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols=$arg - test -f "$arg" \ - || func_fatal_error "symbol file '$arg' does not exist" - prev= - continue - ;; - expsyms_regex) - export_symbols_regex=$arg - prev= - continue - ;; - framework) - case $host in - *-*-darwin*) - case "$deplibs " in - *" $qarg.ltframework "*) ;; - *) func_append deplibs " $qarg.ltframework" # this is fixed later - ;; - esac - ;; - esac - prev= - continue - ;; - inst_prefix) - inst_prefix_dir=$arg - prev= - continue - ;; - mllvm) - # Clang does not use LLVM to link, so we can simply discard any - # '-mllvm $arg' options when doing the link step. - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat "$save_arg"` - do -# func_append moreargs " $fil" - arg=$fil - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test none = "$pic_object" && - test none = "$non_pic_object"; then - func_fatal_error "cannot find name of object for '$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir=$func_dirname_result - - if test none != "$pic_object"; then - # Prepend the subdirectory the object is found in. - pic_object=$xdir$pic_object - - if test dlfiles = "$prev"; then - if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test dlprefiles = "$prev"; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg=$pic_object - fi - - # Non-PIC object. - if test none != "$non_pic_object"; then - # Prepend the subdirectory the object is found in. - non_pic_object=$xdir$non_pic_object - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test none = "$pic_object"; then - arg=$non_pic_object - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object=$pic_object - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir=$func_dirname_result - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "'$arg' is not a valid libtool object" - fi - fi - done - else - func_fatal_error "link input file '$arg' does not exist" - fi - arg=$save_arg - prev= - continue - ;; - os2dllname) - os2dllname=$arg - prev= - continue - ;; - precious_regex) - precious_files_regex=$arg - prev= - continue - ;; - release) - release=-$arg - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - if test rpath = "$prev"; then - case "$rpath " in - *" $arg "*) ;; - *) func_append rpath " $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) func_append xrpath " $arg" ;; - esac - fi - prev= - continue - ;; - shrext) - shrext_cmds=$arg - prev= - continue - ;; - weak) - func_append weak_libs " $arg" - prev= - continue - ;; - xassembler) - func_append compiler_flags " -Xassembler $qarg" - prev= - func_append compile_command " -Xassembler $qarg" - func_append finalize_command " -Xassembler $qarg" - continue - ;; - xcclinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xcompiler) - func_append compiler_flags " $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xlinker) - func_append linker_flags " $qarg" - func_append compiler_flags " $wl$qarg" - prev= - func_append compile_command " $wl$qarg" - func_append finalize_command " $wl$qarg" - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" - - prevarg=$arg - - case $arg in - -all-static) - if test -n "$link_static_flag"; then - # See comment for -static flag below, for more details. - func_append compile_command " $link_static_flag" - func_append finalize_command " $link_static_flag" - fi - continue - ;; - - -allow-undefined) - # FIXME: remove this flag sometime in the future. - func_fatal_error "'-allow-undefined' must not be used because it is the default" - ;; - - -avoid-version) - avoid_version=yes - continue - ;; - - -bindir) - prev=bindir - continue - ;; - - -dlopen) - prev=dlfiles - continue - ;; - - -dlpreopen) - prev=dlprefiles - continue - ;; - - -export-dynamic) - export_dynamic=yes - continue - ;; - - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - func_fatal_error "more than one -exported-symbols argument is not allowed" - fi - if test X-export-symbols = "X$arg"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; - - -framework) - prev=framework - continue - ;; - - -inst-prefix-dir) - prev=inst_prefix - continue - ;; - - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - func_append compile_command " $arg" - func_append finalize_command " $arg" - ;; - esac - continue - ;; - - -L*) - func_stripname "-L" '' "$arg" - if test -z "$func_stripname_result"; then - if test "$#" -gt 0; then - func_fatal_error "require no space between '-L' and '$1'" - else - func_fatal_error "need path for '-L' option" - fi - fi - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - test -z "$absdir" && \ - func_fatal_error "cannot determine absolute directory name of '$dir'" - dir=$absdir - ;; - esac - case "$deplibs " in - *" -L$dir "* | *" $arg "*) - # Will only happen for absolute or sysroot arguments - ;; - *) - # Preserve sysroot, but never include relative directories - case $dir in - [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; - *) func_append deplibs " -L$dir" ;; - esac - func_append lib_search_path " $dir" - ;; - esac - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$dir:"*) ;; - ::) dllsearchpath=$dir;; - *) func_append dllsearchpath ":$dir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - continue - ;; - - -l*) - if test X-lc = "X$arg" || test X-lm = "X$arg"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test X-lc = "X$arg" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) - # Do not include libc due to us having libc/libc_r. - test X-lc = "X$arg" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - func_append deplibs " System.ltframework" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test X-lc = "X$arg" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test X-lc = "X$arg" && continue - ;; - esac - elif test X-lc_r = "X$arg"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig* | *-*-midnightbsd*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac - fi - func_append deplibs " $arg" - continue - ;; - - -mllvm) - prev=mllvm - continue - ;; - - -module) - module=yes - continue - ;; - - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot|--sysroot) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - prev=xcompiler - continue - ;; - # Solaris ld rejects as of 11.4. Refer to Oracle bug 22985199. - -pthread) - case $host in - *solaris2*) ;; - *) - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) func_append new_inherited_linker_flags " $arg" ;; - esac - ;; - esac - continue - ;; - -mt|-mthreads|-kthread|-Kthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - func_append compiler_flags " $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) func_append new_inherited_linker_flags " $arg" ;; - esac - continue - ;; - - -multi_module) - single_module=$wl-multi_module - continue - ;; - - -no-fast-install) - fast_install=no - continue - ;; - - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) - # The PATH hackery in wrapper scripts is required on Windows - # and Darwin in order for the loader to find any dlls it needs. - func_warning "'-no-install' is ignored for $host" - func_warning "assuming '-no-fast-install' instead" - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; - - -no-undefined) - allow_undefined=no - continue - ;; - - -objectlist) - prev=objectlist - continue - ;; - - -os2dllname) - prev=os2dllname - continue - ;; - - -o) prev=output ;; - - -precious-files-regex) - prev=precious_regex - continue - ;; - - -release) - prev=release - continue - ;; - - -rpath) - prev=rpath - continue - ;; - - -R) - prev=xrpath - continue - ;; - - -R*) - func_stripname '-R' '' "$arg" - dir=$func_stripname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - =*) - func_stripname '=' '' "$dir" - dir=$lt_sysroot$func_stripname_result - ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - continue - ;; - - -shared) - # The effects of -shared are defined in a previous loop. - continue - ;; - - -shrext) - prev=shrext - continue - ;; - - -static | -static-libtool-libs) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; - - -thread-safe) - thread_safe=yes - continue - ;; - - -version-info) - prev=vinfo - continue - ;; - - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; - - -weak) - prev=weak - continue - ;; - - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs=$IFS; IFS=, - for flag in $args; do - IFS=$save_ifs - func_quote_arg pretty "$flag" - func_append arg " $func_quote_arg_result" - func_append compiler_flags " $func_quote_arg_result" - done - IFS=$save_ifs - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Wl,*) - func_stripname '-Wl,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs=$IFS; IFS=, - for flag in $args; do - IFS=$save_ifs - func_quote_arg pretty "$flag" - func_append arg " $wl$func_quote_arg_result" - func_append compiler_flags " $wl$func_quote_arg_result" - func_append linker_flags " $func_quote_arg_result" - done - IFS=$save_ifs - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; - - -Xassembler) - prev=xassembler - continue - ;; - - -Xcompiler) - prev=xcompiler - continue - ;; - - -Xlinker) - prev=xlinker - continue - ;; - - -XCClinker) - prev=xcclinker - continue - ;; - - # -msg_* for osf cc - -msg_*) - func_quote_arg pretty "$arg" - arg=$func_quote_arg_result - ;; - - # Flags to be passed through unchanged, with rationale: - # -64, -mips[0-9] enable 64-bit mode for the SGI compiler - # -r[0-9][0-9]* specify processor for the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler - # +DA*, +DD* enable 64-bit mode for the HP compiler - # -q* compiler args for the IBM compiler - # -m*, -t[45]*, -txscale* architecture-specific flags for GCC - # -F/path path to uninstalled frameworks, gcc on darwin - # -p, -pg, --coverage, -fprofile-* profiling flags for GCC - # -fstack-protector* stack protector flags for GCC - # @file GCC response files - # -tp=* Portland pgcc target processor selection - # --sysroot=* for sysroot support - # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization - # -specs=* GCC specs files - # -stdlib=* select c++ std lib with clang - # -fsanitize=* Clang/GCC memory and address sanitizer - # -fuse-ld=* Linker select flags for GCC - # -Wa,* Pass flags directly to the assembler - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ - -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ - -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*) - func_quote_arg pretty "$arg" - arg=$func_quote_arg_result - func_append compile_command " $arg" - func_append finalize_command " $arg" - func_append compiler_flags " $arg" - continue - ;; - - -Z*) - if test os2 = "`expr $host : '.*\(os2\)'`"; then - # OS/2 uses -Zxxx to specify OS/2-specific options - compiler_flags="$compiler_flags $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case $arg in - -Zlinker | -Zstack) - prev=xcompiler - ;; - esac - continue - else - # Otherwise treat like 'Some other compiler flag' below - func_quote_arg pretty "$arg" - arg=$func_quote_arg_result - fi - ;; - - # Some other compiler flag. - -* | +*) - func_quote_arg pretty "$arg" - arg=$func_quote_arg_result - ;; - - *.$objext) - # A standard object. - func_append objs " $arg" - ;; - - *.lo) - # A libtool-controlled object. - - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= - - # Read the .lo file - func_source "$arg" - - if test -z "$pic_object" || - test -z "$non_pic_object" || - test none = "$pic_object" && - test none = "$non_pic_object"; then - func_fatal_error "cannot find name of object for '$arg'" - fi - - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir=$func_dirname_result - - test none = "$pic_object" || { - # Prepend the subdirectory the object is found in. - pic_object=$xdir$pic_object - - if test dlfiles = "$prev"; then - if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then - func_append dlfiles " $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi - - # CHECK ME: I think I busted this. -Ossama - if test dlprefiles = "$prev"; then - # Preload the old-style object. - func_append dlprefiles " $pic_object" - prev= - fi - - # A PIC object. - func_append libobjs " $pic_object" - arg=$pic_object - } - - # Non-PIC object. - if test none != "$non_pic_object"; then - # Prepend the subdirectory the object is found in. - non_pic_object=$xdir$non_pic_object - - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test none = "$pic_object"; then - arg=$non_pic_object - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object=$pic_object - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir=$func_dirname_result - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "'$arg' is not a valid libtool object" - fi - fi - ;; - - *.$libext) - # An archive. - func_append deplibs " $arg" - func_append old_deplibs " $arg" - continue - ;; - - *.la) - # A libtool-controlled library. - - func_resolve_sysroot "$arg" - if test dlfiles = "$prev"; then - # This library was specified with -dlopen. - func_append dlfiles " $func_resolve_sysroot_result" - prev= - elif test dlprefiles = "$prev"; then - # The library was specified with -dlpreopen. - func_append dlprefiles " $func_resolve_sysroot_result" - prev= - else - func_append deplibs " $func_resolve_sysroot_result" - fi - continue - ;; - - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - func_quote_arg pretty "$arg" - arg=$func_quote_arg_result - ;; - esac # arg - - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - done # argument parsing loop - - test -n "$prev" && \ - func_fatal_help "the '$prevarg' option requires an argument" - - if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi - - oldlibs= - # calculate the name of the file, without its directory - func_basename "$output" - outputname=$func_basename_result - libobjs_save=$libobjs - - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - - # Definition is injected by LT_CONFIG during libtool generation. - func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH" - - func_dirname "$output" "/" "" - output_objdir=$func_dirname_result$objdir - func_to_tool_file "$output_objdir/" - tool_output_objdir=$func_to_tool_file_result - # Create the object directory. - func_mkdir_p "$output_objdir" - - # Determine the type of output - case $output in - "") - func_fatal_help "you must specify an output file" - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac - - specialdeplibs= - - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if $opt_preserve_dup_deps; then - case "$libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append libs " $deplib" - done - - if test lib = "$linkmode"; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" - - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if $opt_duplicate_compiler_generated_deps; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; - esac - func_append pre_post_deps " $pre_post_dep" - done - fi - pre_post_deps= - fi - - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - notinst_path= # paths that contain not-installed libtool libraries - - case $linkmode in - lib) - passes="conv dlpreopen link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - func_fatal_help "libraries can '-dlopen' only libtool libraries: $file" - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=false - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac - - for pass in $passes; do - # The preopen pass in lib mode reverses $deplibs; put it back here - # so that -L comes before libs that need it for instance... - if test lib,link = "$linkmode,$pass"; then - ## FIXME: Find the place where the list is rebuilt in the wrong - ## order, and fix it there properly - tmp_deplibs= - for deplib in $deplibs; do - tmp_deplibs="$deplib $tmp_deplibs" - done - deplibs=$tmp_deplibs - fi - - if test lib,link = "$linkmode,$pass" || - test prog,scan = "$linkmode,$pass"; then - libs=$deplibs - deplibs= - fi - if test prog = "$linkmode"; then - case $pass in - dlopen) libs=$dlfiles ;; - dlpreopen) libs=$dlprefiles ;; - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; - esac - fi - if test lib,dlpreopen = "$linkmode,$pass"; then - # Collect and forward deplibs of preopened libtool libs - for lib in $dlprefiles; do - # Ignore non-libtool-libs - dependency_libs= - func_resolve_sysroot "$lib" - case $lib in - *.la) func_source "$func_resolve_sysroot_result" ;; - esac - - # Collect preopened libtool deplibs, except any this library - # has declared as weak libs - for deplib in $dependency_libs; do - func_basename "$deplib" - deplib_base=$func_basename_result - case " $weak_libs " in - *" $deplib_base "*) ;; - *) func_append deplibs " $deplib" ;; - esac - done - done - libs=$dlprefiles - fi - if test dlopen = "$pass"; then - # Collect dlpreopened libraries - save_deplibs=$deplibs - deplibs= - fi - - for deplib in $libs; do - lib= - found=false - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) - if test prog,link = "$linkmode,$pass"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append compiler_flags " $deplib" - if test lib = "$linkmode"; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -l*) - if test lib != "$linkmode" && test prog != "$linkmode"; then - func_warning "'-l' is ignored for archives/objects" - continue - fi - func_stripname '-l' '' "$deplib" - name=$func_stripname_result - if test lib = "$linkmode"; then - searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" - else - searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" - fi - for searchdir in $searchdirs; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib=$searchdir/lib$name$search_ext - if test -f "$lib"; then - if test .la = "$search_ext"; then - found=: - else - found=false - fi - break 2 - fi - done - done - if $found; then - # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test yes = "$allow_libtool_libs_with_static_runtimes"; then - case " $predeps $postdeps " in - *" $deplib "*) - if func_lalib_p "$lib"; then - library_names= - old_library= - func_source "$lib" - for l in $old_library $library_names; do - ll=$l - done - if test "X$ll" = "X$old_library"; then # only static version available - found=false - func_dirname "$lib" "" "." - ladir=$func_dirname_result - lib=$ladir/$old_library - if test prog,link = "$linkmode,$pass"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - else - # deplib doesn't seem to be a libtool library - if test prog,link = "$linkmode,$pass"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - ;; # -l - *.ltframework) - if test prog,link = "$linkmode,$pass"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - if test lib = "$linkmode"; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) func_append new_inherited_linker_flags " $deplib" ;; - esac - fi - fi - continue - ;; - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test conv = "$pass" && continue - newdependency_libs="$deplib $newdependency_libs" - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - prog) - if test conv = "$pass"; then - deplibs="$deplib $deplibs" - continue - fi - if test scan = "$pass"; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - *) - func_warning "'-L' is ignored for archives/objects" - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test link = "$pass"; then - func_stripname '-R' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - dir=$func_resolve_sysroot_result - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) func_append xrpath " $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) - func_resolve_sysroot "$deplib" - lib=$func_resolve_sysroot_result - ;; - *.$libext) - if test conv = "$pass"; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - # Linking convenience modules into shared libraries is allowed, - # but linking other static libraries is non-portable. - case " $dlpreconveniencelibs " in - *" $deplib "*) ;; - *) - valid_a_lib=false - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=: - fi - ;; - pass_all) - valid_a_lib=: - ;; - esac - if $valid_a_lib; then - echo - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - else - echo - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because the file extensions .$libext of this argument makes me believe" - echo "*** that it is just a static archive that I should not use here." - fi - ;; - esac - continue - ;; - prog) - if test link != "$pass"; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test conv = "$pass"; then - deplibs="$deplib $deplibs" - elif test prog = "$linkmode"; then - if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - func_append newdlprefiles " $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - func_append newdlfiles " $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=: - continue - ;; - esac # case $deplib - - $found || test -f "$lib" \ - || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'" - - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$lib" \ - || func_fatal_error "'$lib' is not a valid libtool archive" - - func_dirname "$lib" "" "." - ladir=$func_dirname_result - - dlname= - dlopen= - dlpreopen= - libdir= - library_names= - old_library= - inherited_linker_flags= - # If the library was installed with an old release of libtool, - # it will not redefine variables installed, or shouldnotlink - installed=yes - shouldnotlink=no - avoidtemprpath= - - - # Read the .la file - func_source "$lib" - - # Convert "-framework foo" to "foo.ltframework" - if test -n "$inherited_linker_flags"; then - tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` - for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do - case " $new_inherited_linker_flags " in - *" $tmp_inherited_linker_flag "*) ;; - *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; - esac - done - fi - dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - if test lib,link = "$linkmode,$pass" || - test prog,scan = "$linkmode,$pass" || - { test prog != "$linkmode" && test lib != "$linkmode"; }; then - test -n "$dlopen" && func_append dlfiles " $dlopen" - test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" - fi - - if test conv = "$pass"; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - func_fatal_error "cannot find name of link library for '$lib'" - fi - # It is a libtool convenience library, so add in its objects. - func_append convenience " $ladir/$objdir/$old_library" - func_append old_convenience " $ladir/$objdir/$old_library" - elif test prog != "$linkmode" && test lib != "$linkmode"; then - func_fatal_error "'$lib' is not a convenience library" - fi - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done - continue - fi # $pass = conv - - - # Get the name of the library we link against. - linklib= - if test -n "$old_library" && - { test yes = "$prefer_static_libs" || - test built,no = "$prefer_static_libs,$installed"; }; then - linklib=$old_library - else - for l in $old_library $library_names; do - linklib=$l - done - fi - if test -z "$linklib"; then - func_fatal_error "cannot find name of link library for '$lib'" - fi - - # This library was specified with -dlopen. - if test dlopen = "$pass"; then - test -z "$libdir" \ - && func_fatal_error "cannot -dlopen a convenience library: '$lib'" - if test -z "$dlname" || - test yes != "$dlopen_support" || - test no = "$build_libtool_libs" - then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - func_append dlprefiles " $lib $dependency_libs" - else - func_append newdlfiles " $lib" - fi - continue - fi # $pass = dlopen - - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - func_warning "cannot determine absolute directory name of '$ladir'" - func_warning "passing it literally to the linker, although it might fail" - abs_ladir=$ladir - fi - ;; - esac - func_basename "$lib" - laname=$func_basename_result - - # Find the relevant object directory and library name. - if test yes = "$installed"; then - if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - func_warning "library '$lib' was moved." - dir=$ladir - absdir=$abs_ladir - libdir=$abs_ladir - else - dir=$lt_sysroot$libdir - absdir=$lt_sysroot$libdir - fi - test yes = "$hardcode_automatic" && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir=$ladir - absdir=$abs_ladir - # Remove this search path later - func_append notinst_path " $abs_ladir" - else - dir=$ladir/$objdir - absdir=$abs_ladir/$objdir - # Remove this search path later - func_append notinst_path " $abs_ladir" - fi - fi # $installed = yes - func_stripname 'lib' '.la' "$laname" - name=$func_stripname_result - - # This library was specified with -dlpreopen. - if test dlpreopen = "$pass"; then - if test -z "$libdir" && test prog = "$linkmode"; then - func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'" - fi - case $host in - # special handling for platforms with PE-DLLs. - *cygwin* | *mingw* | *cegcc* ) - # Linker will automatically link against shared library if both - # static and shared are present. Therefore, ensure we extract - # symbols from the import library if a shared library is present - # (otherwise, the dlopen module name will be incorrect). We do - # this by putting the import library name into $newdlprefiles. - # We recover the dlopen module name by 'saving' the la file - # name in a special purpose variable, and (later) extracting the - # dlname from the la file. - if test -n "$dlname"; then - func_tr_sh "$dir/$linklib" - eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" - func_append newdlprefiles " $dir/$linklib" - else - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - fi - ;; - * ) - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - func_append newdlprefiles " $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - func_append dlpreconveniencelibs " $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - func_append newdlprefiles " $dir/$dlname" - else - func_append newdlprefiles " $dir/$linklib" - fi - ;; - esac - fi # $pass = dlpreopen - - if test -z "$libdir"; then - # Link the convenience library - if test lib = "$linkmode"; then - deplibs="$dir/$old_library $deplibs" - elif test prog,link = "$linkmode,$pass"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi - - - if test prog = "$linkmode" && test link != "$pass"; then - func_append newlib_search_path " $ladir" - deplibs="$lib $deplibs" - - linkalldeplibs=false - if test no != "$link_all_deplibs" || test -z "$library_names" || - test no = "$build_libtool_libs"; then - linkalldeplibs=: - fi - - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result" - func_append newlib_search_path " $func_resolve_sysroot_result" - ;; - esac - # Need to link against all dependency_libs? - if $linkalldeplibs; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if $opt_preserve_dup_deps; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done # for deplib - continue - fi # $linkmode = prog... - - if test prog,link = "$linkmode,$pass"; then - if test -n "$library_names" && - { { test no = "$prefer_static_libs" || - test built,yes = "$prefer_static_libs,$installed"; } || - test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then - # Make sure the rpath contains only unique directories. - case $temp_rpath: in - *"$absdir:"*) ;; - *) func_append temp_rpath "$absdir:" ;; - esac - fi - - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi # $linkmode,$pass = prog,link... - - if $alldeplibs && - { test pass_all = "$deplibs_check_method" || - { test yes = "$build_libtool_libs" && - test -n "$library_names"; }; }; then - # We only need to search for static libraries - continue - fi - fi - - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test built = "$use_static_libs" && test yes = "$installed"; then - use_static_libs=no - fi - if test -n "$library_names" && - { test no = "$use_static_libs" || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc* | *os2*) - # No point in relinking DLLs because paths are not encoded - func_append notinst_deplibs " $lib" - need_relink=no - ;; - *) - if test no = "$installed"; then - func_append notinst_deplibs " $lib" - need_relink=yes - fi - ;; - esac - # This is a shared library - - # Warn about portability, can't link against -module's on some - # systems (darwin). Don't bleat about dlopened modules though! - dlopenmodule= - for dlpremoduletest in $dlprefiles; do - if test "X$dlpremoduletest" = "X$lib"; then - dlopenmodule=$dlpremoduletest - break - fi - done - if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then - echo - if test prog = "$linkmode"; then - $ECHO "*** Warning: Linking the executable $output against the loadable module" - else - $ECHO "*** Warning: Linking the shared library $output against the loadable module" - fi - $ECHO "*** $linklib is not portable!" - fi - if test lib = "$linkmode" && - test yes = "$hardcode_into_libs"; then - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - ;; - esac - fi - - if test -n "$old_archive_from_expsyms_cmds"; then - # figure out the soname - set dummy $library_names - shift - realname=$1 - shift - libname=`eval "\\$ECHO \"$libname_spec\""` - # use dlname if we got it. it's perfectly good, no? - if test -n "$dlname"; then - soname=$dlname - elif test -n "$soname_spec"; then - # bleh windows - case $host in - *cygwin* | mingw* | *cegcc* | *os2*) - func_arith $current - $age - major=$func_arith_result - versuffix=-$major - ;; - esac - eval soname=\"$soname_spec\" - else - soname=$realname - fi - - # Make a new name for the extract_expsyms_cmds to use - soroot=$soname - func_basename "$soroot" - soname=$func_basename_result - func_stripname 'lib' '.dll' "$soname" - newlib=libimp-$func_stripname_result.a - - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - func_verbose "extracting exported symbol list from '$soname'" - func_execute_cmds "$extract_expsyms_cmds" 'exit $?' - fi - - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - func_verbose "generating import library for '$soname'" - func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" - - if test prog = "$linkmode" || test relink != "$opt_mode"; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test no = "$hardcode_direct"; then - add=$dir/$linklib - case $host in - *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; - *-*-sysv4*uw2*) add_dir=-L$dir ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir=-L$dir ;; - *-*-darwin* ) - # if the lib is a (non-dlopened) module then we cannot - # link against it, someone is ignoring the earlier warnings - if /usr/bin/file -L $add 2> /dev/null | - $GREP ": [^:]* bundle" >/dev/null; then - if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" - if test -z "$old_library"; then - echo - echo "*** And there doesn't seem to be a static archive available" - echo "*** The link will probably fail, sorry" - else - add=$dir/$old_library - fi - elif test -n "$old_library"; then - add=$dir/$old_library - fi - fi - esac - elif test no = "$hardcode_minus_L"; then - case $host in - *-*-sunos*) add_shlibpath=$dir ;; - esac - add_dir=-L$dir - add=-l$name - elif test no = "$hardcode_shlibpath_var"; then - add_shlibpath=$dir - add=-l$name - else - lib_linked=no - fi - ;; - relink) - if test yes = "$hardcode_direct" && - test no = "$hardcode_direct_absolute"; then - add=$dir/$linklib - elif test yes = "$hardcode_minus_L"; then - add_dir=-L$absdir - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add=-l$name - elif test yes = "$hardcode_shlibpath_var"; then - add_shlibpath=$dir - add=-l$name - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac - - if test yes != "$lib_linked"; then - func_fatal_configuration "unsupported hardcode properties" - fi - - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) func_append compile_shlibpath "$add_shlibpath:" ;; - esac - fi - if test prog = "$linkmode"; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test yes != "$hardcode_direct" && - test yes != "$hardcode_minus_L" && - test yes = "$hardcode_shlibpath_var"; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - fi - fi - fi - - if test prog = "$linkmode" || test relink = "$opt_mode"; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test yes = "$hardcode_direct" && - test no = "$hardcode_direct_absolute"; then - add=$libdir/$linklib - elif test yes = "$hardcode_minus_L"; then - add_dir=-L$libdir - add=-l$name - elif test yes = "$hardcode_shlibpath_var"; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) func_append finalize_shlibpath "$libdir:" ;; - esac - add=-l$name - elif test yes = "$hardcode_automatic"; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib"; then - add=$inst_prefix_dir$libdir/$linklib - else - add=$libdir/$linklib - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir=-L$libdir - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - func_append add_dir " -L$inst_prefix_dir$libdir" - ;; - esac - fi - add=-l$name - fi - - if test prog = "$linkmode"; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test prog = "$linkmode"; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test unsupported != "$hardcode_direct"; then - test -n "$old_library" && linklib=$old_library - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test yes = "$build_libtool_libs"; then - # Not a shared library - if test pass_all != "$deplibs_check_method"; then - # We're trying link a shared library against a static one - # but the system doesn't support it. - - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - echo - $ECHO "*** Warning: This system cannot link to static lib archive $lib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have." - if test yes = "$module"; then - echo "*** But as you try to build a module library, libtool will still create " - echo "*** a static module, that should work as long as the dlopening application" - echo "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using 'nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** 'nm' from GNU binutils and a full rebuild may help." - fi - if test no = "$build_old_libs"; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? - - if test lib = "$linkmode"; then - if test -n "$dependency_libs" && - { test yes != "$hardcode_into_libs" || - test yes = "$build_old_libs" || - test yes = "$link_static"; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) func_stripname '-R' '' "$libdir" - temp_xrpath=$func_stripname_result - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) func_append xrpath " $temp_xrpath";; - esac;; - *) func_append temp_deplibs " $libdir";; - esac - done - dependency_libs=$temp_deplibs - fi - - func_append newlib_search_path " $absdir" - # Link against this library - test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - func_resolve_sysroot "$func_stripname_result";; - *) func_resolve_sysroot "$deplib" ;; - esac - if $opt_preserve_dup_deps; then - case "$tmp_libs " in - *" $func_resolve_sysroot_result "*) - func_append specialdeplibs " $func_resolve_sysroot_result" ;; - esac - fi - func_append tmp_libs " $func_resolve_sysroot_result" - done - - if test no != "$link_all_deplibs"; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - path= - case $deplib in - -L*) path=$deplib ;; - *.la) - func_resolve_sysroot "$deplib" - deplib=$func_resolve_sysroot_result - func_dirname "$deplib" "" "." - dir=$func_dirname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - func_warning "cannot determine absolute directory name of '$dir'" - absdir=$dir - fi - ;; - esac - if $GREP "^installed=no" $deplib > /dev/null; then - case $host in - *-*-darwin*) - depdepl= - eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names"; then - for tmp in $deplibrary_names; do - depdepl=$tmp - done - if test -f "$absdir/$objdir/$depdepl"; then - depdepl=$absdir/$objdir/$depdepl - darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - if test -z "$darwin_install_name"; then - darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - fi - func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl" - func_append linker_flags " -dylib_file $darwin_install_name:$depdepl" - path= - fi - fi - ;; - *) - path=-L$absdir/$objdir - ;; - esac - else - eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "'$deplib' is not a valid libtool archive" - test "$absdir" != "$libdir" && \ - func_warning "'$deplib' seems to be moved" - - path=-L$absdir - fi - ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - if test link = "$pass"; then - if test prog = "$linkmode"; then - compile_deplibs="$new_inherited_linker_flags $compile_deplibs" - finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" - else - compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - fi - fi - dependency_libs=$newdependency_libs - if test dlpreopen = "$pass"; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test dlopen != "$pass"; then - test conv = "$pass" || { - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) func_append lib_search_path " $dir" ;; - esac - done - newlib_search_path= - } - - if test prog,link = "$linkmode,$pass"; then - vars="compile_deplibs finalize_deplibs" - else - vars=deplibs - fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) func_append tmp_libs " $deplib" ;; - esac - ;; - *) func_append tmp_libs " $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - - # Add Sun CC postdeps if required: - test CXX = "$tagname" && { - case $host_os in - linux*) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) # Sun C++ 5.9 - func_suncc_cstd_abi - - if test no != "$suncc_use_cstd_abi"; then - func_append postdeps ' -library=Cstd -library=Crun' - fi - ;; - esac - ;; - - solaris*) - func_cc_basename "$CC" - case $func_cc_basename_result in - CC* | sunCC*) - func_suncc_cstd_abi - - if test no != "$suncc_use_cstd_abi"; then - func_append postdeps ' -library=Cstd -library=Crun' - fi - ;; - esac - ;; - esac - } - - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i= - ;; - esac - if test -n "$i"; then - func_append tmp_libs " $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test prog = "$linkmode"; then - dlfiles=$newdlfiles - fi - if test prog = "$linkmode" || test lib = "$linkmode"; then - dlprefiles=$newdlprefiles - fi - - case $linkmode in - oldlib) - if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then - func_warning "'-dlopen' is ignored for archives" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "'-l' and '-L' are ignored for archives" ;; - esac - - test -n "$rpath" && \ - func_warning "'-rpath' is ignored for archives" - - test -n "$xrpath" && \ - func_warning "'-R' is ignored for archives" - - test -n "$vinfo" && \ - func_warning "'-version-info/-version-number' is ignored for archives" - - test -n "$release" && \ - func_warning "'-release' is ignored for archives" - - test -n "$export_symbols$export_symbols_regex" && \ - func_warning "'-export-symbols' is ignored for archives" - - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs=$output - func_append objs "$old_deplibs" - ;; - - lib) - # Make sure we only generate libraries of the form 'libNAME.la'. - case $outputname in - lib*) - func_stripname 'lib' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - test no = "$module" \ - && func_fatal_help "libtool library '$output' must begin with 'lib'" - - if test no != "$need_lib_prefix"; then - # Add the "lib" prefix for modules if required - func_stripname '' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - func_stripname '' '.la' "$outputname" - libname=$func_stripname_result - fi - ;; - esac - - if test -n "$objs"; then - if test pass_all != "$deplibs_check_method"; then - func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" - else - echo - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" - func_append libobjs " $objs" - fi - fi - - test no = "$dlself" \ - || func_warning "'-dlopen self' is ignored for libtool libraries" - - set dummy $rpath - shift - test 1 -lt "$#" \ - && func_warning "ignoring multiple '-rpath's for a libtool library" - - install_libdir=$1 - - oldlibs= - if test -z "$rpath"; then - if test yes = "$build_libtool_libs"; then - # Building a libtool convenience library. - # Some compilers have problems with a '.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi - - test -n "$vinfo" && \ - func_warning "'-version-info/-version-number' is ignored for convenience libraries" - - test -n "$release" && \ - func_warning "'-release' is ignored for convenience libraries" - else - - # Parse the version information argument. - save_ifs=$IFS; IFS=: - set dummy $vinfo 0 0 0 - shift - IFS=$save_ifs - - test -n "$7" && \ - func_fatal_help "too many parameters to '-version-info'" - - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible - - case $vinfo_number in - yes) - number_major=$1 - number_minor=$2 - number_revision=$3 - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # that has an extra 1 added just for fun - # - case $version_type in - # correct linux to gnu/linux during the next big refactor - darwin|freebsd-elf|linux|midnightbsd-elf|osf|windows|none) - func_arith $number_major + $number_minor - current=$func_arith_result - age=$number_minor - revision=$number_revision - ;; - freebsd-aout|qnx|sunos) - current=$number_major - revision=$number_minor - age=0 - ;; - irix|nonstopux) - func_arith $number_major + $number_minor - current=$func_arith_result - age=$number_minor - revision=$number_minor - lt_irix_increment=no - ;; - esac - ;; - no) - current=$1 - revision=$2 - age=$3 - ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "CURRENT '$current' must be a nonnegative integer" - func_fatal_error "'$vinfo' is not valid version information" - ;; - esac - - case $revision in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "REVISION '$revision' must be a nonnegative integer" - func_fatal_error "'$vinfo' is not valid version information" - ;; - esac - - case $age in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "AGE '$age' must be a nonnegative integer" - func_fatal_error "'$vinfo' is not valid version information" - ;; - esac - - if test "$age" -gt "$current"; then - func_error "AGE '$age' is greater than the current interface number '$current'" - func_fatal_error "'$vinfo' is not valid version information" - fi - - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; - - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - func_arith $current - $age - major=.$func_arith_result - versuffix=$major.$age.$revision - # Darwin ld doesn't like 0 for these options... - func_arith $current + 1 - minor_current=$func_arith_result - xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - # On Darwin other compilers - case $CC in - nagfor*) - verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" - ;; - *) - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - ;; - esac - ;; - - freebsd-aout) - major=.$current - versuffix=.$current.$revision - ;; - - freebsd-elf | midnightbsd-elf) - func_arith $current - $age - major=.$func_arith_result - versuffix=$major.$age.$revision - ;; - - irix | nonstopux) - if test no = "$lt_irix_increment"; then - func_arith $current - $age - else - func_arith $current - $age + 1 - fi - major=$func_arith_result - - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring=$verstring_prefix$major.$revision - - # Add in all the interfaces that we are compatible with. - loop=$revision - while test 0 -ne "$loop"; do - func_arith $revision - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring=$verstring_prefix$major.$iface:$verstring - done - - # Before this point, $major must not contain '.'. - major=.$major - versuffix=$major.$revision - ;; - - linux) # correct to gnu/linux during the next big refactor - func_arith $current - $age - major=.$func_arith_result - versuffix=$major.$age.$revision - ;; - - osf) - func_arith $current - $age - major=.$func_arith_result - versuffix=.$current.$age.$revision - verstring=$current.$age.$revision - - # Add in all the interfaces that we are compatible with. - loop=$age - while test 0 -ne "$loop"; do - func_arith $current - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring=$verstring:$iface.0 - done - - # Make executables depend on our current version. - func_append verstring ":$current.0" - ;; - - qnx) - major=.$current - versuffix=.$current - ;; - - sco) - major=.$current - versuffix=.$current - ;; - - sunos) - major=.$current - versuffix=.$current.$revision - ;; - - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 file systems. - func_arith $current - $age - major=$func_arith_result - versuffix=-$major - ;; - - *) - func_fatal_configuration "unknown library version type '$version_type'" - ;; - esac - - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring=0.0 - ;; - esac - if test no = "$need_version"; then - versuffix= - else - versuffix=.0.0 - fi - fi - - # Remove version info from name if versioning should be avoided - if test yes,no = "$avoid_version,$need_version"; then - major= - versuffix= - verstring= - fi - - # Check to see if the archive will have undefined symbols. - if test yes = "$allow_undefined"; then - if test unsupported = "$allow_undefined_flag"; then - if test yes = "$build_old_libs"; then - func_warning "undefined symbols not allowed in $host shared libraries; building static only" - build_libtool_libs=no - else - func_fatal_error "can't build $host shared library unless -no-undefined is specified" - fi - fi - else - # Don't allow undefined symbols. - allow_undefined_flag=$no_undefined_flag - fi - - fi - - func_generate_dlsyms "$libname" "$libname" : - func_append libobjs " $symfileobj" - test " " = "$libobjs" && libobjs= - - if test relink != "$opt_mode"; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$ECHO "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext | *.gcno) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*) - if test -n "$precious_files_regex"; then - if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - func_append removelist " $p" - ;; - *) ;; - esac - done - test -n "$removelist" && \ - func_show_eval "${RM}r \$removelist" - fi - - # Now set the variables for building old libraries. - if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then - func_append oldlibs " $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP` - fi - - # Eliminate all temporary directories. - #for path in $notinst_path; do - # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` - # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` - # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` - #done - - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - func_replace_sysroot "$libdir" - func_append temp_xrpath " -R$func_replace_sysroot_result" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then - dependency_libs="$temp_xrpath $dependency_libs" - fi - fi - - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles=$dlfiles - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) func_append dlfiles " $lib" ;; - esac - done - - # Make sure dlprefiles contains only unique files - old_dlprefiles=$dlprefiles - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) func_append dlprefiles " $lib" ;; - esac - done - - if test yes = "$build_libtool_libs"; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - func_append deplibs " System.ltframework" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) - # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test yes = "$build_libtool_need_lc"; then - func_append deplibs " -lc" - fi - ;; - esac - fi - - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release= - versuffix= - major= - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c </dev/null` - $nocaseglob - else - potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` - fi - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null | - $GREP " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib=$potent_lib - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | $SED 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;; - *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | - $SED -e 10q | - $EGREP "$file_magic_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib= - break 2 - fi - done - done - fi - if test -n "$a_deplib"; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib"; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - for a_deplib in $deplibs; do - case $a_deplib in - -l*) - func_stripname -l '' "$a_deplib" - name=$func_stripname_result - if test yes = "$allow_libtool_libs_with_static_runtimes"; then - case " $predeps $postdeps " in - *" $a_deplib "*) - func_append newdeplibs " $a_deplib" - a_deplib= - ;; - esac - fi - if test -n "$a_deplib"; then - libname=`eval "\\$ECHO \"$libname_spec\""` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib=$potent_lib # see symlink-check above in file_magic test - if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ - $EGREP "$match_pattern_regex" > /dev/null; then - func_append newdeplibs " $a_deplib" - a_deplib= - break 2 - fi - done - done - fi - if test -n "$a_deplib"; then - droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" - if test -z "$potlib"; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - func_append newdeplibs " $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs= - tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` - if test yes = "$allow_libtool_libs_with_static_runtimes"; then - for i in $predeps $postdeps; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"` - done - fi - case $tmp_deplibs in - *[!\ \ ]*) - echo - if test none = "$deplibs_check_method"; then - echo "*** Warning: inter-library dependencies are not supported in this platform." - else - echo "*** Warning: inter-library dependencies are not known to be supported." - fi - echo "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes - ;; - esac - ;; - esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library with the System framework - newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - if test yes = "$droppeddeps"; then - if test yes = "$module"; then - echo - echo "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - echo "*** a static module, that should work as long as the dlopening" - echo "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using 'nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** 'nm' from GNU binutils and a full rebuild may help." - fi - if test no = "$build_old_libs"; then - oldlibs=$output_objdir/$libname.$libext - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - echo "*** The inter-library dependencies that have been dropped here will be" - echo "*** automatically added whenever a program is linked with this library" - echo "*** or is declared to -dlopen it." - - if test no = "$allow_undefined"; then - echo - echo "*** Since this library must not contain undefined symbols," - echo "*** because either the platform does not support them or" - echo "*** it was explicitly requested with -no-undefined," - echo "*** libtool will only create a static version of it." - if test no = "$build_old_libs"; then - oldlibs=$output_objdir/$libname.$libext - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - case $host in - *-*-darwin*) - newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - deplibs=$new_libs - - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= - - # Test again, we may have decided not to build it any more - if test yes = "$build_libtool_libs"; then - # Remove $wl instances when linking with ld. - # FIXME: should test the right _cmds variable. - case $archive_cmds in - *\$LD\ *) wl= ;; - esac - if test yes = "$hardcode_into_libs"; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath=$finalize_rpath - test relink = "$opt_mode" || rpath=$compile_rpath$rpath - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - func_replace_sysroot "$libdir" - libdir=$func_replace_sysroot_result - if test -z "$hardcode_libdirs"; then - hardcode_libdirs=$libdir - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append dep_rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir=$hardcode_libdirs - eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi - - shlibpath=$finalize_shlibpath - test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi - - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - shift - realname=$1 - shift - - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname=$realname - fi - if test -z "$dlname"; then - dlname=$soname - fi - - lib=$output_objdir/$realname - linknames= - for link - do - func_append linknames " $link" - done - - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` - test "X$libobjs" = "X " && libobjs= - - delfiles= - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" - export_symbols=$output_objdir/$libname.uexp - func_append delfiles " $export_symbols" - fi - - orig_export_symbols= - case $host_os in - cygwin* | mingw* | cegcc*) - if test -n "$export_symbols" && test -z "$export_symbols_regex"; then - # exporting using user supplied symfile - func_dll_def_p "$export_symbols" || { - # and it's NOT already a .def file. Must figure out - # which of the given symbols are data symbols and tag - # them as such. So, trigger use of export_symbols_cmds. - # export_symbols gets reassigned inside the "prepare - # the list of exported symbols" if statement, so the - # include_expsyms logic still works. - orig_export_symbols=$export_symbols - export_symbols= - always_export_symbols=yes - } - fi - ;; - esac - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then - func_verbose "generating symbol list for '$libname.la'" - export_symbols=$output_objdir/$libname.exp - $opt_dry_run || $RM $export_symbols - cmds=$export_symbols_cmds - save_ifs=$IFS; IFS='~' - for cmd1 in $cmds; do - IFS=$save_ifs - # Take the normal branch if the nm_file_list_spec branch - # doesn't work or if tool conversion is not needed. - case $nm_file_list_spec~$to_tool_file_cmd in - *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) - try_normal_branch=yes - eval cmd=\"$cmd1\" - func_len " $cmd" - len=$func_len_result - ;; - *) - try_normal_branch=no - ;; - esac - if test yes = "$try_normal_branch" \ - && { test "$len" -lt "$max_cmd_len" \ - || test "$max_cmd_len" -le -1; } - then - func_show_eval "$cmd" 'exit $?' - skipped_export=false - elif test -n "$nm_file_list_spec"; then - func_basename "$output" - output_la=$func_basename_result - save_libobjs=$libobjs - save_output=$output - output=$output_objdir/$output_la.nm - func_to_tool_file "$output" - libobjs=$nm_file_list_spec$func_to_tool_file_result - func_append delfiles " $output" - func_verbose "creating $NM input file list: $output" - for obj in $save_libobjs; do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > "$output" - eval cmd=\"$cmd1\" - func_show_eval "$cmd" 'exit $?' - output=$save_output - libobjs=$save_libobjs - skipped_export=false - else - # The command line is too long to execute in one step. - func_verbose "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS=$save_ifs - if test -n "$export_symbols_regex" && test : != "$skipped_export"; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - fi - - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols=$export_symbols - test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test : != "$skipped_export" && test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for '$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands, which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - func_append tmp_deplibs " $test_deplib" - ;; - esac - done - deplibs=$tmp_deplibs - - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec" && - test yes = "$compiler_needs_object" && - test -z "$libobjs"; then - # extract the archives, so we have objects to list. - # TODO: could optimize this to just extract one archive. - whole_archive_flag_spec= - fi - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - else - gentop=$output_objdir/${outputname}x - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - fi - - if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - func_append linker_flags " $flag" - fi - - # Make a backup of the uninstalled library when relinking - if test relink = "$opt_mode"; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? - fi - - # Do each of the archive commands. - if test yes = "$module" && test -n "$module_cmds"; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi - - if test : != "$skipped_export" && - func_len " $test_cmds" && - len=$func_len_result && - test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise - # or, if using GNU ld and skipped_export is not :, use a linker - # script. - - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - func_basename "$output" - output_la=$func_basename_result - - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - last_robj= - k=1 - - if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then - output=$output_objdir/$output_la.lnkscript - func_verbose "creating GNU ld script: $output" - echo 'INPUT (' > $output - for obj in $save_libobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - echo ')' >> $output - func_append delfiles " $output" - func_to_tool_file "$output" - output=$func_to_tool_file_result - elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then - output=$output_objdir/$output_la.lnk - func_verbose "creating linker input file list: $output" - : > $output - set x $save_libobjs - shift - firstobj= - if test yes = "$compiler_needs_object"; then - firstobj="$1 " - shift - fi - for obj - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - func_append delfiles " $output" - func_to_tool_file "$output" - output=$firstobj\"$file_list_spec$func_to_tool_file_result\" - else - if test -n "$save_libobjs"; then - func_verbose "creating reloadable object files..." - output=$output_objdir/$output_la-$k.$objext - eval test_cmds=\"$reload_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - if test -z "$objlist" || - test "$len" -lt "$max_cmd_len"; then - func_append objlist " $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test 1 -eq "$k"; then - # The first file doesn't have a previous command to add. - reload_objs=$objlist - eval concat_cmds=\"$reload_cmds\" - else - # All subsequent reloadable object files will link in - # the last one created. - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" - fi - last_robj=$output_objdir/$output_la-$k.$objext - func_arith $k + 1 - k=$func_arith_result - output=$output_objdir/$output_la-$k.$objext - objlist=" $obj" - func_len " $last_robj" - func_arith $len0 + $func_len_result - len=$func_arith_result - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - reload_objs="$objlist $last_robj" - eval concat_cmds=\"\$concat_cmds$reload_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - func_append delfiles " $output" - - else - output= - fi - - ${skipped_export-false} && { - func_verbose "generating symbol list for '$libname.la'" - export_symbols=$output_objdir/$libname.exp - $opt_dry_run || $RM $export_symbols - libobjs=$output - # Append the command to create the export file. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - } - - test -n "$save_libobjs" && - func_verbose "creating a temporary reloadable object file: $output" - - # Loop through the commands generated above and execute them. - save_ifs=$IFS; IFS='~' - for cmd in $concat_cmds; do - IFS=$save_ifs - $opt_quiet || { - func_quote_arg expand,pretty "$cmd" - eval "func_echo $func_quote_arg_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test relink = "$opt_mode"; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS=$save_ifs - - if test -n "$export_symbols_regex" && ${skipped_export-false}; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - - ${skipped_export-false} && { - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols=$export_symbols - test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols - $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' - fi - - if test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for '$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands, which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - func_append delfiles " $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi - } - - libobjs=$output - # Restore the value of output. - output=$save_output - - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. - - # Do each of the archive commands. - if test yes = "$module" && test -n "$module_cmds"; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds - else - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds - else - cmds=$archive_cmds - fi - fi - fi - - if test -n "$delfiles"; then - # Append the command to remove temporary files to $cmds. - eval cmds=\"\$cmds~\$RM $delfiles\" - fi - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop=$output_objdir/${outputname}x - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append libobjs " $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - - save_ifs=$IFS; IFS='~' - for cmd in $cmds; do - IFS=$sp$nl - eval cmd=\"$cmd\" - IFS=$save_ifs - $opt_quiet || { - func_quote_arg expand,pretty "$cmd" - eval "func_echo $func_quote_arg_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test relink = "$opt_mode"; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done - IFS=$save_ifs - - # Restore the uninstalled library and exit - if test relink = "$opt_mode"; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? - - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - func_show_eval '${RM}r "$gentop"' - fi - fi - - exit $EXIT_SUCCESS - fi - - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' - fi - done - - # If -module or -export-dynamic was specified, set the dlname. - if test yes = "$module" || test yes = "$export_dynamic"; then - # On all known operating systems, these are identical. - dlname=$soname - fi - fi - ;; - - obj) - if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then - func_warning "'-dlopen' is ignored for objects" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "'-l' and '-L' are ignored for objects" ;; - esac - - test -n "$rpath" && \ - func_warning "'-rpath' is ignored for objects" - - test -n "$xrpath" && \ - func_warning "'-R' is ignored for objects" - - test -n "$vinfo" && \ - func_warning "'-version-info' is ignored for objects" - - test -n "$release" && \ - func_warning "'-release' is ignored for objects" - - case $output in - *.lo) - test -n "$objs$old_deplibs" && \ - func_fatal_error "cannot build library object '$output' from non-libtool objects" - - libobj=$output - func_lo2o "$libobj" - obj=$func_lo2o_result - ;; - *) - libobj= - obj=$output - ;; - esac - - # Delete the old objects. - $opt_dry_run || $RM $obj $libobj - - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # if reload_cmds runs $LD directly, get rid of -Wl from - # whole_archive_flag_spec and hope we can get by with turning comma - # into space. - case $reload_cmds in - *\$LD[\ \$]*) wl= ;; - esac - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" - test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` - reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags - else - gentop=$output_objdir/${obj}x - func_append generated " $gentop" - - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi - - # If we're not building shared, we need to use non_pic_objs - test yes = "$build_libtool_libs" || libobjs=$non_pic_objects - - # Create the old-style object. - reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs - - output=$obj - func_execute_cmds "$reload_cmds" 'exit $?' - - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - fi - - test yes = "$build_libtool_libs" || { - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - } - - if test -n "$pic_flag" || test default != "$pic_mode"; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output=$libobj - func_execute_cmds "$reload_cmds" 'exit $?' - fi - - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi - - exit $EXIT_SUCCESS - ;; - - prog) - case $host in - *cygwin*) func_stripname '' '.exe' "$output" - output=$func_stripname_result.exe;; - esac - test -n "$vinfo" && \ - func_warning "'-version-info' is ignored for programs" - - test -n "$release" && \ - func_warning "'-release' is ignored for programs" - - $preload \ - && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \ - && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support." - - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` - ;; - esac - - case $host in - *-*-darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - # But is supposedly fixed on 10.4 or later (yay!). - if test CXX = "$tagname"; then - case ${MACOSX_DEPLOYMENT_TARGET-10.0} in - 10.[0123]) - func_append compile_command " $wl-bind_at_load" - func_append finalize_command " $wl-bind_at_load" - ;; - esac - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac - - - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - func_append new_libs " -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) func_append new_libs " $deplib" ;; - esac - ;; - *) func_append new_libs " $deplib" ;; - esac - done - compile_deplibs=$new_libs - - - func_append compile_command " $compile_deplibs" - func_append finalize_command " $finalize_deplibs" - - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in - *" $libdir "*) ;; - *) func_append finalize_rpath " $libdir" ;; - esac - done - fi - - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs=$libdir - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) func_append perm_rpath " $libdir" ;; - esac - fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - ::) dllsearchpath=$libdir;; - *) func_append dllsearchpath ":$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) func_append dllsearchpath ":$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir=$hardcode_libdirs - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath=$rpath - - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs=$libdir - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - func_append rpath " $flag" - fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) func_append finalize_perm_rpath " $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir=$hardcode_libdirs - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath=$rpath - - if test -n "$libobjs" && test yes = "$build_old_libs"; then - # Transform all the library objects into standard objects. - compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` - fi - - func_generate_dlsyms "$outputname" "@PROGRAM@" false - - # template prelinking step - if test -n "$prelink_cmds"; then - func_execute_cmds "$prelink_cmds" 'exit $?' - fi - - wrappers_required=: - case $host in - *cegcc* | *mingw32ce*) - # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. - wrappers_required=false - ;; - *cygwin* | *mingw* ) - test yes = "$build_libtool_libs" || wrappers_required=false - ;; - *) - if test no = "$need_relink" || test yes != "$build_libtool_libs"; then - wrappers_required=false - fi - ;; - esac - $wrappers_required || { - # Replace the output file specification. - compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - link_command=$compile_command$compile_rpath - - # We have no uninstalled library dependencies, so finalize right now. - exit_status=0 - func_show_eval "$link_command" 'exit_status=$?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Delete the generated files. - if test -f "$output_objdir/${outputname}S.$objext"; then - func_show_eval '$RM "$output_objdir/${outputname}S.$objext"' - fi - - exit $exit_status - } - - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi - - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - func_append rpath "$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - func_append rpath "$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " - fi - fi - - if test yes = "$no_install"; then - # We don't need to create a wrapper script. - link_command=$compile_var$compile_command$compile_rpath - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $opt_dry_run || $RM $output - # Link the executable and exit - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - exit $EXIT_SUCCESS - fi - - case $hardcode_action,$fast_install in - relink,*) - # Fast installation is not supported - link_command=$compile_var$compile_command$compile_rpath - relink_command=$finalize_var$finalize_command$finalize_rpath - - func_warning "this platform does not like uninstalled shared libraries" - func_warning "'$output' will be relinked during installation" - ;; - *,yes) - link_command=$finalize_var$compile_command$finalize_rpath - relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` - ;; - *,no) - link_command=$compile_var$compile_command$compile_rpath - relink_command=$finalize_var$finalize_command$finalize_rpath - ;; - *,needless) - link_command=$finalize_var$compile_command$finalize_rpath - relink_command= - ;; - esac - - # Replace the output file specification. - link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - - # Delete the old output files. - $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname - - func_show_eval "$link_command" 'exit $?' - - if test -n "$postlink_cmds"; then - func_to_tool_file "$output_objdir/$outputname" - postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` - func_execute_cmds "$postlink_cmds" 'exit $?' - fi - - # Now create the wrapper script. - func_verbose "creating $output" - - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_arg pretty "$var_value" - relink_command="$var=$func_quote_arg_result; export $var; $relink_command" - fi - done - func_quote eval cd "`pwd`" - func_quote_arg pretty,unquoted "($func_quote_result; $relink_command)" - relink_command=$func_quote_arg_unquoted_result - fi - - # Only actually do things if not in dry run mode. - $opt_dry_run || { - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) func_stripname '' '.exe' "$output" - output=$func_stripname_result ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - func_stripname '' '.exe' "$outputname" - outputname=$func_stripname_result ;; - *) exeext= ;; - esac - case $host in - *cygwin* | *mingw* ) - func_dirname_and_basename "$output" "" "." - output_name=$func_basename_result - output_path=$func_dirname_result - cwrappersource=$output_path/$objdir/lt-$output_name.c - cwrapper=$output_path/$output_name.exe - $RM $cwrappersource $cwrapper - trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - - func_emit_cwrapperexe_src > $cwrappersource - - # The wrapper executable is built using the $host compiler, - # because it contains $host paths and files. If cross- - # compiling, it, like the target executable, must be - # executed on the $host or under an emulation environment. - $opt_dry_run || { - $LTCC $LTCFLAGS -o $cwrapper $cwrappersource - $STRIP $cwrapper - } - - # Now, create the wrapper script for func_source use: - func_ltwrapper_scriptname $cwrapper - $RM $func_ltwrapper_scriptname_result - trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 - $opt_dry_run || { - # note: this script will not be executed, so do not chmod. - if test "x$build" = "x$host"; then - $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result - else - func_emit_wrapper no > $func_ltwrapper_scriptname_result - fi - } - ;; - * ) - $RM $output - trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 - - func_emit_wrapper no > $output - chmod +x $output - ;; - esac - } - exit $EXIT_SUCCESS - ;; - esac - - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do - - case $build_libtool_libs in - convenience) - oldobjs="$libobjs_save $symfileobj" - addlibs=$convenience - build_libtool_libs=no - ;; - module) - oldobjs=$libobjs_save - addlibs=$old_convenience - build_libtool_libs=no - ;; - *) - oldobjs="$old_deplibs $non_pic_objects" - $preload && test -f "$symfileobj" \ - && func_append oldobjs " $symfileobj" - addlibs=$old_convenience - ;; - esac - - if test -n "$addlibs"; then - gentop=$output_objdir/${outputname}x - func_append generated " $gentop" - - func_extract_archives $gentop $addlibs - func_append oldobjs " $func_extract_archives_result" - fi - - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then - cmds=$old_archive_from_new_cmds - else - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop=$output_objdir/${outputname}x - func_append generated " $gentop" - - func_extract_archives $gentop $dlprefiles - func_append oldobjs " $func_extract_archives_result" - fi - - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - func_basename "$obj" - $ECHO "$func_basename_result" - done | sort | sort -uc >/dev/null 2>&1); then - : - else - echo "copying selected object files to avoid basename conflicts..." - gentop=$output_objdir/${outputname}x - func_append generated " $gentop" - func_mkdir_p "$gentop" - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - func_basename "$obj" - objbase=$func_basename_result - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - func_arith $counter + 1 - counter=$func_arith_result - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - func_append oldobjs " $gentop/$newobj" - ;; - *) func_append oldobjs " $obj" ;; - esac - done - fi - func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 - tool_oldlib=$func_to_tool_file_result - eval cmds=\"$old_archive_cmds\" - - func_len " $cmds" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds - elif test -n "$archiver_list_spec"; then - func_verbose "using command file archive linking..." - for obj in $oldobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" - done > $output_objdir/$libname.libcmd - func_to_tool_file "$output_objdir/$libname.libcmd" - oldobjs=" $archiver_list_spec$func_to_tool_file_result" - cmds=$old_archive_cmds - else - # the command line is too long to link in one step, link in parts - func_verbose "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - oldobjs= - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - eval test_cmds=\"$old_archive_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - for obj in $save_oldobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - func_append objlist " $obj" - if test "$len" -lt "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj"; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$old_archive_cmds\" - objlist= - len=$len0 - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test -z "$oldobjs"; then - eval cmds=\"\$concat_cmds\" - else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" - fi - fi - fi - func_execute_cmds "$cmds" 'exit $?' - done - - test -n "$generated" && \ - func_show_eval "${RM}r$generated" - - # Now create the libtool archive. - case $output in - *.la) - old_library= - test yes = "$build_old_libs" && old_library=$libname.$libext - func_verbose "creating $output" - - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_arg pretty,unquoted "$var_value" - relink_command="$var=$func_quote_arg_unquoted_result; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - func_quote eval cd "`pwd`" - relink_command="($func_quote_result; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - func_quote_arg pretty,unquoted "$relink_command" - relink_command=$func_quote_arg_unquoted_result - if test yes = "$hardcode_automatic"; then - relink_command= - fi - - # Only create the output if not a dry run. - $opt_dry_run || { - for installed in no yes; do - if test yes = "$installed"; then - if test -z "$install_libdir"; then - break - fi - output=$output_objdir/${outputname}i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - func_basename "$deplib" - name=$func_basename_result - func_resolve_sysroot "$deplib" - eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` - test -z "$libdir" && \ - func_fatal_error "'$deplib' is not a valid libtool archive" - func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" - ;; - -L*) - func_stripname -L '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -L$func_replace_sysroot_result" - ;; - -R*) - func_stripname -R '' "$deplib" - func_replace_sysroot "$func_stripname_result" - func_append newdependency_libs " -R$func_replace_sysroot_result" - ;; - *) func_append newdependency_libs " $deplib" ;; - esac - done - dependency_libs=$newdependency_libs - newdlfiles= - - for lib in $dlfiles; do - case $lib in - *.la) - func_basename "$lib" - name=$func_basename_result - eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "'$lib' is not a valid libtool archive" - func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" - ;; - *) func_append newdlfiles " $lib" ;; - esac - done - dlfiles=$newdlfiles - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - *.la) - # Only pass preopened files to the pseudo-archive (for - # eventual linking with the app. that links it) if we - # didn't already link the preopened objects directly into - # the library: - func_basename "$lib" - name=$func_basename_result - eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "'$lib' is not a valid libtool archive" - func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" - ;; - esac - done - dlprefiles=$newdlprefiles - else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlfiles " $abs" - done - dlfiles=$newdlfiles - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; - *) abs=`pwd`"/$lib" ;; - esac - func_append newdlprefiles " $abs" - done - dlprefiles=$newdlprefiles - fi - $RM $output - # place dlname in correct position for cygwin - # In fact, it would be nice if we could use this code for all target - # systems that can't hard-code library paths into their executables - # and that have no shared library path variable independent of PATH, - # but it turns out we can't easily determine that from inspecting - # libtool variables, so we have to hard-code the OSs to which it - # applies here; at the moment, that means platforms that use the PE - # object format with DLL files. See the long comment at the top of - # tests/bindir.at for full details. - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) - # If a -bindir argument was supplied, place the dll there. - if test -n "$bindir"; then - func_relative_path "$install_libdir" "$bindir" - tdlname=$func_relative_path_result/$dlname - else - # Otherwise fall back on heuristic. - tdlname=../bin/$dlname - fi - ;; - esac - $ECHO > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM (GNU $PACKAGE) $VERSION -# -# Please DO NOT delete this file! -# It is necessary for linking the library. - -# The name that we can dlopen(3). -dlname='$tdlname' - -# Names of this library. -library_names='$library_names' - -# The name of the static archive. -old_library='$old_library' - -# Linker flags that cannot go in dependency_libs. -inherited_linker_flags='$new_inherited_linker_flags' - -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' - -# Names of additional weak libraries provided by this library -weak_library_names='$weak_libs' - -# Version information for $libname. -current=$current -age=$age -revision=$revision - -# Is this an already installed library? -installed=$installed - -# Should we warn about portability when linking against -modules? -shouldnotlink=$module - -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' - -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test no,yes = "$installed,$need_relink"; then - $ECHO >> $output "\ -relink_command=\"$relink_command\"" - fi - done - } - - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' - ;; - esac - exit $EXIT_SUCCESS -} - -if test link = "$opt_mode" || test relink = "$opt_mode"; then - func_mode_link ${1+"$@"} -fi - - -# func_mode_uninstall arg... -func_mode_uninstall () -{ - $debug_cmd - - RM=$nonopt - files= - rmforce=false - exit_status=0 - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic=$magic - - for arg - do - case $arg in - -f) func_append RM " $arg"; rmforce=: ;; - -*) func_append RM " $arg" ;; - *) func_append files " $arg" ;; - esac - done - - test -z "$RM" && \ - func_fatal_help "you must specify an RM program" - - rmdirs= - - for file in $files; do - func_dirname "$file" "" "." - dir=$func_dirname_result - if test . = "$dir"; then - odir=$objdir - else - odir=$dir/$objdir - fi - func_basename "$file" - name=$func_basename_result - test uninstall = "$opt_mode" && odir=$dir - - # Remember odir for removal later, being careful to avoid duplicates - if test clean = "$opt_mode"; then - case " $rmdirs " in - *" $odir "*) ;; - *) func_append rmdirs " $odir" ;; - esac - fi - - # Don't error if the file doesn't exist and rm -f was used. - if { test -L "$file"; } >/dev/null 2>&1 || - { test -h "$file"; } >/dev/null 2>&1 || - test -f "$file"; then - : - elif test -d "$file"; then - exit_status=1 - continue - elif $rmforce; then - continue - fi - - rmfiles=$file - - case $name in - *.la) - # Possibly a libtool archive, so verify it. - if func_lalib_p "$file"; then - func_source $dir/$name - - # Delete the libtool libraries and symlinks. - for n in $library_names; do - func_append rmfiles " $odir/$n" - done - test -n "$old_library" && func_append rmfiles " $odir/$old_library" - - case $opt_mode in - clean) - case " $library_names " in - *" $dlname "*) ;; - *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; - esac - test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" - ;; - uninstall) - if test -n "$library_names"; then - # Do each command in the postuninstall commands. - func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1' - fi - - if test -n "$old_library"; then - # Do each command in the old_postuninstall commands. - func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1' - fi - # FIXME: should reinstall the best remaining shared library. - ;; - esac - fi - ;; - - *.lo) - # Possibly a libtool object, so verify it. - if func_lalib_p "$file"; then - - # Read the .lo file - func_source $dir/$name - - # Add PIC object to the list of files to remove. - if test -n "$pic_object" && test none != "$pic_object"; then - func_append rmfiles " $dir/$pic_object" - fi - - # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" && test none != "$non_pic_object"; then - func_append rmfiles " $dir/$non_pic_object" - fi - fi - ;; - - *) - if test clean = "$opt_mode"; then - noexename=$name - case $file in - *.exe) - func_stripname '' '.exe' "$file" - file=$func_stripname_result - func_stripname '' '.exe' "$name" - noexename=$func_stripname_result - # $file with .exe has already been added to rmfiles, - # add $file without .exe - func_append rmfiles " $file" - ;; - esac - # Do a test to see if this is a libtool program. - if func_ltwrapper_p "$file"; then - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - relink_command= - func_source $func_ltwrapper_scriptname_result - func_append rmfiles " $func_ltwrapper_scriptname_result" - else - relink_command= - func_source $dir/$noexename - fi - - # note $name still contains .exe if it was in $file originally - # as does the version of $file that was added into $rmfiles - func_append rmfiles " $odir/$name $odir/${name}S.$objext" - if test yes = "$fast_install" && test -n "$relink_command"; then - func_append rmfiles " $odir/lt-$name" - fi - if test "X$noexename" != "X$name"; then - func_append rmfiles " $odir/lt-$noexename.c" - fi - fi - fi - ;; - esac - func_show_eval "$RM $rmfiles" 'exit_status=1' - done - - # Try to remove the $objdir's in the directories where we deleted files - for dir in $rmdirs; do - if test -d "$dir"; then - func_show_eval "rmdir $dir >/dev/null 2>&1" - fi - done - - exit $exit_status -} - -if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then - func_mode_uninstall ${1+"$@"} -fi - -test -z "$opt_mode" && { - help=$generic_help - func_fatal_help "you must specify a MODE" -} - -test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode '$opt_mode'" - -if test -n "$exec_cmd"; then - eval exec "$exec_cmd" - exit $EXIT_FAILURE -fi - -exit $exit_status - - -# The TAGs below are defined such that we never get into a situation -# where we disable both kinds of libraries. Given conflicting -# choices, we go for a static library, that is the most portable, -# since we can't tell whether shared libraries were disabled because -# the user asked for that or because the platform doesn't support -# them. This is particularly important on AIX, because we don't -# support having both static and shared libraries enabled at the same -# time on that platform, so we default to a shared-only configuration. -# If a disable-shared tag is given, we'll fallback to a static-only -# configuration. But we'll never go from static-only to shared-only. - -# ### BEGIN LIBTOOL TAG CONFIG: disable-shared -build_libtool_libs=no -build_old_libs=yes -# ### END LIBTOOL TAG CONFIG: disable-shared - -# ### BEGIN LIBTOOL TAG CONFIG: disable-static -build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` -# ### END LIBTOOL TAG CONFIG: disable-static - -# Local Variables: -# mode:shell-script -# sh-indentation:2 -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/missing b/lib/libcgroup-3.1.0/build-aux/missing deleted file mode 100755 index 1fe1611f185..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/missing +++ /dev/null @@ -1,215 +0,0 @@ -#! /bin/sh -# Common wrapper for a few potentially missing GNU programs. - -scriptversion=2018-03-07.03; # UTC - -# Copyright (C) 1996-2021 Free Software Foundation, Inc. -# Originally written by Fran,cois Pinard , 1996. - -# 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, or (at your option) -# any later version. - -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -if test $# -eq 0; then - echo 1>&2 "Try '$0 --help' for more information" - exit 1 -fi - -case $1 in - - --is-lightweight) - # Used by our autoconf macros to check whether the available missing - # script is modern enough. - exit 0 - ;; - - --run) - # Back-compat with the calling convention used by older automake. - shift - ;; - - -h|--h|--he|--hel|--help) - echo "\ -$0 [OPTION]... PROGRAM [ARGUMENT]... - -Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due -to PROGRAM being missing or too old. - -Options: - -h, --help display this help and exit - -v, --version output version information and exit - -Supported PROGRAM values: - aclocal autoconf autoheader autom4te automake makeinfo - bison yacc flex lex help2man - -Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and -'g' are ignored when checking the name. - -Send bug reports to ." - exit $? - ;; - - -v|--v|--ve|--ver|--vers|--versi|--versio|--version) - echo "missing $scriptversion (GNU Automake)" - exit $? - ;; - - -*) - echo 1>&2 "$0: unknown '$1' option" - echo 1>&2 "Try '$0 --help' for more information" - exit 1 - ;; - -esac - -# Run the given program, remember its exit status. -"$@"; st=$? - -# If it succeeded, we are done. -test $st -eq 0 && exit 0 - -# Also exit now if we it failed (or wasn't found), and '--version' was -# passed; such an option is passed most likely to detect whether the -# program is present and works. -case $2 in --version|--help) exit $st;; esac - -# Exit code 63 means version mismatch. This often happens when the user -# tries to use an ancient version of a tool on a file that requires a -# minimum version. -if test $st -eq 63; then - msg="probably too old" -elif test $st -eq 127; then - # Program was missing. - msg="missing on your system" -else - # Program was found and executed, but failed. Give up. - exit $st -fi - -perl_URL=https://www.perl.org/ -flex_URL=https://github.com/westes/flex -gnu_software_URL=https://www.gnu.org/software - -program_details () -{ - case $1 in - aclocal|automake) - echo "The '$1' program is part of the GNU Automake package:" - echo "<$gnu_software_URL/automake>" - echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/autoconf>" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - autoconf|autom4te|autoheader) - echo "The '$1' program is part of the GNU Autoconf package:" - echo "<$gnu_software_URL/autoconf/>" - echo "It also requires GNU m4 and Perl in order to run:" - echo "<$gnu_software_URL/m4/>" - echo "<$perl_URL>" - ;; - esac -} - -give_advice () -{ - # Normalize program name to check for. - normalized_program=`echo "$1" | sed ' - s/^gnu-//; t - s/^gnu//; t - s/^g//; t'` - - printf '%s\n' "'$1' is $msg." - - configure_deps="'configure.ac' or m4 files included by 'configure.ac'" - case $normalized_program in - autoconf*) - echo "You should only need it if you modified 'configure.ac'," - echo "or m4 files included by it." - program_details 'autoconf' - ;; - autoheader*) - echo "You should only need it if you modified 'acconfig.h' or" - echo "$configure_deps." - program_details 'autoheader' - ;; - automake*) - echo "You should only need it if you modified 'Makefile.am' or" - echo "$configure_deps." - program_details 'automake' - ;; - aclocal*) - echo "You should only need it if you modified 'acinclude.m4' or" - echo "$configure_deps." - program_details 'aclocal' - ;; - autom4te*) - echo "You might have modified some maintainer files that require" - echo "the 'autom4te' program to be rebuilt." - program_details 'autom4te' - ;; - bison*|yacc*) - echo "You should only need it if you modified a '.y' file." - echo "You may want to install the GNU Bison package:" - echo "<$gnu_software_URL/bison/>" - ;; - lex*|flex*) - echo "You should only need it if you modified a '.l' file." - echo "You may want to install the Fast Lexical Analyzer package:" - echo "<$flex_URL>" - ;; - help2man*) - echo "You should only need it if you modified a dependency" \ - "of a man page." - echo "You may want to install the GNU Help2man package:" - echo "<$gnu_software_URL/help2man/>" - ;; - makeinfo*) - echo "You should only need it if you modified a '.texi' file, or" - echo "any other file indirectly affecting the aspect of the manual." - echo "You might want to install the Texinfo package:" - echo "<$gnu_software_URL/texinfo/>" - echo "The spurious makeinfo call might also be the consequence of" - echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" - echo "want to install GNU make:" - echo "<$gnu_software_URL/make/>" - ;; - *) - echo "You might have modified some files without having the proper" - echo "tools for further handling them. Check the 'README' file, it" - echo "often tells you about the needed prerequisites for installing" - echo "this package. You may also peek at any GNU archive site, in" - echo "case some other package contains this missing '$1' program." - ;; - esac -} - -give_advice "$1" | sed -e '1s/^/WARNING: /' \ - -e '2,$s/^/ /' >&2 - -# Propagate the correct exit status (expected to be 127 for a program -# not found, 63 for a program that failed due to version mismatch). -exit $st - -# Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/test-driver b/lib/libcgroup-3.1.0/build-aux/test-driver deleted file mode 100755 index be73b80adf9..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/test-driver +++ /dev/null @@ -1,153 +0,0 @@ -#! /bin/sh -# test-driver - basic testsuite driver script. - -scriptversion=2018-03-07.03; # UTC - -# Copyright (C) 2011-2021 Free Software Foundation, Inc. -# -# 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, or (at your option) -# any later version. -# -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -# Make unconditional expansion of undefined variables an error. This -# helps a lot in preventing typo-related bugs. -set -u - -usage_error () -{ - echo "$0: $*" >&2 - print_usage >&2 - exit 2 -} - -print_usage () -{ - cat <"$log_file" -"$@" >>"$log_file" 2>&1 -estatus=$? - -if test $enable_hard_errors = no && test $estatus -eq 99; then - tweaked_estatus=1 -else - tweaked_estatus=$estatus -fi - -case $tweaked_estatus:$expect_failure in - 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; - 0:*) col=$grn res=PASS recheck=no gcopy=no;; - 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; - 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; - *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; - *:*) col=$red res=FAIL recheck=yes gcopy=yes;; -esac - -# Report the test outcome and exit status in the logs, so that one can -# know whether the test passed or failed simply by looking at the '.log' -# file, without the need of also peaking into the corresponding '.trs' -# file (automake bug#11814). -echo "$res $test_name (exit status: $estatus)" >>"$log_file" - -# Report outcome to console. -echo "${col}${res}${std}: $test_name" - -# Register the test result, and other relevant metadata. -echo ":test-result: $res" > $trs_file -echo ":global-test-result: $res" >> $trs_file -echo ":recheck: $recheck" >> $trs_file -echo ":copy-in-global-log: $gcopy" >> $trs_file - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/build-aux/ylwrap b/lib/libcgroup-3.1.0/build-aux/ylwrap deleted file mode 100755 index e8ec109fa26..00000000000 --- a/lib/libcgroup-3.1.0/build-aux/ylwrap +++ /dev/null @@ -1,247 +0,0 @@ -#! /bin/sh -# ylwrap - wrapper for lex/yacc invocations. - -scriptversion=2018-03-07.03; # UTC - -# Copyright (C) 1996-2021 Free Software Foundation, Inc. -# -# Written by Tom Tromey . -# -# 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, or (at your option) -# any later version. -# -# 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, see . - -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# This file is maintained in Automake, please report -# bugs to or send patches to -# . - -get_dirname () -{ - case $1 in - */*|*\\*) printf '%s\n' "$1" | sed -e 's|\([\\/]\)[^\\/]*$|\1|';; - # Otherwise, we want the empty string (not "."). - esac -} - -# guard FILE -# ---------- -# The CPP macro used to guard inclusion of FILE. -guard () -{ - printf '%s\n' "$1" \ - | sed \ - -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \ - -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g' \ - -e 's/__*/_/g' -} - -# quote_for_sed [STRING] -# ---------------------- -# Return STRING (or stdin) quoted to be used as a sed pattern. -quote_for_sed () -{ - case $# in - 0) cat;; - 1) printf '%s\n' "$1";; - esac \ - | sed -e 's|[][\\.*]|\\&|g' -} - -case "$1" in - '') - echo "$0: No files given. Try '$0 --help' for more information." 1>&2 - exit 1 - ;; - --basedir) - basedir=$2 - shift 2 - ;; - -h|--h*) - cat <<\EOF -Usage: ylwrap [--help|--version] INPUT [OUTPUT DESIRED]... -- PROGRAM [ARGS]... - -Wrapper for lex/yacc invocations, renaming files as desired. - - INPUT is the input file - OUTPUT is one file PROG generates - DESIRED is the file we actually want instead of OUTPUT - PROGRAM is program to run - ARGS are passed to PROG - -Any number of OUTPUT,DESIRED pairs may be used. - -Report bugs to . -EOF - exit $? - ;; - -v|--v*) - echo "ylwrap $scriptversion" - exit $? - ;; -esac - - -# The input. -input=$1 -shift -# We'll later need for a correct munging of "#line" directives. -input_sub_rx=`get_dirname "$input" | quote_for_sed` -case $input in - [\\/]* | ?:[\\/]*) - # Absolute path; do nothing. - ;; - *) - # Relative path. Make it absolute. - input=`pwd`/$input - ;; -esac -input_rx=`get_dirname "$input" | quote_for_sed` - -# Since DOS filename conventions don't allow two dots, -# the DOS version of Bison writes out y_tab.c instead of y.tab.c -# and y_tab.h instead of y.tab.h. Test to see if this is the case. -y_tab_nodot=false -if test -f y_tab.c || test -f y_tab.h; then - y_tab_nodot=true -fi - -# The parser itself, the first file, is the destination of the .y.c -# rule in the Makefile. -parser=$1 - -# A sed program to s/FROM/TO/g for all the FROM/TO so that, for -# instance, we rename #include "y.tab.h" into #include "parse.h" -# during the conversion from y.tab.c to parse.c. -sed_fix_filenames= - -# Also rename header guards, as Bison 2.7 for instance uses its header -# guard in its implementation file. -sed_fix_header_guards= - -while test $# -ne 0; do - if test x"$1" = x"--"; then - shift - break - fi - from=$1 - # Handle y_tab.c and y_tab.h output by DOS - if $y_tab_nodot; then - case $from in - "y.tab.c") from=y_tab.c;; - "y.tab.h") from=y_tab.h;; - esac - fi - shift - to=$1 - shift - sed_fix_filenames="${sed_fix_filenames}s|"`quote_for_sed "$from"`"|$to|g;" - sed_fix_header_guards="${sed_fix_header_guards}s|"`guard "$from"`"|"`guard "$to"`"|g;" -done - -# The program to run. -prog=$1 -shift -# Make any relative path in $prog absolute. -case $prog in - [\\/]* | ?:[\\/]*) ;; - *[\\/]*) prog=`pwd`/$prog ;; -esac - -dirname=ylwrap$$ -do_exit="cd '`pwd`' && rm -rf $dirname > /dev/null 2>&1;"' (exit $ret); exit $ret' -trap "ret=129; $do_exit" 1 -trap "ret=130; $do_exit" 2 -trap "ret=141; $do_exit" 13 -trap "ret=143; $do_exit" 15 -mkdir $dirname || exit 1 - -cd $dirname - -case $# in - 0) "$prog" "$input" ;; - *) "$prog" "$@" "$input" ;; -esac -ret=$? - -if test $ret -eq 0; then - for from in * - do - to=`printf '%s\n' "$from" | sed "$sed_fix_filenames"` - if test -f "$from"; then - # If $2 is an absolute path name, then just use that, - # otherwise prepend '../'. - case $to in - [\\/]* | ?:[\\/]*) target=$to;; - *) target=../$to;; - esac - - # Do not overwrite unchanged header files to avoid useless - # recompilations. Always update the parser itself: it is the - # destination of the .y.c rule in the Makefile. Divert the - # output of all other files to a temporary file so we can - # compare them to existing versions. - if test $from != $parser; then - realtarget=$target - target=tmp-`printf '%s\n' "$target" | sed 's|.*[\\/]||g'` - fi - - # Munge "#line" or "#" directives. Don't let the resulting - # debug information point at an absolute srcdir. Use the real - # output file name, not yy.lex.c for instance. Adjust the - # include guards too. - sed -e "/^#/!b" \ - -e "s|$input_rx|$input_sub_rx|" \ - -e "$sed_fix_filenames" \ - -e "$sed_fix_header_guards" \ - "$from" >"$target" || ret=$? - - # Check whether files must be updated. - if test "$from" != "$parser"; then - if test -f "$realtarget" && cmp -s "$realtarget" "$target"; then - echo "$to is unchanged" - rm -f "$target" - else - echo "updating $to" - mv -f "$target" "$realtarget" - fi - fi - else - # A missing file is only an error for the parser. This is a - # blatant hack to let us support using "yacc -d". If -d is not - # specified, don't fail when the header file is "missing". - if test "$from" = "$parser"; then - ret=1 - fi - fi - done -fi - -# Remove the directory. -cd .. -rm -rf $dirname - -exit $ret - -# Local Variables: -# mode: shell-script -# sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" -# time-stamp-time-zone: "UTC0" -# time-stamp-end: "; # UTC" -# End: diff --git a/lib/libcgroup-3.1.0/config.h.in b/lib/libcgroup-3.1.0/config.h.in deleted file mode 100644 index a26397bdae5..00000000000 --- a/lib/libcgroup-3.1.0/config.h.in +++ /dev/null @@ -1,190 +0,0 @@ -/* config.h.in. Generated from configure.ac by autoheader. */ - -/* Cgrulesengd socket path */ -#undef CGRULE_CGRED_SOCKET_PATH - -/* Python bindings build flag. */ -#undef ENABLE_PYTHON - -/* Define to 1 if your system has a working `chown' function. */ -#undef HAVE_CHOWN - -/* Define to 1 if you have the declaration of `strerror_r', and to 0 if you - don't. */ -#undef HAVE_DECL_STRERROR_R - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -#undef HAVE_DIRENT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_DLFCN_H - -/* Define to 1 if you have the `getmntent' function. */ -#undef HAVE_GETMNTENT - -/* Define to 1 if you have the `hasmntopt' function. */ -#undef HAVE_HASMNTOPT - -/* Define to 1 if you have the header file. */ -#undef HAVE_INTTYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_LIMITS_H - -/* Define to 1 if your system has a GNU libc compatible `malloc' function, and - to 0 otherwise. */ -#undef HAVE_MALLOC - -/* Define to 1 if you have the `memset' function. */ -#undef HAVE_MEMSET - -/* Define to 1 if you have the `mkdir' function. */ -#undef HAVE_MKDIR - -/* Define to 1 if you have the header file. */ -#undef HAVE_MNTENT_H - -/* Define to 1 if you have the header file, and it defines `DIR'. */ -#undef HAVE_NDIR_H - -/* Define to 1 if your system has a GNU libc compatible `realloc' function, - and to 0 otherwise. */ -#undef HAVE_REALLOC - -/* Define to 1 if you have the `rmdir' function. */ -#undef HAVE_RMDIR - -/* Define to 1 if you have the header file. */ -#undef HAVE_SECURITY_PAM_EXT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SECURITY_PAM_MODULES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SECURITY_PAM_MODUTIL_H - -/* Define to 1 if `stat' has the bug that it succeeds when given the - zero-length file name argument. */ -#undef HAVE_STAT_EMPTY_STRING_BUG - -/* Define to 1 if stdbool.h conforms to C99. */ -#undef HAVE_STDBOOL_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDINT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDIO_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STDLIB_H - -/* Define to 1 if you have the `strdup' function. */ -#undef HAVE_STRDUP - -/* Define if you have `strerror_r'. */ -#undef HAVE_STRERROR_R - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRINGS_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_STRING_H - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -#undef HAVE_SYS_DIR_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_MOUNT_H - -/* Define to 1 if you have the header file, and it defines `DIR'. - */ -#undef HAVE_SYS_NDIR_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_STAT_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_SYS_TYPES_H - -/* Define to 1 if you have the header file. */ -#undef HAVE_UNISTD_H - -/* Define to 1 if the system has the type `_Bool'. */ -#undef HAVE__BOOL - -/* Define to 1 if `lstat' dereferences a symlink specified with a trailing - slash. */ -#undef LSTAT_FOLLOWS_SLASHED_SYMLINK - -/* Define to the sub-directory where libtool stores uninstalled libraries. */ -#undef LT_OBJDIR - -/* Define to ignore specific hierarchy. */ -#undef OPAQUE_HIERARCHY - -/* Name of package */ -#undef PACKAGE - -/* Define to the address where bug reports for this package should be sent. */ -#undef PACKAGE_BUGREPORT - -/* Define to the full name of this package. */ -#undef PACKAGE_NAME - -/* Define to the full name and version of this package. */ -#undef PACKAGE_STRING - -/* Define to the one symbol short name of this package. */ -#undef PACKAGE_TARNAME - -/* Define to the home page for this package. */ -#undef PACKAGE_URL - -/* Define to the version of this package. */ -#undef PACKAGE_VERSION - -/* Define to 1 if all of the C90 standard headers exist (not just the ones - required in a freestanding environment). This macro is provided for - backward compatibility; new code need not use it. */ -#undef STDC_HEADERS - -/* Define to 1 if strerror_r returns char *. */ -#undef STRERROR_R_CHAR_P - -/* Version number of package */ -#undef VERSION - -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ -#undef YYTEXT_POINTER - -/* Define to empty if `const' does not conform to ANSI C. */ -#undef const - -/* Define to `int' if doesn't define. */ -#undef gid_t - -/* Define to `__inline__' or `__inline' if that's what the C compiler - calls it, or to nothing if 'inline' is not supported under any name. */ -#ifndef __cplusplus -#undef inline -#endif - -/* Define to the type of a signed integer type of width exactly 64 bits if - such a type exists and the standard includes do not define it. */ -#undef int64_t - -/* Define to rpl_malloc if the replacement function should be used. */ -#undef malloc - -/* Define as a signed integer type capable of holding a process identifier. */ -#undef pid_t - -/* Define to rpl_realloc if the replacement function should be used. */ -#undef realloc - -/* Define to `int' if doesn't define. */ -#undef uid_t diff --git a/lib/libcgroup-3.1.0/configure b/lib/libcgroup-3.1.0/configure deleted file mode 100755 index 3a79da0d0ba..00000000000 --- a/lib/libcgroup-3.1.0/configure +++ /dev/null @@ -1,23756 +0,0 @@ -#! /bin/sh -# Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for libcgroup 3.1.0. -# -# -# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, -# Inc. -# -# -# This configure script is free software; the Free Software Foundation -# gives unlimited permission to copy, distribute and modify it. -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -as_nop=: -if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 -then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else $as_nop - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - - -# Reset variables that may have inherited troublesome values from -# the environment. - -# IFS needs to be set, to space, tab, and newline, in precisely that order. -# (If _AS_PATH_WALK were called with IFS unset, it would have the -# side effect of setting IFS to empty, thus disabling word splitting.) -# Quoting is to prevent editors from complaining about space-tab. -as_nl=' -' -export as_nl -IFS=" "" $as_nl" - -PS1='$ ' -PS2='> ' -PS4='+ ' - -# Ensure predictable behavior from utilities with locale-dependent output. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# We cannot yet rely on "unset" to work, but we need these variables -# to be unset--not just set to an empty or harmless value--now, to -# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct -# also avoids known problems related to "unset" and subshell syntax -# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). -for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH -do eval test \${$as_var+y} \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done - -# Ensure that fds 0, 1, and 2 are open. -if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi -if (exec 3>&2) ; then :; else exec 2>/dev/null; fi - -# The user is always right. -if ${PATH_SEPARATOR+false} :; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - test -r "$as_dir$0" && as_myself=$as_dir$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - - -# Use a proper internal environment variable to ensure we don't fall - # into an infinite loop, continuously re-executing ourselves. - if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then - _as_can_reexec=no; export _as_can_reexec; - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 - fi - # We don't want this to propagate to other subprocesses. - { _as_can_reexec=; unset _as_can_reexec;} -if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="as_nop=: -if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 -then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else \$as_nop - case \`(set -o) 2>/dev/null\` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi -" - as_required="as_fn_return () { (exit \$1); } -as_fn_success () { as_fn_return 0; } -as_fn_failure () { as_fn_return 1; } -as_fn_ret_success () { return 0; } -as_fn_ret_failure () { return 1; } - -exitcode=0 -as_fn_success || { exitcode=1; echo as_fn_success failed.; } -as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } -as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } -as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ) -then : - -else \$as_nop - exitcode=1; echo positional parameters were not saved. -fi -test x\$exitcode = x0 || exit 1 -blah=\$(echo \$(echo blah)) -test x\"\$blah\" = xblah || exit 1 -test -x / || exit 1" - as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO - as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO - eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && - test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 - - test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ - || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 -test \$(( 1 + 1 )) = 2 || exit 1" - if (eval "$as_required") 2>/dev/null -then : - as_have_required=yes -else $as_nop - as_have_required=no -fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null -then : - -else $as_nop - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - as_found=: - case $as_dir in #( - /*) - for as_base in sh bash ksh sh5; do - # Try only shells that exist, to save several forks. - as_shell=$as_dir$as_base - if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null -then : - CONFIG_SHELL=$as_shell as_have_required=yes - if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null -then : - break 2 -fi -fi - done;; - esac - as_found=false -done -IFS=$as_save_IFS -if $as_found -then : - -else $as_nop - if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null -then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi -fi - - - if test "x$CONFIG_SHELL" != x -then : - export CONFIG_SHELL - # We cannot yet assume a decent shell, so we have to provide a -# neutralization value for shells without unset; and this also -# works around shells that cannot unset nonexistent variables. -# Preserve -v and -x to the replacement shell. -BASH_ENV=/dev/null -ENV=/dev/null -(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV -case $- in # (((( - *v*x* | *x*v* ) as_opts=-vx ;; - *v* ) as_opts=-v ;; - *x* ) as_opts=-x ;; - * ) as_opts= ;; -esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} -# Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 -exit 255 -fi - - if test x$as_have_required = xno -then : - printf "%s\n" "$0: This script requires a shell more modern than all" - printf "%s\n" "$0: the shells that I found on your system." - if test ${ZSH_VERSION+y} ; then - printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should" - printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later." - else - printf "%s\n" "$0: Please tell bug-autoconf@gnu.org about your system, -$0: including any error possibly output before this -$0: message. Then install a modern shell, or manually run -$0: the script under such a shell if you do have one." - fi - exit 1 -fi -fi -fi -SHELL=${CONFIG_SHELL-/bin/sh} -export SHELL -# Unset more variables known to interfere with behavior of common tools. -CLICOLOR_FORCE= GREP_OPTIONS= -unset CLICOLOR_FORCE GREP_OPTIONS - -## --------------------- ## -## M4sh Shell Functions. ## -## --------------------- ## -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit -# as_fn_nop -# --------- -# Do nothing but, unlike ":", preserve the value of $?. -as_fn_nop () -{ - return $? -} -as_nop=as_fn_nop - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null -then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else $as_nop - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null -then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else $as_nop - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - -# as_fn_nop -# --------- -# Do nothing but, unlike ":", preserve the value of $?. -as_fn_nop () -{ - return $? -} -as_nop=as_fn_nop - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - printf "%s\n" "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - - as_lineno_1=$LINENO as_lineno_1a=$LINENO - as_lineno_2=$LINENO as_lineno_2a=$LINENO - eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && - test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { - # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } - - # If we had to re-execute with $CONFIG_SHELL, we're ensured to have - # already done that, so ensure we don't try to do so again and fall - # in an infinite loop. This has already happened in practice. - _as_can_reexec=no; export _as_can_reexec - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} - - -# Determine whether it's possible to make 'echo' print without a newline. -# These variables are no longer used directly by Autoconf, but are AC_SUBSTed -# for compatibility with existing Makefiles. -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -# For backward compatibility with old third-party macros, we provide -# the shell variables $as_echo and $as_echo_n. New code should use -# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. -as_echo='printf %s\n' -as_echo_n='printf %s' - - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - -SHELL=${CONFIG_SHELL-/bin/sh} - - -test -n "$DJDIR" || exec 7<&0 &1 - -# Name of the host. -# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, -# so uname gets run too. -ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` - -# -# Initializations. -# -ac_default_prefix=/usr/local -ac_clean_files= -ac_config_libobj_dir=. -LIBOBJS= -cross_compiling=no -subdirs= -MFLAGS= -MAKEFLAGS= - -# Identity of this package. -PACKAGE_NAME='libcgroup' -PACKAGE_TARNAME='libcgroup' -PACKAGE_VERSION='3.1.0' -PACKAGE_STRING='libcgroup 3.1.0' -PACKAGE_BUGREPORT='' -PACKAGE_URL='' - -# Factoring default headers for most tests. -ac_includes_default="\ -#include -#ifdef HAVE_STDIO_H -# include -#endif -#ifdef HAVE_STDLIB_H -# include -#endif -#ifdef HAVE_STRING_H -# include -#endif -#ifdef HAVE_INTTYPES_H -# include -#endif -#ifdef HAVE_STDINT_H -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include -#endif -#ifdef HAVE_UNISTD_H -# include -#endif" - -ac_header_c_list= -ac_unique_file="src" -ac_subst_vars='am__EXEEXT_FALSE -am__EXEEXT_TRUE -LTLIBOBJS -CODE_COVERAGE_RULES -CODE_COVERAGE_LDFLAGS -CODE_COVERAGE_LIBS -CODE_COVERAGE_CXXFLAGS -CODE_COVERAGE_CFLAGS -CODE_COVERAGE_CPPFLAGS -GENHTML -LCOV -GCOV -CODE_COVERAGE_ENABLED -CODE_COVERAGE_ENABLED_FALSE -CODE_COVERAGE_ENABLED_TRUE -LIBOBJS -CPP -LEXLIB -LEX_OUTPUT_ROOT -LEX -REALLY_YACC -YFLAGS -YACC -CXXCPP -am__fastdepCXX_FALSE -am__fastdepCXX_TRUE -CXXDEPMODE -ac_ct_CXX -CXXFLAGS -CXX -WITH_SAMPLES_FALSE -WITH_SAMPLES_TRUE -WITH_TESTS_FALSE -WITH_TESTS_TRUE -pamlibdir -WITH_INITSCRIPT_INSTALL_FALSE -WITH_INITSCRIPT_INSTALL_TRUE -WITH_SYSTEMD_FALSE -WITH_SYSTEMD_TRUE -ENABLE_PYTHON_FALSE -ENABLE_PYTHON_TRUE -pkgpyexecdir -pyexecdir -pkgpythondir -pythondir -PYTHON_EXEC_PREFIX -PYTHON_PREFIX -PYTHON_PLATFORM -PYTHON_VERSION -PYTHON -WITH_DAEMON_FALSE -WITH_DAEMON_TRUE -WITH_PAM_FALSE -WITH_PAM_TRUE -WITH_TOOLS_FALSE -WITH_TOOLS_TRUE -LT_SYS_LIBRARY_PATH -OTOOL64 -OTOOL -LIPO -NMEDIT -DSYMUTIL -MANIFEST_TOOL -RANLIB -DLLTOOL -OBJDUMP -FILECMD -LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP -EGREP -GREP -SED -host_os -host_vendor -host_cpu -host -build_os -build_vendor -build_cpu -build -LIBTOOL -am__fastdepCC_FALSE -am__fastdepCC_TRUE -CCDEPMODE -am__nodep -AMDEPBACKSLASH -AMDEP_FALSE -AMDEP_TRUE -am__include -DEPDIR -OBJEXT -EXEEXT -ac_ct_CC -CPPFLAGS -LDFLAGS -CFLAGS -CC -ac_ct_AR -AR -LIBRARY_VERSION_RELEASE -LIBRARY_VERSION_MINOR -LIBRARY_VERSION_MAJOR -AM_BACKSLASH -AM_DEFAULT_VERBOSITY -AM_DEFAULT_V -AM_V -CSCOPE -ETAGS -CTAGS -am__untar -am__tar -AMTAR -am__leading_dot -SET_MAKE -AWK -mkdir_p -MKDIR_P -INSTALL_STRIP_PROGRAM -STRIP -install_sh -MAKEINFO -AUTOHEADER -AUTOMAKE -AUTOCONF -ACLOCAL -VERSION -PACKAGE -CYGPATH_W -am__isrc -INSTALL_DATA -INSTALL_SCRIPT -INSTALL_PROGRAM -target_alias -host_alias -build_alias -LIBS -ECHO_T -ECHO_N -ECHO_C -DEFS -mandir -localedir -libdir -psdir -pdfdir -dvidir -htmldir -infodir -docdir -oldincludedir -includedir -runstatedir -localstatedir -sharedstatedir -sysconfdir -datadir -datarootdir -libexecdir -sbindir -bindir -program_transform_name -prefix -exec_prefix -PACKAGE_URL -PACKAGE_BUGREPORT -PACKAGE_STRING -PACKAGE_VERSION -PACKAGE_TARNAME -PACKAGE_NAME -PATH_SEPARATOR -SHELL -am__quote' -ac_subst_files='' -ac_user_opts=' -enable_option_checking -enable_silent_rules -enable_dependency_tracking -enable_shared -enable_static -with_pic -enable_fast_install -with_aix_soname -with_gnu_ld -with_sysroot -enable_libtool_lock -enable_tools -enable_pam -enable_daemon -enable_python -with_python_sys_prefix -with_python_prefix -with_python_exec_prefix -enable_systemd -enable_initscript_install -enable_cgred_socket -enable_pam_module_dir -enable_opaque_hierarchy -enable_tests -enable_samples -with_gcov -enable_code_coverage -' - ac_precious_vars='build_alias -host_alias -target_alias -CC -CFLAGS -LDFLAGS -LIBS -CPPFLAGS -LT_SYS_LIBRARY_PATH -PYTHON -CXX -CXXFLAGS -CCC -CXXCPP -YACC -YFLAGS -CPP' - - -# Initialize some variables set by options. -ac_init_help= -ac_init_version=false -ac_unrecognized_opts= -ac_unrecognized_sep= -# The variables have the same names as the options, with -# dashes changed to underlines. -cache_file=/dev/null -exec_prefix=NONE -no_create= -no_recursion= -prefix=NONE -program_prefix=NONE -program_suffix=NONE -program_transform_name=s,x,x, -silent= -site= -srcdir= -verbose= -x_includes=NONE -x_libraries=NONE - -# Installation directory options. -# These are left unexpanded so users can "make install exec_prefix=/foo" -# and all the variables that are supposed to be based on exec_prefix -# by default will actually change. -# Use braces instead of parens because sh, perl, etc. also accept them. -# (The list follows the same order as the GNU Coding Standards.) -bindir='${exec_prefix}/bin' -sbindir='${exec_prefix}/sbin' -libexecdir='${exec_prefix}/libexec' -datarootdir='${prefix}/share' -datadir='${datarootdir}' -sysconfdir='${prefix}/etc' -sharedstatedir='${prefix}/com' -localstatedir='${prefix}/var' -runstatedir='${localstatedir}/run' -includedir='${prefix}/include' -oldincludedir='/usr/include' -docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' -infodir='${datarootdir}/info' -htmldir='${docdir}' -dvidir='${docdir}' -pdfdir='${docdir}' -psdir='${docdir}' -libdir='${exec_prefix}/lib' -localedir='${datarootdir}/locale' -mandir='${datarootdir}/man' - -ac_prev= -ac_dashdash= -for ac_option -do - # If the previous option needs an argument, assign it. - if test -n "$ac_prev"; then - eval $ac_prev=\$ac_option - ac_prev= - continue - fi - - case $ac_option in - *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *=) ac_optarg= ;; - *) ac_optarg=yes ;; - esac - - case $ac_dashdash$ac_option in - --) - ac_dashdash=yes ;; - - -bindir | --bindir | --bindi | --bind | --bin | --bi) - ac_prev=bindir ;; - -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) - bindir=$ac_optarg ;; - - -build | --build | --buil | --bui | --bu) - ac_prev=build_alias ;; - -build=* | --build=* | --buil=* | --bui=* | --bu=*) - build_alias=$ac_optarg ;; - - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - cache_file=$ac_optarg ;; - - --config-cache | -C) - cache_file=config.cache ;; - - -datadir | --datadir | --datadi | --datad) - ac_prev=datadir ;; - -datadir=* | --datadir=* | --datadi=* | --datad=*) - datadir=$ac_optarg ;; - - -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ - | --dataroo | --dataro | --datar) - ac_prev=datarootdir ;; - -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ - | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) - datarootdir=$ac_optarg ;; - - -disable-* | --disable-*) - ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: \`$ac_useropt'" - ac_useropt_orig=$ac_useropt - ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=no ;; - - -docdir | --docdir | --docdi | --doc | --do) - ac_prev=docdir ;; - -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) - docdir=$ac_optarg ;; - - -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) - ac_prev=dvidir ;; - -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) - dvidir=$ac_optarg ;; - - -enable-* | --enable-*) - ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: \`$ac_useropt'" - ac_useropt_orig=$ac_useropt - ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"enable_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval enable_$ac_useropt=\$ac_optarg ;; - - -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ - | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ - | --exec | --exe | --ex) - ac_prev=exec_prefix ;; - -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ - | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ - | --exec=* | --exe=* | --ex=*) - exec_prefix=$ac_optarg ;; - - -gas | --gas | --ga | --g) - # Obsolete; use --with-gas. - with_gas=yes ;; - - -help | --help | --hel | --he | -h) - ac_init_help=long ;; - -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) - ac_init_help=recursive ;; - -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) - ac_init_help=short ;; - - -host | --host | --hos | --ho) - ac_prev=host_alias ;; - -host=* | --host=* | --hos=* | --ho=*) - host_alias=$ac_optarg ;; - - -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) - ac_prev=htmldir ;; - -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ - | --ht=*) - htmldir=$ac_optarg ;; - - -includedir | --includedir | --includedi | --included | --include \ - | --includ | --inclu | --incl | --inc) - ac_prev=includedir ;; - -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ - | --includ=* | --inclu=* | --incl=* | --inc=*) - includedir=$ac_optarg ;; - - -infodir | --infodir | --infodi | --infod | --info | --inf) - ac_prev=infodir ;; - -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) - infodir=$ac_optarg ;; - - -libdir | --libdir | --libdi | --libd) - ac_prev=libdir ;; - -libdir=* | --libdir=* | --libdi=* | --libd=*) - libdir=$ac_optarg ;; - - -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ - | --libexe | --libex | --libe) - ac_prev=libexecdir ;; - -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ - | --libexe=* | --libex=* | --libe=*) - libexecdir=$ac_optarg ;; - - -localedir | --localedir | --localedi | --localed | --locale) - ac_prev=localedir ;; - -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) - localedir=$ac_optarg ;; - - -localstatedir | --localstatedir | --localstatedi | --localstated \ - | --localstate | --localstat | --localsta | --localst | --locals) - ac_prev=localstatedir ;; - -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ - | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) - localstatedir=$ac_optarg ;; - - -mandir | --mandir | --mandi | --mand | --man | --ma | --m) - ac_prev=mandir ;; - -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) - mandir=$ac_optarg ;; - - -nfp | --nfp | --nf) - # Obsolete; use --without-fp. - with_fp=no ;; - - -no-create | --no-create | --no-creat | --no-crea | --no-cre \ - | --no-cr | --no-c | -n) - no_create=yes ;; - - -no-recursion | --no-recursion | --no-recursio | --no-recursi \ - | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) - no_recursion=yes ;; - - -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ - | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ - | --oldin | --oldi | --old | --ol | --o) - ac_prev=oldincludedir ;; - -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ - | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ - | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) - oldincludedir=$ac_optarg ;; - - -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) - ac_prev=prefix ;; - -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) - prefix=$ac_optarg ;; - - -program-prefix | --program-prefix | --program-prefi | --program-pref \ - | --program-pre | --program-pr | --program-p) - ac_prev=program_prefix ;; - -program-prefix=* | --program-prefix=* | --program-prefi=* \ - | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) - program_prefix=$ac_optarg ;; - - -program-suffix | --program-suffix | --program-suffi | --program-suff \ - | --program-suf | --program-su | --program-s) - ac_prev=program_suffix ;; - -program-suffix=* | --program-suffix=* | --program-suffi=* \ - | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) - program_suffix=$ac_optarg ;; - - -program-transform-name | --program-transform-name \ - | --program-transform-nam | --program-transform-na \ - | --program-transform-n | --program-transform- \ - | --program-transform | --program-transfor \ - | --program-transfo | --program-transf \ - | --program-trans | --program-tran \ - | --progr-tra | --program-tr | --program-t) - ac_prev=program_transform_name ;; - -program-transform-name=* | --program-transform-name=* \ - | --program-transform-nam=* | --program-transform-na=* \ - | --program-transform-n=* | --program-transform-=* \ - | --program-transform=* | --program-transfor=* \ - | --program-transfo=* | --program-transf=* \ - | --program-trans=* | --program-tran=* \ - | --progr-tra=* | --program-tr=* | --program-t=*) - program_transform_name=$ac_optarg ;; - - -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) - ac_prev=pdfdir ;; - -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) - pdfdir=$ac_optarg ;; - - -psdir | --psdir | --psdi | --psd | --ps) - ac_prev=psdir ;; - -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) - psdir=$ac_optarg ;; - - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - silent=yes ;; - - -runstatedir | --runstatedir | --runstatedi | --runstated \ - | --runstate | --runstat | --runsta | --runst | --runs \ - | --run | --ru | --r) - ac_prev=runstatedir ;; - -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ - | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ - | --run=* | --ru=* | --r=*) - runstatedir=$ac_optarg ;; - - -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) - ac_prev=sbindir ;; - -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ - | --sbi=* | --sb=*) - sbindir=$ac_optarg ;; - - -sharedstatedir | --sharedstatedir | --sharedstatedi \ - | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ - | --sharedst | --shareds | --shared | --share | --shar \ - | --sha | --sh) - ac_prev=sharedstatedir ;; - -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ - | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ - | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ - | --sha=* | --sh=*) - sharedstatedir=$ac_optarg ;; - - -site | --site | --sit) - ac_prev=site ;; - -site=* | --site=* | --sit=*) - site=$ac_optarg ;; - - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - srcdir=$ac_optarg ;; - - -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ - | --syscon | --sysco | --sysc | --sys | --sy) - ac_prev=sysconfdir ;; - -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ - | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) - sysconfdir=$ac_optarg ;; - - -target | --target | --targe | --targ | --tar | --ta | --t) - ac_prev=target_alias ;; - -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) - target_alias=$ac_optarg ;; - - -v | -verbose | --verbose | --verbos | --verbo | --verb) - verbose=yes ;; - - -version | --version | --versio | --versi | --vers | -V) - ac_init_version=: ;; - - -with-* | --with-*) - ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: \`$ac_useropt'" - ac_useropt_orig=$ac_useropt - ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=\$ac_optarg ;; - - -without-* | --without-*) - ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` - # Reject names that are not valid shell variable names. - expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: \`$ac_useropt'" - ac_useropt_orig=$ac_useropt - ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` - case $ac_user_opts in - *" -"with_$ac_useropt" -"*) ;; - *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" - ac_unrecognized_sep=', ';; - esac - eval with_$ac_useropt=no ;; - - --x) - # Obsolete; use --with-x. - with_x=yes ;; - - -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ - | --x-incl | --x-inc | --x-in | --x-i) - ac_prev=x_includes ;; - -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ - | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) - x_includes=$ac_optarg ;; - - -x-libraries | --x-libraries | --x-librarie | --x-librari \ - | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) - ac_prev=x_libraries ;; - -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ - | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) - x_libraries=$ac_optarg ;; - - -*) as_fn_error $? "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information" - ;; - - *=*) - ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` - # Reject names that are not valid shell variable names. - case $ac_envvar in #( - '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; - esac - eval $ac_envvar=\$ac_optarg - export $ac_envvar ;; - - *) - # FIXME: should be removed in autoconf 3.0. - printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2 - expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2 - : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" - ;; - - esac -done - -if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` - as_fn_error $? "missing argument to $ac_option" -fi - -if test -n "$ac_unrecognized_opts"; then - case $enable_option_checking in - no) ;; - fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; - *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; - esac -fi - -# Check all directory arguments for consistency. -for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ - datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir runstatedir -do - eval ac_val=\$$ac_var - # Remove trailing slashes. - case $ac_val in - */ ) - ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` - eval $ac_var=\$ac_val;; - esac - # Be sure to have absolute directory names. - case $ac_val in - [\\/$]* | ?:[\\/]* ) continue;; - NONE | '' ) case $ac_var in *prefix ) continue;; esac;; - esac - as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" -done - -# There might be people who depend on the old broken behavior: `$host' -# used to hold the argument of --host etc. -# FIXME: To remove some day. -build=$build_alias -host=$host_alias -target=$target_alias - -# FIXME: To remove some day. -if test "x$host_alias" != x; then - if test "x$build_alias" = x; then - cross_compiling=maybe - elif test "x$build_alias" != "x$host_alias"; then - cross_compiling=yes - fi -fi - -ac_tool_prefix= -test -n "$host_alias" && ac_tool_prefix=$host_alias- - -test "$silent" = yes && exec 6>/dev/null - - -ac_pwd=`pwd` && test -n "$ac_pwd" && -ac_ls_di=`ls -di .` && -ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - as_fn_error $? "working directory cannot be determined" -test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - as_fn_error $? "pwd does not report name of working directory" - - -# Find the source files, if location was not specified. -if test -z "$srcdir"; then - ac_srcdir_defaulted=yes - # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$as_myself" || -$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_myself" : 'X\(//\)[^/]' \| \ - X"$as_myself" : 'X\(//\)$' \| \ - X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$as_myself" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - srcdir=$ac_confdir - if test ! -r "$srcdir/$ac_unique_file"; then - srcdir=.. - fi -else - ac_srcdir_defaulted=no -fi -if test ! -r "$srcdir/$ac_unique_file"; then - test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" -fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" -ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" - pwd)` -# When building in place, set srcdir=. -if test "$ac_abs_confdir" = "$ac_pwd"; then - srcdir=. -fi -# Remove unnecessary trailing slashes from srcdir. -# Double slashes in file names in object file debugging info -# mess up M-x gdb in Emacs. -case $srcdir in -*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; -esac -for ac_var in $ac_precious_vars; do - eval ac_env_${ac_var}_set=\${${ac_var}+set} - eval ac_env_${ac_var}_value=\$${ac_var} - eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} - eval ac_cv_env_${ac_var}_value=\$${ac_var} -done - -# -# Report the --help message. -# -if test "$ac_init_help" = "long"; then - # Omit some internal or obsolete options to make the list less imposing. - # This message is too long to be a string in the A/UX 3.1 sh. - cat <<_ACEOF -\`configure' configures libcgroup 3.1.0 to adapt to many kinds of systems. - -Usage: $0 [OPTION]... [VAR=VALUE]... - -To assign environment variables (e.g., CC, CFLAGS...), specify them as -VAR=VALUE. See below for descriptions of some of the useful variables. - -Defaults for the options are specified in brackets. - -Configuration: - -h, --help display this help and exit - --help=short display options specific to this package - --help=recursive display the short help of all the included packages - -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking ...' messages - --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' - -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] - -Installation directories: - --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] - --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] - -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. - -For better control, use the options below. - -Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/libcgroup] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] -_ACEOF - - cat <<\_ACEOF - -Program names: - --program-prefix=PREFIX prepend PREFIX to installed program names - --program-suffix=SUFFIX append SUFFIX to installed program names - --program-transform-name=PROGRAM run sed PROGRAM on installed program names - -System types: - --build=BUILD configure for building on BUILD [guessed] - --host=HOST cross-compile to build programs to run on HOST [BUILD] -_ACEOF -fi - -if test -n "$ac_init_help"; then - case $ac_init_help in - short | recursive ) echo "Configuration of libcgroup 3.1.0:";; - esac - cat <<\_ACEOF - -Optional Features: - --disable-option-checking ignore unrecognized --enable/--with options - --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) - --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --enable-silent-rules less verbose build output (undo: "make V=1") - --disable-silent-rules verbose build output (undo: "make V=0") - --enable-dependency-tracking - do not reject slow dependency extractors - --disable-dependency-tracking - speeds up one-time build - --enable-shared[=PKGS] build shared libraries [default=yes] - --enable-static[=PKGS] build static libraries [default=yes] - --enable-fast-install[=PKGS] - optimize for fast installation [default=yes] - --disable-libtool-lock avoid locking (might break parallel builds) - --enable-tools compile libcgroup tools [default=yes] - --enable-pam compile libcgroup PAM module [default=yes] - --enable-daemon compile libcgroup daemon [default=yes] - --enable-python build the python bindings, requires cython - --enable-systemd enable systemd support [default=yes] - --enable-initscript-install - install init scripts [default=no] - --enable-cgred-socket=PATH - specify location of cgrulesengd communication socket - (default=/var/run/cgred.socket) - --enable-pam-module-dir=PATH - specify location of libcgroup PAM module - (default=$libdir/security) - --enable-opaque-hierarchy=NAME - specify name of a hierarchy which libcgroup should - ignore, e.g. name=systemd (default=none) - --enable-tests compile libcgroup tests [default=yes] - --enable-samples compile libcgroup samples C programs [default=no] - --enable-code-coverage Whether to enable code coverage support - -Optional Packages: - --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] - --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use - both] - --with-aix-soname=aix|svr4|both - shared library versioning (aka "SONAME") variant to - provide on AIX, [default=aix]. - --with-gnu-ld assume the C compiler uses GNU ld [default=no] - --with-sysroot[=DIR] Search for dependent libraries within DIR (or the - compiler's sysroot if not specified). - --with-python-sys-prefix - use Python's sys.prefix and sys.exec_prefix values - --with-python_prefix override the default PYTHON_PREFIX - --with-python_exec_prefix - override the default PYTHON_EXEC_PREFIX - --with-gcov=GCOV use given GCOV for coverage (GCOV=gcov). - -Some influential environment variables: - CC C compiler command - CFLAGS C compiler flags - LDFLAGS linker flags, e.g. -L if you have libraries in a - nonstandard directory - LIBS libraries to pass to the linker, e.g. -l - CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if - you have headers in a nonstandard directory - LT_SYS_LIBRARY_PATH - User-defined run-time library search path. - PYTHON the Python interpreter - CXX C++ compiler command - CXXFLAGS C++ compiler flags - CXXCPP C++ preprocessor - YACC The `Yet Another Compiler Compiler' implementation to use. - Defaults to the first program found out of: `bison -y', `byacc', - `yacc'. - YFLAGS The list of arguments that will be passed by default to $YACC. - This script will default YFLAGS to the empty string to avoid a - default value of `-d' given by some make applications. - CPP C preprocessor - -Use these variables to override the choices made by `configure' or to help -it to find libraries and programs with nonstandard names/locations. - -Report bugs to the package provider. -_ACEOF -ac_status=$? -fi - -if test "$ac_init_help" = "recursive"; then - # If there are subdirs, report their specific --help. - for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || - { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || - continue - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - cd "$ac_dir" || { ac_status=$?; continue; } - # Check for configure.gnu first; this name is used for a wrapper for - # Metaconfig's "Configure" on case-insensitive file systems. - if test -f "$ac_srcdir/configure.gnu"; then - echo && - $SHELL "$ac_srcdir/configure.gnu" --help=recursive - elif test -f "$ac_srcdir/configure"; then - echo && - $SHELL "$ac_srcdir/configure" --help=recursive - else - printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2 - fi || ac_status=$? - cd "$ac_pwd" || { ac_status=$?; break; } - done -fi - -test -n "$ac_init_help" && exit $ac_status -if $ac_init_version; then - cat <<\_ACEOF -libcgroup configure 3.1.0 -generated by GNU Autoconf 2.71 - -Copyright (C) 2021 Free Software Foundation, Inc. -This configure script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it. -_ACEOF - exit -fi - -## ------------------------ ## -## Autoconf initialization. ## -## ------------------------ ## - -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest.beam - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_compile - -# ac_fn_c_try_link LINENO -# ----------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - } -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link - -# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists and can be compiled using the include files in -# INCLUDES, setting the cache variable VAR accordingly. -ac_fn_c_check_header_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -printf %s "checking for $2... " >&6; } -if eval test \${$3+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - eval "$3=yes" -else $as_nop - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -eval ac_res=\$$3 - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_compile - -# ac_fn_c_check_func LINENO FUNC VAR -# ---------------------------------- -# Tests whether FUNC exists, setting the cache variable VAR accordingly -ac_fn_c_check_func () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -printf %s "checking for $2... " >&6; } -if eval test \${$3+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Define $2 to an innocuous variant, in case declares $2. - For example, HP-UX 11i declares gettimeofday. */ -#define $2 innocuous_$2 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. */ - -#include -#undef $2 - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $2 (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$2 || defined __stub___$2 -choke me -#endif - -int -main (void) -{ -return $2 (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - eval "$3=yes" -else $as_nop - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -fi -eval ac_res=\$$3 - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_func - -# ac_fn_cxx_try_compile LINENO -# ---------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest.beam - if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_cxx_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_compile - -# ac_fn_cxx_try_cpp LINENO -# ------------------------ -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || - test ! -s conftest.err - } -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_cpp - -# ac_fn_cxx_try_link LINENO -# ------------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_link () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { - test -z "$ac_cxx_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - test -x conftest$ac_exeext - } -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_cxx_try_link - -# ac_fn_c_check_type LINENO TYPE VAR INCLUDES -# ------------------------------------------- -# Tests whether TYPE exists after having included INCLUDES, setting cache -# variable VAR accordingly. -ac_fn_c_check_type () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -printf %s "checking for $2... " >&6; } -if eval test \${$3+y} -then : - printf %s "(cached) " >&6 -else $as_nop - eval "$3=no" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main (void) -{ -if (sizeof ($2)) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main (void) -{ -if (sizeof (($2))) - return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - -else $as_nop - eval "$3=yes" -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -eval ac_res=\$$3 - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_type - -# ac_fn_c_try_cpp LINENO -# ---------------------- -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_cpp () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - } -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_cpp - -# ac_fn_c_find_intX_t LINENO BITS VAR -# ----------------------------------- -# Finds a signed integer type with width BITS, setting cache variable VAR -# accordingly. -ac_fn_c_find_intX_t () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 -printf %s "checking for int$2_t... " >&6; } -if eval test \${$3+y} -then : - printf %s "(cached) " >&6 -else $as_nop - eval "$3=no" - # Order is important - never check a type that is potentially smaller - # than half of the expected target width. - for ac_type in int$2_t 'int' 'long int' \ - 'long long int' 'short int' 'signed char'; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default - enum { N = $2 / 2 - 1 }; -int -main (void) -{ -static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default - enum { N = $2 / 2 - 1 }; -int -main (void) -{ -static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) - < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; -test_array [0] = 0; -return test_array [0]; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - -else $as_nop - case $ac_type in #( - int$2_t) : - eval "$3=yes" ;; #( - *) : - eval "$3=\$ac_type" ;; -esac -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - if eval test \"x\$"$3"\" = x"no" -then : - -else $as_nop - break -fi - done -fi -eval ac_res=\$$3 - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_find_intX_t - -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that -# executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; } -then : - ac_retval=0 -else $as_nop - printf "%s\n" "$as_me: program exited with status $ac_status" >&5 - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_run - -# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR -# ------------------------------------------------------------------ -# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR -# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR. -ac_fn_check_decl () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - as_decl_name=`echo $2|sed 's/ *(.*//'` - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 -printf %s "checking whether $as_decl_name is declared... " >&6; } -if eval test \${$3+y} -then : - printf %s "(cached) " >&6 -else $as_nop - as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` - eval ac_save_FLAGS=\$$6 - as_fn_append $6 " $5" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -int -main (void) -{ -#ifndef $as_decl_name -#ifdef __cplusplus - (void) $as_decl_use; -#else - (void) $as_decl_name; -#endif -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - eval "$3=yes" -else $as_nop - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - eval $6=\$ac_save_FLAGS - -fi -eval ac_res=\$$3 - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_check_decl -ac_configure_args_raw= -for ac_arg -do - case $ac_arg in - *\'*) - ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append ac_configure_args_raw " '$ac_arg'" -done - -case $ac_configure_args_raw in - *$as_nl*) - ac_safe_unquote= ;; - *) - ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab. - ac_unsafe_a="$ac_unsafe_z#~" - ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g" - ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;; -esac - -cat >config.log <<_ACEOF -This file contains any messages produced by compilers while -running configure, to aid debugging if configure makes a mistake. - -It was created by libcgroup $as_me 3.1.0, which was -generated by GNU Autoconf 2.71. Invocation command line was - - $ $0$ac_configure_args_raw - -_ACEOF -exec 5>>config.log -{ -cat <<_ASUNAME -## --------- ## -## Platform. ## -## --------- ## - -hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` -uname -m = `(uname -m) 2>/dev/null || echo unknown` -uname -r = `(uname -r) 2>/dev/null || echo unknown` -uname -s = `(uname -s) 2>/dev/null || echo unknown` -uname -v = `(uname -v) 2>/dev/null || echo unknown` - -/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` -/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` - -/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` -/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` -/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` -/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` -/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` -/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` -/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` - -_ASUNAME - -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - printf "%s\n" "PATH: $as_dir" - done -IFS=$as_save_IFS - -} >&5 - -cat >&5 <<_ACEOF - - -## ----------- ## -## Core tests. ## -## ----------- ## - -_ACEOF - - -# Keep a trace of the command line. -# Strip out --no-create and --no-recursion so they do not pile up. -# Strip out --silent because we don't want to record it for future runs. -# Also quote any args containing shell meta-characters. -# Make two passes to allow for proper duplicate-argument suppression. -ac_configure_args= -ac_configure_args0= -ac_configure_args1= -ac_must_keep_next=false -for ac_pass in 1 2 -do - for ac_arg - do - case $ac_arg in - -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil) - continue ;; - *\'*) - ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - case $ac_pass in - 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; - 2) - as_fn_append ac_configure_args1 " '$ac_arg'" - if test $ac_must_keep_next = true; then - ac_must_keep_next=false # Got value, back to normal. - else - case $ac_arg in - *=* | --config-cache | -C | -disable-* | --disable-* \ - | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ - | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ - | -with-* | --with-* | -without-* | --without-* | --x) - case "$ac_configure_args0 " in - "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; - esac - ;; - -* ) ac_must_keep_next=true ;; - esac - fi - as_fn_append ac_configure_args " '$ac_arg'" - ;; - esac - done -done -{ ac_configure_args0=; unset ac_configure_args0;} -{ ac_configure_args1=; unset ac_configure_args1;} - -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# WARNING: Use '\'' to represent an apostrophe within the trap. -# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. -trap 'exit_status=$? - # Sanitize IFS. - IFS=" "" $as_nl" - # Save into config.log some information that might help in debugging. - { - echo - - printf "%s\n" "## ---------------- ## -## Cache variables. ## -## ---------------- ##" - echo - # The following way of writing the cache mishandles newlines in values, -( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - sed -n \ - "s/'\''/'\''\\\\'\'''\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" - ;; #( - *) - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) - echo - - printf "%s\n" "## ----------------- ## -## Output variables. ## -## ----------------- ##" - echo - for ac_var in $ac_subst_vars - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - printf "%s\n" "$ac_var='\''$ac_val'\''" - done | sort - echo - - if test -n "$ac_subst_files"; then - printf "%s\n" "## ------------------- ## -## File substitutions. ## -## ------------------- ##" - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - printf "%s\n" "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - printf "%s\n" "## ----------- ## -## confdefs.h. ## -## ----------- ##" - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - printf "%s\n" "$as_me: caught signal $ac_signal" - printf "%s\n" "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && - rm -f -r conftest* confdefs* conf$$* $ac_clean_files && - exit $exit_status -' 0 -for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal -done -ac_signal=0 - -# confdefs.h avoids OS command line length limits that DEFS can exceed. -rm -f -r conftest* confdefs.h - -printf "%s\n" "/* confdefs.h */" > confdefs.h - -# Predefined preprocessor variables. - -printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h - -printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h - -printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h - -printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h - -printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h - -printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h - - -# Let the site file select an alternate cache file if it wants to. -# Prefer an explicitly selected file to automatically selected ones. -if test -n "$CONFIG_SITE"; then - ac_site_files="$CONFIG_SITE" -elif test "x$prefix" != xNONE; then - ac_site_files="$prefix/share/config.site $prefix/etc/config.site" -else - ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" -fi - -for ac_site_file in $ac_site_files -do - case $ac_site_file in #( - */*) : - ;; #( - *) : - ac_site_file=./$ac_site_file ;; -esac - if test -f "$ac_site_file" && test -r "$ac_site_file"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;} - sed 's/^/| /' "$ac_site_file" >&5 - . "$ac_site_file" \ - || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5; } - fi -done - -if test -r "$cache_file"; then - # Some versions of bash will fail to source /dev/null (special files - # actually), so we avoid doing that. DJGPP emulates it as a regular file. - if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -printf "%s\n" "$as_me: loading cache $cache_file" >&6;} - case $cache_file in - [\\/]* | ?:[\\/]* ) . "$cache_file";; - *) . "./$cache_file";; - esac - fi -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -printf "%s\n" "$as_me: creating cache $cache_file" >&6;} - >$cache_file -fi - -# Test code for whether the C compiler supports C89 (global declarations) -ac_c_conftest_c89_globals=' -/* Does the compiler advertise C89 conformance? - Do not test the value of __STDC__, because some compilers set it to 0 - while being otherwise adequately conformant. */ -#if !defined __STDC__ -# error "Compiler does not advertise C89 conformance" -#endif - -#include -#include -struct stat; -/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */ -struct buf { int x; }; -struct buf * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not \xHH hex character constants. - These do not provoke an error unfortunately, instead are silently treated - as an "x". The following induces an error, until -std is added to get - proper ANSI mode. Curiously \x00 != x always comes out true, for an - array size at least. It is necessary to write \x00 == 0 to get something - that is true only with -std. */ -int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1]; - -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) '\''x'\'' -int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1]; - -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int), - int, int);' - -# Test code for whether the C compiler supports C89 (body of main). -ac_c_conftest_c89_main=' -ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]); -' - -# Test code for whether the C compiler supports C99 (global declarations) -ac_c_conftest_c99_globals=' -// Does the compiler advertise C99 conformance? -#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L -# error "Compiler does not advertise C99 conformance" -#endif - -#include -extern int puts (const char *); -extern int printf (const char *, ...); -extern int dprintf (int, const char *, ...); -extern void *malloc (size_t); - -// Check varargs macros. These examples are taken from C99 6.10.3.5. -// dprintf is used instead of fprintf to avoid needing to declare -// FILE and stderr. -#define debug(...) dprintf (2, __VA_ARGS__) -#define showlist(...) puts (#__VA_ARGS__) -#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) -static void -test_varargs_macros (void) -{ - int x = 1234; - int y = 5678; - debug ("Flag"); - debug ("X = %d\n", x); - showlist (The first, second, and third items.); - report (x>y, "x is %d but y is %d", x, y); -} - -// Check long long types. -#define BIG64 18446744073709551615ull -#define BIG32 4294967295ul -#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) -#if !BIG_OK - #error "your preprocessor is broken" -#endif -#if BIG_OK -#else - #error "your preprocessor is broken" -#endif -static long long int bignum = -9223372036854775807LL; -static unsigned long long int ubignum = BIG64; - -struct incomplete_array -{ - int datasize; - double data[]; -}; - -struct named_init { - int number; - const wchar_t *name; - double average; -}; - -typedef const char *ccp; - -static inline int -test_restrict (ccp restrict text) -{ - // See if C++-style comments work. - // Iterate through items via the restricted pointer. - // Also check for declarations in for loops. - for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i) - continue; - return 0; -} - -// Check varargs and va_copy. -static bool -test_varargs (const char *format, ...) -{ - va_list args; - va_start (args, format); - va_list args_copy; - va_copy (args_copy, args); - - const char *str = ""; - int number = 0; - float fnumber = 0; - - while (*format) - { - switch (*format++) - { - case '\''s'\'': // string - str = va_arg (args_copy, const char *); - break; - case '\''d'\'': // int - number = va_arg (args_copy, int); - break; - case '\''f'\'': // float - fnumber = va_arg (args_copy, double); - break; - default: - break; - } - } - va_end (args_copy); - va_end (args); - - return *str && number && fnumber; -} -' - -# Test code for whether the C compiler supports C99 (body of main). -ac_c_conftest_c99_main=' - // Check bool. - _Bool success = false; - success |= (argc != 0); - - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; - - // Check varargs. - success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234); - test_varargs_macros (); - - // Check flexible array members. - struct incomplete_array *ia = - malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); - ia->datasize = 10; - for (int i = 0; i < ia->datasize; ++i) - ia->data[i] = i * 1.234; - - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; - - ni.number = 58; - - int dynamic_array[ni.number]; - dynamic_array[0] = argv[0][0]; - dynamic_array[ni.number - 1] = 543; - - // work around unused variable warnings - ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\'' - || dynamic_array[ni.number - 1] != 543); -' - -# Test code for whether the C compiler supports C11 (global declarations) -ac_c_conftest_c11_globals=' -// Does the compiler advertise C11 conformance? -#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L -# error "Compiler does not advertise C11 conformance" -#endif - -// Check _Alignas. -char _Alignas (double) aligned_as_double; -char _Alignas (0) no_special_alignment; -extern char aligned_as_int; -char _Alignas (0) _Alignas (int) aligned_as_int; - -// Check _Alignof. -enum -{ - int_alignment = _Alignof (int), - int_array_alignment = _Alignof (int[100]), - char_alignment = _Alignof (char) -}; -_Static_assert (0 < -_Alignof (int), "_Alignof is signed"); - -// Check _Noreturn. -int _Noreturn does_not_return (void) { for (;;) continue; } - -// Check _Static_assert. -struct test_static_assert -{ - int x; - _Static_assert (sizeof (int) <= sizeof (long int), - "_Static_assert does not work in struct"); - long int y; -}; - -// Check UTF-8 literals. -#define u8 syntax error! -char const utf8_literal[] = u8"happens to be ASCII" "another string"; - -// Check duplicate typedefs. -typedef long *long_ptr; -typedef long int *long_ptr; -typedef long_ptr long_ptr; - -// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1. -struct anonymous -{ - union { - struct { int i; int j; }; - struct { int k; long int l; } w; - }; - int m; -} v1; -' - -# Test code for whether the C compiler supports C11 (body of main). -ac_c_conftest_c11_main=' - _Static_assert ((offsetof (struct anonymous, i) - == offsetof (struct anonymous, w.k)), - "Anonymous union alignment botch"); - v1.i = 2; - v1.w.k = 5; - ok |= v1.i != 5; -' - -# Test code for whether the C compiler supports C11 (complete). -ac_c_conftest_c11_program="${ac_c_conftest_c89_globals} -${ac_c_conftest_c99_globals} -${ac_c_conftest_c11_globals} - -int -main (int argc, char **argv) -{ - int ok = 0; - ${ac_c_conftest_c89_main} - ${ac_c_conftest_c99_main} - ${ac_c_conftest_c11_main} - return ok; -} -" - -# Test code for whether the C compiler supports C99 (complete). -ac_c_conftest_c99_program="${ac_c_conftest_c89_globals} -${ac_c_conftest_c99_globals} - -int -main (int argc, char **argv) -{ - int ok = 0; - ${ac_c_conftest_c89_main} - ${ac_c_conftest_c99_main} - return ok; -} -" - -# Test code for whether the C compiler supports C89 (complete). -ac_c_conftest_c89_program="${ac_c_conftest_c89_globals} - -int -main (int argc, char **argv) -{ - int ok = 0; - ${ac_c_conftest_c89_main} - return ok; -} -" - -as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H" -as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H" -as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H" -as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H" -as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H" -as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H" -as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H" -as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H" -as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H" -# Test code for whether the C++ compiler supports C++98 (global declarations) -ac_cxx_conftest_cxx98_globals=' -// Does the compiler advertise C++98 conformance? -#if !defined __cplusplus || __cplusplus < 199711L -# error "Compiler does not advertise C++98 conformance" -#endif - -// These inclusions are to reject old compilers that -// lack the unsuffixed header files. -#include -#include - -// and are *not* freestanding headers in C++98. -extern void assert (int); -namespace std { - extern int strcmp (const char *, const char *); -} - -// Namespaces, exceptions, and templates were all added after "C++ 2.0". -using std::exception; -using std::strcmp; - -namespace { - -void test_exception_syntax() -{ - try { - throw "test"; - } catch (const char *s) { - // Extra parentheses suppress a warning when building autoconf itself, - // due to lint rules shared with more typical C programs. - assert (!(strcmp) (s, "test")); - } -} - -template struct test_template -{ - T const val; - explicit test_template(T t) : val(t) {} - template T add(U u) { return static_cast(u) + val; } -}; - -} // anonymous namespace -' - -# Test code for whether the C++ compiler supports C++98 (body of main) -ac_cxx_conftest_cxx98_main=' - assert (argc); - assert (! argv[0]); -{ - test_exception_syntax (); - test_template tt (2.0); - assert (tt.add (4) == 6.0); - assert (true && !false); -} -' - -# Test code for whether the C++ compiler supports C++11 (global declarations) -ac_cxx_conftest_cxx11_globals=' -// Does the compiler advertise C++ 2011 conformance? -#if !defined __cplusplus || __cplusplus < 201103L -# error "Compiler does not advertise C++11 conformance" -#endif - -namespace cxx11test -{ - constexpr int get_val() { return 20; } - - struct testinit - { - int i; - double d; - }; - - class delegate - { - public: - delegate(int n) : n(n) {} - delegate(): delegate(2354) {} - - virtual int getval() { return this->n; }; - protected: - int n; - }; - - class overridden : public delegate - { - public: - overridden(int n): delegate(n) {} - virtual int getval() override final { return this->n * 2; } - }; - - class nocopy - { - public: - nocopy(int i): i(i) {} - nocopy() = default; - nocopy(const nocopy&) = delete; - nocopy & operator=(const nocopy&) = delete; - private: - int i; - }; - - // for testing lambda expressions - template Ret eval(Fn f, Ret v) - { - return f(v); - } - - // for testing variadic templates and trailing return types - template auto sum(V first) -> V - { - return first; - } - template auto sum(V first, Args... rest) -> V - { - return first + sum(rest...); - } -} -' - -# Test code for whether the C++ compiler supports C++11 (body of main) -ac_cxx_conftest_cxx11_main=' -{ - // Test auto and decltype - auto a1 = 6538; - auto a2 = 48573953.4; - auto a3 = "String literal"; - - int total = 0; - for (auto i = a3; *i; ++i) { total += *i; } - - decltype(a2) a4 = 34895.034; -} -{ - // Test constexpr - short sa[cxx11test::get_val()] = { 0 }; -} -{ - // Test initializer lists - cxx11test::testinit il = { 4323, 435234.23544 }; -} -{ - // Test range-based for - int array[] = {9, 7, 13, 15, 4, 18, 12, 10, 5, 3, - 14, 19, 17, 8, 6, 20, 16, 2, 11, 1}; - for (auto &x : array) { x += 23; } -} -{ - // Test lambda expressions - using cxx11test::eval; - assert (eval ([](int x) { return x*2; }, 21) == 42); - double d = 2.0; - assert (eval ([&](double x) { return d += x; }, 3.0) == 5.0); - assert (d == 5.0); - assert (eval ([=](double x) mutable { return d += x; }, 4.0) == 9.0); - assert (d == 5.0); -} -{ - // Test use of variadic templates - using cxx11test::sum; - auto a = sum(1); - auto b = sum(1, 2); - auto c = sum(1.0, 2.0, 3.0); -} -{ - // Test constructor delegation - cxx11test::delegate d1; - cxx11test::delegate d2(); - cxx11test::delegate d3(45); -} -{ - // Test override and final - cxx11test::overridden o1(55464); -} -{ - // Test nullptr - char *c = nullptr; -} -{ - // Test template brackets - test_template<::test_template> v(test_template(12)); -} -{ - // Unicode literals - char const *utf8 = u8"UTF-8 string \u2500"; - char16_t const *utf16 = u"UTF-8 string \u2500"; - char32_t const *utf32 = U"UTF-32 string \u2500"; -} -' - -# Test code for whether the C compiler supports C++11 (complete). -ac_cxx_conftest_cxx11_program="${ac_cxx_conftest_cxx98_globals} -${ac_cxx_conftest_cxx11_globals} - -int -main (int argc, char **argv) -{ - int ok = 0; - ${ac_cxx_conftest_cxx98_main} - ${ac_cxx_conftest_cxx11_main} - return ok; -} -" - -# Test code for whether the C compiler supports C++98 (complete). -ac_cxx_conftest_cxx98_program="${ac_cxx_conftest_cxx98_globals} -int -main (int argc, char **argv) -{ - int ok = 0; - ${ac_cxx_conftest_cxx98_main} - return ok; -} -" - - -# Auxiliary files required by this configure script. -ac_aux_files="config.guess config.sub ltmain.sh compile ar-lib missing install-sh" - -# Locations in which to look for auxiliary files. -ac_aux_dir_candidates="${srcdir}/build-aux" - -# Search for a directory containing all of the required auxiliary files, -# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates. -# If we don't find one directory that contains all the files we need, -# we report the set of missing files from the *first* directory in -# $ac_aux_dir_candidates and give up. -ac_missing_aux_files="" -ac_first_candidate=: -printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5 -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_found=false -for as_dir in $ac_aux_dir_candidates -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - as_found=: - - printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5 - ac_aux_dir_found=yes - ac_install_sh= - for ac_aux in $ac_aux_files - do - # As a special case, if "install-sh" is required, that requirement - # can be satisfied by any of "install-sh", "install.sh", or "shtool", - # and $ac_install_sh is set appropriately for whichever one is found. - if test x"$ac_aux" = x"install-sh" - then - if test -f "${as_dir}install-sh"; then - printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5 - ac_install_sh="${as_dir}install-sh -c" - elif test -f "${as_dir}install.sh"; then - printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5 - ac_install_sh="${as_dir}install.sh -c" - elif test -f "${as_dir}shtool"; then - printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5 - ac_install_sh="${as_dir}shtool install -c" - else - ac_aux_dir_found=no - if $ac_first_candidate; then - ac_missing_aux_files="${ac_missing_aux_files} install-sh" - else - break - fi - fi - else - if test -f "${as_dir}${ac_aux}"; then - printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5 - else - ac_aux_dir_found=no - if $ac_first_candidate; then - ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}" - else - break - fi - fi - fi - done - if test "$ac_aux_dir_found" = yes; then - ac_aux_dir="$as_dir" - break - fi - ac_first_candidate=false - - as_found=false -done -IFS=$as_save_IFS -if $as_found -then : - -else $as_nop - as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 -fi - - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -if test -f "${ac_aux_dir}config.guess"; then - ac_config_guess="$SHELL ${ac_aux_dir}config.guess" -fi -if test -f "${ac_aux_dir}config.sub"; then - ac_config_sub="$SHELL ${ac_aux_dir}config.sub" -fi -if test -f "$ac_aux_dir/configure"; then - ac_configure="$SHELL ${ac_aux_dir}configure" -fi - -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;} - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac - # Pass precious variables to config.status. - if test "$ac_new_set" = set; then - case $ac_new_val in - *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; - *) ac_arg=$ac_var=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - fi -done -if $ac_cache_corrupted; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file' - and start over" "$LINENO" 5 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - - - - -am__api_version='1.16' - - - - # Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -printf %s "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if test ${ac_cv_path_install+y} -then : - printf %s "(cached) " >&6 -else $as_nop - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - # Account for fact that we put trailing slashes in our PATH walk. -case $as_dir in #(( - ./ | /[cC]/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then - if test $ac_prog = install && - grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done - done - ;; -esac - - done -IFS=$as_save_IFS - -rm -rf conftest.one conftest.two conftest.dir - -fi - if test ${ac_cv_path_install+y}; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -printf "%s\n" "$INSTALL" >&6; } - -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' - -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' - -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -printf %s "checking whether build environment is sane... " >&6; } -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[\\\"\#\$\&\'\`$am_lf]*) - as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; -esac -case $srcdir in - *[\\\"\#\$\&\'\`$am_lf\ \ ]*) - as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; -esac - -# Do 'set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error $? "ls -t appears to fail. Make sure there is not a broken - alias in your environment" "$LINENO" 5 - fi - if test "$2" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error $? "newly created file is older than distributed files! -Check your system clock" "$LINENO" 5 -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } -# If we didn't sleep, we still need to ensure time stamps of config.status and -# generated files are strictly newer. -am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & - am_sleep_pid=$! -fi - -rm -f conftest.file - -test "$program_prefix" != NONE && - program_transform_name="s&^&$program_prefix&;$program_transform_name" -# Use a double $ so make ignores it. -test "$program_suffix" != NONE && - program_transform_name="s&\$&$program_suffix&;$program_transform_name" -# Double any \ or $. -# By default was `s,x,x', remove it if useless. -ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"` - - -# Expand $ac_aux_dir to an absolute path. -am_aux_dir=`cd "$ac_aux_dir" && pwd` - - - if test x"${MISSING+set}" != xset; then - MISSING="\${SHELL} '$am_aux_dir/missing'" -fi -# Use eval to expand $SHELL -if eval "$MISSING --is-lightweight"; then - am_missing_run="$MISSING " -else - am_missing_run= - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 -printf "%s\n" "$as_me: WARNING: 'missing' script is too old or missing" >&2;} -fi - -if test x"${install_sh+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi - -# Installed binaries are usually stripped using 'strip' when the user -# run "make install-strip". However 'strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the 'STRIP' environment variable to overrule this program. -if test "$cross_compiling" != no; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_STRIP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -printf "%s\n" "$STRIP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_STRIP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -printf "%s\n" "$ac_ct_STRIP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5 -printf %s "checking for a race-free mkdir -p... " >&6; } -if test -z "$MKDIR_P"; then - if test ${ac_cv_path_mkdir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in mkdir gmkdir; do - for ac_exec_ext in '' $ac_executable_extensions; do - as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue - case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir ('*'coreutils) '* | \ - 'BusyBox '* | \ - 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext - break 3;; - esac - done - done - done -IFS=$as_save_IFS - -fi - - test -d ./--version && rmdir ./--version - if test ${ac_cv_path_mkdir+y}; then - MKDIR_P="$ac_cv_path_mkdir -p" - else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -printf "%s\n" "$MKDIR_P" >&6; } - -for ac_prog in gawk mawk nawk awk -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_AWK+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$AWK"; then - ac_cv_prog_AWK="$AWK" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_AWK="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AWK=$ac_cv_prog_AWK -if test -n "$AWK"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -printf "%s\n" "$AWK" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$AWK" && break -done - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } -set x ${MAKE-make} -ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if eval test \${ac_cv_prog_make_${ac_make}_set+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat >conftest.make <<\_ACEOF -SHELL = /bin/sh -all: - @echo '@@@%%%=$(MAKE)=@@@%%%' -_ACEOF -# GNU make sometimes prints "make[1]: Entering ...", which would confuse us. -case `${MAKE-make} -f conftest.make 2>/dev/null` in - *@@@%%%=?*=@@@%%%*) - eval ac_cv_prog_make_${ac_make}_set=yes;; - *) - eval ac_cv_prog_make_${ac_make}_set=no;; -esac -rm -f conftest.make -fi -if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } - SET_MAKE= -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } - SET_MAKE="MAKE=${MAKE-make}" -fi - -rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null - -# Check whether --enable-silent-rules was given. -if test ${enable_silent_rules+y} -then : - enableval=$enable_silent_rules; -fi - -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=1;; -esac -am_make=${MAKE-make} -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -printf %s "checking whether $am_make supports nested variables... " >&6; } -if test ${am_cv_make_support_nested_variables+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if printf "%s\n" 'TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -printf "%s\n" "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AM_BACKSLASH='\' - -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - am__isrc=' -I$(srcdir)' - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 - fi -fi - -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' - else - CYGPATH_W=echo - fi -fi - - -# Define the identity of the package. - PACKAGE='libcgroup' - VERSION='3.1.0' - - -printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h - - -printf "%s\n" "#define VERSION \"$VERSION\"" >>confdefs.h - -# Some tools Automake needs. - -ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} - - -AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} - - -AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} - - -AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} - - -MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} - -# For better backward compatibility. To be removed once Automake 1.9.x -# dies out for good. For more background, see: -# -# -mkdir_p='$(MKDIR_P)' - -# We need awk for the "check" target (and possibly the TAP driver). The -# system "awk" is bad on some platforms. -# Always define AMTAR for backward compatibility. Yes, it's still used -# in the wild :-( We should find a proper way to deprecate it ... -AMTAR='$${TAR-tar}' - - -# We'll loop over all known methods to create a tar archive until one works. -_am_tools='gnutar pax cpio none' - -am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' - - - - - -# Variables for tags utilities; see am/tags.am -if test -z "$CTAGS"; then - CTAGS=ctags -fi - -if test -z "$ETAGS"; then - ETAGS=etags -fi - -if test -z "$CSCOPE"; then - CSCOPE=cscope -fi - - - -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! - -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: - -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. - -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. - -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: . - -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. - -END - as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 - fi -fi - - -# Check whether --enable-silent-rules was given. -if test ${enable_silent_rules+y} -then : - enableval=$enable_silent_rules; -fi - -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=0;; -esac -am_make=${MAKE-make} -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -printf %s "checking whether $am_make supports nested variables... " >&6; } -if test ${am_cv_make_support_nested_variables+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if printf "%s\n" 'TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -printf "%s\n" "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AM_BACKSLASH='\' - - -# set library version, soname is libcgroup.so.MAJOR -LIBRARY_VERSION_MAJOR=3 - -LIBRARY_VERSION_MINOR=1 - -LIBRARY_VERSION_RELEASE=0 - - -# we do not want static libraries -#AC_DISABLE_STATIC - - - - - - - - - - -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 -printf %s "checking whether ${MAKE-make} supports the include directive... " >&6; } -cat > confinc.mk << 'END' -am__doit: - @echo this is the am__doit target >confinc.out -.PHONY: am__doit -END -am__include="#" -am__quote= -# BSD make does it like this. -echo '.include "confinc.mk" # ignored' > confmf.BSD -# Other make implementations (GNU, Solaris 10, AIX) do it like this. -echo 'include confinc.mk # ignored' > confmf.GNU -_am_result=no -for s in GNU BSD; do - { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 - (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } - case $?:`cat confinc.out 2>/dev/null` in #( - '0:this is the am__doit target') : - case $s in #( - BSD) : - am__include='.include' am__quote='"' ;; #( - *) : - am__include='include' am__quote='' ;; -esac ;; #( - *) : - ;; -esac - if test "$am__include" != "#"; then - _am_result="yes ($s style)" - break - fi -done -rm -f confinc.* confmf.* -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 -printf "%s\n" "${_am_result}" >&6; } - -# Check whether --enable-dependency-tracking was given. -if test ${enable_dependency_tracking+y} -then : - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' - am__nodep='_no' -fi - if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args. -set dummy ${ac_tool_prefix}clang; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}clang" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "clang", so it can be a program name with args. -set dummy clang; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="clang" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -fi - - -test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion -version; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" -# Try to create an executable without -o first, disregard a.out. -# It will help us diagnose broken compilers, and finding out an intuition -# of exeext. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -printf %s "checking whether the C compiler works... " >&6; } -ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link_default") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' -# in a Makefile. We should not override ac_cv_exeext if it was cached, -# so that the user can short-circuit this test for compilers unknown to -# Autoconf. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no; - then :; else - ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - fi - # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' - # argument, so we may need to know it at that point already. - # Even if this section looks crufty: it has the advantage of - # actually working. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else $as_nop - ac_file='' -fi -if test -z "$ac_file" -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -printf %s "checking for C compiler default output file name... " >&6; } -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -printf "%s\n" "$ac_file" >&6; } -ac_exeext=$ac_cv_exeext - -rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out -ac_clean_files=$ac_clean_files_save -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -printf %s "checking for suffix of executables... " >&6; } -if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) break;; - esac -done -else $as_nop - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest conftest$ac_cv_exeext -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -printf "%s\n" "$ac_cv_exeext" >&6; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main (void) -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_ACEOF -ac_clean_files="$ac_clean_files conftest.out" -# Check that the compiler produces executables we can run. If not, either -# the compiler is broken, or we cross compile. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -printf %s "checking whether we are cross compiling... " >&6; } -if test "$cross_compiling" != yes; then - { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then - cross_compiling=no - else - if test "$cross_compiling" = maybe; then - cross_compiling=yes - else - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error 77 "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5; } - fi - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -printf "%s\n" "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out -ac_clean_files=$ac_clean_files_save -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -printf %s "checking for suffix of object files... " >&6; } -if test ${ac_cv_objext+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compile") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -then : - for ac_file in conftest.o conftest.obj conftest.*; do - test -f "$ac_file" || continue; - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac -done -else $as_nop - printf "%s\n" "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -printf "%s\n" "$ac_cv_objext" >&6; } -OBJEXT=$ac_cv_objext -ac_objext=$OBJEXT -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 -printf %s "checking whether the compiler supports GNU C... " >&6; } -if test ${ac_cv_c_compiler_gnu+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_compiler_gnu=yes -else $as_nop - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+y} -ac_save_CFLAGS=$CFLAGS -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -printf %s "checking whether $CC accepts -g... " >&6; } -if test ${ac_cv_prog_cc_g+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_g=yes -else $as_nop - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - -else $as_nop - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -printf "%s\n" "$ac_cv_prog_cc_g" >&6; } -if test $ac_test_CFLAGS; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -ac_prog_cc_stdc=no -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 -printf %s "checking for $CC option to enable C11 features... " >&6; } -if test ${ac_cv_prog_cc_c11+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c11=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c11_program -_ACEOF -for ac_arg in '' -std=gnu11 -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c11=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c11" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c11" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c11" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 -printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } - CC="$CC $ac_cv_prog_cc_c11" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 - ac_prog_cc_stdc=c11 -fi -fi -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 -printf %s "checking for $CC option to enable C99 features... " >&6; } -if test ${ac_cv_prog_cc_c99+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c99_program -_ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c99=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c99" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c99" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } - CC="$CC $ac_cv_prog_cc_c99" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 - ac_prog_cc_stdc=c99 -fi -fi -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 -printf %s "checking for $CC option to enable C89 features... " >&6; } -if test ${ac_cv_prog_cc_c89+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c89_program -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c89" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c89" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } - CC="$CC $ac_cv_prog_cc_c89" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 - ac_prog_cc_stdc=c89 -fi -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 -printf %s "checking whether $CC understands -c and -o together... " >&6; } -if test ${am_cv_prog_cc_c_o+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF - # Make sure it works both with $CC and with simple cc. - # Following AC_PROG_CC_C_O, we do the test twice because some - # compilers refuse to overwrite an existing .o file with -o, - # though they will create one. - am_cv_prog_cc_c_o=yes - for am_i in 1 2; do - if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 - ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } \ - && test -f conftest2.$ac_objext; then - : OK - else - am_cv_prog_cc_c_o=no - break - fi - done - rm -f core conftest* - unset am_i -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 -printf "%s\n" "$am_cv_prog_cc_c_o" >&6; } -if test "$am_cv_prog_cc_c_o" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -depcc="$CC" am_compiler_list= - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -printf %s "checking dependency style of $depcc... " >&6; } -if test ${am_cv_CC_dependencies_compiler_type+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - - - - if test -n "$ac_tool_prefix"; then - for ac_prog in ar lib "link -lib" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_AR+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -printf "%s\n" "$AR" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$AR" && break - done -fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar lib "link -lib" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_AR+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AR="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -printf "%s\n" "$ac_ct_AR" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_AR" && break -done - - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -fi - -: ${AR=ar} - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the archiver ($AR) interface" >&5 -printf %s "checking the archiver ($AR) interface... " >&6; } -if test ${am_cv_ar_interface+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - am_cv_ar_interface=ar - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int some_variable = 0; -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - am_ar_try='$AR cru libconftest.a conftest.$ac_objext >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 - (eval $am_ar_try) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -eq 0; then - am_cv_ar_interface=ar - else - am_ar_try='$AR -NOLOGO -OUT:conftest.lib conftest.$ac_objext >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$am_ar_try\""; } >&5 - (eval $am_ar_try) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test "$ac_status" -eq 0; then - am_cv_ar_interface=lib - else - am_cv_ar_interface=unknown - fi - fi - rm -f conftest.lib libconftest.a - -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_ar_interface" >&5 -printf "%s\n" "$am_cv_ar_interface" >&6; } - -case $am_cv_ar_interface in -ar) - ;; -lib) - # Microsoft lib, so override with the ar-lib wrapper script. - # FIXME: It is wrong to rewrite AR. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__AR in this case, - # and then we could set am__AR="$am_aux_dir/ar-lib \$(AR)" or something - # similar. - AR="$am_aux_dir/ar-lib $AR" - ;; -unknown) - as_fn_error $? "could not determine $AR interface" "$LINENO" 5 - ;; -esac - -case `pwd` in - *\ * | *\ *) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -printf "%s\n" "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; -esac - - - -macro_version='2.4.7' -macro_revision='2.4.7' - - - - - - - - - - - - - - -ltmain=$ac_aux_dir/ltmain.sh - - - - # Make sure we can run config.sub. -$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 || - as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5 - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -printf %s "checking build system type... " >&6; } -if test ${ac_cv_build+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"` -test "x$ac_build_alias" = x && - as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` || - as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5 - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -printf "%s\n" "$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 -printf %s "checking host system type... " >&6; } -if test ${ac_cv_host+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` || - as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5 -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -printf "%s\n" "$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - -# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\(["`$\\]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 -printf %s "checking how to print strings... " >&6; } -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "" -} - -case $ECHO in - printf*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: printf" >&5 -printf "%s\n" "printf" >&6; } ;; - print*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 -printf "%s\n" "print -r" >&6; } ;; - *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cat" >&5 -printf "%s\n" "cat" >&6; } ;; -esac - - - - - - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -printf %s "checking for a sed that does not truncate output... " >&6; } -if test ${ac_cv_path_SED+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for ac_i in 1 2 3 4 5 6 7; do - ac_script="$ac_script$as_nl$ac_script" - done - echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed - { ac_script=; unset ac_script;} - if test -z "$SED"; then - ac_path_SED_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in sed gsed - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_SED" || continue -# Check for GNU ac_path_SED and select it if it is found. - # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in -*GNU*) - ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; -*) - ac_count=0 - printf %s 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - printf "%s\n" '' >> "conftest.nl" - "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_SED="$ac_path_SED" - ac_path_SED_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_SED_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_SED"; then - as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 - fi -else - ac_cv_path_SED=$SED -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -printf "%s\n" "$ac_cv_path_SED" >&6; } - SED="$ac_cv_path_SED" - rm -f conftest.sed - -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" - - - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -printf %s "checking for grep that handles long lines and -e... " >&6; } -if test ${ac_cv_path_GREP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$GREP"; then - ac_path_GREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in grep ggrep - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_GREP" || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; -*) - ac_count=0 - printf %s 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - printf "%s\n" 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_GREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_GREP=$GREP -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -printf "%s\n" "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -printf %s "checking for egrep... " >&6; } -if test ${ac_cv_path_EGREP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in egrep - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - printf %s 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - printf "%s\n" 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_EGREP=$EGREP -fi - - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -printf "%s\n" "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 -printf %s "checking for fgrep... " >&6; } -if test ${ac_cv_path_FGREP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in fgrep - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_FGREP" || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in -*GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; -*) - ac_count=0 - printf %s 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - printf "%s\n" 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_FGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_FGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_FGREP=$FGREP -fi - - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 -printf "%s\n" "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - - - - - -# Check whether --with-gnu-ld was given. -if test ${with_gnu_ld+y} -then : - withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes -else $as_nop - with_gnu_ld=no -fi - -ac_prog=ld -if test yes = "$GCC"; then - # Check if gcc -print-prog-name=ld gives a path. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -printf %s "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return, which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD=$ac_prog - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test yes = "$with_gnu_ld"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -printf %s "checking for GNU ld... " >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -printf %s "checking for non-GNU ld... " >&6; } -fi -if test ${lt_cv_path_LD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$LD"; then - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD=$ac_dir/$ac_prog - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -printf "%s\n" "$LD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -printf %s "checking if the linker ($LD) is GNU ld... " >&6; } -if test ${lt_cv_prog_gnu_ld+y} -then : - printf %s "(cached) " >&6 -else $as_nop - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 -printf %s "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if test ${lt_cv_path_NM+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM=$NM -else - lt_nm_to_check=${ac_tool_prefix}nm - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - tmp_nm=$ac_dir/$lt_tmp_nm - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the 'sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty - case $build_os in - mingw*) lt_bad_file=conftest.nm/nofile ;; - *) lt_bad_file=/dev/null ;; - esac - case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in - *$lt_bad_file* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break 2 - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break 2 - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS=$lt_save_ifs - done - : ${lt_cv_path_NM=no} -fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -printf "%s\n" "$lt_cv_path_NM" >&6; } -if test no != "$lt_cv_path_NM"; then - NM=$lt_cv_path_NM -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - if test -n "$ac_tool_prefix"; then - for ac_prog in dumpbin "link -dump" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_DUMPBIN+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DUMPBIN=$ac_cv_prog_DUMPBIN -if test -n "$DUMPBIN"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 -printf "%s\n" "$DUMPBIN" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$DUMPBIN" && break - done -fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in dumpbin "link -dump" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_DUMPBIN+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_DUMPBIN"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN -if test -n "$ac_ct_DUMPBIN"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 -printf "%s\n" "$ac_ct_DUMPBIN" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_DUMPBIN" && break -done - - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DUMPBIN=$ac_ct_DUMPBIN - fi -fi - - case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols -headers" - ;; - *) - DUMPBIN=: - ;; - esac - fi - - if test : != "$DUMPBIN"; then - NM=$DUMPBIN - fi -fi -test -z "$NM" && NM=nm - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 -printf %s "checking the name lister ($NM) interface... " >&6; } -if test ${lt_cv_nm_interface+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:$LINENO: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest* -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 -printf "%s\n" "$lt_cv_nm_interface" >&6; } - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -printf %s "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -printf "%s\n" "no, using $LN_S" >&6; } -fi - -# find the maximum length of command line arguments -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -printf %s "checking the maximum length of command line arguments... " >&6; } -if test ${lt_cv_sys_max_cmd_len+y} -then : - printf %s "(cached) " >&6 -else $as_nop - i=0 - teststring=ABCD - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[ ]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test X`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test 17 != "$i" # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac - -fi - -if test -n "$lt_cv_sys_max_cmd_len"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -printf "%s\n" "$lt_cv_sys_max_cmd_len" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5 -printf "%s\n" "none" >&6; } -fi -max_cmd_len=$lt_cv_sys_max_cmd_len - - - - - - -: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi - - - - - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 -printf %s "checking how to convert $build file names to $host format... " >&6; } -if test ${lt_cv_to_host_file_cmd+y} -then : - printf %s "(cached) " >&6 -else $as_nop - case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac - -fi - -to_host_file_cmd=$lt_cv_to_host_file_cmd -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 -printf "%s\n" "$lt_cv_to_host_file_cmd" >&6; } - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 -printf %s "checking how to convert $build file names to toolchain format... " >&6; } -if test ${lt_cv_to_tool_file_cmd+y} -then : - printf %s "(cached) " >&6 -else $as_nop - #assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac - -fi - -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 -printf "%s\n" "$lt_cv_to_tool_file_cmd" >&6; } - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -printf %s "checking for $LD option to reload object files... " >&6; } -if test ${lt_cv_ld_reload_flag+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_ld_reload_flag='-r' -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -printf "%s\n" "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - if test yes != "$GCC"; then - reload_cmds=false - fi - ;; - darwin*) - if test yes = "$GCC"; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}file", so it can be a program name with args. -set dummy ${ac_tool_prefix}file; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_FILECMD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$FILECMD"; then - ac_cv_prog_FILECMD="$FILECMD" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_FILECMD="${ac_tool_prefix}file" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -FILECMD=$ac_cv_prog_FILECMD -if test -n "$FILECMD"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $FILECMD" >&5 -printf "%s\n" "$FILECMD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_FILECMD"; then - ac_ct_FILECMD=$FILECMD - # Extract the first word of "file", so it can be a program name with args. -set dummy file; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_FILECMD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_FILECMD"; then - ac_cv_prog_ac_ct_FILECMD="$ac_ct_FILECMD" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_FILECMD="file" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_FILECMD=$ac_cv_prog_ac_ct_FILECMD -if test -n "$ac_ct_FILECMD"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_FILECMD" >&5 -printf "%s\n" "$ac_ct_FILECMD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_FILECMD" = x; then - FILECMD=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - FILECMD=$ac_ct_FILECMD - fi -else - FILECMD="$ac_cv_prog_FILECMD" -fi - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_OBJDUMP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -printf "%s\n" "$OBJDUMP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_OBJDUMP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -printf "%s\n" "$ac_ct_OBJDUMP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" -fi - -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 -printf %s "checking how to recognize dependent libraries... " >&6; } -if test ${lt_cv_deplibs_check_method+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# 'unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# that responds to the $file_magic_cmd with a given extended regex. -# If you have 'file' or equivalent on your system and you're not sure -# whether 'pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[4-9]*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='$FILECMD -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - if ( file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly* | midnightbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=$FILECMD - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=$FILECMD - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[3-9]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=$FILECMD - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd* | bitrig*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -os2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -printf "%s\n" "$lt_cv_deplibs_check_method" >&6; } - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - - - - - - - - - - - - - - - - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_DLLTOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -printf "%s\n" "$DLLTOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_DLLTOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -printf "%s\n" "$ac_ct_DLLTOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" -fi - -test -z "$DLLTOOL" && DLLTOOL=dlltool - - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 -printf %s "checking how to associate runtime and link libraries... " >&6; } -if test ${lt_cv_sharedlib_from_linklib_cmd+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh; - # decide which one to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd=$ECHO - ;; -esac - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 -printf "%s\n" "$lt_cv_sharedlib_from_linklib_cmd" >&6; } -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - - - - - - - -if test -n "$ac_tool_prefix"; then - for ac_prog in ar - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_AR+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -printf "%s\n" "$AR" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$AR" && break - done -fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_AR+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AR="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -printf "%s\n" "$ac_ct_AR" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_AR" && break -done - - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AR=$ac_ct_AR - fi -fi - -: ${AR=ar} - - - - - - -# Use ARFLAGS variable as AR's operation code to sync the variable naming with -# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have -# higher priority because thats what people were doing historically (setting -# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS -# variable obsoleted/removed. - -test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} -lt_ar_flags=$AR_FLAGS - - - - - - -# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override -# by AR_FLAGS because that was never working and AR_FLAGS is about to die. - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 -printf %s "checking for archiver @FILE support... " >&6; } -if test ${lt_cv_ar_at_file+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_ar_at_file=no - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test 0 -eq "$ac_status"; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 - (eval $lt_ar_try) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if test 0 -ne "$ac_status"; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 -printf "%s\n" "$lt_cv_ar_at_file" >&6; } - -if test no = "$lt_cv_ar_at_file"; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi - - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_STRIP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_STRIP="${ac_tool_prefix}strip" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -printf "%s\n" "$STRIP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_STRIP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_STRIP="strip" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -printf "%s\n" "$ac_ct_STRIP" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_STRIP" = x; then - STRIP=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - STRIP=$ac_ct_STRIP - fi -else - STRIP="$ac_cv_prog_STRIP" -fi - -test -z "$STRIP" && STRIP=: - - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_RANLIB+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -printf "%s\n" "$RANLIB" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_RANLIB+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -printf "%s\n" "$ac_ct_RANLIB" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi - -test -z "$RANLIB" && RANLIB=: - - - - - - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - bitrig* | openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - -# Check for command to grab the raw symbol name followed by C symbol from nm. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -printf %s "checking command to parse $NM output from $compiler object... " >&6; } -if test ${lt_cv_sys_global_symbol_pipe+y} -then : - printf %s "(cached) " >&6 -else $as_nop - -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[BCDEGRST]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([_A-Za-z][_A-Za-z0-9]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[BCDT]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[ABCDGISTW]' - ;; -hpux*) - if test ia64 = "$host_cpu"; then - symcode='[ABCDEGRST]' - fi - ;; -irix* | nonstopux*) - symcode='[BCDEGRST]' - ;; -osf*) - symcode='[BCDEGQRST]' - ;; -solaris*) - symcode='[BDRT]' - ;; -sco3.2v5*) - symcode='[DT]' - ;; -sysv4.2uw2*) - symcode='[DT]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[ABDT]' - ;; -sysv4) - symcode='[DFNSTU]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac - -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Gets list of data symbols to import. - lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" - # Adjust the below global symbol transforms to fixup imported variables. - lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" - lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" - lt_c_name_lib_hook="\ - -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ - -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" -else - # Disable hooks by default. - lt_cv_sys_global_symbol_to_import= - lt_cdecl_hook= - lt_c_name_hook= - lt_c_name_lib_hook= -fi - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ -$lt_cdecl_hook\ -" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ -$lt_c_name_hook\ -" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" - -# Transform an extracted symbol line into symbol name with lib prefix and -# symbol address. -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ -$lt_c_name_lib_hook\ -" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ -" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function, - # D for any global variable and I for any imported variable. - # Also find C++ and __fastcall symbols from MSVC++ or ICC, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK '"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ -" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ -" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ -" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ -" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx" - else - lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Now try to grab the symbols. - nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE -/* DATA imports from DLLs on WIN32 can't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT_DLSYM_CONST -#elif defined __osf__ -/* This system does not cope well with relocations in const data. */ -# define LT_DLSYM_CONST -#else -# define LT_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS=conftstm.$ac_objext - CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s conftest$ac_exeext; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&5 - fi - else - echo "cannot find nm_test_var in $nlist" >&5 - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "$progname: failed program was:" >&5 - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test yes = "$pipe_works"; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done - -fi - -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -printf "%s\n" "failed" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -printf "%s\n" "ok" >&6; } -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 -printf %s "checking for sysroot... " >&6; } - -# Check whether --with-sysroot was given. -if test ${with_sysroot+y} -then : - withval=$with_sysroot; -else $as_nop - with_sysroot=no -fi - - -lt_sysroot= -case $with_sysroot in #( - yes) - if test yes = "$GCC"; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 -printf "%s\n" "$with_sysroot" >&6; } - as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 - ;; -esac - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 -printf "%s\n" "${lt_sysroot:-no}" >&6; } - - - - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 -printf %s "checking for a working dd... " >&6; } -if test ${ac_cv_path_lt_DD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - printf 0123456789abcdef0123456789abcdef >conftest.i -cat conftest.i conftest.i >conftest2.i -: ${lt_DD:=$DD} -if test -z "$lt_DD"; then - ac_path_lt_DD_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in dd - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_lt_DD="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_lt_DD" || continue -if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then - cmp -s conftest.i conftest.out \ - && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: -fi - $ac_path_lt_DD_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_lt_DD"; then - : - fi -else - ac_cv_path_lt_DD=$lt_DD -fi - -rm -f conftest.i conftest2.i conftest.out -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 -printf "%s\n" "$ac_cv_path_lt_DD" >&6; } - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 -printf %s "checking how to truncate binary pipes... " >&6; } -if test ${lt_cv_truncate_bin+y} -then : - printf %s "(cached) " >&6 -else $as_nop - printf 0123456789abcdef0123456789abcdef >conftest.i -cat conftest.i conftest.i >conftest2.i -lt_cv_truncate_bin= -if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then - cmp -s conftest.i conftest.out \ - && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" -fi -rm -f conftest.i conftest2.i conftest.out -test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 -printf "%s\n" "$lt_cv_truncate_bin" >&6; } - - - - - - - -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -func_cc_basename () -{ - for cc_temp in $*""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac - done - func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` -} - -# Check whether --enable-libtool-lock was given. -if test ${enable_libtool_lock+y} -then : - enableval=$enable_libtool_lock; -fi - -test no = "$enable_libtool_lock" || enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out what ABI is being produced by ac_compile, and set mode - # options accordingly. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `$FILECMD conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE=32 - ;; - *ELF-64*) - HPUX_IA64_MODE=64 - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo '#line '$LINENO' "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - if test yes = "$lt_cv_prog_gnu_ld"; then - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -mips64*-*linux*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo '#line '$LINENO' "configure"' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - emul=elf - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - emul="${emul}32" - ;; - *64-bit*) - emul="${emul}64" - ;; - esac - case `$FILECMD conftest.$ac_objext` in - *MSB*) - emul="${emul}btsmip" - ;; - *LSB*) - emul="${emul}ltsmip" - ;; - esac - case `$FILECMD conftest.$ac_objext` in - *N32*) - emul="${emul}n32" - ;; - esac - LD="${LD-ld} -m $emul" - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. Note that the listed cases only cover the - # situations where additional linker options are needed (such as when - # doing 32-bit compilation for a host where ld defaults to 64-bit, or - # vice versa); the common cases where no linker options are needed do - # not appear in the list. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `$FILECMD conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `$FILECMD conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*linux*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*linux*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS=$CFLAGS - CFLAGS="$CFLAGS -belf" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -printf %s "checking whether the C compiler needs -belf... " >&6; } -if test ${lt_cv_cc_needs_belf+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - lt_cv_cc_needs_belf=yes -else $as_nop - lt_cv_cc_needs_belf=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -printf "%s\n" "$lt_cv_cc_needs_belf" >&6; } - if test yes != "$lt_cv_cc_needs_belf"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS=$SAVE_CFLAGS - fi - ;; -*-*solaris*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo 'int i;' > conftest.$ac_ext - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - case `$FILECMD conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*|x86_64-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD=${LD-ld}_sol2 - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks=$enable_libtool_lock - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. -set dummy ${ac_tool_prefix}mt; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_MANIFEST_TOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$MANIFEST_TOOL"; then - ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL -if test -n "$MANIFEST_TOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 -printf "%s\n" "$MANIFEST_TOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_MANIFEST_TOOL"; then - ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL - # Extract the first word of "mt", so it can be a program name with args. -set dummy mt; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_MANIFEST_TOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_MANIFEST_TOOL"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL -if test -n "$ac_ct_MANIFEST_TOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 -printf "%s\n" "$ac_ct_MANIFEST_TOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_MANIFEST_TOOL" = x; then - MANIFEST_TOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL - fi -else - MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" -fi - -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 -printf %s "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } -if test ${lt_cv_path_mainfest_tool+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&5 - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest* -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 -printf "%s\n" "$lt_cv_path_mainfest_tool" >&6; } -if test yes != "$lt_cv_path_mainfest_tool"; then - MANIFEST_TOOL=: -fi - - - - - - - case $host_os in - rhapsody* | darwin*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. -set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_DSYMUTIL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -DSYMUTIL=$ac_cv_prog_DSYMUTIL -if test -n "$DSYMUTIL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 -printf "%s\n" "$DSYMUTIL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_DSYMUTIL"; then - ac_ct_DSYMUTIL=$DSYMUTIL - # Extract the first word of "dsymutil", so it can be a program name with args. -set dummy dsymutil; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_DSYMUTIL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL -if test -n "$ac_ct_DSYMUTIL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 -printf "%s\n" "$ac_ct_DSYMUTIL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DSYMUTIL=$ac_ct_DSYMUTIL - fi -else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. -set dummy ${ac_tool_prefix}nmedit; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_NMEDIT+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -NMEDIT=$ac_cv_prog_NMEDIT -if test -n "$NMEDIT"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 -printf "%s\n" "$NMEDIT" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_NMEDIT"; then - ac_ct_NMEDIT=$NMEDIT - # Extract the first word of "nmedit", so it can be a program name with args. -set dummy nmedit; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_NMEDIT+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_NMEDIT"; then - ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_NMEDIT="nmedit" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT -if test -n "$ac_ct_NMEDIT"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 -printf "%s\n" "$ac_ct_NMEDIT" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_NMEDIT" = x; then - NMEDIT=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - NMEDIT=$ac_ct_NMEDIT - fi -else - NMEDIT="$ac_cv_prog_NMEDIT" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. -set dummy ${ac_tool_prefix}lipo; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_LIPO+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$LIPO"; then - ac_cv_prog_LIPO="$LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_LIPO="${ac_tool_prefix}lipo" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LIPO=$ac_cv_prog_LIPO -if test -n "$LIPO"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 -printf "%s\n" "$LIPO" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_LIPO"; then - ac_ct_LIPO=$LIPO - # Extract the first word of "lipo", so it can be a program name with args. -set dummy lipo; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_LIPO+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_LIPO"; then - ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_LIPO="lipo" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO -if test -n "$ac_ct_LIPO"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 -printf "%s\n" "$ac_ct_LIPO" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_LIPO" = x; then - LIPO=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - LIPO=$ac_ct_LIPO - fi -else - LIPO="$ac_cv_prog_LIPO" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_OTOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$OTOOL"; then - ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL="${ac_tool_prefix}otool" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL=$ac_cv_prog_OTOOL -if test -n "$OTOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 -printf "%s\n" "$OTOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL"; then - ac_ct_OTOOL=$OTOOL - # Extract the first word of "otool", so it can be a program name with args. -set dummy otool; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_OTOOL+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_OTOOL"; then - ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL="otool" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL -if test -n "$ac_ct_OTOOL"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 -printf "%s\n" "$ac_ct_OTOOL" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_OTOOL" = x; then - OTOOL=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL=$ac_ct_OTOOL - fi -else - OTOOL="$ac_cv_prog_OTOOL" -fi - - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool64; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_OTOOL64+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$OTOOL64"; then - ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -OTOOL64=$ac_cv_prog_OTOOL64 -if test -n "$OTOOL64"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 -printf "%s\n" "$OTOOL64" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL64"; then - ac_ct_OTOOL64=$OTOOL64 - # Extract the first word of "otool64", so it can be a program name with args. -set dummy otool64; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_OTOOL64+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_OTOOL64"; then - ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OTOOL64="otool64" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 -if test -n "$ac_ct_OTOOL64"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 -printf "%s\n" "$ac_ct_OTOOL64" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_OTOOL64" = x; then - OTOOL64=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL64=$ac_ct_OTOOL64 - fi -else - OTOOL64="$ac_cv_prog_OTOOL64" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 -printf %s "checking for -single_module linker flag... " >&6; } -if test ${lt_cv_apple_cc_single_mod+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_apple_cc_single_mod=no - if test -z "$LT_MULTI_MODULE"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&5 - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test 0 = "$_lt_result"; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&5 - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 -printf "%s\n" "$lt_cv_apple_cc_single_mod" >&6; } - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 -printf %s "checking for -exported_symbols_list linker flag... " >&6; } -if test ${lt_cv_ld_exported_symbols_list+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - lt_cv_ld_exported_symbols_list=yes -else $as_nop - lt_cv_ld_exported_symbols_list=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 -printf "%s\n" "$lt_cv_ld_exported_symbols_list" >&6; } - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 -printf %s "checking for -force_load linker flag... " >&6; } -if test ${lt_cv_ld_force_load+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 - echo "$AR $AR_FLAGS libconftest.a conftest.o" >&5 - $AR $AR_FLAGS libconftest.a conftest.o 2>&5 - echo "$RANLIB libconftest.a" >&5 - $RANLIB libconftest.a 2>&5 - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&5 - elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&5 - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 -printf "%s\n" "$lt_cv_ld_force_load" >&6; } - case $host_os in - rhapsody* | darwin1.[012]) - _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - darwin*) - case $MACOSX_DEPLOYMENT_TARGET,$host in - 10.[012],*|,*powerpc*-darwin[5-8]*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - *) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test yes = "$lt_cv_apple_cc_single_mod"; then - _lt_dar_single_mod='$single_module' - fi - if test yes = "$lt_cv_ld_exported_symbols_list"; then - _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' - fi - if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac - -# func_munge_path_list VARIABLE PATH -# ----------------------------------- -# VARIABLE is name of variable containing _space_ separated list of -# directories to be munged by the contents of PATH, which is string -# having a format: -# "DIR[:DIR]:" -# string "DIR[ DIR]" will be prepended to VARIABLE -# ":DIR[:DIR]" -# string "DIR[ DIR]" will be appended to VARIABLE -# "DIRP[:DIRP]::[DIRA:]DIRA" -# string "DIRP[ DIRP]" will be prepended to VARIABLE and string -# "DIRA[ DIRA]" will be appended to VARIABLE -# "DIR[:DIR]" -# VARIABLE will be replaced by "DIR[ DIR]" -func_munge_path_list () -{ - case x$2 in - x) - ;; - *:) - eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" - ;; - x:*) - eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" - ;; - *::*) - eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" - eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" - ;; - *) - eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" - ;; - esac -} - -ac_header= ac_cache= -for ac_item in $ac_header_c_list -do - if test $ac_cache; then - ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default" - if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then - printf "%s\n" "#define $ac_item 1" >> confdefs.h - fi - ac_header= ac_cache= - elif test $ac_header; then - ac_cache=$ac_item - else - ac_header=$ac_item - fi -done - - - - - - - - -if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes -then : - -printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default -" -if test "x$ac_cv_header_dlfcn_h" = xyes -then : - printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h - -fi - - - - - -# Set options - - - - enable_dlopen=no - - - enable_win32_dll=no - - - # Check whether --enable-shared was given. -if test ${enable_shared+y} -then : - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS=$lt_save_ifs - ;; - esac -else $as_nop - enable_shared=yes -fi - - - - - - - - - - # Check whether --enable-static was given. -if test ${enable_static+y} -then : - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS=$lt_save_ifs - ;; - esac -else $as_nop - enable_static=yes -fi - - - - - - - - - - -# Check whether --with-pic was given. -if test ${with_pic+y} -then : - withval=$with_pic; lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for lt_pkg in $withval; do - IFS=$lt_save_ifs - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS=$lt_save_ifs - ;; - esac -else $as_nop - pic_mode=default -fi - - - - - - - - - # Check whether --enable-fast-install was given. -if test ${enable_fast_install+y} -then : - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS=$lt_save_ifs - ;; - esac -else $as_nop - enable_fast_install=yes -fi - - - - - - - - - shared_archive_member_spec= -case $host,$enable_shared in -power*-*-aix[5-9]*,yes) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 -printf %s "checking which variant of shared library versioning to provide... " >&6; } - -# Check whether --with-aix-soname was given. -if test ${with_aix_soname+y} -then : - withval=$with_aix_soname; case $withval in - aix|svr4|both) - ;; - *) - as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 - ;; - esac - lt_cv_with_aix_soname=$with_aix_soname -else $as_nop - if test ${lt_cv_with_aix_soname+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_with_aix_soname=aix -fi - - with_aix_soname=$lt_cv_with_aix_soname -fi - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 -printf "%s\n" "$with_aix_soname" >&6; } - if test aix != "$with_aix_soname"; then - # For the AIX way of multilib, we name the shared archive member - # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', - # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. - # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, - # the AIX toolchain works better with OBJECT_MODE set (default 32). - if test 64 = "${OBJECT_MODE-32}"; then - shared_archive_member_spec=shr_64 - else - shared_archive_member_spec=shr - fi - fi - ;; -*) - with_aix_soname=aix - ;; -esac - - - - - - - - - - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS=$ltmain - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -test -z "$LN_S" && LN_S="ln -s" - - - - - - - - - - - - - - -if test -n "${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST -fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -printf %s "checking for objdir... " >&6; } -if test ${lt_cv_objdir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -printf "%s\n" "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir - - - - - -printf "%s\n" "#define LT_OBJDIR \"$lt_cv_objdir/\"" >>confdefs.h - - - - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test set != "${COLLECT_NAMES+set}"; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a '.a' archive for static linking (except MSVC and -# ICC, which need '.lib'). -libext=a - -with_gnu_ld=$lt_cv_prog_gnu_ld - -old_CC=$CC -old_CFLAGS=$CFLAGS - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -func_cc_basename $compiler -cc_basename=$func_cc_basename_result - - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -printf %s "checking for ${ac_tool_prefix}file... " >&6; } -if test ${lt_cv_path_MAGIC_CMD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD=$MAGIC_CMD - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/${ac_tool_prefix}file"; then - lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD=$lt_cv_path_MAGIC_CMD - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS=$lt_save_ifs - MAGIC_CMD=$lt_save_MAGIC_CMD - ;; -esac -fi - -MAGIC_CMD=$lt_cv_path_MAGIC_CMD -if test -n "$MAGIC_CMD"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -printf "%s\n" "$MAGIC_CMD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - - - -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -printf %s "checking for file... " >&6; } -if test ${lt_cv_path_MAGIC_CMD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD=$MAGIC_CMD - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/file"; then - lt_cv_path_MAGIC_CMD=$ac_dir/"file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD=$lt_cv_path_MAGIC_CMD - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS=$lt_save_ifs - MAGIC_CMD=$lt_save_MAGIC_CMD - ;; -esac -fi - -MAGIC_CMD=$lt_cv_path_MAGIC_CMD -if test -n "$MAGIC_CMD"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -printf "%s\n" "$MAGIC_CMD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - else - MAGIC_CMD=: - fi -fi - - fi - ;; -esac - -# Use C for the default configuration in the libtool script - -lt_save_CC=$CC -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -objext=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - -lt_prog_compiler_no_builtin_flag= - -if test yes = "$GCC"; then - case $cc_basename in - nvcc*) - lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; - *) - lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; - esac - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -printf %s "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test ${lt_cv_prog_compiler_rtti_exceptions+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -printf "%s\n" "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - -if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi - -fi - - - - - - - lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= - - - if test yes = "$GCC"; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - lt_prog_compiler_pic='-fPIC' - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the '-m68020' flag to GCC prevents building anything better, - # like '-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic='-DDLL_EXPORT' - case $host_os in - os2*) - lt_prog_compiler_static='$wl-static' - ;; - esac - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - ;; - - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic - fi - ;; - - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - lt_prog_compiler_wl='-Xlinker ' - if test -n "$lt_prog_compiler_pic"; then - lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' - case $cc_basename in - nagfor*) - # NAG Fortran compiler - lt_prog_compiler_wl='-Wl,-Wl,,' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - esac - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' - case $host_os in - os2*) - lt_prog_compiler_static='$wl-static' - ;; - esac - ;; - - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='$wl-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64, which still supported -KPIC. - ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='--shared' - lt_prog_compiler_static='--static' - ;; - nagfor*) - # NAG Fortran compiler - lt_prog_compiler_wl='-Wl,-Wl,,' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - tcc*) - # Fabrice Bellard et al's Tiny C Compiler - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-qpic' - lt_prog_compiler_static='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' - ;; - *Sun\ F* | *Sun*Fortran*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Wl,' - ;; - *Intel*\ [CF]*Compiler*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - *Portland\ Group*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - - rdos*) - lt_prog_compiler_static='-non_shared' - ;; - - solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - lt_prog_compiler_wl='-Qoption ld ';; - *) - lt_prog_compiler_wl='-Wl,';; - esac - ;; - - sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; - - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no - ;; - - uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' - ;; - - *) - lt_prog_compiler_can_build_shared=no - ;; - esac - fi - -case $host_os in - # For platforms that do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -printf %s "checking for $compiler option to produce PIC... " >&6; } -if test ${lt_cv_prog_compiler_pic+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_pic=$lt_prog_compiler_pic -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 -printf "%s\n" "$lt_cv_prog_compiler_pic" >&6; } -lt_prog_compiler_pic=$lt_cv_prog_compiler_pic - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if test ${lt_cv_prog_compiler_pic_works+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works=yes - fi - fi - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 -printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; } - -if test yes = "$lt_cv_prog_compiler_pic_works"; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac -else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no -fi - -fi - - - - - - - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if test ${lt_cv_prog_compiler_static_works+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_static_works=no - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works=yes - fi - else - lt_cv_prog_compiler_static_works=yes - fi - fi - $RM -r conftest* - LDFLAGS=$save_LDFLAGS - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 -printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; } - -if test yes = "$lt_cv_prog_compiler_static_works"; then - : -else - lt_prog_compiler_static= -fi - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test ${lt_cv_prog_compiler_c_o+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test ${lt_cv_prog_compiler_c_o+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } - - - - -hard_links=nottested -if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then - # do not overwrite the value of need_locks provided by the user - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -printf %s "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -printf "%s\n" "$hard_links" >&6; } - if test no = "$hard_links"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 -printf "%s\n" "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag= - always_export_symbols=no - archive_cmds= - archive_expsym_cmds= - compiler_needs_object=no - enable_shared_with_static_runtimes=no - export_dynamic_flag_spec= - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - hardcode_automatic=no - hardcode_direct=no - hardcode_direct_absolute=no - hardcode_libdir_flag_spec= - hardcode_libdir_separator= - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - inherit_rpath=no - link_all_deplibs=unknown - module_cmds= - module_expsym_cmds= - old_archive_from_new_cmds= - old_archive_from_expsyms_cmds= - thread_safe_flag_spec= - whole_archive_flag_spec= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ' (' and ')$', so one must not match beginning or - # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', - # as well as any symbol that contains 'd'. - exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++ or Intel C++ Compiler. - if test yes != "$GCC"; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) - with_gnu_ld=yes - ;; - openbsd* | bitrig*) - with_gnu_ld=no - ;; - esac - - ld_shlibs=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test yes = "$with_gnu_ld"; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; - *\ \(GNU\ Binutils\)\ [3-9]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test yes = "$lt_use_gnu_ld_interface"; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='$wl' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - export_dynamic_flag_spec='$wl--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - else - whole_archive_flag_spec= - fi - supports_anon_versioning=no - case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[3-9]*) - # On AIX/PPC, the GNU linker is very broken - if test ia64 != "$host_cpu"; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - export_dynamic_flag_spec='$wl--export-all-symbols' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' - exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file, use it as - # is; otherwise, prepend EXPORTS... - archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs=no - fi - ;; - - haiku*) - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - link_all_deplibs=yes - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - shrext_cmds=.dll - archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - enable_shared_with_static_runtimes=yes - file_list_spec='@' - ;; - - interix[3-9]*) - hardcode_direct=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='$wl-rpath,$libdir' - export_dynamic_flag_spec='$wl-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test linux-dietlibc = "$host_os"; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test no = "$tmp_diet" - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - whole_archive_flag_spec= - tmp_sharedflag='--shared' ;; - nagfor*) # NAGFOR 5.3 - tmp_sharedflag='-Wl,-shared' ;; - xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - compiler_needs_object=yes - ;; - esac - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) # Sun C 5.9 - whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - compiler_needs_object=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - - if test yes = "$supports_anon_versioning"; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - tcc*) - export_dynamic_flag_spec='-rdynamic' - ;; - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test yes = "$supports_anon_versioning"; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - ld_shlibs=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) - ld_shlibs=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac - - if test no = "$ld_shlibs"; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; - - aix[4-9]*) - if test ia64 = "$host_cpu"; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag= - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to GNU nm, but means don't demangle to AIX nm. - # Without the "-l" option, or with the "-B" option, AIX nm treats - # weak defined symbols like other global defined symbols, whereas - # GNU nm marks them as "W". - # While the 'weak' keyword is ignored in the Export File, we need - # it in the Import File for the 'aix-soname' feature, so we have - # to replace the "-B" option with "-P" for AIX nm. - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # have runtime linking enabled, and use it for executables. - # For shared libraries, we enable/disable runtime linking - # depending on the kind of the shared library created - - # when "with_aix_soname,aix_use_runtimelinking" is: - # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables - # "aix,yes" lib.so shared, rtl:yes, for executables - # lib.a static archive - # "both,no" lib.so.V(shr.o) shared, rtl:yes - # lib.a(lib.so.V) shared, rtl:no, for executables - # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a(lib.so.V) shared, rtl:no - # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a static archive - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then - aix_use_runtimelinking=yes - break - fi - done - if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then - # With aix-soname=svr4, we create the lib.so.V shared archives only, - # so we don't have lib.a shared libs to link our executables. - # We have to force runtime linking in this case. - aix_use_runtimelinking=yes - LDFLAGS="$LDFLAGS -Wl,-brtl" - fi - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds='' - hardcode_direct=yes - hardcode_direct_absolute=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - file_list_spec='$wl-f,' - case $with_aix_soname,$aix_use_runtimelinking in - aix,*) ;; # traditional, no import file - svr4,* | *,yes) # use import file - # The Import File defines what to hardcode. - hardcode_direct=no - hardcode_direct_absolute=no - ;; - esac - - if test yes = "$GCC"; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`$CC -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - ;; - esac - shared_flag='-shared' - if test yes = "$aix_use_runtimelinking"; then - shared_flag="$shared_flag "'$wl-G' - fi - # Need to ensure runtime linking is disabled for the traditional - # shared library, or the linker may eventually find shared libraries - # /with/ Import File - we do not want to mix them. - shared_flag_aix='-shared' - shared_flag_svr4='-shared $wl-G' - else - # not using gcc - if test ia64 = "$host_cpu"; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test yes = "$aix_use_runtimelinking"; then - shared_flag='$wl-G' - else - shared_flag='$wl-bM:SRE' - fi - shared_flag_aix='$wl-bM:SRE' - shared_flag_svr4='$wl-G' - fi - fi - - export_dynamic_flag_spec='$wl-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - if test set = "${lt_cv_aix_libpath+set}"; then - aix_libpath=$lt_cv_aix_libpath -else - if test ${lt_cv_aix_libpath_+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=/usr/lib:/lib - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag - else - if test ia64 = "$host_cpu"; then - hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test set = "${lt_cv_aix_libpath+set}"; then - aix_libpath=$lt_cv_aix_libpath -else - if test ${lt_cv_aix_libpath_+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath_"; then - lt_cv_aix_libpath_=/usr/lib:/lib - fi - -fi - - aix_libpath=$lt_cv_aix_libpath_ -fi - - hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' $wl-bernotok' - allow_undefined_flag=' $wl-berok' - if test yes = "$with_gnu_ld"; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec='$convenience' - fi - archive_cmds_need_lc=yes - archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' - # -brtl affects multiple linker settings, -berok does not and is overridden later - compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' - if test svr4 != "$with_aix_soname"; then - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' - fi - if test aix != "$with_aix_soname"; then - archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' - else - # used by -dlpreopen to get the symbols - archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' - fi - archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++ or Intel C++ Compiler. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl* | icl*) - # Native MSVC or ICC - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - always_export_symbols=yes - file_list_spec='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' - archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then - cp "$export_symbols" "$output_objdir/$soname.def"; - echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; - else - $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, )='true' - enable_shared_with_static_runtimes=yes - exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' - # Don't use ranlib - old_postinstall_cmds='chmod 644 $oldlib' - postlink_cmds='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile=$lt_outputfile.exe - lt_tool_outputfile=$lt_tool_outputfile.exe - ;; - esac~ - if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC and ICC wrapper - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' - enable_shared_with_static_runtimes=yes - ;; - esac - ;; - - darwin* | rhapsody*) - - - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - if test yes = "$lt_cv_ld_force_load"; then - whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' - - else - whole_archive_flag_spec='' - fi - link_all_deplibs=yes - allow_undefined_flag=$_lt_dar_allow_undefined - case $cc_basename in - ifort*|nagfor*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test yes = "$_lt_dar_can_shared"; then - output_verbose_link_cmd=func_echo_all - archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" - module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - archive_expsym_cmds="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - module_expsym_cmds="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" - - else - ld_shlibs=no - fi - - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly* | midnightbsd*) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9*) - if test yes = "$GCC"; then - archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - else - archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec='$wl+b $wl$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='$wl-E' - ;; - - hpux10*) - if test yes,no = "$GCC,$with_gnu_ld"; then - archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test no = "$with_gnu_ld"; then - hardcode_libdir_flag_spec='$wl+b $wl$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='$wl-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - fi - ;; - - hpux11*) - if test yes,no = "$GCC,$with_gnu_ld"; then - case $host_cpu in - hppa*64*) - archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 -printf %s "checking if $CC understands -b... " >&6; } -if test ${lt_cv_prog_compiler__b+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler__b=no - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS -b" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler__b=yes - fi - else - lt_cv_prog_compiler__b=yes - fi - fi - $RM -r conftest* - LDFLAGS=$save_LDFLAGS - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 -printf "%s\n" "$lt_cv_prog_compiler__b" >&6; } - -if test yes = "$lt_cv_prog_compiler__b"; then - archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' -else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' -fi - - ;; - esac - fi - if test no = "$with_gnu_ld"; then - hardcode_libdir_flag_spec='$wl+b $wl$libdir' - hardcode_libdir_separator=: - - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - *) - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='$wl-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test yes = "$GCC"; then - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 -printf %s "checking whether the $host_os linker accepts -exported_symbol... " >&6; } -if test ${lt_cv_irix_exported_symbol+y} -then : - printf %s "(cached) " >&6 -else $as_nop - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -int foo (void) { return 0; } -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - lt_cv_irix_exported_symbol=yes -else $as_nop - lt_cv_irix_exported_symbol=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 -printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; } - if test yes = "$lt_cv_irix_exported_symbol"; then - archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' - fi - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - hardcode_libdir_separator=: - inherit_rpath=yes - link_all_deplibs=yes - ;; - - linux*) - case $cc_basename in - tcc*) - # Fabrice Bellard et al's Tiny C Compiler - ld_shlibs=yes - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; - - *nto* | *qnx*) - ;; - - openbsd* | bitrig*) - if test -f /usr/libexec/ld.so; then - hardcode_direct=yes - hardcode_shlibpath_var=no - hardcode_direct_absolute=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='$wl-rpath,$libdir' - export_dynamic_flag_spec='$wl-E' - else - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='$wl-rpath,$libdir' - fi - else - ld_shlibs=no - fi - ;; - - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - shrext_cmds=.dll - archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - enable_shared_with_static_runtimes=yes - file_list_spec='@' - ;; - - osf3*) - if test yes = "$GCC"; then - allow_undefined_flag=' $wl-expect_unresolved $wl\*' - archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - hardcode_libdir_separator=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test yes = "$GCC"; then - allow_undefined_flag=' $wl-expect_unresolved $wl\*' - archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' - - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - archive_cmds_need_lc='no' - hardcode_libdir_separator=: - ;; - - solaris*) - no_undefined_flag=' -z defs' - if test yes = "$GCC"; then - wlarc='$wl' - archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='$wl' - archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands '-z linker_flag'. GCC discards it without '$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test yes = "$GCC"; then - whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' - else - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' - fi - ;; - esac - link_all_deplibs=yes - ;; - - sunos4*) - if test sequent = "$host_vendor"; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag='$wl-z,text' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - - if test yes = "$GCC"; then - archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We CANNOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag='$wl-z,text' - allow_undefined_flag='$wl-z,nodefs' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='$wl-R,$libdir' - hardcode_libdir_separator=':' - link_all_deplibs=yes - export_dynamic_flag_spec='$wl-Bexport' - runpath_var='LD_RUN_PATH' - - if test yes = "$GCC"; then - archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - *) - ld_shlibs=no - ;; - esac - - if test sni = "$host_vendor"; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - export_dynamic_flag_spec='$wl-Blargedynsym' - ;; - esac - fi - fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -printf "%s\n" "$ld_shlibs" >&6; } -test no = "$ld_shlibs" && can_build_shared=no - -with_gnu_ld=$with_gnu_ld - - - - - - - - - - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes - - if test yes,yes = "$GCC,$enable_shared"; then - case $archive_cmds in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -printf %s "checking whether -lc should be explicitly linked in... " >&6; } -if test ${lt_cv_archive_cmds_need_lc+y} -then : - printf %s "(cached) " >&6 -else $as_nop - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - pic_flag=$lt_prog_compiler_pic - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc=no - else - lt_cv_archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 -printf "%s\n" "$lt_cv_archive_cmds_need_lc" >&6; } - archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -printf %s "checking dynamic linker characteristics... " >&6; } - -if test yes = "$GCC"; then - case $host_os in - darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; - *) lt_awk_arg='/^libraries:/' ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; - *) lt_sed_strip_eq='s|=/|/|g' ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary... - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - # ...but if some path component already ends with the multilib dir we assume - # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). - case "$lt_multi_os_dir; $lt_search_path_spec " in - "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) - lt_multi_os_dir= - ;; - esac - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" - elif test -n "$lt_multi_os_dir"; then - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS = " "; FS = "/|\n";} { - lt_foo = ""; - lt_count = 0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo = "/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[lt_foo]++; } - if (lt_freq[lt_foo] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's|/\([A-Za-z]:\)|\1|g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=.so -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - - - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='$libname$release$shared_ext$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test ia64 = "$host_cpu"; then - # AIX 5 supports IA64 - library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line '#! .'. This would cause the generated library to - # depend on '.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # Using Import Files as archive members, it is possible to support - # filename-based versioning of shared library archives on AIX. While - # this would work for both with and without runtime linking, it will - # prevent static linking of such archives. So we do filename-based - # shared library versioning with .so extension only, which is used - # when both runtime linking and shared linking is enabled. - # Unfortunately, runtime linking may impact performance, so we do - # not want this to be the default eventually. Also, we use the - # versioned .so libs for executables only if there is the -brtl - # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. - # To allow for filename-based versioning support, we need to create - # libNAME.so.V as an archive file, containing: - # *) an Import File, referring to the versioned filename of the - # archive as well as the shared archive member, telling the - # bitwidth (32 or 64) of that shared object, and providing the - # list of exported symbols of that shared object, eventually - # decorated with the 'weak' keyword - # *) the shared object with the F_LOADONLY flag set, to really avoid - # it being seen by the linker. - # At run time we better use the real file rather than another symlink, - # but for link time we create the symlink libNAME.so -> libNAME.so.V - - case $with_aix_soname,$aix_use_runtimelinking in - # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - aix,yes) # traditional libtool - dynamic_linker='AIX unversionable lib.so' - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - aix,no) # traditional AIX only - dynamic_linker='AIX lib.a(lib.so.V)' - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - ;; - svr4,*) # full svr4 only - dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,yes) # both, prefer svr4 - dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # unpreferred sharedlib libNAME.a needs extra handling - postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' - postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,no) # both, prefer aix - dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling - postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' - postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' - ;; - esac - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - esac - ;; - -beos*) - library_names_spec='$libname$shared_ext' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl* | *,icl*) - # Native MSVC or ICC - libname_spec='$name' - soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - library_names_spec='$libname.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec=$LIB - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC and ICC wrapper - library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' - soname_spec='$libname$release$major$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly* | midnightbsd*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=no - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - if test 32 = "$HPUX_IA64_MODE"; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - sys_lib_dlsearch_path_spec=/usr/lib/hpux32 - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - sys_lib_dlsearch_path_spec=/usr/lib/hpux64 - fi - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test yes = "$lt_cv_prog_gnu_ld"; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" - sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -linux*android*) - version_type=none # Android doesn't support versioned libraries. - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext' - soname_spec='$libname$release$shared_ext' - finish_cmds= - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - dynamic_linker='Android linker' - # Don't embed -rpath directories since the linker doesn't support them. - hardcode_libdir_flag_spec='-L$libdir' - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if test ${lt_cv_shlibpath_overrides_runpath+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null -then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - - # Ideally, we could use ldconfig to report *all* directores which are - # searched for libraries, however this is still not possible. Aside from not - # being certain /sbin/ldconfig is available, command - # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, - # even though it is searched at run-time. Try to do the best guess by - # appending ld.so.conf contents (and includes) to the search path. - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd* | bitrig*) - version_type=sunos - sys_lib_dlsearch_path_spec=/usr/lib - need_lib_prefix=no - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - need_version=no - else - need_version=yes - fi - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -os2*) - libname_spec='$name' - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - # OS/2 can only load a DLL with a base name of 8 characters or less. - soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; - v=$($ECHO $release$versuffix | tr -d .-); - n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); - $ECHO $n$v`$shared_ext' - library_names_spec='${libname}_dll.$libext' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=BEGINLIBPATH - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test yes = "$with_gnu_ld"; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec; then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' - soname_spec='$libname$shared_ext.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=sco - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test yes = "$with_gnu_ld"; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -printf "%s\n" "$dynamic_linker" >&6; } -test no = "$dynamic_linker" && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test yes = "$GCC"; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then - sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec -fi - -if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then - sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec -fi - -# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... -configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec - -# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code -func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" - -# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool -configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -printf %s "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || - test -n "$runpath_var" || - test yes = "$hardcode_automatic"; then - - # We can hardcode non-existent directories. - if test no != "$hardcode_direct" && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && - test no != "$hardcode_minus_L"; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -printf "%s\n" "$hardcode_action" >&6; } - -if test relink = "$hardcode_action" || - test yes = "$inherit_rpath"; then - # Fast installation is not supported - enable_fast_install=no -elif test yes = "$shlibpath_overrides_runpath" || - test no = "$enable_shared"; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - if test yes != "$enable_dlopen"; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen=load_add_on - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen=LoadLibrary - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen=dlopen - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -printf %s "checking for dlopen in -ldl... " >&6; } -if test ${ac_cv_lib_dl_dlopen+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char dlopen (); -int -main (void) -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_dl_dlopen=yes -else $as_nop - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes -then : - lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl -else $as_nop - - lt_cv_dlopen=dyld - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - -fi - - ;; - - tpf*) - # Don't try to run any link tests for TPF. We know it's impossible - # because TPF is a cross-compiler, and we know how we open DSOs. - lt_cv_dlopen=dlopen - lt_cv_dlopen_libs= - lt_cv_dlopen_self=no - ;; - - *) - ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = xyes -then : - lt_cv_dlopen=shl_load -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -printf %s "checking for shl_load in -ldld... " >&6; } -if test ${ac_cv_lib_dld_shl_load+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char shl_load (); -int -main (void) -{ -return shl_load (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_dld_shl_load=yes -else $as_nop - ac_cv_lib_dld_shl_load=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = xyes -then : - lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld -else $as_nop - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = xyes -then : - lt_cv_dlopen=dlopen -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -printf %s "checking for dlopen in -ldl... " >&6; } -if test ${ac_cv_lib_dl_dlopen+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char dlopen (); -int -main (void) -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_dl_dlopen=yes -else $as_nop - ac_cv_lib_dl_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes -then : - lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -printf %s "checking for dlopen in -lsvld... " >&6; } -if test ${ac_cv_lib_svld_dlopen+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char dlopen (); -int -main (void) -{ -return dlopen (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_svld_dlopen=yes -else $as_nop - ac_cv_lib_svld_dlopen=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -printf "%s\n" "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = xyes -then : - lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -printf %s "checking for dld_link in -ldld... " >&6; } -if test ${ac_cv_lib_dld_dld_link+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char dld_link (); -int -main (void) -{ -return dld_link (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_dld_dld_link=yes -else $as_nop - ac_cv_lib_dld_dld_link=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -printf "%s\n" "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = xyes -then : - lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld -fi - - -fi - - -fi - - -fi - - -fi - - -fi - - ;; - esac - - if test no = "$lt_cv_dlopen"; then - enable_dlopen=no - else - enable_dlopen=yes - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS=$CPPFLAGS - test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS=$LDFLAGS - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS=$LIBS - LIBS="$lt_cv_dlopen_libs $LIBS" - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -printf %s "checking whether a program can dlopen itself... " >&6; } -if test ${lt_cv_dlopen_self+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test yes = "$cross_compiling"; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisibility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self=no - fi -fi -rm -fr conftest* - - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -printf "%s\n" "$lt_cv_dlopen_self" >&6; } - - if test yes = "$lt_cv_dlopen_self"; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -printf %s "checking whether a statically linked program can dlopen itself... " >&6; } -if test ${lt_cv_dlopen_self_static+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test yes = "$cross_compiling"; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisibility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 - (eval $ac_link) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no - fi -fi -rm -fr conftest* - - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -printf "%s\n" "$lt_cv_dlopen_self_static" >&6; } - fi - - CPPFLAGS=$save_CPPFLAGS - LDFLAGS=$save_LDFLAGS - LIBS=$save_LIBS - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi - - - - - - - - - - - - - - - - - -striplib= -old_striplib= -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -printf %s "checking whether stripping libraries is possible... " >&6; } -if test -z "$STRIP"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -else - if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - old_striplib="$STRIP --strip-debug" - striplib="$STRIP --strip-unneeded" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } - else - case $host_os in - darwin*) - # FIXME - insert some real tests, host_os isn't really good enough - striplib="$STRIP -x" - old_striplib="$STRIP -S" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } - ;; - freebsd*) - if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then - old_striplib="$STRIP --strip-debug" - striplib="$STRIP --strip-unneeded" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } - else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } - fi - ;; - *) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } - ;; - esac - fi -fi - - - - - - - - - - - - - # Report what library types will actually be built - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -printf %s "checking if libtool supports shared libraries... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -printf "%s\n" "$can_build_shared" >&6; } - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -printf %s "checking whether to build shared libraries... " >&6; } - test no = "$can_build_shared" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test yes = "$enable_shared" && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[4-9]*) - if test ia64 != "$host_cpu"; then - case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in - yes,aix,yes) ;; # shared object as lib.so file only - yes,svr4,*) ;; # shared object as lib.so archive member only - yes,*) enable_static=no ;; # shared object in lib.a archive as well - esac - fi - ;; - esac - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -printf "%s\n" "$enable_shared" >&6; } - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -printf %s "checking whether to build static libraries... " >&6; } - # Make sure either enable_shared or enable_static is yes. - test yes = "$enable_shared" || enable_static=yes - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -printf "%s\n" "$enable_static" >&6; } - - - - -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -CC=$lt_save_CC - - - - - - - - - - - - - - - - ac_config_commands="$ac_config_commands libtool" - - - - -# Only expand once: - - - - -ac_config_headers="$ac_config_headers config.h" - - -# Process command line options -# Check whether --enable-tools was given. -if test ${enable_tools+y} -then : - enableval=$enable_tools; - if test "x$enableval" = xno; then - with_tools=false - else - with_tools=true - fi - -else $as_nop - with_tools=true -fi - - if test x$with_tools = xtrue; then - WITH_TOOLS_TRUE= - WITH_TOOLS_FALSE='#' -else - WITH_TOOLS_TRUE='#' - WITH_TOOLS_FALSE= -fi - - -# Check whether --enable-pam was given. -if test ${enable_pam+y} -then : - enableval=$enable_pam; - if test "x$enableval" = xno; then - with_pam=false - else - with_pam=true - fi - -else $as_nop - with_pam=true -fi - - if test x$with_pam = xtrue; then - WITH_PAM_TRUE= - WITH_PAM_FALSE='#' -else - WITH_PAM_TRUE='#' - WITH_PAM_FALSE= -fi - - -# Check whether --enable-daemon was given. -if test ${enable_daemon+y} -then : - enableval=$enable_daemon; - if test "x$enableval" = xno; then - with_daemon=false - else - with_daemon=true - fi - -else $as_nop - with_daemon=true -fi - - if test x$with_daemon = xtrue; then - WITH_DAEMON_TRUE= - WITH_DAEMON_FALSE='#' -else - WITH_DAEMON_TRUE='#' - WITH_DAEMON_FALSE= -fi - - -# Check whether --enable-python was given. -if test ${enable_python+y} -then : - enableval=$enable_python; -fi - -if test "$enable_python" = yes -then : - - # cython version check - if test "$CYTHON_VER_MAJ" -eq 0 -a "$CYTHON_VER_MIN" -lt 29 -then : - - as_fn_error $? "python bindings require cython 0.29 or higher" "$LINENO" 5 - -fi - - - - - - - if test -n "$PYTHON"; then - # If the user set $PYTHON, use it and don't search something else. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $PYTHON version is >= 3" >&5 -printf %s "checking whether $PYTHON version is >= 3... " >&6; } - prog="import sys -# split strings by '.' and convert to numeric. Append some zeros -# because we need at least 4 digits for the hex conversion. -# map returns an iterator in Python 3.0 and a list in 2.x -minver = list(map(int, '3'.split('.'))) + [0, 0, 0] -minverhex = 0 -# xrange is not present in Python 3.0 and range returns an iterator -for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i] -sys.exit(sys.hexversion < minverhex)" - if { echo "$as_me:$LINENO: $PYTHON -c "$prog"" >&5 - ($PYTHON -c "$prog") >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -printf "%s\n" "yes" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } - as_fn_error $? "Python interpreter is too old" "$LINENO" 5 -fi - am_display_PYTHON=$PYTHON - else - # Otherwise, try each interpreter until we find one that satisfies - # VERSION. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a Python interpreter with version >= 3" >&5 -printf %s "checking for a Python interpreter with version >= 3... " >&6; } -if test ${am_cv_pathless_PYTHON+y} -then : - printf %s "(cached) " >&6 -else $as_nop - - for am_cv_pathless_PYTHON in python python2 python3 python3.9 python3.8 python3.7 python3.6 python3.5 python3.4 python3.3 python3.2 python3.1 python3.0 python2.7 python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 none; do - test "$am_cv_pathless_PYTHON" = none && break - prog="import sys -# split strings by '.' and convert to numeric. Append some zeros -# because we need at least 4 digits for the hex conversion. -# map returns an iterator in Python 3.0 and a list in 2.x -minver = list(map(int, '3'.split('.'))) + [0, 0, 0] -minverhex = 0 -# xrange is not present in Python 3.0 and range returns an iterator -for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i] -sys.exit(sys.hexversion < minverhex)" - if { echo "$as_me:$LINENO: $am_cv_pathless_PYTHON -c "$prog"" >&5 - ($am_cv_pathless_PYTHON -c "$prog") >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -then : - break -fi - done -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_pathless_PYTHON" >&5 -printf "%s\n" "$am_cv_pathless_PYTHON" >&6; } - # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON. - if test "$am_cv_pathless_PYTHON" = none; then - PYTHON=: - else - # Extract the first word of "$am_cv_pathless_PYTHON", so it can be a program name with args. -set dummy $am_cv_pathless_PYTHON; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_path_PYTHON+y} -then : - printf %s "(cached) " >&6 -else $as_nop - case $PYTHON in - [\\/]* | ?:[\\/]*) - ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_path_PYTHON="$as_dir$ac_word$ac_exec_ext" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - - ;; -esac -fi -PYTHON=$ac_cv_path_PYTHON -if test -n "$PYTHON"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 -printf "%s\n" "$PYTHON" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - fi - am_display_PYTHON=$am_cv_pathless_PYTHON - fi - - - if test "$PYTHON" = :; then - as_fn_error $? "no suitable Python interpreter found" "$LINENO" 5 - else - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON version" >&5 -printf %s "checking for $am_display_PYTHON version... " >&6; } -if test ${am_cv_python_version+y} -then : - printf %s "(cached) " >&6 -else $as_nop - am_cv_python_version=`$PYTHON -c "import sys; print ('%u.%u' % sys.version_info[:2])"` -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_version" >&5 -printf "%s\n" "$am_cv_python_version" >&6; } - PYTHON_VERSION=$am_cv_python_version - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON platform" >&5 -printf %s "checking for $am_display_PYTHON platform... " >&6; } -if test ${am_cv_python_platform+y} -then : - printf %s "(cached) " >&6 -else $as_nop - am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"` -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_platform" >&5 -printf "%s\n" "$am_cv_python_platform" >&6; } - PYTHON_PLATFORM=$am_cv_python_platform - - - if test "x$prefix" = xNONE; then - am__usable_prefix=$ac_default_prefix - else - am__usable_prefix=$prefix - fi - - # Allow user to request using sys.* values from Python, - # instead of the GNU $prefix values. - -# Check whether --with-python-sys-prefix was given. -if test ${with_python_sys_prefix+y} -then : - withval=$with_python_sys_prefix; am_use_python_sys=: -else $as_nop - am_use_python_sys=false -fi - - - # Allow user to override whatever the default Python prefix is. - -# Check whether --with-python_prefix was given. -if test ${with_python_prefix+y} -then : - withval=$with_python_prefix; am_python_prefix_subst=$withval - am_cv_python_prefix=$withval - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for explicit $am_display_PYTHON prefix" >&5 -printf %s "checking for explicit $am_display_PYTHON prefix... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_prefix" >&5 -printf "%s\n" "$am_cv_python_prefix" >&6; } -else $as_nop - - if $am_use_python_sys; then - # using python sys.prefix value, not GNU - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for python default $am_display_PYTHON prefix" >&5 -printf %s "checking for python default $am_display_PYTHON prefix... " >&6; } -if test ${am_cv_python_prefix+y} -then : - printf %s "(cached) " >&6 -else $as_nop - am_cv_python_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.prefix)"` -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_prefix" >&5 -printf "%s\n" "$am_cv_python_prefix" >&6; } - - case $am_cv_python_prefix in - $am__usable_prefix*) - am__strip_prefix=`echo "$am__usable_prefix" | sed 's|.|.|g'` - am_python_prefix_subst=`echo "$am_cv_python_prefix" | sed "s,^$am__strip_prefix,\\${prefix},"` - ;; - *) - am_python_prefix_subst=$am_cv_python_prefix - ;; - esac - else # using GNU prefix value, not python sys.prefix - am_python_prefix_subst='${prefix}' - am_python_prefix=$am_python_prefix_subst - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU default $am_display_PYTHON prefix" >&5 -printf %s "checking for GNU default $am_display_PYTHON prefix... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_python_prefix" >&5 -printf "%s\n" "$am_python_prefix" >&6; } - fi -fi - - # Substituting python_prefix_subst value. - PYTHON_PREFIX=$am_python_prefix_subst - - - # emacs-page Now do it all over again for Python exec_prefix, but with yet - # another conditional: fall back to regular prefix if that was specified. - -# Check whether --with-python_exec_prefix was given. -if test ${with_python_exec_prefix+y} -then : - withval=$with_python_exec_prefix; am_python_exec_prefix_subst=$withval - am_cv_python_exec_prefix=$withval - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for explicit $am_display_PYTHON exec_prefix" >&5 -printf %s "checking for explicit $am_display_PYTHON exec_prefix... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_exec_prefix" >&5 -printf "%s\n" "$am_cv_python_exec_prefix" >&6; } -else $as_nop - - # no explicit --with-python_exec_prefix, but if - # --with-python_prefix was given, use its value for python_exec_prefix too. - if test -n "$with_python_prefix" -then : - am_python_exec_prefix_subst=$with_python_prefix - am_cv_python_exec_prefix=$with_python_prefix - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for python_prefix-given $am_display_PYTHON exec_prefix" >&5 -printf %s "checking for python_prefix-given $am_display_PYTHON exec_prefix... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_exec_prefix" >&5 -printf "%s\n" "$am_cv_python_exec_prefix" >&6; } -else $as_nop - - # Set am__usable_exec_prefix whether using GNU or Python values, - # since we use that variable for pyexecdir. - if test "x$exec_prefix" = xNONE; then - am__usable_exec_prefix=$am__usable_prefix - else - am__usable_exec_prefix=$exec_prefix - fi - # - if $am_use_python_sys; then # using python sys.exec_prefix, not GNU - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for python default $am_display_PYTHON exec_prefix" >&5 -printf %s "checking for python default $am_display_PYTHON exec_prefix... " >&6; } -if test ${am_cv_python_exec_prefix+y} -then : - printf %s "(cached) " >&6 -else $as_nop - am_cv_python_exec_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.exec_prefix)"` -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_exec_prefix" >&5 -printf "%s\n" "$am_cv_python_exec_prefix" >&6; } - case $am_cv_python_exec_prefix in - $am__usable_exec_prefix*) - am__strip_prefix=`echo "$am__usable_exec_prefix" | sed 's|.|.|g'` - am_python_exec_prefix_subst=`echo "$am_cv_python_exec_prefix" | sed "s,^$am__strip_prefix,\\${exec_prefix},"` - ;; - *) - am_python_exec_prefix_subst=$am_cv_python_exec_prefix - ;; - esac - else # using GNU $exec_prefix, not python sys.exec_prefix - am_python_exec_prefix_subst='${exec_prefix}' - am_python_exec_prefix=$am_python_exec_prefix_subst - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU default $am_display_PYTHON exec_prefix" >&5 -printf %s "checking for GNU default $am_display_PYTHON exec_prefix... " >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_python_exec_prefix" >&5 -printf "%s\n" "$am_python_exec_prefix" >&6; } - fi -fi -fi - - # Substituting python_exec_prefix_subst. - PYTHON_EXEC_PREFIX=$am_python_exec_prefix_subst - - - # Factor out some code duplication into this shell variable. - am_python_setup_sysconfig="\ -import sys -# Prefer sysconfig over distutils.sysconfig, for better compatibility -# with python 3.x. See automake bug#10227. -try: - import sysconfig -except ImportError: - can_use_sysconfig = 0 -else: - can_use_sysconfig = 1 -# Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs: -# -try: - from platform import python_implementation - if python_implementation() == 'CPython' and sys.version[:3] == '2.7': - can_use_sysconfig = 0 -except ImportError: - pass" - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON script directory (pythondir)" >&5 -printf %s "checking for $am_display_PYTHON script directory (pythondir)... " >&6; } -if test ${am_cv_python_pythondir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "x$am_cv_python_prefix" = x; then - am_py_prefix=$am__usable_prefix - else - am_py_prefix=$am_cv_python_prefix - fi - am_cv_python_pythondir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix') -sys.stdout.write(sitedir)"` - # - case $am_cv_python_pythondir in - $am_py_prefix*) - am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'` - am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,\\${PYTHON_PREFIX},"` - ;; - *) - case $am_py_prefix in - /usr|/System*) ;; - *) am_cv_python_pythondir="\${PYTHON_PREFIX}/lib/python$PYTHON_VERSION/site-packages" - ;; - esac - ;; - esac - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pythondir" >&5 -printf "%s\n" "$am_cv_python_pythondir" >&6; } - pythondir=$am_cv_python_pythondir - - - pkgpythondir=\${pythondir}/$PACKAGE - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $am_display_PYTHON extension module directory (pyexecdir)" >&5 -printf %s "checking for $am_display_PYTHON extension module directory (pyexecdir)... " >&6; } -if test ${am_cv_python_pyexecdir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "x$am_cv_python_exec_prefix" = x; then - am_py_exec_prefix=$am__usable_exec_prefix - else - am_py_exec_prefix=$am_cv_python_exec_prefix - fi - am_cv_python_pyexecdir=`$PYTHON -c " -$am_python_setup_sysconfig -if can_use_sysconfig: - sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_exec_prefix'}) -else: - from distutils import sysconfig - sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_exec_prefix') -sys.stdout.write(sitedir)"` - # - case $am_cv_python_pyexecdir in - $am_py_exec_prefix*) - am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'` - am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,\\${PYTHON_EXEC_PREFIX},"` - ;; - *) - case $am_py_exec_prefix in - /usr|/System*) ;; - *) am_cv_python_pyexecdir="\${PYTHON_EXEC_PREFIX}/lib/python$PYTHON_VERSION/site-packages" - ;; - esac - ;; - esac - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_python_pyexecdir" >&5 -printf "%s\n" "$am_cv_python_pyexecdir" >&6; } - pyexecdir=$am_cv_python_pyexecdir - - - pkgpyexecdir=\${pyexecdir}/$PACKAGE - - - - fi - - -fi - if test "$enable_python" = yes; then - ENABLE_PYTHON_TRUE= - ENABLE_PYTHON_FALSE='#' -else - ENABLE_PYTHON_TRUE='#' - ENABLE_PYTHON_FALSE= -fi - - -printf "%s\n" "#define ENABLE_PYTHON $(test \"$enable_python\" = yes && echo 1 || echo 0)" >>confdefs.h - - -# Check whether --enable-systemd was given. -if test ${enable_systemd+y} -then : - enableval=$enable_systemd; - if test "x$enableval" = xno; then - with_systemd=false - else - with_systemd=true - fi - -else $as_nop - with_systemd=true -fi - - if test x$with_systemd = xtrue; then - WITH_SYSTEMD_TRUE= - WITH_SYSTEMD_FALSE='#' -else - WITH_SYSTEMD_TRUE='#' - WITH_SYSTEMD_FALSE= -fi - - -# Check whether --enable-initscript-install was given. -if test ${enable_initscript_install+y} -then : - enableval=$enable_initscript_install; - if test "x$enableval" = xno; then - with_initscript_install=false - else - with_initscript_install=true - fi - -else $as_nop - with_initscript_install=false -fi - - if test x$with_initscript_install = xtrue; then - WITH_INITSCRIPT_INSTALL_TRUE= - WITH_INITSCRIPT_INSTALL_FALSE='#' -else - WITH_INITSCRIPT_INSTALL_TRUE='#' - WITH_INITSCRIPT_INSTALL_FALSE= -fi - - -socket_path="/var/run/cgred.socket" -# Check whether --enable-cgred-socket was given. -if test ${enable_cgred_socket+y} -then : - enableval=$enable_cgred_socket; - if test "x$enableval" = xno -o "x$enableval" = xyes; then - as_fn_error $? "Provide valid path with --enable-cgred-socket option." "$LINENO" 5 - else - socket_path="$enableval" - fi - -fi - - -printf "%s\n" "#define CGRULE_CGRED_SOCKET_PATH \"$socket_path\"" >>confdefs.h - - -pam_module_dir="$libdir/security" -# Check whether --enable-pam-module-dir was given. -if test ${enable_pam_module_dir+y} -then : - enableval=$enable_pam_module_dir; - if test "x$enableval" = xno -o "x$enableval" = xyes; then - as_fn_error $? "Provide valid path with --enable-pam-module-dir option." "$LINENO" 5 - else - pam_module_dir="$enableval" - fi - -fi - -pamlibdir="$pam_module_dir" - - -# Check whether --enable-opaque-hierarchy was given. -if test ${enable_opaque_hierarchy+y} -then : - enableval=$enable_opaque_hierarchy; - if test "x$enableval" = xno -o "x$enableval" = xyes; then - as_fn_error $? "Provide name of a hierarchy." "$LINENO" 5 - else - -printf "%s\n" "#define OPAQUE_HIERARCHY \"$enableval\"" >>confdefs.h - - fi - -fi - - -# Check whether --enable-tests was given. -if test ${enable_tests+y} -then : - enableval=$enable_tests; - if test "x$enableval" = xno; then - with_tests=false - else - with_tests=true - fi - -else $as_nop - with_tests=true -fi - - if test x$with_tests = xtrue; then - WITH_TESTS_TRUE= - WITH_TESTS_FALSE='#' -else - WITH_TESTS_TRUE='#' - WITH_TESTS_FALSE= -fi - - -# Check whether --enable-samples was given. -if test ${enable_samples+y} -then : - enableval=$enable_samples; - if test "x$enableval" = xno; then - with_samples=false - else - with_samples=true - fi - -else $as_nop - with_samples=false -fi - - if test x$with_samples = xtrue; then - WITH_SAMPLES_TRUE= - WITH_SAMPLES_FALSE='#' -else - WITH_SAMPLES_TRUE='#' - WITH_SAMPLES_FALSE= -fi - - -# Checks for programs. - - - - - - -ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -if test -z "$CXX"; then - if test -n "$CCC"; then - CXX=$CCC - else - if test -n "$ac_tool_prefix"; then - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CXX"; then - ac_cv_prog_CXX="$CXX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CXX=$ac_cv_prog_CXX -if test -n "$CXX"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 -printf "%s\n" "$CXX" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$CXX" && break - done -fi -if test -z "$CXX"; then - ac_ct_CXX=$CXX - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CXX"; then - ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CXX="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CXX=$ac_cv_prog_ac_ct_CXX -if test -n "$ac_ct_CXX"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 -printf "%s\n" "$ac_ct_CXX" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_CXX" && break -done - - if test "x$ac_ct_CXX" = x; then - CXX="g++" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CXX=$ac_ct_CXX - fi -fi - - fi -fi -# Provide some information about the compiler. -printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C++" >&5 -printf %s "checking whether the compiler supports GNU C++... " >&6; } -if test ${ac_cv_cxx_compiler_gnu+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO" -then : - ac_compiler_gnu=yes -else $as_nop - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -ac_cv_cxx_compiler_gnu=$ac_compiler_gnu - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 -printf "%s\n" "$ac_cv_cxx_compiler_gnu" >&6; } -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu - -if test $ac_compiler_gnu = yes; then - GXX=yes -else - GXX= -fi -ac_test_CXXFLAGS=${CXXFLAGS+y} -ac_save_CXXFLAGS=$CXXFLAGS -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 -printf %s "checking whether $CXX accepts -g... " >&6; } -if test ${ac_cv_prog_cxx_g+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_save_cxx_werror_flag=$ac_cxx_werror_flag - ac_cxx_werror_flag=yes - ac_cv_prog_cxx_g=no - CXXFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO" -then : - ac_cv_prog_cxx_g=yes -else $as_nop - CXXFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO" -then : - -else $as_nop - ac_cxx_werror_flag=$ac_save_cxx_werror_flag - CXXFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_compile "$LINENO" -then : - ac_cv_prog_cxx_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - ac_cxx_werror_flag=$ac_save_cxx_werror_flag -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 -printf "%s\n" "$ac_cv_prog_cxx_g" >&6; } -if test $ac_test_CXXFLAGS; then - CXXFLAGS=$ac_save_CXXFLAGS -elif test $ac_cv_prog_cxx_g = yes; then - if test "$GXX" = yes; then - CXXFLAGS="-g -O2" - else - CXXFLAGS="-g" - fi -else - if test "$GXX" = yes; then - CXXFLAGS="-O2" - else - CXXFLAGS= - fi -fi -ac_prog_cxx_stdcxx=no -if test x$ac_prog_cxx_stdcxx = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++11 features" >&5 -printf %s "checking for $CXX option to enable C++11 features... " >&6; } -if test ${ac_cv_prog_cxx_cxx11+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cxx_cxx11=no -ac_save_CXX=$CXX -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_cxx_conftest_cxx11_program -_ACEOF -for ac_arg in '' -std=gnu++11 -std=gnu++0x -std=c++11 -std=c++0x -qlanglvl=extended0x -AA -do - CXX="$ac_save_CXX $ac_arg" - if ac_fn_cxx_try_compile "$LINENO" -then : - ac_cv_prog_cxx_cxx11=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cxx_cxx11" != "xno" && break -done -rm -f conftest.$ac_ext -CXX=$ac_save_CXX -fi - -if test "x$ac_cv_prog_cxx_cxx11" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cxx_cxx11" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx11" >&5 -printf "%s\n" "$ac_cv_prog_cxx_cxx11" >&6; } - CXX="$CXX $ac_cv_prog_cxx_cxx11" -fi - ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx11 - ac_prog_cxx_stdcxx=cxx11 -fi -fi -if test x$ac_prog_cxx_stdcxx = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++98 features" >&5 -printf %s "checking for $CXX option to enable C++98 features... " >&6; } -if test ${ac_cv_prog_cxx_cxx98+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cxx_cxx98=no -ac_save_CXX=$CXX -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_cxx_conftest_cxx98_program -_ACEOF -for ac_arg in '' -std=gnu++98 -std=c++98 -qlanglvl=extended -AA -do - CXX="$ac_save_CXX $ac_arg" - if ac_fn_cxx_try_compile "$LINENO" -then : - ac_cv_prog_cxx_cxx98=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cxx_cxx98" != "xno" && break -done -rm -f conftest.$ac_ext -CXX=$ac_save_CXX -fi - -if test "x$ac_cv_prog_cxx_cxx98" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cxx_cxx98" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx98" >&5 -printf "%s\n" "$ac_cv_prog_cxx_cxx98" >&6; } - CXX="$CXX $ac_cv_prog_cxx_cxx98" -fi - ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx98 - ac_prog_cxx_stdcxx=cxx98 -fi -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -depcc="$CXX" am_compiler_list= - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -printf %s "checking dependency style of $depcc... " >&6; } -if test ${am_cv_CXX_dependencies_compiler_type+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CXX_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CXX_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CXX_dependencies_compiler_type=none -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 -printf "%s\n" "$am_cv_CXX_dependencies_compiler_type" >&6; } -CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then - am__fastdepCXX_TRUE= - am__fastdepCXX_FALSE='#' -else - am__fastdepCXX_TRUE='#' - am__fastdepCXX_FALSE= -fi - - - - -func_stripname_cnf () -{ - case $2 in - .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;; - *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;; - esac -} # func_stripname_cnf - - if test -n "$CXX" && ( test no != "$CXX" && - ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || - (test g++ != "$CXX"))); then - ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 -printf %s "checking how to run the C++ preprocessor... " >&6; } -if test -z "$CXXCPP"; then - if test ${ac_cv_prog_CXXCPP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - # Double quotes because $CXX needs to be expanded - for CXXCPP in "$CXX -E" cpp /lib/cpp - do - ac_preproc_ok=false -for ac_cxx_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - Syntax error -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO" -then : - -else $as_nop - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO" -then : - # Broken: success on invalid input. -continue -else $as_nop - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok -then : - break -fi - - done - ac_cv_prog_CXXCPP=$CXXCPP - -fi - CXXCPP=$ac_cv_prog_CXXCPP -else - ac_cv_prog_CXXCPP=$CXXCPP -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 -printf "%s\n" "$CXXCPP" >&6; } -ac_preproc_ok=false -for ac_cxx_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - Syntax error -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO" -then : - -else $as_nop - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_cxx_try_cpp "$LINENO" -then : - # Broken: success on invalid input. -continue -else $as_nop - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok -then : - -else $as_nop - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -else - _lt_caught_CXX_error=yes -fi - -ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu - -archive_cmds_need_lc_CXX=no -allow_undefined_flag_CXX= -always_export_symbols_CXX=no -archive_expsym_cmds_CXX= -compiler_needs_object_CXX=no -export_dynamic_flag_spec_CXX= -hardcode_direct_CXX=no -hardcode_direct_absolute_CXX=no -hardcode_libdir_flag_spec_CXX= -hardcode_libdir_separator_CXX= -hardcode_minus_L_CXX=no -hardcode_shlibpath_var_CXX=unsupported -hardcode_automatic_CXX=no -inherit_rpath_CXX=no -module_cmds_CXX= -module_expsym_cmds_CXX= -link_all_deplibs_CXX=unknown -old_archive_cmds_CXX=$old_archive_cmds -reload_flag_CXX=$reload_flag -reload_cmds_CXX=$reload_cmds -no_undefined_flag_CXX= -whole_archive_flag_spec_CXX= -enable_shared_with_static_runtimes_CXX=no - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -objext_CXX=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test yes != "$_lt_caught_CXX_error"; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - - - # save warnings/boilerplate of simple test code - ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - - ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_CFLAGS=$CFLAGS - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - CFLAGS=$CXXFLAGS - compiler=$CC - compiler_CXX=$CC - func_cc_basename $compiler -cc_basename=$func_cc_basename_result - - - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test yes = "$GXX"; then - lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' - else - lt_prog_compiler_no_builtin_flag_CXX= - fi - - if test yes = "$GXX"; then - # Set up default GNU C++ configuration - - - -# Check whether --with-gnu-ld was given. -if test ${with_gnu_ld+y} -then : - withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes -else $as_nop - with_gnu_ld=no -fi - -ac_prog=ld -if test yes = "$GCC"; then - # Check if gcc -print-prog-name=ld gives a path. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -printf %s "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return, which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [\\/]* | ?:[\\/]*) - re_direlt='/[^/][^/]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD=$ac_prog - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test yes = "$with_gnu_ld"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -printf %s "checking for GNU ld... " >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -printf %s "checking for non-GNU ld... " >&6; } -fi -if test ${lt_cv_path_LD+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$LD"; then - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD=$ac_dir/$ac_prog - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &5 -printf "%s\n" "$LD" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi -test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -printf %s "checking if the linker ($LD) is GNU ld... " >&6; } -if test ${lt_cv_prog_gnu_ld+y} -then : - printf %s "(cached) " >&6 -else $as_nop - # I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 &5 -printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; } -with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test yes = "$with_gnu_ld"; then - archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - - hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' - export_dynamic_flag_spec_CXX='$wl--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='$wl' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - else - whole_archive_flag_spec_CXX= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - ld_shlibs_CXX=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aix[4-9]*) - if test ia64 = "$host_cpu"; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag= - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # have runtime linking enabled, and use it for executables. - # For shared libraries, we enable/disable runtime linking - # depending on the kind of the shared library created - - # when "with_aix_soname,aix_use_runtimelinking" is: - # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables - # "aix,yes" lib.so shared, rtl:yes, for executables - # lib.a static archive - # "both,no" lib.so.V(shr.o) shared, rtl:yes - # lib.a(lib.so.V) shared, rtl:no, for executables - # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a(lib.so.V) shared, rtl:no - # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a static archive - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then - # With aix-soname=svr4, we create the lib.so.V shared archives only, - # so we don't have lib.a shared libs to link our executables. - # We have to force runtime linking in this case. - aix_use_runtimelinking=yes - LDFLAGS="$LDFLAGS -Wl,-brtl" - fi - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - archive_cmds_CXX='' - hardcode_direct_CXX=yes - hardcode_direct_absolute_CXX=yes - hardcode_libdir_separator_CXX=':' - link_all_deplibs_CXX=yes - file_list_spec_CXX='$wl-f,' - case $with_aix_soname,$aix_use_runtimelinking in - aix,*) ;; # no import file - svr4,* | *,yes) # use import file - # The Import File defines what to hardcode. - hardcode_direct_CXX=no - hardcode_direct_absolute_CXX=no - ;; - esac - - if test yes = "$GXX"; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`$CC -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct_CXX=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L_CXX=yes - hardcode_libdir_flag_spec_CXX='-L$libdir' - hardcode_libdir_separator_CXX= - fi - esac - shared_flag='-shared' - if test yes = "$aix_use_runtimelinking"; then - shared_flag=$shared_flag' $wl-G' - fi - # Need to ensure runtime linking is disabled for the traditional - # shared library, or the linker may eventually find shared libraries - # /with/ Import File - we do not want to mix them. - shared_flag_aix='-shared' - shared_flag_svr4='-shared $wl-G' - else - # not using gcc - if test ia64 = "$host_cpu"; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test yes = "$aix_use_runtimelinking"; then - shared_flag='$wl-G' - else - shared_flag='$wl-bM:SRE' - fi - shared_flag_aix='$wl-bM:SRE' - shared_flag_svr4='$wl-G' - fi - fi - - export_dynamic_flag_spec_CXX='$wl-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - always_export_symbols_CXX=yes - if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - # The "-G" linker flag allows undefined symbols. - no_undefined_flag_CXX='-bernotok' - # Determine the default libpath from the value encoded in an empty - # executable. - if test set = "${lt_cv_aix_libpath+set}"; then - aix_libpath=$lt_cv_aix_libpath -else - if test ${lt_cv_aix_libpath__CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO" -then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=/usr/lib:/lib - fi - -fi - - aix_libpath=$lt_cv_aix_libpath__CXX -fi - - hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" - - archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag - else - if test ia64 = "$host_cpu"; then - hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib' - allow_undefined_flag_CXX="-z nodefs" - archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - if test set = "${lt_cv_aix_libpath+set}"; then - aix_libpath=$lt_cv_aix_libpath -else - if test ${lt_cv_aix_libpath__CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO" -then : - - lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }' - lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - if test -z "$lt_cv_aix_libpath__CXX"; then - lt_cv_aix_libpath__CXX=/usr/lib:/lib - fi - -fi - - aix_libpath=$lt_cv_aix_libpath__CXX -fi - - hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag_CXX=' $wl-bernotok' - allow_undefined_flag_CXX=' $wl-berok' - if test yes = "$with_gnu_ld"; then - # We only use this code for GNU lds that support --whole-archive. - whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec_CXX='$convenience' - fi - archive_cmds_need_lc_CXX=yes - archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' - # -brtl affects multiple linker settings, -berok does not and is overridden later - compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' - if test svr4 != "$with_aix_soname"; then - # This is similar to how AIX traditionally builds its shared - # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. - archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' - fi - if test aix != "$with_aix_soname"; then - archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' - else - # used by -dlpreopen to get the symbols - archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir' - fi - archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d' - fi - fi - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag_CXX=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - else - ld_shlibs_CXX=no - fi - ;; - - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - case $GXX,$cc_basename in - ,cl* | no,cl* | ,icl* | no,icl*) - # Native MSVC or ICC - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec_CXX=' ' - allow_undefined_flag_CXX=unsupported - always_export_symbols_CXX=yes - file_list_spec_CXX='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' - archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then - cp "$export_symbols" "$output_objdir/$soname.def"; - echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; - else - $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' - enable_shared_with_static_runtimes_CXX=yes - # Don't use ranlib - old_postinstall_cmds_CXX='chmod 644 $oldlib' - postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile=$lt_outputfile.exe - lt_tool_outputfile=$lt_tool_outputfile.exe - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # g++ - # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec_CXX='-L$libdir' - export_dynamic_flag_spec_CXX='$wl--export-all-symbols' - allow_undefined_flag_CXX=unsupported - always_export_symbols_CXX=no - enable_shared_with_static_runtimes_CXX=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file, use it as - # is; otherwise, prepend EXPORTS... - archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs_CXX=no - fi - ;; - esac - ;; - darwin* | rhapsody*) - - - archive_cmds_need_lc_CXX=no - hardcode_direct_CXX=no - hardcode_automatic_CXX=yes - hardcode_shlibpath_var_CXX=unsupported - if test yes = "$lt_cv_ld_force_load"; then - whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' - - else - whole_archive_flag_spec_CXX='' - fi - link_all_deplibs_CXX=yes - allow_undefined_flag_CXX=$_lt_dar_allow_undefined - case $cc_basename in - ifort*|nagfor*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test yes = "$_lt_dar_can_shared"; then - output_verbose_link_cmd=func_echo_all - archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" - module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - archive_expsym_cmds_CXX="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - module_expsym_cmds_CXX="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" - if test yes != "$lt_cv_apple_cc_single_mod"; then - archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" - archive_expsym_cmds_CXX="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" - fi - - else - ld_shlibs_CXX=no - fi - - ;; - - os2*) - hardcode_libdir_flag_spec_CXX='-L$libdir' - hardcode_minus_L_CXX=yes - allow_undefined_flag_CXX=unsupported - shrext_cmds=.dll - archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - enable_shared_with_static_runtimes_CXX=yes - file_list_spec_CXX='@' - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - freebsd2.*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - ld_shlibs_CXX=no - ;; - - freebsd-elf*) - archive_cmds_need_lc_CXX=no - ;; - - freebsd* | dragonfly* | midnightbsd*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - ld_shlibs_CXX=yes - ;; - - haiku*) - archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - link_all_deplibs_CXX=yes - ;; - - hpux9*) - hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' - hardcode_libdir_separator_CXX=: - export_dynamic_flag_spec_CXX='$wl-E' - hardcode_direct_CXX=yes - hardcode_minus_L_CXX=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aCC*) - archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes = "$GXX"; then - archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - hpux10*|hpux11*) - if test no = "$with_gnu_ld"; then - hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' - hardcode_libdir_separator_CXX=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - export_dynamic_flag_spec_CXX='$wl-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct_CXX=no - hardcode_shlibpath_var_CXX=no - ;; - *) - hardcode_direct_CXX=yes - hardcode_direct_absolute_CXX=yes - hardcode_minus_L_CXX=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes = "$GXX"; then - if test no = "$with_gnu_ld"; then - case $host_cpu in - hppa*64*) - archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - interix[3-9]*) - hardcode_direct_CXX=no - hardcode_shlibpath_var_CXX=no - hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' - export_dynamic_flag_spec_CXX='$wl-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - archive_expsym_cmds_CXX='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test yes = "$GXX"; then - if test no = "$with_gnu_ld"; then - archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - else - archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' - fi - fi - link_all_deplibs_CXX=yes - ;; - esac - hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' - hardcode_libdir_separator_CXX=: - inherit_rpath_CXX=yes - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - - hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' - export_dynamic_flag_spec_CXX='$wl--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - archive_cmds_need_lc_CXX=no - hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' - export_dynamic_flag_spec_CXX='$wl--export-dynamic' - whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [1-5].* | *pgcpp\ [1-5].*) - prelink_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' - old_archive_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' - archive_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 6 and above use weak symbols - archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - - hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir' - export_dynamic_flag_spec_CXX='$wl--export-dynamic' - whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - ;; - cxx*) - # Compaq C++ - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec_CXX='-rpath $libdir' - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' - ;; - xl* | mpixl* | bgxl*) - # IBM XL 8.0 on PPC, with GNU ld - hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' - export_dynamic_flag_spec_CXX='$wl--export-dynamic' - archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - if test yes = "$supports_anon_versioning"; then - archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) - # Sun C++ 5.9 - no_undefined_flag_CXX=' -zdefs' - archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' - hardcode_libdir_flag_spec_CXX='-R$libdir' - whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - compiler_needs_object_CXX=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - esac - ;; - - lynxos*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - m88k*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - hardcode_libdir_flag_spec_CXX='-R$libdir' - hardcode_direct_CXX=yes - hardcode_shlibpath_var_CXX=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - - *nto* | *qnx*) - ld_shlibs_CXX=yes - ;; - - openbsd* | bitrig*) - if test -f /usr/libexec/ld.so; then - hardcode_direct_CXX=yes - hardcode_shlibpath_var_CXX=no - hardcode_direct_absolute_CXX=yes - archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then - archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' - export_dynamic_flag_spec_CXX='$wl-E' - whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - fi - output_verbose_link_cmd=func_echo_all - else - ld_shlibs_CXX=no - fi - ;; - - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' - hardcode_libdir_separator_CXX=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - cxx*) - case $host in - osf3*) - allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' - archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' - ;; - *) - allow_undefined_flag_CXX=' -expect_unresolved \*' - archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ - $RM $lib.exp' - hardcode_libdir_flag_spec_CXX='-rpath $libdir' - ;; - esac - - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes,no = "$GXX,$with_gnu_ld"; then - allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' - case $host in - osf3*) - archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - ;; - *) - archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - ;; - esac - - hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' - hardcode_libdir_separator_CXX=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - archive_cmds_need_lc_CXX=yes - no_undefined_flag_CXX=' -zdefs' - archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - hardcode_libdir_flag_spec_CXX='-R$libdir' - hardcode_shlibpath_var_CXX=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands '-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' - ;; - esac - link_all_deplibs_CXX=yes - - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test yes,no = "$GXX,$with_gnu_ld"; then - no_undefined_flag_CXX=' $wl-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - else - # g++ 2.7 appears to require '-G' NOT '-shared' on this - # platform. - archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - fi - - hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir' - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag_CXX='$wl-z,text' - archive_cmds_need_lc_CXX=no - hardcode_shlibpath_var_CXX=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We CANNOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag_CXX='$wl-z,text' - allow_undefined_flag_CXX='$wl-z,nodefs' - archive_cmds_need_lc_CXX=no - hardcode_shlibpath_var_CXX=no - hardcode_libdir_flag_spec_CXX='$wl-R,$libdir' - hardcode_libdir_separator_CXX=':' - link_all_deplibs_CXX=yes - export_dynamic_flag_spec_CXX='$wl-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ - '"$old_archive_cmds_CXX" - reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ - '"$reload_cmds_CXX" - ;; - *) - archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - - *) - # FIXME: insert proper C++ library support - ld_shlibs_CXX=no - ;; - esac - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 -printf "%s\n" "$ld_shlibs_CXX" >&6; } - test no = "$ld_shlibs_CXX" && can_build_shared=no - - GCC_CXX=$GXX - LD_CXX=$LD - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - # Dependencies to place before and after the object being linked: -predep_objects_CXX= -postdep_objects_CXX= -predeps_CXX= -postdeps_CXX= -compiler_lib_search_path_CXX= - -cat > conftest.$ac_ext <<_LT_EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -_LT_EOF - - -_lt_libdeps_save_CFLAGS=$CFLAGS -case "$CC $CFLAGS " in #( -*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; -*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; -*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; -esac - -if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - for p in `eval "$output_verbose_link_cmd"`; do - case $prev$p in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test x-L = "$p" || - test x-R = "$p"; then - prev=$p - continue - fi - - # Expand the sysroot to ease extracting the directories later. - if test -z "$prev"; then - case $p in - -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; - -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; - -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; - esac - fi - case $p in - =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; - esac - if test no = "$pre_test_object_deps_done"; then - case $prev in - -L | -R) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$compiler_lib_search_path_CXX"; then - compiler_lib_search_path_CXX=$prev$p - else - compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$postdeps_CXX"; then - postdeps_CXX=$prev$p - else - postdeps_CXX="${postdeps_CXX} $prev$p" - fi - fi - prev= - ;; - - *.lto.$objext) ;; # Ignore GCC LTO objects - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test no = "$pre_test_object_deps_done"; then - if test -z "$predep_objects_CXX"; then - predep_objects_CXX=$p - else - predep_objects_CXX="$predep_objects_CXX $p" - fi - else - if test -z "$postdep_objects_CXX"; then - postdep_objects_CXX=$p - else - postdep_objects_CXX="$postdep_objects_CXX $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling CXX test program" -fi - -$RM -f confest.$objext -CFLAGS=$_lt_libdeps_save_CFLAGS - -# PORTME: override above test on systems where it is broken -case $host_os in -interix[3-9]*) - # Interix 3.5 installs completely hosed .la files for C++, so rather than - # hack all around it, let's just trust "g++" to DTRT. - predep_objects_CXX= - postdep_objects_CXX= - postdeps_CXX= - ;; -esac - - -case " $postdeps_CXX " in -*" -lc "*) archive_cmds_need_lc_CXX=no ;; -esac - compiler_lib_search_dirs_CXX= -if test -n "${compiler_lib_search_path_CXX}"; then - compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'` -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - lt_prog_compiler_wl_CXX= -lt_prog_compiler_pic_CXX= -lt_prog_compiler_static_CXX= - - - # C++ specific cases for pic, static, wl, etc. - if test yes = "$GXX"; then - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_CXX='-Bstatic' - fi - lt_prog_compiler_pic_CXX='-fPIC' - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic_CXX='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the '-m68020' flag to GCC prevents building anything better, - # like '-m68040'. - lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic_CXX='-DDLL_EXPORT' - case $host_os in - os2*) - lt_prog_compiler_static_CXX='$wl-static' - ;; - esac - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic_CXX='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - lt_prog_compiler_pic_CXX= - ;; - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - lt_prog_compiler_static_CXX= - ;; - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic_CXX=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - lt_prog_compiler_pic_CXX='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic_CXX='-fPIC -shared' - ;; - *) - lt_prog_compiler_pic_CXX='-fPIC' - ;; - esac - else - case $host_os in - aix[4-9]*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static_CXX='-Bstatic' - else - lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic_CXX='-DDLL_EXPORT' - ;; - dgux*) - case $cc_basename in - ec++*) - lt_prog_compiler_pic_CXX='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - lt_prog_compiler_pic_CXX='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly* | midnightbsd*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='$wl-a ${wl}archive' - if test ia64 != "$host_cpu"; then - lt_prog_compiler_pic_CXX='+Z' - fi - ;; - aCC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='$wl-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic_CXX='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_static_CXX='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - lt_prog_compiler_wl_CXX='--backend -Wl,' - lt_prog_compiler_pic_CXX='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64, which still supported -KPIC. - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-fPIC' - lt_prog_compiler_static_CXX='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-fpic' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - lt_prog_compiler_pic_CXX= - lt_prog_compiler_static_CXX='-non_shared' - ;; - xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) - # IBM XL 8.0, 9.0 on PPC and BlueGene - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-qpic' - lt_prog_compiler_static_CXX='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) - # Sun C++ 5.9 - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - lt_prog_compiler_wl_CXX='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - lt_prog_compiler_pic_CXX='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic_CXX='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - lt_prog_compiler_wl_CXX='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - lt_prog_compiler_pic_CXX='-pic' - ;; - cxx*) - # Digital/Compaq C++ - lt_prog_compiler_wl_CXX='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - lt_prog_compiler_pic_CXX= - lt_prog_compiler_static_CXX='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - lt_prog_compiler_wl_CXX='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - lt_prog_compiler_pic_CXX='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - lt_prog_compiler_pic_CXX='-pic' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - lcc*) - # Lucid - lt_prog_compiler_pic_CXX='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - lt_prog_compiler_wl_CXX='-Wl,' - lt_prog_compiler_pic_CXX='-KPIC' - lt_prog_compiler_static_CXX='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - lt_prog_compiler_pic_CXX='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - lt_prog_compiler_can_build_shared_CXX=no - ;; - esac - fi - -case $host_os in - # For platforms that do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic_CXX= - ;; - *) - lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" - ;; -esac - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -printf %s "checking for $compiler option to produce PIC... " >&6; } -if test ${lt_cv_prog_compiler_pic_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 -printf "%s\n" "$lt_cv_prog_compiler_pic_CXX" >&6; } -lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$lt_prog_compiler_pic_CXX"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 -printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } -if test ${lt_cv_prog_compiler_pic_works_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_pic_works_CXX=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works_CXX=yes - fi - fi - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 -printf "%s\n" "$lt_cv_prog_compiler_pic_works_CXX" >&6; } - -if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then - case $lt_prog_compiler_pic_CXX in - "" | " "*) ;; - *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; - esac -else - lt_prog_compiler_pic_CXX= - lt_prog_compiler_can_build_shared_CXX=no -fi - -fi - - - - - -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if test ${lt_cv_prog_compiler_static_works_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_static_works_CXX=no - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works_CXX=yes - fi - else - lt_cv_prog_compiler_static_works_CXX=yes - fi - fi - $RM -r conftest* - LDFLAGS=$save_LDFLAGS - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 -printf "%s\n" "$lt_cv_prog_compiler_static_works_CXX" >&6; } - -if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then - : -else - lt_prog_compiler_static_CXX= -fi - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test ${lt_cv_prog_compiler_c_o_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_c_o_CXX=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_CXX=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 -printf "%s\n" "$lt_cv_prog_compiler_c_o_CXX" >&6; } - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test ${lt_cv_prog_compiler_c_o_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_prog_compiler_c_o_CXX=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o_CXX=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 -printf "%s\n" "$lt_cv_prog_compiler_c_o_CXX" >&6; } - - - - -hard_links=nottested -if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then - # do not overwrite the value of need_locks provided by the user - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -printf %s "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -printf "%s\n" "$hard_links" >&6; } - if test no = "$hard_links"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 -printf "%s\n" "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} - need_locks=warn - fi -else - need_locks=no -fi - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - case $host_os in - aix[4-9]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to GNU nm, but means don't demangle to AIX nm. - # Without the "-l" option, or with the "-B" option, AIX nm treats - # weak defined symbols like other global defined symbols, whereas - # GNU nm marks them as "W". - # While the 'weak' keyword is ignored in the Export File, we need - # it in the Import File for the 'aix-soname' feature, so we have - # to replace the "-B" option with "-P" for AIX nm. - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - export_symbols_cmds_CXX=$ltdll_cmds - ;; - cygwin* | mingw* | cegcc*) - case $cc_basename in - cl* | icl*) - exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - ;; - *) - export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' - exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' - ;; - esac - ;; - *) - export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 -printf "%s\n" "$ld_shlibs_CXX" >&6; } -test no = "$ld_shlibs_CXX" && can_build_shared=no - -with_gnu_ld_CXX=$with_gnu_ld - - - - - - -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc_CXX" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc_CXX=yes - - if test yes,yes = "$GCC,$enable_shared"; then - case $archive_cmds_CXX in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -printf %s "checking whether -lc should be explicitly linked in... " >&6; } -if test ${lt_cv_archive_cmds_need_lc_CXX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl_CXX - pic_flag=$lt_prog_compiler_pic_CXX - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag_CXX - allow_undefined_flag_CXX= - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 - (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - then - lt_cv_archive_cmds_need_lc_CXX=no - else - lt_cv_archive_cmds_need_lc_CXX=yes - fi - allow_undefined_flag_CXX=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 -printf "%s\n" "$lt_cv_archive_cmds_need_lc_CXX" >&6; } - archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX - ;; - esac - fi - ;; -esac - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -printf %s "checking dynamic linker characteristics... " >&6; } - -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=.so -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - - - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='$libname$release$shared_ext$major' - ;; - -aix[4-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test ia64 = "$host_cpu"; then - # AIX 5 supports IA64 - library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line '#! .'. This would cause the generated library to - # depend on '.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # Using Import Files as archive members, it is possible to support - # filename-based versioning of shared library archives on AIX. While - # this would work for both with and without runtime linking, it will - # prevent static linking of such archives. So we do filename-based - # shared library versioning with .so extension only, which is used - # when both runtime linking and shared linking is enabled. - # Unfortunately, runtime linking may impact performance, so we do - # not want this to be the default eventually. Also, we use the - # versioned .so libs for executables only if there is the -brtl - # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. - # To allow for filename-based versioning support, we need to create - # libNAME.so.V as an archive file, containing: - # *) an Import File, referring to the versioned filename of the - # archive as well as the shared archive member, telling the - # bitwidth (32 or 64) of that shared object, and providing the - # list of exported symbols of that shared object, eventually - # decorated with the 'weak' keyword - # *) the shared object with the F_LOADONLY flag set, to really avoid - # it being seen by the linker. - # At run time we better use the real file rather than another symlink, - # but for link time we create the symlink libNAME.so -> libNAME.so.V - - case $with_aix_soname,$aix_use_runtimelinking in - # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - aix,yes) # traditional libtool - dynamic_linker='AIX unversionable lib.so' - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - aix,no) # traditional AIX only - dynamic_linker='AIX lib.a(lib.so.V)' - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - ;; - svr4,*) # full svr4 only - dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,yes) # both, prefer svr4 - dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # unpreferred sharedlib libNAME.a needs extra handling - postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' - postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,no) # both, prefer aix - dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling - postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' - postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' - ;; - esac - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - esac - ;; - -beos*) - library_names_spec='$libname$shared_ext' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[45]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl* | *,icl*) - # Native MSVC or ICC - libname_spec='$name' - soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' - library_names_spec='$libname.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec=$LIB - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC and ICC wrapper - library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' - soname_spec='$libname$release$major$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly* | midnightbsd*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[23].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=no - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - if test 32 = "$HPUX_IA64_MODE"; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - sys_lib_dlsearch_path_spec=/usr/lib/hpux32 - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - sys_lib_dlsearch_path_spec=/usr/lib/hpux64 - fi - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[3-9]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test yes = "$lt_cv_prog_gnu_ld"; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" - sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -linux*android*) - version_type=none # Android doesn't support versioned libraries. - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext' - soname_spec='$libname$release$shared_ext' - finish_cmds= - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - dynamic_linker='Android linker' - # Don't embed -rpath directories since the linker doesn't support them. - hardcode_libdir_flag_spec_CXX='-L$libdir' - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - if test ${lt_cv_shlibpath_overrides_runpath+y} -then : - printf %s "(cached) " >&6 -else $as_nop - lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_try_link "$LINENO" -then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null -then : - lt_cv_shlibpath_overrides_runpath=yes -fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - -fi - - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - - # Ideally, we could use ldconfig to report *all* directores which are - # searched for libraries, however this is still not possible. Aside from not - # being certain /sbin/ldconfig is available, command - # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, - # even though it is searched at run-time. Try to do the best guess by - # appending ld.so.conf contents (and includes) to the search path. - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd* | bitrig*) - version_type=sunos - sys_lib_dlsearch_path_spec=/usr/lib - need_lib_prefix=no - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - need_version=no - else - need_version=yes - fi - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -os2*) - libname_spec='$name' - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - # OS/2 can only load a DLL with a base name of 8 characters or less. - soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; - v=$($ECHO $release$versuffix | tr -d .-); - n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); - $ECHO $n$v`$shared_ext' - library_names_spec='${libname}_dll.$libext' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=BEGINLIBPATH - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test yes = "$with_gnu_ld"; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec; then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' - soname_spec='$libname$shared_ext.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=sco - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test yes = "$with_gnu_ld"; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -printf "%s\n" "$dynamic_linker" >&6; } -test no = "$dynamic_linker" && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test yes = "$GCC"; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then - sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec -fi - -if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then - sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec -fi - -# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... -configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec - -# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code -func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" - -# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool -configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -printf %s "checking how to hardcode library paths into programs... " >&6; } -hardcode_action_CXX= -if test -n "$hardcode_libdir_flag_spec_CXX" || - test -n "$runpath_var_CXX" || - test yes = "$hardcode_automatic_CXX"; then - - # We can hardcode non-existent directories. - if test no != "$hardcode_direct_CXX" && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" && - test no != "$hardcode_minus_L_CXX"; then - # Linking always hardcodes the temporary library directory. - hardcode_action_CXX=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action_CXX=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action_CXX=unsupported -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 -printf "%s\n" "$hardcode_action_CXX" >&6; } - -if test relink = "$hardcode_action_CXX" || - test yes = "$inherit_rpath_CXX"; then - # Fast installation is not supported - enable_fast_install=no -elif test yes = "$shlibpath_overrides_runpath" || - test no = "$enable_shared"; then - # Fast installation is not necessary - enable_fast_install=needless -fi - - - - - - - - fi # test -n "$compiler" - - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test yes != "$_lt_caught_CXX_error" - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}gcc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="gcc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}cc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$ac_ct_CC" && break -done - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi - -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args. -set dummy ${ac_tool_prefix}clang; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_CC="${ac_tool_prefix}clang" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -printf "%s\n" "$CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "clang", so it can be a program name with args. -set dummy clang; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_CC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_CC="clang" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -printf "%s\n" "$ac_ct_CC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi - -fi - - -test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } - -# Provide some information about the compiler. -printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -for ac_option in --version -v -V -qversion -version; do - { { ac_try="$ac_compiler $ac_option >&5" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 -printf %s "checking whether the compiler supports GNU C... " >&6; } -if test ${ac_cv_c_compiler_gnu+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ -#ifndef __GNUC__ - choke me -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_compiler_gnu=yes -else $as_nop - ac_compiler_gnu=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } -ac_compiler_gnu=$ac_cv_c_compiler_gnu - -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+y} -ac_save_CFLAGS=$CFLAGS -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -printf %s "checking whether $CC accepts -g... " >&6; } -if test ${ac_cv_prog_cc_g+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_g=yes -else $as_nop - CFLAGS="" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - -else $as_nop - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_g=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -printf "%s\n" "$ac_cv_prog_cc_g" >&6; } -if test $ac_test_CFLAGS; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi -else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= - fi -fi -ac_prog_cc_stdc=no -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 -printf %s "checking for $CC option to enable C11 features... " >&6; } -if test ${ac_cv_prog_cc_c11+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c11=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c11_program -_ACEOF -for ac_arg in '' -std=gnu11 -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c11=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c11" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c11" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c11" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 -printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } - CC="$CC $ac_cv_prog_cc_c11" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 - ac_prog_cc_stdc=c11 -fi -fi -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 -printf %s "checking for $CC option to enable C99 features... " >&6; } -if test ${ac_cv_prog_cc_c99+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c99_program -_ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c99=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c99" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c99" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } - CC="$CC $ac_cv_prog_cc_c99" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 - ac_prog_cc_stdc=c99 -fi -fi -if test x$ac_prog_cc_stdc = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 -printf %s "checking for $CC option to enable C89 features... " >&6; } -if test ${ac_cv_prog_cc_c89+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_prog_cc_c89=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_c_conftest_c89_program -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_cc_c89=$ac_arg -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC -fi - -if test "x$ac_cv_prog_cc_c89" = xno -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } -else $as_nop - if test "x$ac_cv_prog_cc_c89" = x -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } -else $as_nop - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } - CC="$CC $ac_cv_prog_cc_c89" -fi - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 - ac_prog_cc_stdc=c89 -fi -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - - ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 -printf %s "checking whether $CC understands -c and -o together... " >&6; } -if test ${am_cv_prog_cc_c_o+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - - ; - return 0; -} -_ACEOF - # Make sure it works both with $CC and with simple cc. - # Following AC_PROG_CC_C_O, we do the test twice because some - # compilers refuse to overwrite an existing .o file with -o, - # though they will create one. - am_cv_prog_cc_c_o=yes - for am_i in 1 2; do - if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 - ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } \ - && test -f conftest2.$ac_objext; then - : OK - else - am_cv_prog_cc_c_o=no - break - fi - done - rm -f core conftest* - unset am_i -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 -printf "%s\n" "$am_cv_prog_cc_c_o" >&6; } -if test "$am_cv_prog_cc_c_o" != yes; then - # Losing compiler, so override with the script. - # FIXME: It is wrong to rewrite CC. - # But if we don't then we get into trouble of one sort or another. - # A longer-term fix would be to have automake use am__CC in this case, - # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" - CC="$am_aux_dir/compile $CC" -fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -depcc="$CC" am_compiler_list= - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -printf %s "checking dependency style of $depcc... " >&6; } -if test ${am_cv_CC_dependencies_compiler_type+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi - - -for ac_prog in 'bison -y' byacc -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_YACC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$YACC"; then - ac_cv_prog_YACC="$YACC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_YACC="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -YACC=$ac_cv_prog_YACC -if test -n "$YACC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 -printf "%s\n" "$YACC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$YACC" && break -done -test -n "$YACC" || YACC="yacc" - -if test "$YACC" = yacc; then - # Extract the first word of "yacc", so it can be a program name with args. -set dummy yacc; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_REALLY_YACC+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$REALLY_YACC"; then - ac_cv_prog_REALLY_YACC="$REALLY_YACC" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_REALLY_YACC="yacc" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -REALLY_YACC=$ac_cv_prog_REALLY_YACC -if test -n "$REALLY_YACC"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $REALLY_YACC" >&5 -printf "%s\n" "$REALLY_YACC" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - if test "$REALLY_YACC" = ""; then - as_fn_error $? "This program cannot be built unless a version of yacc is installed." "$LINENO" 5 - fi -fi -for ac_prog in flex lex -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_LEX+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$LEX"; then - ac_cv_prog_LEX="$LEX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_LEX="$ac_prog" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LEX=$ac_cv_prog_LEX -if test -n "$LEX"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5 -printf "%s\n" "$LEX" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - test -n "$LEX" && break -done -test -n "$LEX" || LEX=":" - - if test "x$LEX" != "x:"; then - cat >conftest.l <<_ACEOF -%{ -#ifdef __cplusplus -extern "C" -#endif -int yywrap(void); -%} -%% -a { ECHO; } -b { REJECT; } -c { yymore (); } -d { yyless (1); } -e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */ -#ifdef __cplusplus - yyless ((yyinput () != 0)); -#else - yyless ((input () != 0)); -#endif - } -f { unput (yytext[0]); } -. { BEGIN INITIAL; } -%% -#ifdef YYTEXT_POINTER -extern char *yytext; -#endif -int -yywrap (void) -{ - return 1; -} -int -main (void) -{ - return ! yylex (); -} -_ACEOF -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lex output file root" >&5 -printf %s "checking for lex output file root... " >&6; } -if test ${ac_cv_prog_lex_root+y} -then : - printf %s "(cached) " >&6 -else $as_nop - -ac_cv_prog_lex_root=unknown -{ { ac_try="$LEX conftest.l" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -printf "%s\n" "$ac_try_echo"; } >&5 - (eval "$LEX conftest.l") 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && -if test -f lex.yy.c; then - ac_cv_prog_lex_root=lex.yy -elif test -f lexyy.c; then - ac_cv_prog_lex_root=lexyy -fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5 -printf "%s\n" "$ac_cv_prog_lex_root" >&6; } -if test "$ac_cv_prog_lex_root" = unknown -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot find output from $LEX; giving up on $LEX" >&5 -printf "%s\n" "$as_me: WARNING: cannot find output from $LEX; giving up on $LEX" >&2;} - LEX=: LEXLIB= -fi -LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root - -if test ${LEXLIB+y} -then : - -else $as_nop - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lex library" >&5 -printf %s "checking for lex library... " >&6; } -if test ${ac_cv_lib_lex+y} -then : - printf %s "(cached) " >&6 -else $as_nop - - ac_save_LIBS="$LIBS" - ac_found=false - for ac_cv_lib_lex in 'none needed' -lfl -ll 'not found'; do - case $ac_cv_lib_lex in #( - 'none needed') : - ;; #( - 'not found') : - break ;; #( - *) : - LIBS="$ac_cv_lib_lex $ac_save_LIBS" ;; #( - *) : - ;; -esac - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -`cat $LEX_OUTPUT_ROOT.c` -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_found=: -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext - if $ac_found; then - break - fi - done - LIBS="$ac_save_LIBS" - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5 -printf "%s\n" "$ac_cv_lib_lex" >&6; } - if test "$ac_cv_lib_lex" = 'not found' -then : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: required lex library not found; giving up on $LEX" >&5 -printf "%s\n" "$as_me: WARNING: required lex library not found; giving up on $LEX" >&2;} - LEX=: LEXLIB= -elif test "$ac_cv_lib_lex" = 'none needed' -then : - LEXLIB='' -else $as_nop - LEXLIB=$ac_cv_lib_lex -fi - ac_save_LIBS="$LIBS" - LIBS= - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing yywrap" >&5 -printf %s "checking for library containing yywrap... " >&6; } -if test ${ac_cv_search_yywrap+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char yywrap (); -int -main (void) -{ -return yywrap (); - ; - return 0; -} -_ACEOF -for ac_lib in '' fl l -do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO" -then : - ac_cv_search_yywrap=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext - if test ${ac_cv_search_yywrap+y} -then : - break -fi -done -if test ${ac_cv_search_yywrap+y} -then : - -else $as_nop - ac_cv_search_yywrap=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_yywrap" >&5 -printf "%s\n" "$ac_cv_search_yywrap" >&6; } -ac_res=$ac_cv_search_yywrap -if test "$ac_res" != no -then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - LEXLIB="$LIBS" -fi - - LIBS="$ac_save_LIBS" -fi - - -if test "$LEX" != : -then : - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5 -printf %s "checking whether yytext is a pointer... " >&6; } -if test ${ac_cv_prog_lex_yytext_pointer+y} -then : - printf %s "(cached) " >&6 -else $as_nop - # POSIX says lex can declare yytext either as a pointer or an array; the -# default is implementation-dependent. Figure out which it is, since -# not all implementations provide the %pointer and %array declarations. -ac_cv_prog_lex_yytext_pointer=no -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - - #define YYTEXT_POINTER 1 -`cat $LEX_OUTPUT_ROOT.c` -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_prog_lex_yytext_pointer=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5 -printf "%s\n" "$ac_cv_prog_lex_yytext_pointer" >&6; } -if test $ac_cv_prog_lex_yytext_pointer = yes; then - -printf "%s\n" "#define YYTEXT_POINTER 1" >>confdefs.h - -fi - -fi -rm -f conftest.l $LEX_OUTPUT_ROOT.c - -fi -if test "$LEX" = :; then - LEX=${am_missing_run}flex -fi -if test "$LEX" != flex; then - as_fn_error $? "This program cannot be built unless flex is installed." "$LINENO" 5 -fi - - -# Checks for header files. -ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`printf "%s\n" "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 -printf %s "checking for $ac_hdr that defines DIR... " >&6; } -if eval test \${$as_ac_Header+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include <$ac_hdr> - -int -main (void) -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - eval "$as_ac_Header=yes" -else $as_nop - eval "$as_ac_Header=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -eval ac_res=\$$as_ac_Header - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -printf "%s\n" "$ac_res" >&6; } -if eval test \"x\$"$as_ac_Header"\" = x"yes" -then : - cat >>confdefs.h <<_ACEOF -#define `printf "%s\n" "HAVE_$ac_hdr" | $as_tr_cpp` 1 -_ACEOF - -ac_header_dirent=$ac_hdr; break -fi - -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -printf %s "checking for library containing opendir... " >&6; } -if test ${ac_cv_search_opendir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char opendir (); -int -main (void) -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dir -do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO" -then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext - if test ${ac_cv_search_opendir+y} -then : - break -fi -done -if test ${ac_cv_search_opendir+y} -then : - -else $as_nop - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -printf "%s\n" "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no -then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 -printf %s "checking for library containing opendir... " >&6; } -if test ${ac_cv_search_opendir+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char opendir (); -int -main (void) -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x -do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO" -then : - ac_cv_search_opendir=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext - if test ${ac_cv_search_opendir+y} -then : - break -fi -done -if test ${ac_cv_search_opendir+y} -then : - -else $as_nop - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 -printf "%s\n" "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no -then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -fi - -# Autoupdate added the next two lines to ensure that your configure -# script's behavior did not change. They are probably safe to remove. - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -printf %s "checking for egrep... " >&6; } -if test ${ac_cv_path_EGREP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_prog in egrep - do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - printf %s 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - printf "%s\n" 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_EGREP_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 - fi -else - ac_cv_path_EGREP=$EGREP -fi - - fi -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -printf "%s\n" "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" - - - -ac_fn_c_check_header_compile "$LINENO" "limits.h" "ac_cv_header_limits_h" "$ac_includes_default" -if test "x$ac_cv_header_limits_h" = xyes -then : - printf "%s\n" "#define HAVE_LIMITS_H 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "mntent.h" "ac_cv_header_mntent_h" "$ac_includes_default" -if test "x$ac_cv_header_mntent_h" = xyes -then : - printf "%s\n" "#define HAVE_MNTENT_H 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default" -if test "x$ac_cv_header_stdlib_h" = xyes -then : - printf "%s\n" "#define HAVE_STDLIB_H 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default" -if test "x$ac_cv_header_string_h" = xyes -then : - printf "%s\n" "#define HAVE_STRING_H 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_mount_h" = xyes -then : - printf "%s\n" "#define HAVE_SYS_MOUNT_H 1" >>confdefs.h - -fi -ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default" -if test "x$ac_cv_header_unistd_h" = xyes -then : - printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h - -fi - - -# Checks for typedefs, structures, and compiler characteristics. -ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" -if test "x$ac_cv_type__Bool" = xyes -then : - -printf "%s\n" "#define HAVE__BOOL 1" >>confdefs.h - - -fi - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 -printf %s "checking for stdbool.h that conforms to C99... " >&6; } -if test ${ac_cv_header_stdbool_h+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - - #ifndef __bool_true_false_are_defined - #error "__bool_true_false_are_defined is not defined" - #endif - char a[__bool_true_false_are_defined == 1 ? 1 : -1]; - - /* Regardless of whether this is C++ or "_Bool" is a - valid type name, "true" and "false" should be usable - in #if expressions and integer constant expressions, - and "bool" should be a valid type name. */ - - #if !true - #error "'true' is not true" - #endif - #if true != 1 - #error "'true' is not equal to 1" - #endif - char b[true == 1 ? 1 : -1]; - char c[true]; - - #if false - #error "'false' is not false" - #endif - #if false != 0 - #error "'false' is not equal to 0" - #endif - char d[false == 0 ? 1 : -1]; - - enum { e = false, f = true, g = false * true, h = true * 256 }; - - char i[(bool) 0.5 == true ? 1 : -1]; - char j[(bool) 0.0 == false ? 1 : -1]; - char k[sizeof (bool) > 0 ? 1 : -1]; - - struct sb { bool s: 1; bool t; } s; - char l[sizeof s.t > 0 ? 1 : -1]; - - /* The following fails for - HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ - bool m[h]; - char n[sizeof m == h * sizeof m[0] ? 1 : -1]; - char o[-1 - (bool) 0 < 0 ? 1 : -1]; - /* Catch a bug in an HP-UX C compiler. See - https://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html - https://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html - */ - bool p = true; - bool *pp = &p; - - /* C 1999 specifies that bool, true, and false are to be - macros, but C++ 2011 and later overrule this. */ - #if __cplusplus < 201103 - #ifndef bool - #error "bool is not defined" - #endif - #ifndef false - #error "false is not defined" - #endif - #ifndef true - #error "true is not defined" - #endif - #endif - - /* If _Bool is available, repeat with it all the tests - above that used bool. */ - #ifdef HAVE__BOOL - struct sB { _Bool s: 1; _Bool t; } t; - - char q[(_Bool) 0.5 == true ? 1 : -1]; - char r[(_Bool) 0.0 == false ? 1 : -1]; - char u[sizeof (_Bool) > 0 ? 1 : -1]; - char v[sizeof t.t > 0 ? 1 : -1]; - - _Bool w[h]; - char x[sizeof m == h * sizeof m[0] ? 1 : -1]; - char y[-1 - (_Bool) 0 < 0 ? 1 : -1]; - _Bool z = true; - _Bool *pz = &p; - #endif - -int -main (void) -{ - - bool ps = &s; - *pp |= p; - *pp |= ! p; - - #ifdef HAVE__BOOL - _Bool pt = &t; - *pz |= z; - *pz |= ! z; - #endif - - /* Refer to every declared value, so they cannot be - discarded as unused. */ - return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !j + !k - + !l + !m + !n + !o + !p + !pp + !ps - #ifdef HAVE__BOOL - + !q + !r + !u + !v + !w + !x + !y + !z + !pt - #endif - ); - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_header_stdbool_h=yes -else $as_nop - ac_cv_header_stdbool_h=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 -printf "%s\n" "$ac_cv_header_stdbool_h" >&6; } - -if test $ac_cv_header_stdbool_h = yes; then - -printf "%s\n" "#define HAVE_STDBOOL_H 1" >>confdefs.h - -fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 -printf %s "checking for an ANSI C-conforming const... " >&6; } -if test ${ac_cv_c_const+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ - -#ifndef __cplusplus - /* Ultrix mips cc rejects this sort of thing. */ - typedef int charset[2]; - const charset cs = { 0, 0 }; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* IBM XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this sort of thing. */ - char tx; - char *t = &tx; - char const *s = 0 ? (char *) 0 : (char const *) 0; - - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* IBM XL C 1.02.0.0 rejects this sort of thing, saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; } bx; - struct s *b = &bx; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_c_const=yes -else $as_nop - ac_cv_c_const=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 -printf "%s\n" "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -printf "%s\n" "#define const /**/" >>confdefs.h - -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -printf %s "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test ${ac_cv_prog_CPP+y} -then : - printf %s "(cached) " >&6 -else $as_nop - # Double quotes because $CC needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO" -then : - -else $as_nop - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO" -then : - # Broken: success on invalid input. -continue -else $as_nop - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok -then : - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -printf "%s\n" "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO" -then : - -else $as_nop - # Broken: fails on valid input. -continue -fi -rm -f conftest.err conftest.i conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -_ACEOF -if ac_fn_c_try_cpp "$LINENO" -then : - # Broken: success on invalid input. -continue -else $as_nop - # Passes both tests. -ac_preproc_ok=: -break -fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok -then : - -else $as_nop - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 -printf %s "checking for uid_t in sys/types.h... " >&6; } -if test ${ac_cv_type_uid_t+y} -then : - printf %s "(cached) " >&6 -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "uid_t" >/dev/null 2>&1 -then : - ac_cv_type_uid_t=yes -else $as_nop - ac_cv_type_uid_t=no -fi -rm -rf conftest* - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 -printf "%s\n" "$ac_cv_type_uid_t" >&6; } -if test $ac_cv_type_uid_t = no; then - -printf "%s\n" "#define uid_t int" >>confdefs.h - - -printf "%s\n" "#define gid_t int" >>confdefs.h - -fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -printf %s "checking for inline... " >&6; } -if test ${ac_cv_c_inline+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_cv_c_inline=no -for ac_kw in inline __inline__ __inline; do - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifndef __cplusplus -typedef int foo_t; -static $ac_kw foo_t static_foo (void) {return 0; } -$ac_kw foo_t foo (void) {return 0; } -#endif - -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_c_inline=$ac_kw -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - test "$ac_cv_c_inline" != no && break -done - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -printf "%s\n" "$ac_cv_c_inline" >&6; } - -case $ac_cv_c_inline in - inline | yes) ;; - *) - case $ac_cv_c_inline in - no) ac_val=;; - *) ac_val=$ac_cv_c_inline;; - esac - cat >>confdefs.h <<_ACEOF -#ifndef __cplusplus -#define inline $ac_val -#endif -_ACEOF - ;; -esac - -ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" -case $ac_cv_c_int64_t in #( - no|yes) ;; #( - *) - -printf "%s\n" "#define int64_t $ac_cv_c_int64_t" >>confdefs.h -;; -esac - - - ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default -" -if test "x$ac_cv_type_pid_t" = xyes -then : - -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - - #if defined _WIN64 && !defined __CYGWIN__ - LLP64 - #endif - -int -main (void) -{ - - ; - return 0; -} - -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_pid_type='int' -else $as_nop - ac_pid_type='__int64' -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - -printf "%s\n" "#define pid_t $ac_pid_type" >>confdefs.h - - -fi - - - -# Checks for library functions. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5 -printf %s "checking for working chown... " >&6; } -if test ${ac_cv_func_chown_works+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "$cross_compiling" = yes -then : - case "$host_os" in # (( - # Guess yes on glibc systems. - *-gnu*) ac_cv_func_chown_works=yes ;; - # If we don't know, assume the worst. - *) ac_cv_func_chown_works=no ;; - esac -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -#include - -int -main (void) -{ - char *f = "conftest.chown"; - struct stat before, after; - - if (creat (f, 0600) < 0) - return 1; - if (stat (f, &before) < 0) - return 1; - if (chown (f, (uid_t) -1, (gid_t) -1) == -1) - return 1; - if (stat (f, &after) < 0) - return 1; - return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid); - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO" -then : - ac_cv_func_chown_works=yes -else $as_nop - ac_cv_func_chown_works=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -rm -f conftest.chown - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5 -printf "%s\n" "$ac_cv_func_chown_works" >&6; } -if test $ac_cv_func_chown_works = yes; then - -printf "%s\n" "#define HAVE_CHOWN 1" >>confdefs.h - -fi - -# getmntent is in the standard C library on UNICOS, in -lsun on Irix 4, -# -lseq on Dynix/PTX, -lgen on Unixware. -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing getmntent" >&5 -printf %s "checking for library containing getmntent... " >&6; } -if test ${ac_cv_search_getmntent+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char getmntent (); -int -main (void) -{ -return getmntent (); - ; - return 0; -} -_ACEOF -for ac_lib in '' sun seq gen -do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO" -then : - ac_cv_search_getmntent=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext - if test ${ac_cv_search_getmntent+y} -then : - break -fi -done -if test ${ac_cv_search_getmntent+y} -then : - -else $as_nop - ac_cv_search_getmntent=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getmntent" >&5 -printf "%s\n" "$ac_cv_search_getmntent" >&6; } -ac_res=$ac_cv_search_getmntent -if test "$ac_res" != no -then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - ac_cv_func_getmntent=yes - -printf "%s\n" "#define HAVE_GETMNTENT 1" >>confdefs.h - -else $as_nop - ac_cv_func_getmntent=no -fi - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5 -printf %s "checking for GNU libc compatible malloc... " >&6; } -if test ${ac_cv_func_malloc_0_nonnull+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "$cross_compiling" = yes -then : - case "$host_os" in # (( - # Guess yes on platforms where we know the result. - *-gnu* | freebsd* | netbsd* | openbsd* | bitrig* \ - | hpux* | solaris* | cygwin* | mingw* | msys* ) - ac_cv_func_malloc_0_nonnull=yes ;; - # If we don't know, assume the worst. - *) ac_cv_func_malloc_0_nonnull=no ;; - esac -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -int -main (void) -{ -void *p = malloc (0); - int result = !p; - free (p); - return result; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO" -then : - ac_cv_func_malloc_0_nonnull=yes -else $as_nop - ac_cv_func_malloc_0_nonnull=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5 -printf "%s\n" "$ac_cv_func_malloc_0_nonnull" >&6; } -if test $ac_cv_func_malloc_0_nonnull = yes -then : - -printf "%s\n" "#define HAVE_MALLOC 1" >>confdefs.h - -else $as_nop - printf "%s\n" "#define HAVE_MALLOC 0" >>confdefs.h - - case " $LIBOBJS " in - *" malloc.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS malloc.$ac_objext" - ;; -esac - - -printf "%s\n" "#define malloc rpl_malloc" >>confdefs.h - -fi - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible realloc" >&5 -printf %s "checking for GNU libc compatible realloc... " >&6; } -if test ${ac_cv_func_realloc_0_nonnull+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "$cross_compiling" = yes -then : - case "$host_os" in # (( - # Guess yes on platforms where we know the result. - *-gnu* | freebsd* | netbsd* | openbsd* | bitrig* \ - | hpux* | solaris* | cygwin* | mingw* | msys* ) - ac_cv_func_realloc_0_nonnull=yes ;; - # If we don't know, assume the worst. - *) ac_cv_func_realloc_0_nonnull=no ;; - esac -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -int -main (void) -{ -void *p = realloc (0, 0); - int result = !p; - free (p); - return result; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO" -then : - ac_cv_func_realloc_0_nonnull=yes -else $as_nop - ac_cv_func_realloc_0_nonnull=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_realloc_0_nonnull" >&5 -printf "%s\n" "$ac_cv_func_realloc_0_nonnull" >&6; } -if test $ac_cv_func_realloc_0_nonnull = yes -then : - -printf "%s\n" "#define HAVE_REALLOC 1" >>confdefs.h - -else $as_nop - printf "%s\n" "#define HAVE_REALLOC 0" >>confdefs.h - - case " $LIBOBJS " in - *" realloc.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS realloc.$ac_objext" - ;; -esac - - -printf "%s\n" "#define realloc rpl_realloc" >>confdefs.h - -fi - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5 -printf %s "checking whether lstat correctly handles trailing slash... " >&6; } -if test ${ac_cv_func_lstat_dereferences_slashed_symlink+y} -then : - printf %s "(cached) " >&6 -else $as_nop - rm -f conftest.sym conftest.file -echo >conftest.file -if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then - if test "$cross_compiling" = yes -then : - case "$host_os" in # (( - # Guess yes on glibc systems. - *-gnu*) ac_cv_func_lstat_dereferences_slashed_symlink=yes ;; - # If we don't know, assume the worst. - *) ac_cv_func_lstat_dereferences_slashed_symlink=no ;; - esac -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -int -main (void) -{ -struct stat sbuf; - /* Linux will dereference the symlink and fail, as required by POSIX. - That is better in the sense that it means we will not - have to compile and use the lstat wrapper. */ - return lstat ("conftest.sym/", &sbuf) == 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO" -then : - ac_cv_func_lstat_dereferences_slashed_symlink=yes -else $as_nop - ac_cv_func_lstat_dereferences_slashed_symlink=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -else - # If the `ln -s' command failed, then we probably don't even - # have an lstat function. - ac_cv_func_lstat_dereferences_slashed_symlink=no -fi -rm -f conftest.sym conftest.file - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 -printf "%s\n" "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; } - -test $ac_cv_func_lstat_dereferences_slashed_symlink = yes && - -printf "%s\n" "#define LSTAT_FOLLOWS_SLASHED_SYMLINK 1" >>confdefs.h - - -if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then - case " $LIBOBJS " in - *" lstat.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS lstat.$ac_objext" - ;; -esac - -fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stat accepts an empty string" >&5 -printf %s "checking whether stat accepts an empty string... " >&6; } -if test ${ac_cv_func_stat_empty_string_bug+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test "$cross_compiling" = yes -then : - ac_cv_func_stat_empty_string_bug=yes -else $as_nop - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$ac_includes_default -int -main (void) -{ -struct stat sbuf; - return stat ("", &sbuf) == 0; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO" -then : - ac_cv_func_stat_empty_string_bug=no -else $as_nop - ac_cv_func_stat_empty_string_bug=yes -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_stat_empty_string_bug" >&5 -printf "%s\n" "$ac_cv_func_stat_empty_string_bug" >&6; } -if test $ac_cv_func_stat_empty_string_bug = yes; then - case " $LIBOBJS " in - *" stat.$ac_objext "* ) ;; - *) LIBOBJS="$LIBOBJS stat.$ac_objext" - ;; -esac - - -printf "%s\n" "#define HAVE_STAT_EMPTY_STRING_BUG 1" >>confdefs.h - -fi - -ac_fn_c_check_func "$LINENO" "getmntent" "ac_cv_func_getmntent" -if test "x$ac_cv_func_getmntent" = xyes -then : - printf "%s\n" "#define HAVE_GETMNTENT 1" >>confdefs.h - -fi -ac_fn_c_check_func "$LINENO" "hasmntopt" "ac_cv_func_hasmntopt" -if test "x$ac_cv_func_hasmntopt" = xyes -then : - printf "%s\n" "#define HAVE_HASMNTOPT 1" >>confdefs.h - -fi -ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset" -if test "x$ac_cv_func_memset" = xyes -then : - printf "%s\n" "#define HAVE_MEMSET 1" >>confdefs.h - -fi -ac_fn_c_check_func "$LINENO" "mkdir" "ac_cv_func_mkdir" -if test "x$ac_cv_func_mkdir" = xyes -then : - printf "%s\n" "#define HAVE_MKDIR 1" >>confdefs.h - -fi -ac_fn_c_check_func "$LINENO" "rmdir" "ac_cv_func_rmdir" -if test "x$ac_cv_func_rmdir" = xyes -then : - printf "%s\n" "#define HAVE_RMDIR 1" >>confdefs.h - -fi -ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" -if test "x$ac_cv_func_strdup" = xyes -then : - printf "%s\n" "#define HAVE_STRDUP 1" >>confdefs.h - -fi - - -orig_CFLAGS="$CFLAGS" -CFLAGS="$CFLAGS -D_GNU_SOURCE" -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5 -printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; } -if test ${ac_cv_c_undeclared_builtin_options+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_save_CFLAGS=$CFLAGS - ac_cv_c_undeclared_builtin_options='cannot detect' - for ac_arg in '' -fno-builtin; do - CFLAGS="$ac_save_CFLAGS $ac_arg" - # This test program should *not* compile successfully. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main (void) -{ -(void) strchr; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - -else $as_nop - # This test program should compile successfully. - # No library function is consistently available on - # freestanding implementations, so test against a dummy - # declaration. Include always-available headers on the - # off chance that they somehow elicit warnings. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#include -#include -extern void ac_decl (int, char *); - -int -main (void) -{ -(void) ac_decl (0, (char *) 0); - (void) ac_decl; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - if test x"$ac_arg" = x -then : - ac_cv_c_undeclared_builtin_options='none needed' -else $as_nop - ac_cv_c_undeclared_builtin_options=$ac_arg -fi - break -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - done - CFLAGS=$ac_save_CFLAGS - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5 -printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; } - case $ac_cv_c_undeclared_builtin_options in #( - 'cannot detect') : - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot make $CC report undeclared builtins -See \`config.log' for more details" "$LINENO" 5; } ;; #( - 'none needed') : - ac_c_undeclared_builtin_options='' ;; #( - *) : - ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;; -esac - -ac_fn_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS" -if test "x$ac_cv_have_decl_strerror_r" = xyes -then : - ac_have_decl=1 -else $as_nop - ac_have_decl=0 -fi -printf "%s\n" "#define HAVE_DECL_STRERROR_R $ac_have_decl" >>confdefs.h - - -if test $ac_cv_have_decl_strerror_r = yes; then - # For backward compatibility's sake, define HAVE_STRERROR_R. - # (We used to run AC_CHECK_FUNCS_ONCE for strerror_r, as well - # as AC_CHECK_DECLS_ONCE.) - -printf "%s\n" "#define HAVE_STRERROR_R 1" >>confdefs.h - -fi - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5 -printf %s "checking whether strerror_r returns char *... " >&6; } -if test ${ac_cv_func_strerror_r_char_p+y} -then : - printf %s "(cached) " >&6 -else $as_nop - - ac_cv_func_strerror_r_char_p=no - if test $ac_cv_have_decl_strerror_r = yes; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main (void) -{ - - char buf[100]; - char x = *strerror_r (0, buf, sizeof buf); - char *p = strerror_r (0, buf, sizeof buf); - return !p || x; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO" -then : - ac_cv_func_strerror_r_char_p=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext - - fi - -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5 -printf "%s\n" "$ac_cv_func_strerror_r_char_p" >&6; } -if test $ac_cv_func_strerror_r_char_p = yes; then - -printf "%s\n" "#define STRERROR_R_CHAR_P 1" >>confdefs.h - -fi - -CFLAGS="$orig_CFLAGS" - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing fts_open" >&5 -printf %s "checking for library containing fts_open... " >&6; } -if test ${ac_cv_search_fts_open+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_func_search_save_LIBS=$LIBS -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char fts_open (); -int -main (void) -{ -return fts_open (); - ; - return 0; -} -_ACEOF -for ac_lib in '' fts -do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - if ac_fn_c_try_link "$LINENO" -then : - ac_cv_search_fts_open=$ac_res -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext - if test ${ac_cv_search_fts_open+y} -then : - break -fi -done -if test ${ac_cv_search_fts_open+y} -then : - -else $as_nop - ac_cv_search_fts_open=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fts_open" >&5 -printf "%s\n" "$ac_cv_search_fts_open" >&6; } -ac_res=$ac_cv_search_fts_open -if test "$ac_res" != no -then : - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -else $as_nop - as_fn_error $? "Unable to find the fts_open() function" "$LINENO" 5 -fi - - -if test x$with_pam = xtrue; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pam_syslog in -lpam" >&5 -printf %s "checking for pam_syslog in -lpam... " >&6; } -if test ${ac_cv_lib_pam_pam_syslog+y} -then : - printf %s "(cached) " >&6 -else $as_nop - ac_check_lib_save_LIBS=$LIBS -LIBS="-lpam $LIBS" -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -char pam_syslog (); -int -main (void) -{ -return pam_syslog (); - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO" -then : - ac_cv_lib_pam_pam_syslog=yes -else $as_nop - ac_cv_lib_pam_pam_syslog=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.beam \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_syslog" >&5 -printf "%s\n" "$ac_cv_lib_pam_pam_syslog" >&6; } -if test "x$ac_cv_lib_pam_pam_syslog" = xyes -then : - - : - -else $as_nop - as_fn_error $? "Cannot compile PAM module without libpam!" "$LINENO" 5 -fi - - - for ac_header in security/pam_modules.h security/pam_modutil.h security/pam_ext.h -do : - as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -if eval test \"x\$"$as_ac_Header"\" = x"yes" -then : - cat >>confdefs.h <<_ACEOF -#define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -else $as_nop - as_fn_error $? "Cannot compile PAM module without necessary - header files!" "$LINENO" 5 -fi - -done -fi - - - - - # allow to override gcov location - -# Check whether --with-gcov was given. -if test ${with_gcov+y} -then : - withval=$with_gcov; _AX_CODE_COVERAGE_GCOV_PROG_WITH=$with_gcov -else $as_nop - _AX_CODE_COVERAGE_GCOV_PROG_WITH=gcov -fi - - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with code coverage support" >&5 -printf %s "checking whether to build with code coverage support... " >&6; } - # Check whether --enable-code-coverage was given. -if test ${enable_code_coverage+y} -then : - enableval=$enable_code_coverage; -else $as_nop - enable_code_coverage=no -fi - - - if test x$enable_code_coverage = xyes; then - CODE_COVERAGE_ENABLED_TRUE= - CODE_COVERAGE_ENABLED_FALSE='#' -else - CODE_COVERAGE_ENABLED_TRUE='#' - CODE_COVERAGE_ENABLED_FALSE= -fi - - CODE_COVERAGE_ENABLED=$enable_code_coverage - - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_code_coverage" >&5 -printf "%s\n" "$enable_code_coverage" >&6; } - - if test "$enable_code_coverage" = "yes" -then : - - # check for gcov - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}$_AX_CODE_COVERAGE_GCOV_PROG_WITH", so it can be a program name with args. -set dummy ${ac_tool_prefix}$_AX_CODE_COVERAGE_GCOV_PROG_WITH; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_GCOV+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$GCOV"; then - ac_cv_prog_GCOV="$GCOV" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_GCOV="${ac_tool_prefix}$_AX_CODE_COVERAGE_GCOV_PROG_WITH" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -GCOV=$ac_cv_prog_GCOV -if test -n "$GCOV"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5 -printf "%s\n" "$GCOV" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_GCOV"; then - ac_ct_GCOV=$GCOV - # Extract the first word of "$_AX_CODE_COVERAGE_GCOV_PROG_WITH", so it can be a program name with args. -set dummy $_AX_CODE_COVERAGE_GCOV_PROG_WITH; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_ac_ct_GCOV+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$ac_ct_GCOV"; then - ac_cv_prog_ac_ct_GCOV="$ac_ct_GCOV" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_GCOV="$_AX_CODE_COVERAGE_GCOV_PROG_WITH" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_GCOV=$ac_cv_prog_ac_ct_GCOV -if test -n "$ac_ct_GCOV"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GCOV" >&5 -printf "%s\n" "$ac_ct_GCOV" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - if test "x$ac_ct_GCOV" = x; then - GCOV=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - GCOV=$ac_ct_GCOV - fi -else - GCOV="$ac_cv_prog_GCOV" -fi - - if test "X$GCOV" = "X:" -then : - as_fn_error $? "gcov is needed to do coverage" "$LINENO" 5 -fi - - - if test "$GCC" = "no" -then : - - as_fn_error $? "not compiling with gcc, which is required for gcov code coverage" "$LINENO" 5 - -fi - - # Extract the first word of "lcov", so it can be a program name with args. -set dummy lcov; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_LCOV+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$LCOV"; then - ac_cv_prog_LCOV="$LCOV" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_LCOV="lcov" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -LCOV=$ac_cv_prog_LCOV -if test -n "$LCOV"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5 -printf "%s\n" "$LCOV" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - # Extract the first word of "genhtml", so it can be a program name with args. -set dummy genhtml; ac_word=$2 -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -printf %s "checking for $ac_word... " >&6; } -if test ${ac_cv_prog_GENHTML+y} -then : - printf %s "(cached) " >&6 -else $as_nop - if test -n "$GENHTML"; then - ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then - ac_cv_prog_GENHTML="genhtml" - printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -GENHTML=$ac_cv_prog_GENHTML -if test -n "$GENHTML"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5 -printf "%s\n" "$GENHTML" >&6; } -else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 -printf "%s\n" "no" >&6; } -fi - - - - if test -z "$LCOV" -then : - - as_fn_error $? "To enable code coverage reporting you must have lcov installed" "$LINENO" 5 - -fi - - if test -z "$GENHTML" -then : - - as_fn_error $? "Could not find genhtml from the lcov package" "$LINENO" 5 - -fi - - CODE_COVERAGE_CPPFLAGS="-DNDEBUG" - CODE_COVERAGE_CFLAGS="-O0 -g -fprofile-arcs -ftest-coverage" - CODE_COVERAGE_CXXFLAGS="-O0 -g -fprofile-arcs -ftest-coverage" - CODE_COVERAGE_LIBS="-lgcov" - CODE_COVERAGE_LDFLAGS="$CODE_COVERAGE_LIBS" - - - - - - - - CODE_COVERAGE_RULES_CHECK=' - -$(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) -k check - $(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) code-coverage-capture -' - CODE_COVERAGE_RULES_CAPTURE=' - $(code_coverage_v_lcov_cap)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --capture --output-file "$(CODE_COVERAGE_OUTPUT_FILE).tmp" --test-name "$(call code_coverage_sanitize,$(PACKAGE_NAME)-$(PACKAGE_VERSION))" --no-checksum --compat-libtool $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_OPTIONS) - $(code_coverage_v_lcov_ign)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --remove "$(CODE_COVERAGE_OUTPUT_FILE).tmp" "/tmp/*" $(CODE_COVERAGE_IGNORE_PATTERN) --output-file "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_RMOPTS) - -@rm -f $(CODE_COVERAGE_OUTPUT_FILE).tmp - $(code_coverage_v_genhtml)LANG=C $(GENHTML) $(code_coverage_quiet) $(addprefix --prefix ,$(CODE_COVERAGE_DIRECTORY)) --output-directory "$(CODE_COVERAGE_OUTPUT_DIRECTORY)" --title "$(PACKAGE_NAME)-$(PACKAGE_VERSION) Code Coverage" --legend --show-details "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_GENHTML_OPTIONS) - @echo "file://$(abs_builddir)/$(CODE_COVERAGE_OUTPUT_DIRECTORY)/index.html" -' - CODE_COVERAGE_RULES_CLEAN=' -clean: code-coverage-clean -distclean: code-coverage-clean -code-coverage-clean: - -$(LCOV) --directory $(top_builddir) -z - -rm -rf $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_FILE).tmp $(CODE_COVERAGE_OUTPUT_DIRECTORY) - -find . \( -name "*.gcda" -o -name "*.gcno" -o -name "*.gcov" \) -delete -' - -else $as_nop - - CODE_COVERAGE_RULES_CHECK=' - @echo "Need to reconfigure with --enable-code-coverage" -' - CODE_COVERAGE_RULES_CAPTURE="$CODE_COVERAGE_RULES_CHECK" - CODE_COVERAGE_RULES_CLEAN='' - -fi - -CODE_COVERAGE_RULES=' -# Code coverage -# -# Optional: -# - CODE_COVERAGE_DIRECTORY: Top-level directory for code coverage reporting. -# Multiple directories may be specified, separated by whitespace. -# (Default: $(top_builddir)) -# - CODE_COVERAGE_OUTPUT_FILE: Filename and path for the .info file generated -# by lcov for code coverage. (Default: -# $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info) -# - CODE_COVERAGE_OUTPUT_DIRECTORY: Directory for generated code coverage -# reports to be created. (Default: -# $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage) -# - CODE_COVERAGE_BRANCH_COVERAGE: Set to 1 to enforce branch coverage, -# set to 0 to disable it and leave empty to stay with the default. -# (Default: empty) -# - CODE_COVERAGE_LCOV_SHOPTS_DEFAULT: Extra options shared between both lcov -# instances. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE) -# - CODE_COVERAGE_LCOV_SHOPTS: Extra options to shared between both lcov -# instances. (Default: $CODE_COVERAGE_LCOV_SHOPTS_DEFAULT) -# - CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH: --gcov-tool pathtogcov -# - CODE_COVERAGE_LCOV_OPTIONS_DEFAULT: Extra options to pass to the -# collecting lcov instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH) -# - CODE_COVERAGE_LCOV_OPTIONS: Extra options to pass to the collecting lcov -# instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_DEFAULT) -# - CODE_COVERAGE_LCOV_RMOPTS_DEFAULT: Extra options to pass to the filtering -# lcov instance. (Default: empty) -# - CODE_COVERAGE_LCOV_RMOPTS: Extra options to pass to the filtering lcov -# instance. (Default: $CODE_COVERAGE_LCOV_RMOPTS_DEFAULT) -# - CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT: Extra options to pass to the -# genhtml instance. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE) -# - CODE_COVERAGE_GENHTML_OPTIONS: Extra options to pass to the genhtml -# instance. (Default: $CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT) -# - CODE_COVERAGE_IGNORE_PATTERN: Extra glob pattern of files to ignore -# -# The generated report will be titled using the $(PACKAGE_NAME) and -# $(PACKAGE_VERSION). In order to add the current git hash to the title, -# use the git-version-gen script, available online. - -# Optional variables -CODE_COVERAGE_DIRECTORY ?= $(top_builddir) -CODE_COVERAGE_OUTPUT_FILE ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info -CODE_COVERAGE_OUTPUT_DIRECTORY ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage -CODE_COVERAGE_BRANCH_COVERAGE ?= -CODE_COVERAGE_LCOV_SHOPTS_DEFAULT ?= $(if $(CODE_COVERAGE_BRANCH_COVERAGE),\ ---rc lcov_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE)) -CODE_COVERAGE_LCOV_SHOPTS ?= $(CODE_COVERAGE_LCOV_SHOPTS_DEFAULT) -CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH ?= --gcov-tool "$(GCOV)" -CODE_COVERAGE_LCOV_OPTIONS_DEFAULT ?= $(CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH) -CODE_COVERAGE_LCOV_OPTIONS ?= $(CODE_COVERAGE_LCOV_OPTIONS_DEFAULT) -CODE_COVERAGE_LCOV_RMOPTS_DEFAULT ?= -CODE_COVERAGE_LCOV_RMOPTS ?= $(CODE_COVERAGE_LCOV_RMOPTS_DEFAULT) -CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT ?=\ -$(if $(CODE_COVERAGE_BRANCH_COVERAGE),\ ---rc genhtml_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE)) -CODE_COVERAGE_GENHTML_OPTIONS ?= $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULTS) -CODE_COVERAGE_IGNORE_PATTERN ?= - -code_coverage_v_lcov_cap = $(code_coverage_v_lcov_cap_$(V)) -code_coverage_v_lcov_cap_ = $(code_coverage_v_lcov_cap_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_lcov_cap_0 = @echo " LCOV --capture"\ - $(CODE_COVERAGE_OUTPUT_FILE); -code_coverage_v_lcov_ign = $(code_coverage_v_lcov_ign_$(V)) -code_coverage_v_lcov_ign_ = $(code_coverage_v_lcov_ign_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_lcov_ign_0 = @echo " LCOV --remove /tmp/*"\ - $(CODE_COVERAGE_IGNORE_PATTERN); -code_coverage_v_genhtml = $(code_coverage_v_genhtml_$(V)) -code_coverage_v_genhtml_ = $(code_coverage_v_genhtml_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_genhtml_0 = @echo " GEN " $(CODE_COVERAGE_OUTPUT_DIRECTORY); -code_coverage_quiet = $(code_coverage_quiet_$(V)) -code_coverage_quiet_ = $(code_coverage_quiet_$(AM_DEFAULT_VERBOSITY)) -code_coverage_quiet_0 = --quiet - -# sanitizes the test-name: replaces with underscores: dashes and dots -code_coverage_sanitize = $(subst -,_,$(subst .,_,$(1))) - -# Use recursive makes in order to ignore errors during check -check-code-coverage:'"$CODE_COVERAGE_RULES_CHECK"' - -# Capture code coverage data -code-coverage-capture: code-coverage-capture-hook'"$CODE_COVERAGE_RULES_CAPTURE"' - -# Hook rule executed before code-coverage-capture, overridable by the user -code-coverage-capture-hook: - -'"$CODE_COVERAGE_RULES_CLEAN"' - -GITIGNOREFILES ?= -GITIGNOREFILES += $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_DIRECTORY) - -A''M_DISTCHECK_CONFIGURE_FLAGS ?= -A''M_DISTCHECK_CONFIGURE_FLAGS += --disable-code-coverage - -.PHONY: check-code-coverage code-coverage-capture code-coverage-capture-hook code-coverage-clean -' - - - - - -ac_config_files="$ac_config_files Makefile src/Makefile src/daemon/Makefile src/tools/Makefile src/pam/Makefile src/python/Makefile scripts/Makefile scripts/init.d/cgconfig scripts/init.d/cgred tests/Makefile tests/ftests/Makefile tests/gunit/Makefile samples/Makefile samples/c/Makefile samples/cmdline/Makefile samples/config/Makefile samples/python/Makefile include/Makefile include/libcgroup/init.h doc/Makefile doc/man/Makefile dist/Makefile libcgroup.pc" - -ac_config_files="$ac_config_files dist/libcgroup.spec:dist/libcgroup.spec.in" - -CFLAGS="$CFLAGS -Wall" -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. - -_ACEOF - -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \. - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - if test "x$cache_file" != "x/dev/null"; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -printf "%s\n" "$as_me: updating cache $cache_file" >&6;} - if test ! -f "$cache_file" || test -h "$cache_file"; then - cat confcache >"$cache_file" - else - case $cache_file in #( - */* | ?:*) - mv -f confcache "$cache_file"$$ && - mv -f "$cache_file"$$ "$cache_file" ;; #( - *) - mv -f confcache "$cache_file" ;; - esac - fi - fi - else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache - -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' - -DEFS=-DHAVE_CONFIG_H - -ac_libobjs= -ac_ltlibobjs= -U= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" - as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs - -LTLIBOBJS=$ac_ltlibobjs - - -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 -printf %s "checking that generated files are newer than configure... " >&6; } - if test -n "$am_sleep_pid"; then - # Hide warnings about reused PIDs. - wait $am_sleep_pid 2>/dev/null - fi - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5 -printf "%s\n" "done" >&6; } - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi - -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - as_fn_error $? "conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_TOOLS_TRUE}" && test -z "${WITH_TOOLS_FALSE}"; then - as_fn_error $? "conditional \"WITH_TOOLS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_PAM_TRUE}" && test -z "${WITH_PAM_FALSE}"; then - as_fn_error $? "conditional \"WITH_PAM\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_DAEMON_TRUE}" && test -z "${WITH_DAEMON_FALSE}"; then - as_fn_error $? "conditional \"WITH_DAEMON\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${ENABLE_PYTHON_TRUE}" && test -z "${ENABLE_PYTHON_FALSE}"; then - as_fn_error $? "conditional \"ENABLE_PYTHON\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_SYSTEMD_TRUE}" && test -z "${WITH_SYSTEMD_FALSE}"; then - as_fn_error $? "conditional \"WITH_SYSTEMD\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_INITSCRIPT_INSTALL_TRUE}" && test -z "${WITH_INITSCRIPT_INSTALL_FALSE}"; then - as_fn_error $? "conditional \"WITH_INITSCRIPT_INSTALL\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_TESTS_TRUE}" && test -z "${WITH_TESTS_FALSE}"; then - as_fn_error $? "conditional \"WITH_TESTS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${WITH_SAMPLES_TRUE}" && test -z "${WITH_SAMPLES_FALSE}"; then - as_fn_error $? "conditional \"WITH_SAMPLES\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi -if test -z "${CODE_COVERAGE_ENABLED_TRUE}" && test -z "${CODE_COVERAGE_ENABLED_FALSE}"; then - as_fn_error $? "conditional \"CODE_COVERAGE_ENABLED\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi - -: "${CONFIG_STATUS=./config.status}" -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;} -as_write_fail=0 -cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. - -debug=false -ac_cs_recheck=false -ac_cs_silent=false - -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 -## -------------------- ## -## M4sh Initialization. ## -## -------------------- ## - -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -as_nop=: -if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 -then : - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else $as_nop - case `(set -o) 2>/dev/null` in #( - *posix*) : - set -o posix ;; #( - *) : - ;; -esac -fi - - - -# Reset variables that may have inherited troublesome values from -# the environment. - -# IFS needs to be set, to space, tab, and newline, in precisely that order. -# (If _AS_PATH_WALK were called with IFS unset, it would have the -# side effect of setting IFS to empty, thus disabling word splitting.) -# Quoting is to prevent editors from complaining about space-tab. -as_nl=' -' -export as_nl -IFS=" "" $as_nl" - -PS1='$ ' -PS2='> ' -PS4='+ ' - -# Ensure predictable behavior from utilities with locale-dependent output. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# We cannot yet rely on "unset" to work, but we need these variables -# to be unset--not just set to an empty or harmless value--now, to -# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct -# also avoids known problems related to "unset" and subshell syntax -# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). -for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH -do eval test \${$as_var+y} \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done - -# Ensure that fds 0, 1, and 2 are open. -if (exec 3>&0) 2>/dev/null; then :; else exec 0&1) 2>/dev/null; then :; else exec 1>/dev/null; fi -if (exec 3>&2) ; then :; else exec 2>/dev/null; fi - -# The user is always right. -if ${PATH_SEPARATOR+false} :; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi - - -# Find who we are. Look in the path if we contain no directory separator. -as_myself= -case $0 in #(( - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - case $as_dir in #((( - '') as_dir=./ ;; - */) ;; - *) as_dir=$as_dir/ ;; - esac - test -r "$as_dir$0" && as_myself=$as_dir$0 && break - done -IFS=$as_save_IFS - - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - exit 1 -fi - - - -# as_fn_error STATUS ERROR [LINENO LOG_FD] -# ---------------------------------------- -# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are -# provided, also output the error to LOG_FD, referencing LINENO. Then exit the -# script with STATUS, using 1 if that was 0. -as_fn_error () -{ - as_status=$1; test $as_status -eq 0 && as_status=1 - if test "$4"; then - as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 - fi - printf "%s\n" "$as_me: error: $2" >&2 - as_fn_exit $as_status -} # as_fn_error - - - -# as_fn_set_status STATUS -# ----------------------- -# Set $? to STATUS, without forking. -as_fn_set_status () -{ - return $1 -} # as_fn_set_status - -# as_fn_exit STATUS -# ----------------- -# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. -as_fn_exit () -{ - set +e - as_fn_set_status $1 - exit $1 -} # as_fn_exit - -# as_fn_unset VAR -# --------------- -# Portably unset VAR. -as_fn_unset () -{ - { eval $1=; unset $1;} -} -as_unset=as_fn_unset - -# as_fn_append VAR VALUE -# ---------------------- -# Append the text in VALUE to the end of the definition contained in VAR. Take -# advantage of any shell optimizations that allow amortized linear growth over -# repeated appends, instead of the typical quadratic growth present in naive -# implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null -then : - eval 'as_fn_append () - { - eval $1+=\$2 - }' -else $as_nop - as_fn_append () - { - eval $1=\$$1\$2 - } -fi # as_fn_append - -# as_fn_arith ARG... -# ------------------ -# Perform arithmetic evaluation on the ARGs, and store the result in the -# global $as_val. Take advantage of shells that can avoid forks. The arguments -# must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null -then : - eval 'as_fn_arith () - { - as_val=$(( $* )) - }' -else $as_nop - as_fn_arith () - { - as_val=`expr "$@" || test $? -eq 1` - } -fi # as_fn_arith - - -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi - -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi - -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi - -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits - - -# Determine whether it's possible to make 'echo' print without a newline. -# These variables are no longer used directly by Autoconf, but are AC_SUBSTed -# for compatibility with existing Makefiles. -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - -# For backward compatibility with old third-party macros, we provide -# the shell variables $as_echo and $as_echo_n. New code should use -# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. -as_echo='printf %s\n' -as_echo_n='printf %s' - -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -pR' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -pR' - fi -else - as_ln_s='cp -pR' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null - - -# as_fn_mkdir_p -# ------------- -# Create "$as_dir" as a directory, including parents if necessary. -as_fn_mkdir_p () -{ - - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || eval $as_mkdir_p || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" - - -} # as_fn_mkdir_p -if mkdir -p . 2>/dev/null; then - as_mkdir_p='mkdir -p "$as_dir"' -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi - - -# as_fn_executable_p FILE -# ----------------------- -# Test if FILE is an executable regular file. -as_fn_executable_p () -{ - test -f "$1" && test -x "$1" -} # as_fn_executable_p -as_test_x='test -x' -as_executable_p=as_fn_executable_p - -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" - - -exec 6>&1 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## -_ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Save the log message, to keep $0 and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by libcgroup $as_me 3.1.0, which was -generated by GNU Autoconf 2.71. Invocation command line was - - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ - -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" - -_ACEOF - -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac - -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac - - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions -from templates according to the current configuration. Unless the files -and actions are specified as TAGs, all are instantiated by default. - -Usage: $0 [OPTION]... [TAG]... - - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - --config print configuration, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE - -Configuration files: -$config_files - -Configuration headers: -$config_headers - -Configuration commands: -$config_commands - -Report bugs to the package provider." - -_ACEOF -ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"` -ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"` -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config='$ac_cs_config_escaped' -ac_cs_version="\\ -libcgroup config.status 3.1.0 -configured by $0, generated by GNU Autoconf 2.71, - with options \\"\$ac_cs_config\\" - -Copyright (C) 2021 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." - -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=?*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - --*=) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg= - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - printf "%s\n" "$ac_cs_version"; exit ;; - --config | --confi | --conf | --con | --co | --c ) - printf "%s\n" "$ac_cs_config"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - '') as_fn_error $? "missing file argument" ;; - esac - as_fn_append CONFIG_FILES " '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - as_fn_append CONFIG_HEADERS " '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - as_fn_error $? "ambiguous option: \`$1' -Try \`$0 --help' for more information.";; - --help | --hel | -h ) - printf "%s\n" "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - - # This is an error. - -*) as_fn_error $? "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; - - *) as_fn_append ac_config_targets " $1" - ac_need_defaults=false ;; - - esac - shift -done - -ac_configure_extra_args= - -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi - -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - printf "%s\n" "$ac_log" -} >&5 - -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" - - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' -macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' -enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' -enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' -pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' -enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' -shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' -SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' -ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' -PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' -host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' -host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' -host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' -build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' -build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' -build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' -SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' -Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' -GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' -EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' -FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' -LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' -NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' -LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' -max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' -ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' -exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' -lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' -lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' -lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' -lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' -lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' -reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' -reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' -FILECMD='`$ECHO "$FILECMD" | $SED "$delay_single_quote_subst"`' -OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' -deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' -file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' -file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' -want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' -DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' -sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' -AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' -lt_ar_flags='`$ECHO "$lt_ar_flags" | $SED "$delay_single_quote_subst"`' -AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' -archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' -STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' -RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' -old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' -old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' -lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' -CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' -CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' -compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' -GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' -lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' -nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' -lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' -lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' -objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' -MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' -need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' -MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' -DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' -NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' -LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' -OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' -OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' -libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' -shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' -extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' -compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' -archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' -module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' -with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' -no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' -hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' -hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' -inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' -link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' -always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' -exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' -include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' -prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' -postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' -file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' -variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' -need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' -need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' -version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' -runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' -shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' -libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' -library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' -soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' -install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' -postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' -postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' -finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' -finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' -hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' -sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' -configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' -configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' -hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' -enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' -enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' -old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' -striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' -predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' -postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' -predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' -postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' -LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' -reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' -reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' -compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' -GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' -lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' -archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' -export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' -archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' -archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' -module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' -module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' -with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' -allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' -no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' -inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' -link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' -always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' -export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' -exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' -include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' -prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' -postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' -file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' -hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' -predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' -postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' -predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' -postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' -compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' - -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in SHELL \ -ECHO \ -PATH_SEPARATOR \ -SED \ -GREP \ -EGREP \ -FGREP \ -LD \ -NM \ -LN_S \ -lt_SP2NL \ -lt_NL2SP \ -reload_flag \ -FILECMD \ -OBJDUMP \ -deplibs_check_method \ -file_magic_cmd \ -file_magic_glob \ -want_nocaseglob \ -DLLTOOL \ -sharedlib_from_linklib_cmd \ -AR \ -archiver_list_spec \ -STRIP \ -RANLIB \ -CC \ -CFLAGS \ -compiler \ -lt_cv_sys_global_symbol_pipe \ -lt_cv_sys_global_symbol_to_cdecl \ -lt_cv_sys_global_symbol_to_import \ -lt_cv_sys_global_symbol_to_c_name_address \ -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ -lt_cv_nm_interface \ -nm_file_list_spec \ -lt_cv_truncate_bin \ -lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_pic \ -lt_prog_compiler_wl \ -lt_prog_compiler_static \ -lt_cv_prog_compiler_c_o \ -need_locks \ -MANIFEST_TOOL \ -DSYMUTIL \ -NMEDIT \ -LIPO \ -OTOOL \ -OTOOL64 \ -shrext_cmds \ -export_dynamic_flag_spec \ -whole_archive_flag_spec \ -compiler_needs_object \ -with_gnu_ld \ -allow_undefined_flag \ -no_undefined_flag \ -hardcode_libdir_flag_spec \ -hardcode_libdir_separator \ -exclude_expsyms \ -include_expsyms \ -file_list_spec \ -variables_saved_for_relink \ -libname_spec \ -library_names_spec \ -soname_spec \ -install_override_mode \ -finish_eval \ -old_striplib \ -striplib \ -compiler_lib_search_dirs \ -predep_objects \ -postdep_objects \ -predeps \ -postdeps \ -compiler_lib_search_path \ -LD_CXX \ -reload_flag_CXX \ -compiler_CXX \ -lt_prog_compiler_no_builtin_flag_CXX \ -lt_prog_compiler_pic_CXX \ -lt_prog_compiler_wl_CXX \ -lt_prog_compiler_static_CXX \ -lt_cv_prog_compiler_c_o_CXX \ -export_dynamic_flag_spec_CXX \ -whole_archive_flag_spec_CXX \ -compiler_needs_object_CXX \ -with_gnu_ld_CXX \ -allow_undefined_flag_CXX \ -no_undefined_flag_CXX \ -hardcode_libdir_flag_spec_CXX \ -hardcode_libdir_separator_CXX \ -exclude_expsyms_CXX \ -include_expsyms_CXX \ -file_list_spec_CXX \ -compiler_lib_search_dirs_CXX \ -predep_objects_CXX \ -postdep_objects_CXX \ -predeps_CXX \ -postdeps_CXX \ -compiler_lib_search_path_CXX; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in reload_cmds \ -old_postinstall_cmds \ -old_postuninstall_cmds \ -old_archive_cmds \ -extract_expsyms_cmds \ -old_archive_from_new_cmds \ -old_archive_from_expsyms_cmds \ -archive_cmds \ -archive_expsym_cmds \ -module_cmds \ -module_expsym_cmds \ -export_symbols_cmds \ -prelink_cmds \ -postlink_cmds \ -postinstall_cmds \ -postuninstall_cmds \ -finish_cmds \ -sys_lib_search_path_spec \ -configure_time_dlsearch_path \ -configure_time_lt_sys_library_path \ -reload_cmds_CXX \ -old_archive_cmds_CXX \ -old_archive_from_new_cmds_CXX \ -old_archive_from_expsyms_cmds_CXX \ -archive_cmds_CXX \ -archive_expsym_cmds_CXX \ -module_cmds_CXX \ -module_expsym_cmds_CXX \ -export_symbols_cmds_CXX \ -prelink_cmds_CXX \ -postlink_cmds_CXX; do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -ac_aux_dir='$ac_aux_dir' - -# See if we are running on zsh, and set the options that allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST -fi - - - PACKAGE='$PACKAGE' - VERSION='$VERSION' - RM='$RM' - ofile='$ofile' - - - - - - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; - "src/daemon/Makefile") CONFIG_FILES="$CONFIG_FILES src/daemon/Makefile" ;; - "src/tools/Makefile") CONFIG_FILES="$CONFIG_FILES src/tools/Makefile" ;; - "src/pam/Makefile") CONFIG_FILES="$CONFIG_FILES src/pam/Makefile" ;; - "src/python/Makefile") CONFIG_FILES="$CONFIG_FILES src/python/Makefile" ;; - "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; - "scripts/init.d/cgconfig") CONFIG_FILES="$CONFIG_FILES scripts/init.d/cgconfig" ;; - "scripts/init.d/cgred") CONFIG_FILES="$CONFIG_FILES scripts/init.d/cgred" ;; - "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; - "tests/ftests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/ftests/Makefile" ;; - "tests/gunit/Makefile") CONFIG_FILES="$CONFIG_FILES tests/gunit/Makefile" ;; - "samples/Makefile") CONFIG_FILES="$CONFIG_FILES samples/Makefile" ;; - "samples/c/Makefile") CONFIG_FILES="$CONFIG_FILES samples/c/Makefile" ;; - "samples/cmdline/Makefile") CONFIG_FILES="$CONFIG_FILES samples/cmdline/Makefile" ;; - "samples/config/Makefile") CONFIG_FILES="$CONFIG_FILES samples/config/Makefile" ;; - "samples/python/Makefile") CONFIG_FILES="$CONFIG_FILES samples/python/Makefile" ;; - "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; - "include/libcgroup/init.h") CONFIG_FILES="$CONFIG_FILES include/libcgroup/init.h" ;; - "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;; - "doc/man/Makefile") CONFIG_FILES="$CONFIG_FILES doc/man/Makefile" ;; - "dist/Makefile") CONFIG_FILES="$CONFIG_FILES dist/Makefile" ;; - "libcgroup.pc") CONFIG_FILES="$CONFIG_FILES libcgroup.pc" ;; - "dist/libcgroup.spec") CONFIG_FILES="$CONFIG_FILES dist/libcgroup.spec:dist/libcgroup.spec.in" ;; - - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; - esac -done - - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files - test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers - test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands -fi - -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= ac_tmp= - trap 'exit_status=$? - : "${ac_tmp:=$tmp}" - { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status -' 0 - trap 'as_fn_exit 1' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. - -{ - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 -ac_tmp=$tmp - -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then - - -ac_cr=`echo X | tr X '\015'` -# On cygwin, bash can eat \r inside `` if the user requested igncr. -# But we know of no other shell where ac_cr would be empty at this -# point, so we can use a bashism as a fallback. -if test "x$ac_cr" = x; then - eval ac_cr=\$\'\\r\' -fi -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\\r' -else - ac_cs_awk_cr=$ac_cr -fi - -echo 'BEGIN {' >"$ac_tmp/subs1.awk" && -_ACEOF - - -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done -rm -f conf$$subs.sh - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\)..*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\)..*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" - -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - - print line -} - -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" -else - cat -fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ - || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 -_ACEOF - -# VPATH may cause trouble with some makes, so we remove sole $(srcdir), -# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ -h -s/// -s/^/:/ -s/[ ]*$/:/ -s/:\$(srcdir):/:/g -s/:\${srcdir}:/:/g -s/:@srcdir@:/:/g -s/^:*// -s/:*$// -x -s/\(=[ ]*\).*/\1/ -G -s/\n// -s/^[^=]*=[ ]*$// -}' -fi - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" - -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$ac_tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF - -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. - -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_tt=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_tt"; then - break - elif $ac_last_try; then - as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " - fi -done - -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. - -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 -fi # test -n "$CONFIG_HEADERS" - - -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag -do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$ac_tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; - esac - case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - as_fn_append ac_file_inputs " '$ac_f'" - done - - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -printf "%s\n" "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`printf "%s\n" "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac - - case $ac_tag in - *:-:* | *:-) cat >"$ac_tmp/stdin" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; - esac - ;; - esac - - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - as_dir="$ac_dir"; as_fn_mkdir_p - ac_builddir=. - -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix - -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; -esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix - - - case $ac_mode in - :F) - # - # CONFIG_FILE - # - - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= -ac_sed_dataroot=' -/datarootdir/ { - p - q -} -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; -esac -_ACEOF - -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ - >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ - "$ac_tmp/out"`; test -z "$ac_out"; } && - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&5 -printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined" >&2;} - - rm -f "$ac_tmp/stdin" - case $ac_file in - -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; - *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; - esac \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - printf "%s\n" "/* $configure_input */" >&1 \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" - } >"$ac_tmp/config.h" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 -printf "%s\n" "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$ac_tmp/config.h" "$ac_file" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - fi - else - printf "%s\n" "/* $configure_input */" >&1 \ - && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ - || as_fn_error $? "could not create -" "$LINENO" 5 - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; - - :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -printf "%s\n" "$as_me: executing $ac_file commands" >&6;} - ;; - esac - - - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Older Autoconf quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - # TODO: see whether this extra hack can be removed once we start - # requiring Autoconf 2.70 or later. - case $CONFIG_FILES in #( - *\'*) : - eval set x "$CONFIG_FILES" ;; #( - *) : - set x $CONFIG_FILES ;; #( - *) : - ;; -esac - shift - # Used to flag and report bootstrapping failures. - am_rc=0 - for am_mf - do - # Strip MF so we end up with the name of the file. - am_mf=`printf "%s\n" "$am_mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile which includes - # dependency-tracking related rules and includes. - # Grep'ing the whole file directly is not great: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ - || continue - am_dirpart=`$as_dirname -- "$am_mf" || -$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$am_mf" : 'X\(//\)[^/]' \| \ - X"$am_mf" : 'X\(//\)$' \| \ - X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X"$am_mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - am_filepart=`$as_basename -- "$am_mf" || -$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ - X"$am_mf" : 'X\(//\)$' \| \ - X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -printf "%s\n" X/"$am_mf" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - { echo "$as_me:$LINENO: cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles" >&5 - (cd "$am_dirpart" \ - && sed -e '/# am--include-marker/d' "$am_filepart" \ - | $MAKE -f - am--depfiles) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } || am_rc=$? - done - if test $am_rc -ne 0; then - { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. If GNU make was not used, consider - re-running the configure script with MAKE=\"gmake\" (or whatever is - necessary). You can also try re-running configure with the - '--disable-dependency-tracking' option to at least be able to build - the package (albeit without support for automatic dependency tracking). -See \`config.log' for more details" "$LINENO" 5; } - fi - { am_dirpart=; unset am_dirpart;} - { am_filepart=; unset am_filepart;} - { am_mf=; unset am_mf;} - { am_rc=; unset am_rc;} - rm -f conftest-deps.mk -} - ;; - "libtool":C) - - # See if we are running on zsh, and set the options that allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST - fi - - cfgfile=${ofile}T - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL -# Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. - -# Provide generalized library-building support services. -# Written by Gordon Matzigkeit, 1996 - -# Copyright (C) 2014 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool 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 of the License, or -# (at your option) any later version. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program or library that is built -# using GNU Libtool, you may include this file under the same -# distribution terms that you use for the rest of that program. -# -# GNU Libtool 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, see . - - -# The names of the tagged configurations supported by this script. -available_tags='CXX ' - -# Configured defaults for sys_lib_dlsearch_path munging. -: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} - -# ### BEGIN LIBTOOL CONFIG - -# Which release of libtool.m4 was used? -macro_version=$macro_version -macro_revision=$macro_revision - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# What type of objects to build. -pic_mode=$pic_mode - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# Shared archive member basename,for filename based shared library versioning on AIX. -shared_archive_member_spec=$shared_archive_member_spec - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# An echo program that protects backslashes. -ECHO=$lt_ECHO - -# The PATH separator for the build system. -PATH_SEPARATOR=$lt_PATH_SEPARATOR - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="\$SED -e 1s/^X//" - -# A grep program that handles long lines. -GREP=$lt_GREP - -# An ERE matcher. -EGREP=$lt_EGREP - -# A literal string matcher. -FGREP=$lt_FGREP - -# A BSD- or MS-compatible name lister. -NM=$lt_NM - -# Whether we need soft or hard links. -LN_S=$lt_LN_S - -# What is the maximum length of a command? -max_cmd_len=$max_cmd_len - -# Object file suffix (normally "o"). -objext=$ac_objext - -# Executable file suffix (normally ""). -exeext=$exeext - -# whether the shell understands "unset". -lt_unset=$lt_unset - -# turn spaces into newlines. -SP2NL=$lt_lt_SP2NL - -# turn newlines into spaces. -NL2SP=$lt_lt_NL2SP - -# convert \$build file names to \$host format. -to_host_file_cmd=$lt_cv_to_host_file_cmd - -# convert \$build files to toolchain format. -to_tool_file_cmd=$lt_cv_to_tool_file_cmd - -# A file(cmd) program that detects file types. -FILECMD=$lt_FILECMD - -# An object symbol dumper. -OBJDUMP=$lt_OBJDUMP - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method = "file_magic". -file_magic_cmd=$lt_file_magic_cmd - -# How to find potential files when deplibs_check_method = "file_magic". -file_magic_glob=$lt_file_magic_glob - -# Find potential files using nocaseglob when deplibs_check_method = "file_magic". -want_nocaseglob=$lt_want_nocaseglob - -# DLL creation program. -DLLTOOL=$lt_DLLTOOL - -# Command to associate shared and link libraries. -sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd - -# The archiver. -AR=$lt_AR - -# Flags to create an archive (by configure). -lt_ar_flags=$lt_ar_flags - -# Flags to create an archive. -AR_FLAGS=\${ARFLAGS-"\$lt_ar_flags"} - -# How to feed a file listing to the archiver. -archiver_list_spec=$lt_archiver_list_spec - -# A symbol stripping program. -STRIP=$lt_STRIP - -# Commands used to install an old-style archive. -RANLIB=$lt_RANLIB -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Whether to use a lock for old archive extraction. -lock_old_archive_extraction=$lock_old_archive_extraction - -# A C compiler. -LTCC=$lt_CC - -# LTCC compiler flags. -LTCFLAGS=$lt_CFLAGS - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration. -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm into a list of symbols to manually relocate. -global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import - -# Transform the output of nm in a C name address pair. -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# Transform the output of nm in a C name address pair when lib prefix is needed. -global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix - -# The name lister interface. -nm_interface=$lt_lt_cv_nm_interface - -# Specify filename containing input files for \$NM. -nm_file_list_spec=$lt_nm_file_list_spec - -# The root where to search for dependent libraries,and where our libraries should be installed. -lt_sysroot=$lt_sysroot - -# Command to truncate a binary pipe. -lt_truncate_bin=$lt_lt_cv_truncate_bin - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# Used to examine libraries when file_magic_cmd begins with "file". -MAGIC_CMD=$MAGIC_CMD - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Manifest tool. -MANIFEST_TOOL=$lt_MANIFEST_TOOL - -# Tool to manipulate archived DWARF debug symbol files on Mac OS X. -DSYMUTIL=$lt_DSYMUTIL - -# Tool to change global to local symbols on Mac OS X. -NMEDIT=$lt_NMEDIT - -# Tool to manipulate fat objects and archives on Mac OS X. -LIPO=$lt_LIPO - -# ldd/readelf like tool for Mach-O binaries on Mac OS X. -OTOOL=$lt_OTOOL - -# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. -OTOOL64=$lt_OTOOL64 - -# Old archive suffix (normally "a"). -libext=$libext - -# Shared library suffix (normally ".so"). -shrext_cmds=$lt_shrext_cmds - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at link time. -variables_saved_for_relink=$lt_variables_saved_for_relink - -# Do we need the "lib" prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Library versioning type. -version_type=$version_type - -# Shared library runtime path variable. -runpath_var=$runpath_var - -# Shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Permission mode override for installation of shared libraries. -install_override_mode=$lt_install_override_mode - -# Command to use after installation of a shared archive. -postinstall_cmds=$lt_postinstall_cmds - -# Command to use after uninstallation of a shared archive. -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# As "finish_cmds", except a single script fragment to be evaled but -# not shown. -finish_eval=$lt_finish_eval - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Compile-time system search path for libraries. -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Detected run-time system search path for libraries. -sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path - -# Explicit LT_SYS_LIBRARY_PATH set during ./configure time. -configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - - -# The linker used to build libraries. -LD=$lt_LD - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds - -# A language specific compiler. -CC=$lt_compiler - -# Is the compiler the GNU compiler? -with_gcc=$GCC - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator - -# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct - -# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \$shlibpath_var if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action - -# The directories searched by this compiler when creating a shared library. -compiler_lib_search_dirs=$lt_compiler_lib_search_dirs - -# Dependencies to place before and after the objects being linked to -# create a shared library. -predep_objects=$lt_predep_objects -postdep_objects=$lt_postdep_objects -predeps=$lt_predeps -postdeps=$lt_postdeps - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path - -# ### END LIBTOOL CONFIG - -_LT_EOF - - cat <<'_LT_EOF' >> "$cfgfile" - -# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE - -# func_munge_path_list VARIABLE PATH -# ----------------------------------- -# VARIABLE is name of variable containing _space_ separated list of -# directories to be munged by the contents of PATH, which is string -# having a format: -# "DIR[:DIR]:" -# string "DIR[ DIR]" will be prepended to VARIABLE -# ":DIR[:DIR]" -# string "DIR[ DIR]" will be appended to VARIABLE -# "DIRP[:DIRP]::[DIRA:]DIRA" -# string "DIRP[ DIRP]" will be prepended to VARIABLE and string -# "DIRA[ DIRA]" will be appended to VARIABLE -# "DIR[:DIR]" -# VARIABLE will be replaced by "DIR[ DIR]" -func_munge_path_list () -{ - case x$2 in - x) - ;; - *:) - eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" - ;; - x:*) - eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" - ;; - *::*) - eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" - eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" - ;; - *) - eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" - ;; - esac -} - - -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -func_cc_basename () -{ - for cc_temp in $*""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac - done - func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` -} - - -# ### END FUNCTIONS SHARED WITH CONFIGURE - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test set != "${COLLECT_NAMES+set}"; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - - -ltmain=$ac_aux_dir/ltmain.sh - - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - $SED '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - - - cat <<_LT_EOF >> "$ofile" - -# ### BEGIN LIBTOOL TAG CONFIG: CXX - -# The linker used to build libraries. -LD=$lt_LD_CXX - -# How to create reloadable object files. -reload_flag=$lt_reload_flag_CXX -reload_cmds=$lt_reload_cmds_CXX - -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds_CXX - -# A language specific compiler. -CC=$lt_compiler_CXX - -# Is the compiler the GNU compiler? -with_gcc=$GCC_CXX - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX - -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic_CXX - -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl_CXX - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static_CXX - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc_CXX - -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX - -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object_CXX - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX - -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds_CXX -archive_expsym_cmds=$lt_archive_expsym_cmds_CXX - -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds_CXX -module_expsym_cmds=$lt_module_expsym_cmds_CXX - -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld_CXX - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag_CXX - -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag_CXX - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX - -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX - -# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct_CXX - -# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \$shlibpath_var if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute_CXX - -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L_CXX - -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX - -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic_CXX - -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath_CXX - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs_CXX - -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols_CXX - -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds_CXX - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms_CXX - -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms_CXX - -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds_CXX - -# Commands necessary for finishing linking programs. -postlink_cmds=$lt_postlink_cmds_CXX - -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec_CXX - -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action_CXX - -# The directories searched by this compiler when creating a shared library. -compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX - -# Dependencies to place before and after the objects being linked to -# create a shared library. -predep_objects=$lt_predep_objects_CXX -postdep_objects=$lt_postdep_objects_CXX -predeps=$lt_predeps_CXX -postdeps=$lt_postdeps_CXX - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_compiler_lib_search_path_CXX - -# ### END LIBTOOL TAG CONFIG: CXX -_LT_EOF - - ;; - - esac -done # for ac_tag - - -as_fn_exit 0 -_ACEOF -ac_clean_files=$ac_clean_files_save - -test $ac_write_fail = 0 || - as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 - - -# configure is writing to config.log, and then calls config.status. -# config.status does its own redirection, appending to config.log. -# Unfortunately, on DOS this fails, as config.log is still kept open -# by configure, so config.status won't be able to write to it; its -# output is simply discarded. So we exec the FD to /dev/null, -# effectively closing config.log, so it can be properly (re)opened and -# appended to by config.status. When coming back to configure, we -# need to make the FD available again. -if test "$no_create" != yes; then - ac_cs_success=: - ac_config_status_args= - test "$silent" = yes && - ac_config_status_args="$ac_config_status_args --quiet" - exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false - exec 5>>config.log - # Use ||, not &&, to avoid exiting from the if with $? = 1, which - # would make configure fail if this is the last instruction. - $ac_cs_success || as_fn_exit 1 -fi -if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} -fi - - diff --git a/lib/libcgroup-3.1.0/configure.ac b/lib/libcgroup-3.1.0/configure.ac deleted file mode 100644 index 341a5756c42..00000000000 --- a/lib/libcgroup-3.1.0/configure.ac +++ /dev/null @@ -1,266 +0,0 @@ -# -*- Autoconf -*- -# SPDX-License-Identifier: LGPL-2.1-only -# Process this file with autoconf to produce a configure script. -# -# Copyright International Business Machines Corp. 2008 -# -# Authors: Balbir Singh -# -AC_PREREQ([2.69]) - -# In following section update all occurences of version, including soname -AC_INIT([libcgroup],[3.1.0]) - -AC_CONFIG_AUX_DIR([build-aux]) -AC_CONFIG_MACRO_DIRS([m4]) - -AM_INIT_AUTOMAKE([foreign dist-bzip2 subdir-objects]) - -m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) - -# set library version, soname is libcgroup.so.MAJOR -AC_SUBST(LIBRARY_VERSION_MAJOR, 3) -AC_SUBST(LIBRARY_VERSION_MINOR, 1) -AC_SUBST(LIBRARY_VERSION_RELEASE, 0) - -# we do not want static libraries -#AC_DISABLE_STATIC - -AM_PROG_AR -LT_INIT - -AC_CONFIG_SRCDIR([src]) -AC_CONFIG_HEADER([config.h]) - -# Process command line options -AC_ARG_ENABLE([tools], - [AS_HELP_STRING([--enable-tools],[compile libcgroup tools [default=yes]])], - [ - if test "x$enableval" = xno; then - with_tools=false - else - with_tools=true - fi - ], - [with_tools=true]) -AM_CONDITIONAL([WITH_TOOLS], [test x$with_tools = xtrue]) - -AC_ARG_ENABLE([pam], - [AS_HELP_STRING([--enable-pam],[compile libcgroup PAM module [default=yes]])], - [ - if test "x$enableval" = xno; then - with_pam=false - else - with_pam=true - fi - ], - [with_pam=true]) -AM_CONDITIONAL([WITH_PAM], [test x$with_pam = xtrue]) - -AC_ARG_ENABLE([daemon], - [AS_HELP_STRING([--enable-daemon],[compile libcgroup daemon [default=yes]])], - [ - if test "x$enableval" = xno; then - with_daemon=false - else - with_daemon=true - fi - ], - [with_daemon=true]) -AM_CONDITIONAL([WITH_DAEMON], [test x$with_daemon = xtrue]) - -AC_ARG_ENABLE([python], - [AS_HELP_STRING([--enable-python], - [build the python bindings, requires cython])]) -AS_IF([test "$enable_python" = yes], [ - # cython version check - AS_IF([test "$CYTHON_VER_MAJ" -eq 0 -a "$CYTHON_VER_MIN" -lt 29], [ - AC_MSG_ERROR([python bindings require cython 0.29 or higher]) - ]) - AM_PATH_PYTHON([3]) -]) -AM_CONDITIONAL([ENABLE_PYTHON], [test "$enable_python" = yes]) -AC_DEFINE_UNQUOTED([ENABLE_PYTHON], - [$(test "$enable_python" = yes && echo 1 || echo 0)], - [Python bindings build flag.]) - -AC_ARG_ENABLE([systemd], - [AS_HELP_STRING([--enable-systemd],[enable systemd support [default=yes]])], - [ - if test "x$enableval" = xno; then - with_systemd=false - else - with_systemd=true - fi - ], - [with_systemd=true]) -AM_CONDITIONAL([WITH_SYSTEMD], [test x$with_systemd = xtrue]) - -AC_ARG_ENABLE([initscript-install], - [AS_HELP_STRING([--enable-initscript-install],[install init scripts [default=no]])], - [ - if test "x$enableval" = xno; then - with_initscript_install=false - else - with_initscript_install=true - fi - ], - [with_initscript_install=false]) -AM_CONDITIONAL([WITH_INITSCRIPT_INSTALL], [test x$with_initscript_install = xtrue]) - -socket_path="/var/run/cgred.socket" -AC_ARG_ENABLE([cgred-socket], - [AS_HELP_STRING([--enable-cgred-socket=PATH],[specify location of cgrulesengd communication socket - (default=/var/run/cgred.socket)])], - [ - if test "x$enableval" = xno -o "x$enableval" = xyes; then - AC_MSG_ERROR([Provide valid path with --enable-cgred-socket option.]) - else - socket_path="$enableval" - fi - ], []) -AC_DEFINE_UNQUOTED([CGRULE_CGRED_SOCKET_PATH],"$socket_path", [Cgrulesengd socket path]) - -pam_module_dir="$libdir/security" -AC_ARG_ENABLE([pam-module-dir], - [AS_HELP_STRING([--enable-pam-module-dir=PATH],[specify location of libcgroup PAM module - (default=$libdir/security)])], - [ - if test "x$enableval" = xno -o "x$enableval" = xyes; then - AC_MSG_ERROR([Provide valid path with --enable-pam-module-dir option.]) - else - pam_module_dir="$enableval" - fi - ], []) -AC_SUBST([pamlibdir],"$pam_module_dir") - -AC_ARG_ENABLE([opaque-hierarchy], - [AS_HELP_STRING([--enable-opaque-hierarchy=NAME],[specify name of a hierarchy which libcgroup should ignore, e.g. name=systemd - (default=none)])], - [ - if test "x$enableval" = xno -o "x$enableval" = xyes; then - AC_MSG_ERROR([Provide name of a hierarchy.]) - else - AC_DEFINE_UNQUOTED([OPAQUE_HIERARCHY], "$enableval", - [Define to ignore specific hierarchy.]) - fi - ], []) - -AC_ARG_ENABLE([tests], - [AS_HELP_STRING([--enable-tests],[compile libcgroup tests [default=yes]])], - [ - if test "x$enableval" = xno; then - with_tests=false - else - with_tests=true - fi - ], - [with_tests=true]) -AM_CONDITIONAL([WITH_TESTS], [test x$with_tests = xtrue]) - -AC_ARG_ENABLE([samples], - [AS_HELP_STRING([--enable-samples],[compile libcgroup samples C programs [default=no]])], - [ - if test "x$enableval" = xno; then - with_samples=false - else - with_samples=true - fi - ], - [with_samples=false]) -AM_CONDITIONAL([WITH_SAMPLES], [test x$with_samples = xtrue]) - -# Checks for programs. -AC_PROG_CXX -AC_PROG_CC -AC_PROG_YACC -if test "$YACC" = yacc; then - AC_CHECK_PROG([REALLY_YACC], [yacc], [yacc]) - if test "$REALLY_YACC" = ""; then - AC_MSG_ERROR([This program cannot be built unless a version of yacc is installed.]) - fi -fi -AM_PROG_LEX -if test "$LEX" != flex; then - AC_MSG_ERROR([This program cannot be built unless flex is installed.]) -fi -LT_INIT - -# Checks for header files. -AC_HEADER_DIRENT -AC_HEADER_STDC -AC_CHECK_HEADERS([limits.h mntent.h stdlib.h string.h sys/mount.h unistd.h]) - -# Checks for typedefs, structures, and compiler characteristics. -AC_HEADER_STDBOOL -AC_C_CONST -AC_TYPE_UID_T -AC_C_INLINE -AC_TYPE_INT64_T -AC_TYPE_PID_T - -# Checks for library functions. -AC_FUNC_CHOWN -AC_FUNC_GETMNTENT -AC_FUNC_MALLOC -AC_FUNC_REALLOC -AC_FUNC_STAT -AC_CHECK_FUNCS([getmntent hasmntopt memset mkdir rmdir strdup]) - -orig_CFLAGS="$CFLAGS" -CFLAGS="$CFLAGS -D_GNU_SOURCE" -AC_FUNC_STRERROR_R -CFLAGS="$orig_CFLAGS" - -AC_SEARCH_LIBS( - [fts_open], - [fts], - [], - [AC_MSG_ERROR([Unable to find the fts_open() function])]) - -if test x$with_pam = xtrue; then - AC_CHECK_LIB( - [pam], - [pam_syslog], - [ - dnl Override the default behavior of AC_CHECK_LIB, - dnl we don't want -lpam in LIBS. - : - ], - [AC_MSG_ERROR([Cannot compile PAM module without libpam!])]) - - AC_CHECK_HEADERS( - [security/pam_modules.h security/pam_modutil.h security/pam_ext.h], - [], - [AC_MSG_ERROR([Cannot compile PAM module without necessary - header files!])]) -fi - -AX_CODE_COVERAGE - -AC_CONFIG_FILES([Makefile - src/Makefile - src/daemon/Makefile - src/tools/Makefile - src/pam/Makefile - src/python/Makefile - scripts/Makefile - scripts/init.d/cgconfig - scripts/init.d/cgred - tests/Makefile - tests/ftests/Makefile - tests/gunit/Makefile - samples/Makefile - samples/c/Makefile - samples/cmdline/Makefile - samples/config/Makefile - samples/python/Makefile - include/Makefile - include/libcgroup/init.h - doc/Makefile - doc/man/Makefile - dist/Makefile - libcgroup.pc]) -AC_CONFIG_FILES([dist/libcgroup.spec:dist/libcgroup.spec.in]) -CFLAGS="$CFLAGS -Wall" -AC_OUTPUT diff --git a/lib/libcgroup-3.1.0/dist/Makefile.am b/lib/libcgroup-3.1.0/dist/Makefile.am deleted file mode 100644 index 346b8b8a6fc..00000000000 --- a/lib/libcgroup-3.1.0/dist/Makefile.am +++ /dev/null @@ -1 +0,0 @@ -EXTRA_DIST = libcgroup.spec diff --git a/lib/libcgroup-3.1.0/dist/Makefile.in b/lib/libcgroup-3.1.0/dist/Makefile.in deleted file mode 100644 index 5223222890e..00000000000 --- a/lib/libcgroup-3.1.0/dist/Makefile.in +++ /dev/null @@ -1,477 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = dist -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = libcgroup.spec -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/libcgroup.spec.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -EXTRA_DIST = libcgroup.spec -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign dist/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign dist/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -libcgroup.spec: $(top_builddir)/config.status $(srcdir)/libcgroup.spec.in - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/dist/libcgroup.spec b/lib/libcgroup-3.1.0/dist/libcgroup.spec deleted file mode 100644 index 25c42fb678b..00000000000 --- a/lib/libcgroup-3.1.0/dist/libcgroup.spec +++ /dev/null @@ -1,168 +0,0 @@ -%define soversion 3.1.0 -%define soversion_major 3 - -Name: libcgroup -Summary: Tools and libraries to control and monitor control groups -Group: System Environment/Libraries -Version: 3.1.0 -Release: 1%{?dist} -License: LGPLv2+ -URL: http://libcg.sourceforge.net/ -Source0: http://downloads.sourceforge.net/libcg/%{name}-%{version}.tar.bz2 -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -BuildRequires: pam-devel -BuildRequires: byacc -BuildRequires: flex -BuildRequires: coreutils -Requires(pre): shadow-utils -Requires(post): chkconfig, /sbin/service -Requires(preun): /sbin/chkconfig - -%description -Control groups infrastructure. The tools and library help manipulate, control, -administrate and monitor control groups and the associated controllers. - -%package pam -Summary: A Pluggable Authentication Module for libcgroup -Group: System Environment/Base -Requires: libcgroup = %{version}-%{release} - -%description pam -Linux-PAM module, which allows administrators to classify the user's login -processes to pre-configured control group. - -%package devel -Summary: Development libraries to develop applications that utilize control groups -Group: Development/Libraries -Requires: libcgroup = %{version}-%{release} - -%description devel -It provides API to create/delete and modify cgroup nodes. It will also in the -future allow creation of persistent configuration for control groups and -provide scripts to manage that configuration. - -%prep -%setup -q - -%build -%configure --bindir=/bin --sbindir=/sbin --libdir=%{_libdir} --enable-initscript-install --enable-pam-module-dir=/%{_lib}/security - -make %{?_smp_mflags} - - -%install -rm -rf $RPM_BUILD_ROOT -make DESTDIR=$RPM_BUILD_ROOT install - -# install config files -mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig -cp samples/config/cgred.conf $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cgred.conf -cp samples/config/cgconfig.sysconfig $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cgconfig -cp samples/config/cgconfig.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgconfig.conf -cp samples/config/cgrules.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgrules.conf -cp samples/config/cgsnapshot_blacklist.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgsnapshot_blacklist.conf - -# sanitize pam module, we need only pam_cgroup.so -mv -f $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so.*.*.* $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so -rm -f $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.la $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so.* - -# move the libraries to / -mkdir -p $RPM_BUILD_ROOT/%{_lib} -mv -f $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_lib} -rm -f $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so.%{soversion_major} -ln -sf libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_lib}/libcgroup.so.%{soversion_major} -ln -sf ../../%{_lib}/libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so -rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la - -%clean -rm -rf $RPM_BUILD_ROOT - -%pre -getent group cgred >/dev/null || groupadd cgred - -%post -/sbin/ldconfig -/sbin/chkconfig --add cgred -/sbin/chkconfig --add cgconfig - -%preun -if [ $1 = 0 ]; then - /sbin/service cgred stop > /dev/null 2>&1 || : - /sbin/service cgconfig stop > /dev/null 2>&1 || : - /sbin/chkconfig --del cgconfig - /sbin/chkconfig --del cgred -fi - -%postun -p /sbin/ldconfig - -%files -%defattr(-,root,root,-) -%config(noreplace) %{_sysconfdir}/sysconfig/cgred.conf -%config(noreplace) %{_sysconfdir}/sysconfig/cgconfig -%config(noreplace) %{_sysconfdir}/cgconfig.conf -%config(noreplace) %{_sysconfdir}/cgrules.conf -%config(noreplace) %{_sysconfdir}/cgsnapshot_blacklist.conf -/%{_lib}/libcgroup.so.* -%attr(2755, root, cgred) /bin/cgexec -/bin/cgclassify -/bin/cgcreate -/bin/cgget -/bin/cgset -/bin/cgdelete -/bin/lscgroup -/bin/lssubsys -/sbin/cgconfigparser -/sbin/cgrulesengd -/bin/cgsnapshot -%attr(0644, root, root) %{_mandir}/man1/* -%attr(0644, root, root) %{_mandir}/man5/* -%attr(0644, root, root) %{_mandir}/man8/* -%attr(0755,root,root) %{_initrddir}/cgconfig -%attr(0755,root,root) %{_initrddir}/cgred - -%doc COPYING INSTALL README_daemon - -%files pam -%defattr(-,root,root,-) -%attr(0755,root,root) /%{_lib}/security/pam_cgroup.so -%doc COPYING INSTALL - -%files devel -%defattr(-,root,root,-) -%{_includedir}/libcgroup.h -%{_includedir}/libcgroup/*.h -%{_libdir}/libcgroup.* -/%{_libdir}/pkgconfig/libcgroup.pc -%doc COPYING INSTALL - - -%changelog -* Tue Nov 2 2010 Jan Safranek 0.37.rc1-1 -- Add cgsnapshot -* Thu Feb 18 2010 Dhaval Giani 0.36.rc1-1 -- Add pkgconfig file -* Tue Jan 19 2010 Balbir Singh 0.35.1 -- Integrate Jan's fixes for distributing cgget and initscripts -* Thu Oct 22 2009 Jan Safranek 0.34-1 -- Update to latest upstream -- Split PAM module to separate subpackage -* Tue Feb 24 2009 Balbir Singh 0.33-1 -- Update to 0.33, spec file changes to add Makefiles and pam_cgroup module -* Fri Oct 10 2008 Dhaval Giani 0.32-1 -- Update to latest upstream -* Thu Sep 11 2008 Dhaval Giani 0.31-1 -- Update to latest upstream -* Sat Aug 2 2008 Dhaval Giani 0.1c-3 -- Change release to fix broken upgrade path -* Wed Jun 11 2008 Dhaval Giani 0.1c-1 -- Update to latest upstream version -* Tue Jun 3 2008 Balbir Singh 0.1b-3 -- Add post and postun. Also fix Requires for devel to depend on base n-v-r -* Sat May 31 2008 Balbir Singh 0.1b-2 -- Fix makeinstall, Source0 and URL (review comments from Tom) -* Mon May 26 2008 Balbir Singh 0.1b-1 -- Add a generatable spec file -* Tue May 20 2008 Balbir Singh 0.1-1 -- Get the spec file to work -* Tue May 20 2008 Dhaval Giani 0.01-1 -- The first version of libcg diff --git a/lib/libcgroup-3.1.0/dist/libcgroup.spec.in b/lib/libcgroup-3.1.0/dist/libcgroup.spec.in deleted file mode 100644 index bb53efefec0..00000000000 --- a/lib/libcgroup-3.1.0/dist/libcgroup.spec.in +++ /dev/null @@ -1,168 +0,0 @@ -%define soversion @LIBRARY_VERSION_MAJOR@.@LIBRARY_VERSION_MINOR@.@LIBRARY_VERSION_RELEASE@ -%define soversion_major @LIBRARY_VERSION_MAJOR@ - -Name: libcgroup -Summary: Tools and libraries to control and monitor control groups -Group: System Environment/Libraries -Version: @PACKAGE_VERSION@ -Release: 1%{?dist} -License: LGPLv2+ -URL: http://libcg.sourceforge.net/ -Source0: http://downloads.sourceforge.net/libcg/%{name}-%{version}.tar.bz2 -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -BuildRequires: pam-devel -BuildRequires: byacc -BuildRequires: flex -BuildRequires: coreutils -Requires(pre): shadow-utils -Requires(post): chkconfig, /sbin/service -Requires(preun): /sbin/chkconfig - -%description -Control groups infrastructure. The tools and library help manipulate, control, -administrate and monitor control groups and the associated controllers. - -%package pam -Summary: A Pluggable Authentication Module for libcgroup -Group: System Environment/Base -Requires: libcgroup = %{version}-%{release} - -%description pam -Linux-PAM module, which allows administrators to classify the user's login -processes to pre-configured control group. - -%package devel -Summary: Development libraries to develop applications that utilize control groups -Group: Development/Libraries -Requires: libcgroup = %{version}-%{release} - -%description devel -It provides API to create/delete and modify cgroup nodes. It will also in the -future allow creation of persistent configuration for control groups and -provide scripts to manage that configuration. - -%prep -%setup -q - -%build -%configure --bindir=/bin --sbindir=/sbin --libdir=%{_libdir} --enable-initscript-install --enable-pam-module-dir=/%{_lib}/security - -make %{?_smp_mflags} - - -%install -rm -rf $RPM_BUILD_ROOT -make DESTDIR=$RPM_BUILD_ROOT install - -# install config files -mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig -cp samples/config/cgred.conf $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cgred.conf -cp samples/config/cgconfig.sysconfig $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/cgconfig -cp samples/config/cgconfig.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgconfig.conf -cp samples/config/cgrules.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgrules.conf -cp samples/config/cgsnapshot_blacklist.conf $RPM_BUILD_ROOT/%{_sysconfdir}/cgsnapshot_blacklist.conf - -# sanitize pam module, we need only pam_cgroup.so -mv -f $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so.*.*.* $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so -rm -f $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.la $RPM_BUILD_ROOT/%{_lib}/security/pam_cgroup.so.* - -# move the libraries to / -mkdir -p $RPM_BUILD_ROOT/%{_lib} -mv -f $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_lib} -rm -f $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so.%{soversion_major} -ln -sf libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_lib}/libcgroup.so.%{soversion_major} -ln -sf ../../%{_lib}/libcgroup.so.%{soversion} $RPM_BUILD_ROOT/%{_libdir}/libcgroup.so -rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la - -%clean -rm -rf $RPM_BUILD_ROOT - -%pre -getent group cgred >/dev/null || groupadd cgred - -%post -/sbin/ldconfig -/sbin/chkconfig --add cgred -/sbin/chkconfig --add cgconfig - -%preun -if [ $1 = 0 ]; then - /sbin/service cgred stop > /dev/null 2>&1 || : - /sbin/service cgconfig stop > /dev/null 2>&1 || : - /sbin/chkconfig --del cgconfig - /sbin/chkconfig --del cgred -fi - -%postun -p /sbin/ldconfig - -%files -%defattr(-,root,root,-) -%config(noreplace) %{_sysconfdir}/sysconfig/cgred.conf -%config(noreplace) %{_sysconfdir}/sysconfig/cgconfig -%config(noreplace) %{_sysconfdir}/cgconfig.conf -%config(noreplace) %{_sysconfdir}/cgrules.conf -%config(noreplace) %{_sysconfdir}/cgsnapshot_blacklist.conf -/%{_lib}/libcgroup.so.* -%attr(2755, root, cgred) /bin/cgexec -/bin/cgclassify -/bin/cgcreate -/bin/cgget -/bin/cgset -/bin/cgdelete -/bin/lscgroup -/bin/lssubsys -/sbin/cgconfigparser -/sbin/cgrulesengd -/bin/cgsnapshot -%attr(0644, root, root) %{_mandir}/man1/* -%attr(0644, root, root) %{_mandir}/man5/* -%attr(0644, root, root) %{_mandir}/man8/* -%attr(0755,root,root) %{_initrddir}/cgconfig -%attr(0755,root,root) %{_initrddir}/cgred - -%doc COPYING INSTALL README_daemon - -%files pam -%defattr(-,root,root,-) -%attr(0755,root,root) /%{_lib}/security/pam_cgroup.so -%doc COPYING INSTALL - -%files devel -%defattr(-,root,root,-) -%{_includedir}/libcgroup.h -%{_includedir}/libcgroup/*.h -%{_libdir}/libcgroup.* -/%{_libdir}/pkgconfig/libcgroup.pc -%doc COPYING INSTALL - - -%changelog -* Tue Nov 2 2010 Jan Safranek 0.37.rc1-1 -- Add cgsnapshot -* Thu Feb 18 2010 Dhaval Giani 0.36.rc1-1 -- Add pkgconfig file -* Tue Jan 19 2010 Balbir Singh 0.35.1 -- Integrate Jan's fixes for distributing cgget and initscripts -* Thu Oct 22 2009 Jan Safranek 0.34-1 -- Update to latest upstream -- Split PAM module to separate subpackage -* Tue Feb 24 2009 Balbir Singh 0.33-1 -- Update to 0.33, spec file changes to add Makefiles and pam_cgroup module -* Fri Oct 10 2008 Dhaval Giani 0.32-1 -- Update to latest upstream -* Thu Sep 11 2008 Dhaval Giani 0.31-1 -- Update to latest upstream -* Sat Aug 2 2008 Dhaval Giani 0.1c-3 -- Change release to fix broken upgrade path -* Wed Jun 11 2008 Dhaval Giani 0.1c-1 -- Update to latest upstream version -* Tue Jun 3 2008 Balbir Singh 0.1b-3 -- Add post and postun. Also fix Requires for devel to depend on base n-v-r -* Sat May 31 2008 Balbir Singh 0.1b-2 -- Fix makeinstall, Source0 and URL (review comments from Tom) -* Mon May 26 2008 Balbir Singh 0.1b-1 -- Add a generatable spec file -* Tue May 20 2008 Balbir Singh 0.1-1 -- Get the spec file to work -* Tue May 20 2008 Dhaval Giani 0.01-1 -- The first version of libcg diff --git a/lib/libcgroup-3.1.0/doc/Makefile.am b/lib/libcgroup-3.1.0/doc/Makefile.am deleted file mode 100644 index e4396141203..00000000000 --- a/lib/libcgroup-3.1.0/doc/Makefile.am +++ /dev/null @@ -1,3 +0,0 @@ -DIST_SUBDIRS = man -SUBDIRS = $(DIST_SUBDIRS) - diff --git a/lib/libcgroup-3.1.0/doc/Makefile.in b/lib/libcgroup-3.1.0/doc/Makefile.in deleted file mode 100644 index 06eee978f2c..00000000000 --- a/lib/libcgroup-3.1.0/doc/Makefile.in +++ /dev/null @@ -1,653 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = doc -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir distdir-am -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -DIST_SUBDIRS = man -SUBDIRS = $(DIST_SUBDIRS) -all: all-recursive - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign doc/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-recursive -all-am: Makefile -installdirs: installdirs-recursive -installdirs-am: -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-recursive - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: - -.MAKE: $(am__recursive_targets) install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - installdirs-am maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/doc/man/Makefile.am b/lib/libcgroup-3.1.0/doc/man/Makefile.am deleted file mode 100644 index 13cc0062ade..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/Makefile.am +++ /dev/null @@ -1,7 +0,0 @@ -man_MANS = cgclassify.1 cgconfig.conf.5 cgconfigparser.8 cgexec.1 \ - cgred.conf.5 cgrules.conf.5 cgrulesengd.8 cgcreate.1 cgset.1 \ - cgget.1 cgdelete.1 lssubsys.1 lscgroup.1 cgsnapshot.1 \ - cgxget.1 cgxset.1 - -EXTRA_DIST = $(man_MANS) - diff --git a/lib/libcgroup-3.1.0/doc/man/Makefile.in b/lib/libcgroup-3.1.0/doc/man/Makefile.in deleted file mode 100644 index 81a4e7160d6..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/Makefile.in +++ /dev/null @@ -1,650 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = doc/man -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -man1dir = $(mandir)/man1 -am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \ - "$(DESTDIR)$(man8dir)" -man5dir = $(mandir)/man5 -man8dir = $(mandir)/man8 -NROFF = nroff -MANS = $(man_MANS) -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -man_MANS = cgclassify.1 cgconfig.conf.5 cgconfigparser.8 cgexec.1 \ - cgred.conf.5 cgrules.conf.5 cgrulesengd.8 cgcreate.1 cgset.1 \ - cgget.1 cgdelete.1 lssubsys.1 lscgroup.1 cgsnapshot.1 \ - cgxget.1 cgxset.1 - -EXTRA_DIST = $(man_MANS) -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/man/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign doc/man/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -install-man1: $(man_MANS) - @$(NORMAL_INSTALL) - @list1=''; \ - list2='$(man_MANS)'; \ - test -n "$(man1dir)" \ - && test -n "`echo $$list1$$list2`" \ - || exit 0; \ - echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ - { for i in $$list1; do echo "$$i"; done; \ - if test -n "$$list2"; then \ - for i in $$list2; do echo "$$i"; done \ - | sed -n '/\.1[a-z]*$$/p'; \ - fi; \ - } | while read p; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; echo "$$p"; \ - done | \ - sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ - sed 'N;N;s,\n, ,g' | { \ - list=; while read file base inst; do \ - if test "$$base" = "$$inst"; then list="$$list $$file"; else \ - echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ - $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ - fi; \ - done; \ - for i in $$list; do echo "$$i"; done | $(am__base_list) | \ - while read files; do \ - test -z "$$files" || { \ - echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ - $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ - done; } - -uninstall-man1: - @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man1dir)" || exit 0; \ - files=`{ for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.1[a-z]*$$/p'; \ - } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) -install-man5: $(man_MANS) - @$(NORMAL_INSTALL) - @list1=''; \ - list2='$(man_MANS)'; \ - test -n "$(man5dir)" \ - && test -n "`echo $$list1$$list2`" \ - || exit 0; \ - echo " $(MKDIR_P) '$(DESTDIR)$(man5dir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(man5dir)" || exit 1; \ - { for i in $$list1; do echo "$$i"; done; \ - if test -n "$$list2"; then \ - for i in $$list2; do echo "$$i"; done \ - | sed -n '/\.5[a-z]*$$/p'; \ - fi; \ - } | while read p; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; echo "$$p"; \ - done | \ - sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ - sed 'N;N;s,\n, ,g' | { \ - list=; while read file base inst; do \ - if test "$$base" = "$$inst"; then list="$$list $$file"; else \ - echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man5dir)/$$inst'"; \ - $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man5dir)/$$inst" || exit $$?; \ - fi; \ - done; \ - for i in $$list; do echo "$$i"; done | $(am__base_list) | \ - while read files; do \ - test -z "$$files" || { \ - echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man5dir)'"; \ - $(INSTALL_DATA) $$files "$(DESTDIR)$(man5dir)" || exit $$?; }; \ - done; } - -uninstall-man5: - @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man5dir)" || exit 0; \ - files=`{ for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.5[a-z]*$$/p'; \ - } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^5][0-9a-z]*$$,5,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - dir='$(DESTDIR)$(man5dir)'; $(am__uninstall_files_from_dir) -install-man8: $(man_MANS) - @$(NORMAL_INSTALL) - @list1=''; \ - list2='$(man_MANS)'; \ - test -n "$(man8dir)" \ - && test -n "`echo $$list1$$list2`" \ - || exit 0; \ - echo " $(MKDIR_P) '$(DESTDIR)$(man8dir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(man8dir)" || exit 1; \ - { for i in $$list1; do echo "$$i"; done; \ - if test -n "$$list2"; then \ - for i in $$list2; do echo "$$i"; done \ - | sed -n '/\.8[a-z]*$$/p'; \ - fi; \ - } | while read p; do \ - if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ - echo "$$d$$p"; echo "$$p"; \ - done | \ - sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ - sed 'N;N;s,\n, ,g' | { \ - list=; while read file base inst; do \ - if test "$$base" = "$$inst"; then list="$$list $$file"; else \ - echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man8dir)/$$inst'"; \ - $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man8dir)/$$inst" || exit $$?; \ - fi; \ - done; \ - for i in $$list; do echo "$$i"; done | $(am__base_list) | \ - while read files; do \ - test -z "$$files" || { \ - echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man8dir)'"; \ - $(INSTALL_DATA) $$files "$(DESTDIR)$(man8dir)" || exit $$?; }; \ - done; } - -uninstall-man8: - @$(NORMAL_UNINSTALL) - @list=''; test -n "$(man8dir)" || exit 0; \ - files=`{ for i in $$list; do echo "$$i"; done; \ - l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ - sed -n '/\.8[a-z]*$$/p'; \ - } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^8][0-9a-z]*$$,8,;x' \ - -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ - dir='$(DESTDIR)$(man8dir)'; $(am__uninstall_files_from_dir) -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(MANS) -installdirs: - for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: install-man - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: install-man1 install-man5 install-man8 - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-man - -uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8 - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-man1 install-man5 install-man8 install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags-am uninstall \ - uninstall-am uninstall-man uninstall-man1 uninstall-man5 \ - uninstall-man8 - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/doc/man/cgclassify.1 b/lib/libcgroup-3.1.0/doc/man/cgclassify.1 deleted file mode 100644 index 950145d05a9..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgclassify.1 +++ /dev/null @@ -1,93 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Varekova . - -.TH CGCLASSIFY 1 2009-03-15 "Linux" "libcgroup Manual" -.SH NAME -cgclassify \- move running task(s) to given cgroups - -.SH SYNOPSIS -\fBcgclassify\fR [\fB-b\fR] [\fB-g\fR <\fIcontrollers>:] [--sticky | --cancel-sticky] <\fIpidlist\fR> - -.SH DESCRIPTION -this command moves processes defined by the list -of processes -(\fBpidlist\fR) -to the given control groups. - -The pids in the pidlist are separated by spaces - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B -g : -defines the control groups where the task will be moved. -\fBcontrollers\fR is a list of controllers and -\fBpath\fR is the relative path to control groups -in the given controllers list. - -This flag can be used multiple times to -define multiple pairs of lists of controllers -and relative paths. -Instead of the list of all mounted controllers, -the wildcard \fB*\fR can be used. - -If this option is not used then -\fBcgclassify\fR will automatically move the task to a -control group based on \fB/etc/cgrules.conf\fR. - -.TP -.B -r -Replaces systemd scope's idle process with the -\fBfirst process\fR of the list of process (\fBpidlist\fR). - -.TP -.B --sticky -If this option is used, the daemon of service cgred (cgrulesengd process) -does not change both the specified \fBpidlist\fR and their children tasks. -Without this option, the daemon does not change the specified \fBpidlist\fR -but it automatically changes their child tasks to the right cgroup based on -\fB/etc/cgrules.conf\fR. - -.TP -.B --cancel-sticky -If this option is used, the daemon of service cgred (cgrulesengd process) -can automatically change both the specified \fBpidlist\fR and their child -tasks to the right cgroup based on \fB/etc/cgrules.conf\fR. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH FILES -.TP -.B /etc/cgrules.conf -default libcgroup configuration file -.TP -.B /etc/cgrules.d -default libcgroup configuration files directory - -.SH EXAMPLES -.TP -.B cgclassify -g cpu:student 1234 -moves process with pid number 1234 to control group student in cpu hierarchy. - -.TP -.B cgclassify 1234 -moves process with pid number 1234 to control groups based on -\fB/etc/cgrules.conf\fR configuration file. - -.TP -.B cgclassify --sticky -g cpu:/student 1234 -moves process with pid number 1234 to control group student in cpu hierarchy. -The daemon of service cgred does not change cgroups of pid 1234 and its children -(based on \fB/etc/cgrules.conf\fR). - -.SH SEE ALSO -cgrules.conf (5), cgexec (1) - diff --git a/lib/libcgroup-3.1.0/doc/man/cgconfig.conf.5 b/lib/libcgroup-3.1.0/doc/man/cgconfig.conf.5 deleted file mode 100644 index 8673bb0cfec..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgconfig.conf.5 +++ /dev/null @@ -1,824 +0,0 @@ -.TH CGCONFIG.CONF 5 -.\"*********************************** -.SH NAME -cgconfig.conf \- libcgroup configuration file -.\"*********************************** -.SH DESCRIPTION -.B "cgconfig.conf" -is a configuration file used by -.B libcgroup -to define control groups, their parameters and their mount points. -The file consists of -.I mount -, -.I group -and -.I default -sections. These sections can be in arbitrary order and all of them are -optional. Any line starting with '#' is considered a comment line and -is ignored. -.LP -.I mount -section has this form: -.RS -.nf -.ft B -.sp -mount { -.RS -.ft B - = ; -.I "..." -.RE -.ft B -} -.ft R -.fi -.RE - -.TP -.B controller -Name of the kernel subsystem. The list of subsystems supported by the kernel -can be found in -.I /proc/cgroups -file. Named hierarchy can be specified as controller -\fB"name="\fR. Do not forget to use double quotes around -this controller name (see examples below). Apart from named hierarchy, -additional mount options may be specified by putting the controller and -the options in quotes. Options supported are \fB nosuid, noexec\fR and\fB nodev\fR. - -.B Libcgroup -merges all subsystems mounted to the same directory (see -Example 1) and the directory is mounted only once. - -.TP -.B path -The directory path where the group hierarchy associated to a given -controller shall be mounted. The directory is created -automatically on cgconfig service startup if it does not exist and -is deleted on service shutdown. -.LP - -If no -.I mount -section is specified, no controllers are mounted. - -.I group -section has this form: -.RS -.nf -.ft B -.sp -group { -.RS -.ft B -[permissions] - { -.RS -.ft B - = ; -.I "..." -.RE -.ft B -} -.I "..." -.RE -.ft B -} -.ft R -.fi -.RE - -.TP -.B name -Name of the control group. It can contain only characters, which are -allowed for directory names. -The groups form a tree, i.e. a control group can contain zero or more -subgroups. Subgroups can be specified using '/' delimiter. - -The root control group is always created automatically in all hierarchies -and it is the base of the group hierarchy. It can be explicitly specified in -.B cgconfig.conf -by using '.' as group name. This can be used e.g. to set its permissions, -as shown in Example 6. - -When the parent control group of a subgroup is not specified -it is created automatically. - -.TP -.B permissions -Permissions of the given control group on mounted filesystem. -.I root -has always permission to do anything with the control group. -Permissions have the following syntax: -.RS 17 -.ft B -.nf -perm { -.RS -.ft B -task { -.RS -.ft B -uid = ; -gid = ; -fperm = -.RE -} -admin { -.RS -uid = ; -gid = ; -dperm = -fperm = -.RE -} -.RE -} -.fi -.RE -.ft R - -.RS -.TP 17 -.B "task user/group" -Name of the user and the group, which own the -.I tasks -file of the control group. Given fperm then specify the file permissions. -Please note that the given value is not used as was specified. Instead, -current file owner permissions are used as a "umask" for group and others -permissions. For example if fperm = 777 then both group and others will get -the same permissions as the file owner. -.TP 17 -.B "admin user/group" -Name of the user and the group which own the rest of control group's -files. Given fperm and dperm control file and directory permissions. -Again, the given value is masked by the file/directory owner permissions. -.LP -Permissions are only apply to the enclosing control group and are not -inherited by subgroups. If there is no -.B perm -section in the control group definition, -.I root:root -is the owner of all files and default file permissions are preserved if -fperm resp. dperm are not specified. -.RE -.TP -.B controller -Name of the kernel subsystem. -The section can be -empty, default kernel parameters will be used in this case. By -specifying -.B controller -the control group and all its parents are controlled by the specific -subsystem. One control group can be controlled by multiple subsystems, -even if the subsystems are mounted on different directories. Each -control group must be controlled by at least one subsystem, so that -.B libcgroup -knows in which hierarchies the control group should be created. - -The parameters of the given controller can be modified in the following -section enclosed in brackets. -.RS -.TP -.B param name -Name of the file to set. Each controller can have zero or more -parameters. -.TP -.B param value -Value which should be written to the file when the control group is -created. If it is enclosed in double quotes `"', it can contain spaces -and other special characters. -.RE - -If no -.I group -section is specified, no groups are created. - -.I default -section has this form: -.RS -.nf -.ft B -.sp -default { -.RS -.ft B -perm { -.RS -.ft B -task { -.RS -.ft B -uid = ; -gid = ; -fperm = -.RE -} -admin { -.RS -uid = ; -gid = ; -dperm = -fperm = -.RE -} -.RE -} -.RE -} -.ft R -.fi -.RE - -Content of the -.B perm -section has the same form as in -.I group -section. The permissions defined here specify owner and permissions of -groups and files of all groups, which do not have explicitly specified -their permissions in their -.I group -section. - -.I template -section has the same structure as -.B group -section. Template name uses the same templates string as -.B cgrules.conf -destination tag (see (\fBcgrules.conf\fR (5)). -Template definition is used as a control group definition for rules in -\fBcgrules.conf\fR (5) with the same destination name. -Templates does not use -.B default -section settings. - -.I /etc/cgconfig.d/ -directory can be used for additional configuration files. cgrulesengd searches this directory for additional templates. - -.\"********************************************" -.SH EXAMPLES -.LP -.SS Example 1 -.LP -The configuration file: -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpu; -.RE -} -.fi -.RE - -creates the hierarchy controlled by two subsystems with no groups -inside. It corresponds to the following operations: -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mount -t cgroup -o cpu,cpuacct cpu /mnt/cgroups/cpu -.fi -.RE - -.SS Example 2 -.LP -The configuration file: -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -"name=scheduler" = /mnt/cgroups/cpu; -"name=noctrl" = /mnt/cgroups/noctrl; -.RE -} - -group daemons { -.RS -cpu { -.RS -cpu.shares = "1000"; -.RE -} -.RE -} -group test { -.RS -"name=noctrl" { -} -.RE -} -.RE -.fi -creates two hierarchies. One hierarchy named \fBscheduler\fR controlled by cpu -subsystem, with group \fBdaemons\fR inside. Second hierarchy is named -\fBnoctrl\fR without any controller, with group \fBtest\fR. It corresponds to -following operations: -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mount -t cgroup -o cpu,name=scheduler cpu /mnt/cgroups/cpu -mount -t cgroup -o none,name=noctrl none /mnt/cgroups/noctrl - -mkdir /mnt/cgroups/cpu/daemons -echo 1000 > /mnt/cgroups/cpu/daemons/www/cpu.shares - -mkdir /mnt/cgroups/noctrl/tests -.fi -.RE - -The -.I daemons -group is created automatically when its first subgroup is -created. All its parameters have the default value and only root can -access group's files. -.LP -Since both -.I cpuacct -and -.I cpu -subsystems are mounted to the same directory, all -groups are implicitly controlled also by -.I cpuacct -subsystem, even if there is no -.I cpuacct -section in any of the groups. -.RE - -.SS Example 3 -.LP -The configuration file: -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpu; -.RE -} - -group daemons/www { -.RS -perm { -.RS -task { -.RS -uid = root; -gid = webmaster; -fperm = 770; -.RE -} -admin { -.RS -uid = root; -gid = root; -dperm = 775; -fperm = 744; -.RE -} -.RE -} -cpu { -.RS -cpu.shares = "1000"; -.RE -} -.RE -} - -group daemons/ftp { -.RS -perm { -.RS -task { -.RS -uid = root; -gid = ftpmaster; -fperm = 774; -.RE -} -admin { -.RS -uid = root; -gid = root; -dperm = 755; -fperm = 700; -.RE -} -.RE -} -cpu { -.RS -cpu.shares = "500"; -.RE -} -.RE -} -.RE -.fi -creates the hierarchy controlled by two subsystems with one group and -two subgroups inside, setting one parameter. -It corresponds to the following operations (except for file permissions -which are little bit trickier to emulate via chmod): - -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mount -t cgroup -o cpu,cpuacct cpu /mnt/cgroups/cpu - -mkdir /mnt/cgroups/cpu/daemons - -mkdir /mnt/cgroups/cpu/daemons/www -chown root:root /mnt/cgroups/cpu/daemons/www/* -chown root:webmaster /mnt/cgroups/cpu/daemons/www/tasks -echo 1000 > /mnt/cgroups/cpu/daemons/www/cpu.shares - - # + chmod the files so the result looks like: - # ls -la /mnt/cgroups/cpu/daemons/www/ - # admin.dperm = 755: - # drwxr-xr-x. 2 root webmaster 0 Jun 16 11:51 . - # - # admin.fperm = 744: - # --w-------. 1 root webmaster 0 Jun 16 11:51 cgroup.event_control - # -r--r--r--. 1 root webmaster 0 Jun 16 11:51 cgroup.procs - # -r--r--r--. 1 root webmaster 0 Jun 16 11:51 cpuacct.stat - # -rw-r--r--. 1 root webmaster 0 Jun 16 11:51 cpuacct.usage - # -r--r--r--. 1 root webmaster 0 Jun 16 11:51 cpuacct.usage_percpu - # -rw-r--r--. 1 root webmaster 0 Jun 16 11:51 cpu.rt_period_us - # -rw-r--r--. 1 root webmaster 0 Jun 16 11:51 cpu.rt_runtime_us - # -rw-r--r--. 1 root webmaster 0 Jun 16 11:51 cpu.shares - # -rw-r--r--. 1 root webmaster 0 Jun 16 11:51 notify_on_release - # - # tasks.fperm = 770 - # -rw-rw----. 1 root webmaster 0 Jun 16 11:51 tasks - - -mkdir /mnt/cgroups/cpu/daemons/ftp -chown root:root /mnt/cgroups/cpu/daemons/ftp/* -chown root:ftpmaster /mnt/cgroups/cpu/daemons/ftp/tasks -echo 500 > /mnt/cgroups/cpu/daemons/ftp/cpu.shares - - # + chmod the files so the result looks like: - # ls -la /mnt/cgroups/cpu/daemons/ftp/ - # admin.dperm = 755: - # drwxr-xr-x. 2 root ftpmaster 0 Jun 16 11:51 . - # - # admin.fperm = 700: - # --w-------. 1 root ftpmaster 0 Jun 16 11:51 cgroup.event_control - # -r--------. 1 root ftpmaster 0 Jun 16 11:51 cgroup.procs - # -r--------. 1 root ftpmaster 0 Jun 16 11:51 cpuacct.stat - # -rw-------. 1 root ftpmaster 0 Jun 16 11:51 cpuacct.usage - # -r--------. 1 root ftpmaster 0 Jun 16 11:51 cpuacct.usage_percpu - # -rw-------. 1 root ftpmaster 0 Jun 16 11:51 cpu.rt_period_us - # -rw-------. 1 root ftpmaster 0 Jun 16 11:51 cpu.rt_runtime_us - # -rw-------. 1 root ftpmaster 0 Jun 16 11:51 cpu.shares - # -rw-------. 1 root ftpmaster 0 Jun 16 11:51 notify_on_release - # - # tasks.fperm = 774: - # -rw-rw-r--. 1 root ftpmaster 0 Jun 16 11:51 tasks - -.fi -.RE - -The -.I daemons -group is created automatically when its first subgroup is -created. All its parameters have the default value and only root can -access the group's files. -.LP -Since both -.I cpuacct -and -.I cpu -subsystems are mounted to the same directory, all -groups are implicitly also controlled by the -.I cpuacct -subsystem, even if there is no -.I cpuacct -section in any of the groups. -.RE - -.SS Example 4 -.LP -The configuration file: - -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpuacct; -.RE -} - -group daemons { -.RS -cpuacct{ -} -cpu { -} -.RE -} -.fi -.RE -creates two hierarchies and one common group in both of them. -It corresponds to the following operations: -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mkdir /mnt/cgroups/cpuacct -mount -t cgroup -o cpu cpu /mnt/cgroups/cpu -mount -t cgroup -o cpuacct cpuacct /mnt/cgroups/cpuacct - -mkdir /mnt/cgroups/cpu/daemons -mkdir /mnt/cgroups/cpuacct/daemons -.fi -.RE - -In fact there are two groups created. One in the -.I cpuacct -hierarchy, the second in the -.I cpu -hierarchy. These two groups have nothing in common and can -contain different subgroups and different tasks. - -.SS Example 5 -.LP - -The configuration file: - -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpuacct; -.RE -} - -group daemons { -.RS -cpuacct{ -} -.RE -} - -group daemons/www { -.RS -cpu { -.RS -cpu.shares = "1000"; -.RE -} -.RE -} - -group daemons/ftp { -.RS -cpu { -.RS -cpu.shares = "500"; -.RE -} -.RE -} -.fi -.RE -creates two hierarchies with few groups inside. One of the groups -is created in both hierarchies. - -It corresponds to the following operations: -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mkdir /mnt/cgroups/cpuacct -mount -t cgroup -o cpu cpu /mnt/cgroups/cpu -mount -t cgroup -o cpuacct cpuacct /mnt/cgroups/cpuacct - -mkdir /mnt/cgroups/cpuacct/daemons -mkdir /mnt/cgroups/cpu/daemons -mkdir /mnt/cgroups/cpu/daemons/www -echo 1000 > /mnt/cgroups/cpu/daemons/www/cpu.shares -mkdir /mnt/cgroups/cpu/daemons/ftp -echo 500 > /mnt/cgroups/cpu/daemons/ftp/cpu.shares -.fi -.RE -Group -.I daemons -is created in both hierarchies. In the -.I cpuacct -hierarchy the group is explicitly mentioned in the configuration -file. In the -.I cpu -hierarchy the group is created implicitly when -.I www -is created there. These two groups have nothing in common, for example -they do not share processes and subgroups. Groups -.I www -and -.I ftp -are created only in the -.I cpu -hierarchy and are not controlled by the -.I cpuacct -subsystem. - -.SS Example 6 -.LP -The configuration file: -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpu; -.RE -} - -group . { -.RS -perm { -.RS -task { -.RS -uid = root; -gid = operator; -.RE -} -admin { -.RS -uid = root; -gid = operator; -.RE -} -.RE -} -cpu { -} -.RE -} - -group daemons { -.RS -perm { -.RS -task { -.RS -uid = root; -gid = daemonmaster; -.RE -} -admin { -.RS -uid = root; -gid = operator; -.RE -} -.RE -} -cpu { -} -.RE -} -.RE -.fi -creates the hierarchy controlled by two subsystems with one group having some -special permissions. -It corresponds to the following operations: -.LP -.RS -.nf -mkdir /mnt/cgroups/cpu -mount -t cgroup -o cpu,cpuacct cpu /mnt/cgroups/cpu - -chown root:operator /mnt/cgroups/cpu/* -chown root:operator /mnt/cgroups/cpu/tasks - -mkdir /mnt/cgroups/cpu/daemons -chown root:operator /mnt/cgroups/cpu/daemons/* -chown root:daemonmaster /mnt/cgroups/cpu/daemons/tasks -.fi -.RE - -Users which are members of the -.I operator -group are allowed to administer the control groups, i.e. create new control -groups and move processes between these groups without having root -privileges. - -Members of the -.I daemonmaster -group can move processes to the -.I daemons -control group, but they can not move the process out of the group. Only the -.I operator -or root can do that. - -.SS Example 7 -.LP -The configuration file: - -.LP -.RS -.nf -mount { -.RS -cpu = /mnt/cgroups/cpu; -cpuacct = /mnt/cgroups/cpuacct; -.RE -} - -group students { -.RS -cpuacct{ -} -cpu { -} -.RE -} - -template students/%u { -.RS -cpuacct{ -} -cpu { -} -.RE -} - -mkdir /mnt/cgroups/cpu/daemons -mkdir /mnt/cgroups/cpuacct/daemons -.fi -.RE - -The situation is the similar as in Example 4. The only difference is template, -which is used if some rule uses "/students/%u" as a destination. - -.SS Example 8 -.LP -The configuration file: - -.LP -.RS -.nf -mount { -.RS -"cpu,nodev,nosuid,noexec" = /mnt/cgroups/cpu; -.RE -} - -.fi -.RE - -This is the same as -mount -t cgroup cgroup -o nodev,nosuid,noexec,cpu /mnt/cgroups/cpu -It mounts the cpu controller with MS_NODEV, MS_NOSUID and MS_NOEXEC -options passed. - - -.SH RECOMMENDATIONS -.SS Keep hierarchies separated -Having multiple hierarchies is perfectly valid and can be useful -in various scenarios. To keeps things clean, do not -create one group in multiple hierarchies. Examples 4 and 5 show -how unreadable and confusing it can be, especially when reading -somebody elses configuration file. - -.SS Explicit is better than implicit -.B libcgroup -can implicitly create groups which are needed for the creation of -configured subgroups. This may be useful and save some typing in -simple scenarios. When it comes to multiple hierarchies, it's -better to explicitly specify all groups and all controllers -related to them. - -.SH FILES -.TP -.B /etc/cgconfig.conf -default libcgroup configuration file -.TP -.B /etc/cgconfig.d/ -default libcgroup configuration files directory - -.SH SEE ALSO -cgconfigparser (8) - -.SH BUGS -Parameter values must be single strings without spaces. -Parsing of quoted strings is not implemented. - -.SH - diff --git a/lib/libcgroup-3.1.0/doc/man/cgconfigparser.8 b/lib/libcgroup-3.1.0/doc/man/cgconfigparser.8 deleted file mode 100644 index 8fff95f450b..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgconfigparser.8 +++ /dev/null @@ -1,92 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Varekova . - -.TH CGCONFIGPARSER 8 2009-03-16 "Linux" "libcgroup Manual" -.SH NAME - -cgconfigparser \- setup control group file system - -.SH SYNOPSIS -\fBcgconfigparser\fR [\fB-h\fR] [\fB-l\fR \fI\fR] [\fB-L\fR \fI\fR] [...] - -.SH OPTIONS -.TP -.B -h, --help -Displays help. -.TP -.B -l, --load=FILE -Parses the control groups configuration file -Sets up the control group file system -defined by the configuration file and mounts -mount points defined by the configuration file. -The format of the file is described in -\fBcgconfig.conf\fR. This option can be used multiple times and can be mixed -with \fB-L\fR option. - -.TP -.B -L, --load-directory=DIR -Finds all files in given directory and parses them in alphabetical order -like they were specified by \fB-l\fR option. This option can be used -multiple times and can be mixed with \fB-l\fR option. - -.TP -.B -a : -defines the default owner of the -rest of the defined control group’s files. These users are -allowed to set subsystem parameters and create subgroups. -The default value is the same as has the parent cgroup. - -.TP -.B -d, --dperm=mode -sets the default permissions of a control groups directory. -The permissions needs to be specified as octal numbers e.g. -\fB-d 775\fR. - -.TP -.B -f, --fperm=mode -sets the default permissions of the control group files. -The permissions needs to be specified as octal numbers e.g. -\fB-f 775\fR. -The value is not used as given because the current owner's -permissions are used as an umask (so 777 will set group and -others permissions to the owners permissions). - -.TP -.B -s, --tperm=mode -sets the default permissions of the control group tasks files. -The permissions needs to be specified as octal numbers e.g. -\fB-f 775\fR. -The value is not used as given because the current owner's -permissions are used as an umask (so 777 will set group and -others permissions to the owners permissions). - -.TP -.B -t : -defines the default owner of tasks file of the defined control -group. I.e. this user and members -of this group have write access to the file. - -.LP - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH FILES -.TP -.B /etc/cgconfig.conf -default libcgroup configuration file -.TP -.B /etc/cgconfig.d/ -default libcgroup configuration files directory - -.SH EXAMPLES -.TP -.B cgconfigparser -l /etc/cgconfig.conf -setup control group file system based on \fB/etc/cgconfig.conf\fR configuration file - - -.SH SEE ALSO -cgconfig.conf (5) diff --git a/lib/libcgroup-3.1.0/doc/man/cgcreate.1 b/lib/libcgroup-3.1.0/doc/man/cgcreate.1 deleted file mode 100644 index 6d924849d14..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgcreate.1 +++ /dev/null @@ -1,113 +0,0 @@ -.\" Written by Ivana Hutarova Varekova - -.TH CGCREATE 1 2009-03-15 "Linux" "libcgroup Manual" -.SH NAME -cgcreate \- create new cgroup(s) - -.SH SYNOPSIS -\fBcgcreate\fR [\fB-h\fR] [\fB-b\fR] [\fB-c\fR] -[\fB-t\fR <\fItuid>:] [\fB-a\fR <\fIagid>:] -[\fB-f\fR mode] [\fB-d\fR mode] -[\fB-s\fR mode] \fB-g\fR <\fIcontrollers>: [\fB-g\fR ...] - -.SH DESCRIPTION -The command creates new cgroup(s) defined by the options -\fB-g\fR. - -.TP -.B -a : -defines the name of the user and the group which own the -rest of the defined control group’s files. These users are -allowed to set subsystem parameters and create subgroups. -The default value is the same as has the parent cgroup. - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B -c, --scope -creates a new systemd scope. The cgroup name provided after the -\fB-g\fR flag must be of the form -\fB.slice/.scope\fR. If the slice -does not exist, systemd will create it. Libcgroup will place an -idle process in the scope's cgroup.procs file unless the \fB-p\fR -flag is provided. - -.TP -.B -d, --dperm=mode -sets the permissions of a control groups directory. -The permissions needs to be specified as octal numbers e.g. -\fB-d 775\fR. - -.TP -.B -f, --fperm=mode -sets the permissions of the control groups parameters. -The permissions needs to be specified as octal numbers e.g. -\fB-f 775\fR. -The value is not used as given because the current owner's -permissions are used as an umask (so 777 will set group and -others permissions to the owners permissions). - -.TP -.B -g : -defines control groups to be added. -\fBcontrollers\fR is a list of controllers. Character "*" can be used -as a shortcut for "all mounted controllers". -\fBpath\fR is the relative path to control groups -in the given controllers list. This option can be specified -multiple times. - -.TP -.B -h, --help -display this help and exit - -.TP -.B -p, --pid=pid -moves the provided \fBpid\fR into the -\fB.slice/.scope\fR. Must be used in -conjunction with \fB-c\fR. - -.TP -.B -s, --tperm=mode -sets the permissions of the control group tasks file. -The permissions needs to be specified as octal numbers e.g. -\fB-s 775\fR. -The value is not used as given because the current owner's -permissions are used as an umask (so 777 will set group and -others permissions to the owners permissions). - -.TP -.B -S, --setdefault -sets the scope specified via the \fB-c\fR option as the default -libcgroup scope. This default scope is used by libcgroup tools -to build up the cgroup path. See the \fB-b\fR option. - -.TP -.B -t : -defines the name of the user and the group, which owns tasks -file of the defined control group. I.e. this user and members -of this group have write access to the file. -The default value is the same as has the parent cgroup. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH EXAMPLES -.TP -.B cgcreate -g *:student devices:teacher -create control group student in all mounted hierarchies and create -control group teacher in hierarchy containing controller devices. - - - - -.SH SEE ALSO -cgrules.conf (5) -cgexec (1) -cgclassify (1) diff --git a/lib/libcgroup-3.1.0/doc/man/cgdelete.1 b/lib/libcgroup-3.1.0/doc/man/cgdelete.1 deleted file mode 100644 index ffd0126daef..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgdelete.1 +++ /dev/null @@ -1,51 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Jan Safranek - -.TH CGDELETE 1 2009-10-26 "Linux" "libcgroup Manual" -.SH NAME - -cgdelete \- remove control group(s) - -.SH SYNOPSIS -\fBcgdelete\fR [\fB-h\fR] [\fB-r\fR] [\fB-b\fR] [[\fB-g\fR] -<\fIcontrollers\fR>:\fI] ... - -.SH DESCRIPTION -The \fBcgdelete\fR -program removes all specified control groups. - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B [-g] : -Defines the control group to delete. Multiple control groups may be -specified. -.B -g -is optional. - -.TP -.B -h, --help -Display this help and exit. - -.TP -.B -r, --recursive -Recursively remove all subgroups. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH EXAMPLES -.TP -.B cgdelete -g cpu,devices:/test -remove control group test from hierarchies containing cpu and device controllers - - -.SH SEE ALSO -cgcreate (1), lscgroup (1) diff --git a/lib/libcgroup-3.1.0/doc/man/cgexec.1 b/lib/libcgroup-3.1.0/doc/man/cgexec.1 deleted file mode 100644 index 1024a79a0ec..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgexec.1 +++ /dev/null @@ -1,106 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Varekova - -.TH CGEXEC 1 2009-03-15 "Linux" "libcgroup Manual" -.SH NAME - -cgexec \- run the task in given control groups - -.SH SYNOPSIS -\fBcgexec\fR [\fB-h\fR] [\fB-b\fR] [\fB-g\fR <\fIcontrollers>:] [--sticky] \fBcommand\fR [\fIarguments\fR] - -.SH DESCRIPTION -The \fBcgexec\fR -program executes the task \fBcommand\fR -with arguments \fBarguments\fR in the given control groups. - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B -g : -defines the control groups in which the task will be run. -\fBcontrollers\fR is a list of controllers and -\fBpath\fR is the relative path to control groups -in the given controllers list. - -This flag can be used multiple times to -define multiple pairs of lists of controllers -and relative paths. -Instead of the list of all mounted controllers, -the wildcard \fBb"*b"\fR can be used. - -If this option is not used, -\fBcgexec\fR will automatically place the task in the right -cgroup based on \fB/etc/cgrules.conf\fR. - -If \fB/etc/cgrules.conf\fR configuration file is used, there can be used -template names. Then the control group name contains -a template in destination tag (see \fBcgrules.conf\fR (5)) -and if the cgroup does not exist in execution time, -it is created, based on \fB/etc/cgconfig.conf\fR specification. -If the specifications are not present the group is created with the default -kernel values. - -.TP -.B -h, --help -Display this help and exit. - -.TP -.B -r -Replaces systemd scope's idle process with the task \fBcommand\fR. - -.TP -.B --sticky -If running the task \fBcommand\fR with this option, the daemon of -service cgred (cgrulesengd process) does not change both the task -of the \fBcommand\fR and the child tasks. Without this option, -the daemon does not change the task of the \fBcommand\fR but it -changes the child tasks to the right cgroup based on -\fB/etc/cgrules.conf\fR automatically. - -.LP - -.SH EXAMPLES - -.nf -.ft B -cgexec -g *:test1 ls -.ft R -.fi -runs command \fBls\fR in control group test1 -in all mounted controllers. - -.nf -.ft B -cgexec -g cpu,memory:test1 ls -l -.ft R -.fi -runs command \fBls -l\fR in control group test1 -in controllers cpu and memory. - -.nf -.ft B -cgexec -g cpu,memory:test1 -g swap:test2 ls -l -.ft R -.fi -runs command \fBls -l\fR in control group test1 -in controllers cpu and memory and control group -test2 in controller swap. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH FILES -.TP -.B /etc/cgrules.conf -default libcgroup configuration file - -.SH SEE ALSO -cgrules.conf (5) diff --git a/lib/libcgroup-3.1.0/doc/man/cgget.1 b/lib/libcgroup-3.1.0/doc/man/cgget.1 deleted file mode 100644 index bba60682f9e..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgget.1 +++ /dev/null @@ -1,115 +0,0 @@ -.\" Copyright (C) 2010 Red Hat, Inc. All Rights Reserved. -.\" Written by Jan Safranek - -.TH CGGET 1 2010-01-18 "Linux" "libcgroup Manual" -.SH NAME - -cgget \- print parameter(s) of given group(s) - -.SH SYNOPSIS -\fBcgget\fR [\fB-n\fR] [\fB-v\fR] [\fB-m\fR] [\fB-b\fR] [\fB-r\fR <\fIname\fR>] -[\fB-g\fR <\fIcontroller\fR>] [\fB-a\fR] <\fBpath\fR> ... -.br -\fBcgget\fR [\fB-n\fR] [\fB-v\fR] [\fB-m\fR] [\fB-b\fR] [\fB-r\fR <\fIname\fR>] -\fB-g\fR <\fIcontroller\fR>:<\fBpath\fR> ... - -.SH DESCRIPTION -Prints the parameter(s) of input cgroup(s). -If neither controller nor variable are specified, -the values of all possible variables are displayed. - -.TP -.B -is the name of the cgroup which should be read. -This parameter can be used multiple times. - -.TP -.B -a, --all -print the variables for all controllers which consist in the given cgroup - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B -c -displays the controllers and their versions. -This option can be used along with -m option. - -.TP -.B -g -defines controllers whose values should be displayed. -This option can be used multiple times. - -.TP -.B -g : -defines control groups whose values should be displayed. -This option can be used multiple times. - -.TP -.B -h, --help -display help and exit - -.TP -.B -m -displays the current control groups setup mode. The control groups can be set up in one of three modes, -legacy (cgroup v1 only), unified (cgroup v2 only) or hybrid (cgroup v1/v2). - -.TP -.B -n -do not print headers, i.e. names of groups. - -.TP -.B -r, --variable -defines parameter to display. -This option can be used multiple times. - - -.TP -.B -v, --values-only -print only values, not parameter names. - -.SH EXAMPLES -.nf -$ cgget -r cpuset.cpus -r cpuset.mems first second -first: -cpuset.cpus=0-1 -cpuset.mems=0 - -second: -cpuset.cpus=0 -cpuset.mems=0 - -$ cgget -n -r cpuset.cpus -r cpuset.mems first second -cpuset.cpus=0-1 -cpuset.mems=0 -cpuset.cpus=0 -cpuset.mems=0 - -$ cgget -nv -r cpuset.cpus -r cpuset.mems first second -0-1 -0 -0 -0 - -$ cgget -n -g cpu / -cpu.rt_period_us=1000000 -cpu.rt_runtime_us=950000 -cpu.shares=1024 - -$ cgget -m -Unified Mode (Cgroup v2 only). - -.fi - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH SEE ALSO -cgrules.conf (1), cgcreate (1), cgget (1) - diff --git a/lib/libcgroup-3.1.0/doc/man/cgred.conf.5 b/lib/libcgroup-3.1.0/doc/man/cgred.conf.5 deleted file mode 100644 index 63b031d3f16..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgred.conf.5 +++ /dev/null @@ -1,49 +0,0 @@ -.\" Copyright (C) 2006 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Varekova . - -.TH CGRED.CONF 5 2009-03-16 "Linux" "libcgroup Manual" -.SH NAME -cgred.conf \- libcgroup configuration file -.SH DESCRIPTION -\fBcgred.conf\fR is cgred service configuration file. -In this file there could be defined several internal values. -Defining anything else in this file will cause the -CGroup Rules Daemon program to fail. -.TP - -\fBCONFIG_FILE\fR -specifies the configuration file for cgred service - -.TP -\fBLOG_FILE\fR -variable specifies the file to which logs will be written -(by default they are not sent to a file but to syslog) - -.TP -\fBNODAEMON\fR -if it is equal to "--nodaemon" then -run cgred in non-daemon mode - -.TP -\fBLOG\fR -define the verbosity of logging. Accepted values are '-v', '-vv', '-q' -and '--nolog'. -.LP - - -.SH FILES -.LP -.PD .1v -.TP 20 -.B /etc/cgred.conf -.TP -default libcgroup configuration file -.PD . - -.SH SEE ALSO -cgrules.conf (5), -cgconfig.conf (5), cgrules.d (5) - - - - diff --git a/lib/libcgroup-3.1.0/doc/man/cgrules.conf.5 b/lib/libcgroup-3.1.0/doc/man/cgrules.conf.5 deleted file mode 100644 index 1971b5cb8da..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgrules.conf.5 +++ /dev/null @@ -1,165 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Varekova - -.TH CGRULES.CONF 5 2009-03-10 "Linux" "libcgroup Manual" -.SH NAME -cgrules.conf \- libcgroup configuration file -.SH DESCRIPTION -.B "cgrules.conf" -configuration file is used by -.B libcgroups -to define control groups to which a process belongs. - - -The file contains a list of rules which assign to a defined group/user a control -group in a subsystem (or control groups in subsystems). - -Rules have two formats: - -.in +4n -.nf - -.fi -.nf -: -.fi -.in - -Where: - -.I user -can be: -.nf - - a user name - - a group name with @group syntax - - the wildcard '*', for any user or group - - '%', which is equivalent to "ditto" (useful for - multi-line rules where different cgroups need to be - specified for various hierarchies for a single user) -.fi - -.I process name -is optional and it can be: -.nf - - a process name - - a full command path of a process -.fi - -.I controllers -can be: -.nf - - comma separated controller names (no spaces) or - - * (for all mounted controllers) -.fi - -.I destination -can be: -.nf - - path relative to the controller hierarchy (ex. pgrp1/gid1/uid1) - - following strings called "\fBtemplates\fR" and will get expanded - - %u username, uid if name resolving fails - %U uid - %g group name, gid if name resolving fails - %G gid - %p process name, pid if name not available - %P pid - - '\\' can be used to escape '%' -.fi -First rule which matches the criteria will be executed. - -Any text starting with '#' is considered as a start of comment line and is -ignored. - -If the -.I destination -contains -.B template -string, the control group can be created on-fly. In time when some process wants -to use the template rule which leads to control group (see -\fBcgexec\fR (1)) and the control group does not exist, the group is created. The -template control group parameters can be specified in -.B cgconfig.conf -configuration file. See (\fBcgconfig.conf\fR (5)). -If the template definition is not found there created group have default -kernel setting. - -To create a hierarchy of configuration files, use \fB/etc/cgrules.d\fR directory. - -.SH EXAMPLES -.nf -student devices /usergroup/students -.fi -Student's processes in the 'devices' subsystem belong to the control -group /usergroup/students. - -.nf -student:cp devices /usergroup/students/cp -.fi -When student executes 'cp' command, the processes in the 'devices' subsystem -belong to the control group /usergroup/students/cp. - -.nf -@admin * admingroup/ -.fi -Processes started by anybody from admin group no matter in what subsystem belong -to the control group admingroup/. - -.nf -peter cpu test1/ -% memory test2/ -.fi -The first line says Peter's task for cpu controller belongs to test1 control -group. The second one says Peter's tasks for memory controller belong to test2/ -control group. - -.nf -* * default/ -.fi -All processes in any subsystem belong to the control group default/. Since -the earliest matched rule is applied, it makes sense to have this line -at the end of the list. It will put a task which was not mentioned in the -previous rules to default/ control group. - -.nf -@students cpu,cpuacct students/%u -.fi -Processes in cpu and cpuacct subsystems started by anybody from students group -belong to group students/name. Where "name" is user name of owner of the -process. - - - -.SH FILES -.LP -.PD .1v -.TP 20 -.B /etc/cgrules.conf -.RS 6 -default libcgroup configuration file -.RE -.TP 20 -.B /etc/cgrules.d -.RS 6 -default libcgroup configuration files directory -.RE -.PD - - -.SH SEE ALSO -cgconfig.conf (5), cgclassify (1), cgred.conf (5), cgrules.d (5) - -.SH BUGS - - - - - - - - - - - - diff --git a/lib/libcgroup-3.1.0/doc/man/cgrulesengd.8 b/lib/libcgroup-3.1.0/doc/man/cgrulesengd.8 deleted file mode 100644 index cf45611853d..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgrulesengd.8 +++ /dev/null @@ -1,84 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Jan Safranek . -.TH CGRULESENGD 8 2009-02-18 "Linux" "libcgroup Manual" -.SH NAME -cgrulesengd \- control group rules daemon - -.SH SYNOPSIS -\fBcgrulesengd\fR [options] - -.SH DESCRIPTION -\fBcgrulesengd\fR is a daemon, which distributes processes to control groups. When -any process changes its effective UID or GID, \fBcgrulesengd\fR inspects the list -of rules loaded from the \fIcgrules.conf\fR file and files in \fIcgrules.d\fR -(see \fBcgrules.d\fR (5) for potential conflicts) directory -and moves the process to the appropriate control group. - -The list of rules is read during the daemon startup and cached in the daemon's memory. -The daemon reloads the list of rules when it receives SIGUSR2 signal. -The daemon reloads the list of templates when it receives SIGUSR1 signal. - -The daemon opens a standard unix socket to receive 'sticky' requests from \fBcgexec\fR. - -.SH OPTIONS -.TP -.B -h|--help -Display help. -.TP -.B -f |--logfile= -Write log messages to the given log file. When '-' is used as , log messages -are written to the standard output. If '\fB-f\fR' and '\fB-s\fR' are used together, -the logs are sent to both destinations. - -.TP -.B -s[facility]|--syslog=[facility] -Write log messages to syslog. The default facility is DAEMON. If '\fB-f\fR' -and '\fB-s\fR' are used together, the logs are sent to both destinations. -.TP -.B -n|--nodaemon -Don't fork the daemon, stay in the foreground. -.TP -.B -v|--verbose -Display more log messages. This option can be used three times to enable more -verbose log messages. -.TP -.B -q|--quiet -Display less log messages. -.TP -.B -Q|--nolog -Disable logging. -.TP -.B -d|--debug -Equivalent to '-nvvvf -', i.e. don't fork the daemon, display all log messages and -write them to the standard output. -.TP -.B -u |--socket-user= -.B -g |--socket-group= -Set the owner of cgrulesengd socket. Assumes that \fBcgexec\fR runs with proper -suid permissions so it can write to the socket when \fBcgexec\fR --sticky is used. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH FILES -.TP -.B /etc/cgrules.conf -default libcgroup configuration file - -.TP -.B /etc/cgrules.d -default libcgroup configuration files directory - -.TP -.B /etc/cgconfig.conf -default templates file - -.TP -.B /etc/cgconfig.d -default templates directory - -.SH SEE ALSO -cgrules.conf (5), cgrules.d (5) diff --git a/lib/libcgroup-3.1.0/doc/man/cgset.1 b/lib/libcgroup-3.1.0/doc/man/cgset.1 deleted file mode 100644 index 91561773487..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgset.1 +++ /dev/null @@ -1,57 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Hutarova Varekova - -.TH CGSET 1 2009-03-15 "Linux" "libcgroup Manual" -.SH NAME - -cgset \- set the parameters of given cgroup(s) - -.SH SYNOPSIS -\fBcgset\fR [\fB-b\fR] [\fB-r\fR <\fIname=value\fR>] <\fBcgroup_path\fR> ... -.br -\fBcgset\fR [\fB-b\fR] \fB--copy-from\fR <\fIsource_cgroup_path\fR> <\fBcgroup_path\fR> ... - -.SH DESCRIPTION -Set the parameters of input cgroups. - -.TP -.B -is the name of the cgroup which should be changed. -This parameter can be used multiple times. - -.TP -.B -b -ignores the default systemd delegated hierarchy path and -constructs the path of the control groups relative to the -cgroup root hierarchy. - -.TP -.B -r -defines the name of the file to set and -the value which should be written to that file. -This parameter can be used multiple times. - -.TP -.B --copy-from -defines the name of the cgroup whose parameters will be -copied to the input cgroup. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH EXAMPLES -.TP -.B cgset -r cpuset.cpus=0-1 student -set variable cpus in control group student (controller cpuset) to 0-1 - -.TP -.B cgset --copy-from group1/ group2/ -copy all parameters of group group1 to group group2 -(for all path where both cgroups are defined) - - -.SH SEE ALSO -cgrules.conf (1), cgcreate (1), cgget (1) diff --git a/lib/libcgroup-3.1.0/doc/man/cgsnapshot.1 b/lib/libcgroup-3.1.0/doc/man/cgsnapshot.1 deleted file mode 100644 index 22de6161574..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgsnapshot.1 +++ /dev/null @@ -1,113 +0,0 @@ -.\" Copyright (C) 2010 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Hutarova Varekova - -.TH CGSNAPSHOT 1 2010-07-28 "Linux" "libcgroup Manual" -.SH NAME - -cgsnapshot \- generate the configuration file for given controllers - -.SH SYNOPSIS -\fBcgsnapshot\fR [\fB-h\fR] [\fB-s\fR] [\fB-t\fR] [\fB-b\fR \fIfile\fR] -[\fB-w\fR \fIfile\fR] [\fB-f\fR \fIoutput_file\fR] [\fBcontroller\fR] [...] - -.SH DESCRIPTION -\fBcgsnapshot\fR -generates the cgconfig compatible configuration file -for the given controllers. -If no controller is set, then -cgsnapshot shows all mounted hierarchies. -The output is in the same format as the -.B cgconfig.conf -configuration file. - -.TP -.B -b file -Display only variables from the denylist. -The default location of the denylist is -.B /etc/cgsnapshot_denylist.conf. -This list contains all variables which should be ignored by the -.B cgsnapshot -. -If the variable is denylisted, it will not be displayed. -If it is not present on the denylist, the allowlist -is checked. - -.TP -.B -h, --help -display this help and exit - -.TP -.B -f, --file -Redirect the output to output_file - - -.TP -.B -s, --silent -Ignore all warnings - -.TP -.B -t, --strict -Do not display the variables which are not on the allowlist - - -.TP -.B -w file -Set the denylist configuration file. -This list contains all variables which should be displayed by -.B cgsnapshot -. -If the variable is not denylisted, the allowlist is checked. -If the variable is on the allowlist, it is displayed by -.B cgsnapshot -. -If the variable is not on the allowlist, -the variable is displayed and a warning message is produced. -By default the allowlist is not used. - -The warning message can be omitted using the -.B -s, --silent -flag. -If the -.B -t, --strict -flag is used, the variable which is not on the allowlist is -not displayed. - -.TP -.B controller -defines the controller whose hierarchies will be -output - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH FILES -.TP -.B /etc/cgsnapshot_denylist.conf -default denylist - -.TP -.B /etc/cgsnapshot_allowlist.conf -default allowlist - -.TP -.B /etc/cgconfig.conf -default libcgroup configuration file - -.SH EXAMPLES -.TP -.B cgsnapshot -s -f /etc/cgconfig.conf.cgsnapshot -create configuration file which contains all mounted controllers and all -control groups which are on the actual system - -.TP -.B cgsnapshot -s -f /etc/cgconfig.conf.cgsnapshot cpu -create configuration file which contains hierarchy containing cpu controller and all its -control groups on the actual system - - - -.SH SEE ALSO -cgconfig.conf (5) diff --git a/lib/libcgroup-3.1.0/doc/man/cgxget.1 b/lib/libcgroup-3.1.0/doc/man/cgxget.1 deleted file mode 100644 index b06adaef34e..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgxget.1 +++ /dev/null @@ -1,127 +0,0 @@ -.TH CGXGET 1 2022-08-03 "Linux" "libcgroup Manual" -.SH NAME - -cgxget \- print parameter(s) of given group(s) - -.SH SYNOPSIS -\fBcgxget\fR [\fB-1\fR] [\fB-2\fR] [\fB-i\fR] [\fB-n\fR] [\fB-v\fR] [\fB-b\fR] [\fB-r\fR <\fIname\fR>] -[\fB-g\fR <\fIcontroller\fR>] [\fB-a\fR] <\fBpath\fR> ... -.br -\fBcgxget\fR [\fB-1\fR] [\fB-2\fR] [\fB-i\fR] [\fB-n\fR] [\fB-v\fR] [\fB-b\fR] [\fB-r\fR <\fIname\fR>] -\fB-g\fR <\fIcontroller\fR>:<\fBpath\fR> ... - -.SH DESCRIPTION -Prints the parameter(s) of input cgroup(s). -If neither controller nor variable are specified, -the values of all possible variables are displayed. -When the request's cgroup version differs from the system's cgroup version, \fBcgxget\fR will -attempt to translate from one version to the other. -If the request version and the system's version are the same, no translation is done and -\fBcgxget\fR will behave like \fBcgget\fR. -If no version is specified by the user (either [\fB-1\fR] or [\fB-2\fR]), the behavior is -undefined. - -.TP -.B -is the name of the cgroup which should be read. -This parameter can be used multiple times. - -.TP -.B -1, --v1 -data in/out of \fBcgxget\fR is in cgroup v1 format. -In this mode, the user will provide values in cgroup v1 format and receive values in v1 format. -format. -If the system is running in cgroup v2 mode, libcgroup will convert the data as necessary - -.TP -.B -2, --v2 -data in/out of \fBcgxget\fR is in cgroup v2 format. -In this mode, the user will provide values in cgroup v2 format and receive values in v2 format. -If the system is running in cgroup v1 mode, libcgroup will convert the data as necessary - -.TP -.B -a, --all -print the variables for all controllers which consist in the given cgroup - -.TP -.B -b -ignores the default systemd delegated hierarchy path and constructs the path of the control groups -relative to the cgroup root hierarchy. - -.TP -.B -g -defines controllers whose values should be displayed. -This option can be used multiple times. - -.TP -.B -g : -defines control groups whose values should be displayed. -This option can be used multiple times. - -.TP -.B -h, --help -display help and exit - -.TP -.B -i, --ignore-unmappable -ignore errors for values that cannot be converted from v1 to v2 or vice versa - -.TP -.B -n -do not print headers, i.e. names of groups. - -.TP -.B -r, --variable -defines parameter to display. -This option can be used multiple times. - - -.TP -.B -v, --values-only -print only values, not parameter names. - -.SH EXAMPLES -.nf -$ cgxget -1 -r cpuset.cpus -r cpuset.mems first second -first: -cpuset.cpus=0-1 -cpuset.mems=0 - -second: -cpuset.cpus=0 -cpuset.mems=0 - -$ cgxget -1 -n -r cpuset.cpus -r cpuset.mems first second -cpuset.cpus=0-1 -cpuset.mems=0 -cpuset.cpus=0 -cpuset.mems=0 - -$ cgxget -1 -nv -r cpuset.cpus -r cpuset.mems first second -0-1 -0 -0 -0 - -$ cgxget -1 -n -g cpu / -cpu.rt_period_us=1000000 -cpu.rt_runtime_us=950000 -cpu.shares=1024 - -$ cgxget -2 -r cpu.max first -first: -cpu.max: max 100000 - -.fi - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH AUTHOR -Tom Hromatka - -.SH SEE ALSO -cgrules.conf (1), cgcreate (1), cgget (1), cgset (1), cgxset (1) diff --git a/lib/libcgroup-3.1.0/doc/man/cgxset.1 b/lib/libcgroup-3.1.0/doc/man/cgxset.1 deleted file mode 100644 index cb384513f02..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/cgxset.1 +++ /dev/null @@ -1,81 +0,0 @@ -.TH CGXSET 1 2022-08-03 "Linux" "libcgroup Manual" -.SH NAME - -cgxset \- set the parameters of given cgroup(s) - -.SH SYNOPSIS -\fBcgxset\fR [\fB-1\fR] [\fB-2\fR] [\fB-i\fR] [\fB-b\fR] [\fB-r\fR <\fIname=value\fR>] <\fBcgroup_path\fR> ... -.br -\fBcgxset\fR [\fB-b\fR] \fB--copy-from\fR <\fIsource_cgroup_path\fR> <\fBcgroup_path\fR> ... - -.SH DESCRIPTION -Set the parameters of input cgroups. -When the request's cgroup version differs from the system's cgroup version, \fBcgxset\fR will -attempt to translate from one version to the other. -If the request version and the system's version are the same, no translation is done and -\fBcgxset\fR will behave like \fBcgset\fR. -If no version is specified by the user (either [\fB-1\fR] or [\fB-2\fR]) and the [\fB-r\fR] flag -is specified, the behavior is undefined. -\fB--copy-from\fR does not require the cgroup version to be specified. - -.TP -.B -is the name of the cgroup which should be changed. -This parameter can be used multiple times. - -.TP -.B -1, --v1 -data in/out of \fBcgxset\fR is in cgroup v1 format. -In this mode, the user will provide values in cgroup v1 format and receive values in v1 format. -format. -If the system is running in cgroup v2 mode, libcgroup will convert the data as necessary - -.TP -.B -2, --v2 -data in/out of \fBcgxset\fR is in cgroup v2 format. -In this mode, the user will provide values in cgroup v2 format and receive values in v2 format. -If the system is running in cgroup v1 mode, libcgroup will convert the data as necessary - -.TP -.B -b -ignores the default systemd delegated hierarchy path and constructs the path of the control groups -relative to the cgroup root hierarchy. - -.TP -.B -i, --ignore-unmappable -ignore errors for values that cannot be converted from v1 to v2 or vice versa - -.TP -.B -r -defines the name of the file to set and -the value which should be written to that file. -This parameter can be used multiple times. - -.TP -.B --copy-from -defines the name of the cgroup whose parameters will be -copied to the input cgroup. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH EXAMPLES -.TP -.B cgxset -1 -r cpuset.cpus=0-1 student -set variable cpus in control group student (controller cpuset) to 0-1 - -.TP -.B cgxset -2 -r cpu.weight=42 first -set variable weight in control group first (controller cpu) to 42 - -.TP -.B cgxset --copy-from group1/ group2/ -copy all parameters of group group1 to group group2 -(for all path where both cgroups are defined) - - -.SH SEE ALSO -cgrules.conf (1), cgcreate (1), cgget (1), cgset (1), cgxget (1) diff --git a/lib/libcgroup-3.1.0/doc/man/lscgroup.1 b/lib/libcgroup-3.1.0/doc/man/lscgroup.1 deleted file mode 100644 index af4ab6b32b8..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/lscgroup.1 +++ /dev/null @@ -1,49 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Hutarova Varekova - -.TH LSCGROUP 1 2009-11-05 "Linux" "libcgroup Manual" -.SH NAME - -lscgroup \- list all cgroups - -.SH SYNOPSIS -\fBlscgroup\fR [[\fB-g\fR] <\fIcontrollers>:] [...] -.br -\fBlscgroup\fR [\fB-h|--help\fR] - -.SH DESCRIPTION -List all/chosen cgroups. - -.TP -.B : -defines the control groups whose subgroups will be shown. -If this parameter is not used, the command will -list all existing cgroups. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.SH EXAMPLES -.TP -.B lscgroup -g cpu:/ -list all cgroups which are in hierarchy containing cpu controller - -.TP -.B lscgroup -g cpu:/student -list all cgroups which are in hierarchy containing cpu controller -in subgroup student - -.TP -.B lscgroup -list all cgroups which in all hierarchies - -.SH NOTES -.TP -lscgroup is currently supported on cgroups v1 only. - -.SH SEE ALSO -lssubsys (1), cgcreate (1), cgdelete (1), -cgconfig.conf (5) diff --git a/lib/libcgroup-3.1.0/doc/man/lssubsys.1 b/lib/libcgroup-3.1.0/doc/man/lssubsys.1 deleted file mode 100644 index 1c49445e068..00000000000 --- a/lib/libcgroup-3.1.0/doc/man/lssubsys.1 +++ /dev/null @@ -1,101 +0,0 @@ -.\" Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. -.\" Written by Ivana Hutarova Varekova - -.TH LSSUBSYS 1 2009-11-05 "Linux" "libcgroup Manual" -.SH NAME - -lssubsys \- list hierarchies containing given subsystem - -.SH SYNOPSIS -\fBlssubsys\fR [\fB-m|--mount-points\fR] [\fB-M|--all-mount-points\fR] -[\fIcontroller\fR] [...] -.br -\fBlssubsys\fR [\fB-m|--mount-points\fR] [\fB-M|--all-mount-points\fR] -[\fB-i|--hierarchies\fR] [\fB-a|--all\fR] -.br -\fBlssubsys\fR [\fB-h|--help\fR] - -.SH DESCRIPTION -\fBlssubsys\fR list the hierarchies containing -the given subsystem(s). If no subsystem is defined, it -displays all mounted hierarchies. - -.TP -.B controller -defines the subsystem whose hierarchy is shown. -If this parameter is not used, the command will -list all mounted subsystems. - -.TP -.B -m, --mount-points -Display mount points. Only the first mount points of shown hierarchies are displayed. - -.TP -.B -M, --all-mount-points -Display mount points. All mount points of shown hierarchies are displayed, each on -separate line. - -.TP -.B -a, --all -Display all subsystems (including unmounted ones). - -.TP -.B -i, --hierarchies -Display the attached hierarchy number if the subsystem is in a hierarchy. -If the option -.B -m -is also used, the hierarchy number is shown only for unmounted hierarchies. - -.TP -.B -h, --help -Display help and exit. - -.SH EXAMPLE -The command -.B lssubsys -am -lists all subsystems which are present in the system, -mounted ones will be shown with their mount point: -.RS -.nf -$ lssubsys -am -ns -cpuset -cpu,devices -cpuacct /cgroup/cpuacct -memory /cgroup/memory -freezer /cgroup/freezer -net_cls /cgroup/net_cls -.fi -.RE -.LP -The command -.B lssubsys -ami -lists all subsystems which are present in the system, -mounted subsystems are listed with their mount points, -unmounted ones which are in a hierarchy are listed with their hierarchy number: -.RS -.nf -$ lssubsys -ami -ns -cpuset 5 -cpu,devices 6 -cpuacct /cgroup/cpuacct -memory /cgroup/memory -freezer /cgroup/freezer -net_cls /cgroup/net_cls -.fi - -.SH NOTES -.TP -lssubsys is currently supported on cgroups v1 only. - -.SH ENVIRONMENT VARIABLES -.TP -.B CGROUP_LOGLEVEL -controls verbosity of the tool. Allowed values are \fBDEBUG\fR, -\fBINFO\fR, \fBWARNING\fR or \fBERROR\fR. - -.RE -.SH SEE ALSO -lscgroup (1), cgcreate (1), cgdelete (1), -cgconfig.conf (5) diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-death-test.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-death-test.h deleted file mode 100644 index 957a69c6a9e..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-death-test.h +++ /dev/null @@ -1,294 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file defines the public API for death tests. It is -// #included by gtest.h so a user doesn't need to include this -// directly. - -#ifndef GTEST_INCLUDE_GTEST_GTEST_DEATH_TEST_H_ -#define GTEST_INCLUDE_GTEST_GTEST_DEATH_TEST_H_ - -#include "gtest/internal/gtest-death-test-internal.h" - -namespace testing { - -// This flag controls the style of death tests. Valid values are "threadsafe", -// meaning that the death test child process will re-execute the test binary -// from the start, running only a single death test, or "fast", -// meaning that the child process will execute the test logic immediately -// after forking. -GTEST_DECLARE_string_(death_test_style); - -#if GTEST_HAS_DEATH_TEST - -namespace internal { - -// Returns a Boolean value indicating whether the caller is currently -// executing in the context of the death test child process. Tools such as -// Valgrind heap checkers may need this to modify their behavior in death -// tests. IMPORTANT: This is an internal utility. Using it may break the -// implementation of death tests. User code MUST NOT use it. -GTEST_API_ bool InDeathTestChild(); - -} // namespace internal - -// The following macros are useful for writing death tests. - -// Here's what happens when an ASSERT_DEATH* or EXPECT_DEATH* is -// executed: -// -// 1. It generates a warning if there is more than one active -// thread. This is because it's safe to fork() or clone() only -// when there is a single thread. -// -// 2. The parent process clone()s a sub-process and runs the death -// test in it; the sub-process exits with code 0 at the end of the -// death test, if it hasn't exited already. -// -// 3. The parent process waits for the sub-process to terminate. -// -// 4. The parent process checks the exit code and error message of -// the sub-process. -// -// Examples: -// -// ASSERT_DEATH(server.SendMessage(56, "Hello"), "Invalid port number"); -// for (int i = 0; i < 5; i++) { -// EXPECT_DEATH(server.ProcessRequest(i), -// "Invalid request .* in ProcessRequest()") -// << "Failed to die on request " << i; -// } -// -// ASSERT_EXIT(server.ExitNow(), ::testing::ExitedWithCode(0), "Exiting"); -// -// bool KilledBySIGHUP(int exit_code) { -// return WIFSIGNALED(exit_code) && WTERMSIG(exit_code) == SIGHUP; -// } -// -// ASSERT_EXIT(client.HangUpServer(), KilledBySIGHUP, "Hanging up!"); -// -// On the regular expressions used in death tests: -// -// On POSIX-compliant systems (*nix), we use the library, -// which uses the POSIX extended regex syntax. -// -// On other platforms (e.g. Windows), we only support a simple regex -// syntax implemented as part of Google Test. This limited -// implementation should be enough most of the time when writing -// death tests; though it lacks many features you can find in PCRE -// or POSIX extended regex syntax. For example, we don't support -// union ("x|y"), grouping ("(xy)"), brackets ("[xy]"), and -// repetition count ("x{5,7}"), among others. -// -// Below is the syntax that we do support. We chose it to be a -// subset of both PCRE and POSIX extended regex, so it's easy to -// learn wherever you come from. In the following: 'A' denotes a -// literal character, period (.), or a single \\ escape sequence; -// 'x' and 'y' denote regular expressions; 'm' and 'n' are for -// natural numbers. -// -// c matches any literal character c -// \\d matches any decimal digit -// \\D matches any character that's not a decimal digit -// \\f matches \f -// \\n matches \n -// \\r matches \r -// \\s matches any ASCII whitespace, including \n -// \\S matches any character that's not a whitespace -// \\t matches \t -// \\v matches \v -// \\w matches any letter, _, or decimal digit -// \\W matches any character that \\w doesn't match -// \\c matches any literal character c, which must be a punctuation -// . matches any single character except \n -// A? matches 0 or 1 occurrences of A -// A* matches 0 or many occurrences of A -// A+ matches 1 or many occurrences of A -// ^ matches the beginning of a string (not that of each line) -// $ matches the end of a string (not that of each line) -// xy matches x followed by y -// -// If you accidentally use PCRE or POSIX extended regex features -// not implemented by us, you will get a run-time failure. In that -// case, please try to rewrite your regular expression within the -// above syntax. -// -// This implementation is *not* meant to be as highly tuned or robust -// as a compiled regex library, but should perform well enough for a -// death test, which already incurs significant overhead by launching -// a child process. -// -// Known caveats: -// -// A "threadsafe" style death test obtains the path to the test -// program from argv[0] and re-executes it in the sub-process. For -// simplicity, the current implementation doesn't search the PATH -// when launching the sub-process. This means that the user must -// invoke the test program via a path that contains at least one -// path separator (e.g. path/to/foo_test and -// /absolute/path/to/bar_test are fine, but foo_test is not). This -// is rarely a problem as people usually don't put the test binary -// directory in PATH. -// -// TODO(wan@google.com): make thread-safe death tests search the PATH. - -// Asserts that a given statement causes the program to exit, with an -// integer exit status that satisfies predicate, and emitting error output -// that matches regex. -# define ASSERT_EXIT(statement, predicate, regex) \ - GTEST_DEATH_TEST_(statement, predicate, regex, GTEST_FATAL_FAILURE_) - -// Like ASSERT_EXIT, but continues on to successive tests in the -// test case, if any: -# define EXPECT_EXIT(statement, predicate, regex) \ - GTEST_DEATH_TEST_(statement, predicate, regex, GTEST_NONFATAL_FAILURE_) - -// Asserts that a given statement causes the program to exit, either by -// explicitly exiting with a nonzero exit code or being killed by a -// signal, and emitting error output that matches regex. -# define ASSERT_DEATH(statement, regex) \ - ASSERT_EXIT(statement, ::testing::internal::ExitedUnsuccessfully, regex) - -// Like ASSERT_DEATH, but continues on to successive tests in the -// test case, if any: -# define EXPECT_DEATH(statement, regex) \ - EXPECT_EXIT(statement, ::testing::internal::ExitedUnsuccessfully, regex) - -// Two predicate classes that can be used in {ASSERT,EXPECT}_EXIT*: - -// Tests that an exit code describes a normal exit with a given exit code. -class GTEST_API_ ExitedWithCode { - public: - explicit ExitedWithCode(int exit_code); - bool operator()(int exit_status) const; - private: - // No implementation - assignment is unsupported. - void operator=(const ExitedWithCode& other); - - const int exit_code_; -}; - -# if !GTEST_OS_WINDOWS -// Tests that an exit code describes an exit due to termination by a -// given signal. -class GTEST_API_ KilledBySignal { - public: - explicit KilledBySignal(int signum); - bool operator()(int exit_status) const; - private: - const int signum_; -}; -# endif // !GTEST_OS_WINDOWS - -// EXPECT_DEBUG_DEATH asserts that the given statements die in debug mode. -// The death testing framework causes this to have interesting semantics, -// since the sideeffects of the call are only visible in opt mode, and not -// in debug mode. -// -// In practice, this can be used to test functions that utilize the -// LOG(DFATAL) macro using the following style: -// -// int DieInDebugOr12(int* sideeffect) { -// if (sideeffect) { -// *sideeffect = 12; -// } -// LOG(DFATAL) << "death"; -// return 12; -// } -// -// TEST(TestCase, TestDieOr12WorksInDgbAndOpt) { -// int sideeffect = 0; -// // Only asserts in dbg. -// EXPECT_DEBUG_DEATH(DieInDebugOr12(&sideeffect), "death"); -// -// #ifdef NDEBUG -// // opt-mode has sideeffect visible. -// EXPECT_EQ(12, sideeffect); -// #else -// // dbg-mode no visible sideeffect. -// EXPECT_EQ(0, sideeffect); -// #endif -// } -// -// This will assert that DieInDebugReturn12InOpt() crashes in debug -// mode, usually due to a DCHECK or LOG(DFATAL), but returns the -// appropriate fallback value (12 in this case) in opt mode. If you -// need to test that a function has appropriate side-effects in opt -// mode, include assertions against the side-effects. A general -// pattern for this is: -// -// EXPECT_DEBUG_DEATH({ -// // Side-effects here will have an effect after this statement in -// // opt mode, but none in debug mode. -// EXPECT_EQ(12, DieInDebugOr12(&sideeffect)); -// }, "death"); -// -# ifdef NDEBUG - -# define EXPECT_DEBUG_DEATH(statement, regex) \ - GTEST_EXECUTE_STATEMENT_(statement, regex) - -# define ASSERT_DEBUG_DEATH(statement, regex) \ - GTEST_EXECUTE_STATEMENT_(statement, regex) - -# else - -# define EXPECT_DEBUG_DEATH(statement, regex) \ - EXPECT_DEATH(statement, regex) - -# define ASSERT_DEBUG_DEATH(statement, regex) \ - ASSERT_DEATH(statement, regex) - -# endif // NDEBUG for EXPECT_DEBUG_DEATH -#endif // GTEST_HAS_DEATH_TEST - -// EXPECT_DEATH_IF_SUPPORTED(statement, regex) and -// ASSERT_DEATH_IF_SUPPORTED(statement, regex) expand to real death tests if -// death tests are supported; otherwise they just issue a warning. This is -// useful when you are combining death test assertions with normal test -// assertions in one test. -#if GTEST_HAS_DEATH_TEST -# define EXPECT_DEATH_IF_SUPPORTED(statement, regex) \ - EXPECT_DEATH(statement, regex) -# define ASSERT_DEATH_IF_SUPPORTED(statement, regex) \ - ASSERT_DEATH(statement, regex) -#else -# define EXPECT_DEATH_IF_SUPPORTED(statement, regex) \ - GTEST_UNSUPPORTED_DEATH_TEST_(statement, regex, ) -# define ASSERT_DEATH_IF_SUPPORTED(statement, regex) \ - GTEST_UNSUPPORTED_DEATH_TEST_(statement, regex, return) -#endif - -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_GTEST_DEATH_TEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-message.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-message.h deleted file mode 100644 index fe879bca792..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-message.h +++ /dev/null @@ -1,250 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file defines the Message class. -// -// IMPORTANT NOTE: Due to limitation of the C++ language, we have to -// leave some internal implementation details in this header file. -// They are clearly marked by comments like this: -// -// // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -// -// Such code is NOT meant to be used by a user directly, and is subject -// to CHANGE WITHOUT NOTICE. Therefore DO NOT DEPEND ON IT in a user -// program! - -#ifndef GTEST_INCLUDE_GTEST_GTEST_MESSAGE_H_ -#define GTEST_INCLUDE_GTEST_GTEST_MESSAGE_H_ - -#include - -#include "gtest/internal/gtest-port.h" - -// Ensures that there is at least one operator<< in the global namespace. -// See Message& operator<<(...) below for why. -void operator<<(const testing::internal::Secret&, int); - -namespace testing { - -// The Message class works like an ostream repeater. -// -// Typical usage: -// -// 1. You stream a bunch of values to a Message object. -// It will remember the text in a stringstream. -// 2. Then you stream the Message object to an ostream. -// This causes the text in the Message to be streamed -// to the ostream. -// -// For example; -// -// testing::Message foo; -// foo << 1 << " != " << 2; -// std::cout << foo; -// -// will print "1 != 2". -// -// Message is not intended to be inherited from. In particular, its -// destructor is not virtual. -// -// Note that stringstream behaves differently in gcc and in MSVC. You -// can stream a NULL char pointer to it in the former, but not in the -// latter (it causes an access violation if you do). The Message -// class hides this difference by treating a NULL char pointer as -// "(null)". -class GTEST_API_ Message { - private: - // The type of basic IO manipulators (endl, ends, and flush) for - // narrow streams. - typedef std::ostream& (*BasicNarrowIoManip)(std::ostream&); - - public: - // Constructs an empty Message. - Message(); - - // Copy constructor. - Message(const Message& msg) : ss_(new ::std::stringstream) { // NOLINT - *ss_ << msg.GetString(); - } - - // Constructs a Message from a C-string. - explicit Message(const char* str) : ss_(new ::std::stringstream) { - *ss_ << str; - } - -#if GTEST_OS_SYMBIAN - // Streams a value (either a pointer or not) to this object. - template - inline Message& operator <<(const T& value) { - StreamHelper(typename internal::is_pointer::type(), value); - return *this; - } -#else - // Streams a non-pointer value to this object. - template - inline Message& operator <<(const T& val) { - // Some libraries overload << for STL containers. These - // overloads are defined in the global namespace instead of ::std. - // - // C++'s symbol lookup rule (i.e. Koenig lookup) says that these - // overloads are visible in either the std namespace or the global - // namespace, but not other namespaces, including the testing - // namespace which Google Test's Message class is in. - // - // To allow STL containers (and other types that has a << operator - // defined in the global namespace) to be used in Google Test - // assertions, testing::Message must access the custom << operator - // from the global namespace. With this using declaration, - // overloads of << defined in the global namespace and those - // visible via Koenig lookup are both exposed in this function. - using ::operator <<; - *ss_ << val; - return *this; - } - - // Streams a pointer value to this object. - // - // This function is an overload of the previous one. When you - // stream a pointer to a Message, this definition will be used as it - // is more specialized. (The C++ Standard, section - // [temp.func.order].) If you stream a non-pointer, then the - // previous definition will be used. - // - // The reason for this overload is that streaming a NULL pointer to - // ostream is undefined behavior. Depending on the compiler, you - // may get "0", "(nil)", "(null)", or an access violation. To - // ensure consistent result across compilers, we always treat NULL - // as "(null)". - template - inline Message& operator <<(T* const& pointer) { // NOLINT - if (pointer == NULL) { - *ss_ << "(null)"; - } else { - *ss_ << pointer; - } - return *this; - } -#endif // GTEST_OS_SYMBIAN - - // Since the basic IO manipulators are overloaded for both narrow - // and wide streams, we have to provide this specialized definition - // of operator <<, even though its body is the same as the - // templatized version above. Without this definition, streaming - // endl or other basic IO manipulators to Message will confuse the - // compiler. - Message& operator <<(BasicNarrowIoManip val) { - *ss_ << val; - return *this; - } - - // Instead of 1/0, we want to see true/false for bool values. - Message& operator <<(bool b) { - return *this << (b ? "true" : "false"); - } - - // These two overloads allow streaming a wide C string to a Message - // using the UTF-8 encoding. - Message& operator <<(const wchar_t* wide_c_str); - Message& operator <<(wchar_t* wide_c_str); - -#if GTEST_HAS_STD_WSTRING - // Converts the given wide string to a narrow string using the UTF-8 - // encoding, and streams the result to this Message object. - Message& operator <<(const ::std::wstring& wstr); -#endif // GTEST_HAS_STD_WSTRING - -#if GTEST_HAS_GLOBAL_WSTRING - // Converts the given wide string to a narrow string using the UTF-8 - // encoding, and streams the result to this Message object. - Message& operator <<(const ::wstring& wstr); -#endif // GTEST_HAS_GLOBAL_WSTRING - - // Gets the text streamed to this object so far as an std::string. - // Each '\0' character in the buffer is replaced with "\\0". - // - // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - std::string GetString() const; - - private: - -#if GTEST_OS_SYMBIAN - // These are needed as the Nokia Symbian Compiler cannot decide between - // const T& and const T* in a function template. The Nokia compiler _can_ - // decide between class template specializations for T and T*, so a - // tr1::type_traits-like is_pointer works, and we can overload on that. - template - inline void StreamHelper(internal::true_type /*is_pointer*/, T* pointer) { - if (pointer == NULL) { - *ss_ << "(null)"; - } else { - *ss_ << pointer; - } - } - template - inline void StreamHelper(internal::false_type /*is_pointer*/, - const T& value) { - // See the comments in Message& operator <<(const T&) above for why - // we need this using statement. - using ::operator <<; - *ss_ << value; - } -#endif // GTEST_OS_SYMBIAN - - // We'll hold the text streamed to this object here. - const internal::scoped_ptr< ::std::stringstream> ss_; - - // We declare (but don't implement) this to prevent the compiler - // from implementing the assignment operator. - void operator=(const Message&); -}; - -// Streams a Message to an ostream. -inline std::ostream& operator <<(std::ostream& os, const Message& sb) { - return os << sb.GetString(); -} - -namespace internal { - -// Converts a streamable value to an std::string. A NULL pointer is -// converted to "(null)". When the input value is a ::string, -// ::std::string, ::wstring, or ::std::wstring object, each NUL -// character in it is replaced with "\\0". -template -std::string StreamableToString(const T& streamable) { - return (Message() << streamable).GetString(); -} - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_GTEST_MESSAGE_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h deleted file mode 100644 index 038f9ba79eb..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h +++ /dev/null @@ -1,1444 +0,0 @@ -// This file was GENERATED by command: -// pump.py gtest-param-test.h.pump -// DO NOT EDIT BY HAND!!! - -// Copyright 2008, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: vladl@google.com (Vlad Losev) -// -// Macros and functions for implementing parameterized tests -// in Google C++ Testing Framework (Google Test) -// -// This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -#ifndef GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ -#define GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ - - -// Value-parameterized tests allow you to test your code with different -// parameters without writing multiple copies of the same test. -// -// Here is how you use value-parameterized tests: - -#if 0 - -// To write value-parameterized tests, first you should define a fixture -// class. It is usually derived from testing::TestWithParam (see below for -// another inheritance scheme that's sometimes useful in more complicated -// class hierarchies), where the type of your parameter values. -// TestWithParam is itself derived from testing::Test. T can be any -// copyable type. If it's a raw pointer, you are responsible for managing the -// lifespan of the pointed values. - -class FooTest : public ::testing::TestWithParam { - // You can implement all the usual class fixture members here. -}; - -// Then, use the TEST_P macro to define as many parameterized tests -// for this fixture as you want. The _P suffix is for "parameterized" -// or "pattern", whichever you prefer to think. - -TEST_P(FooTest, DoesBlah) { - // Inside a test, access the test parameter with the GetParam() method - // of the TestWithParam class: - EXPECT_TRUE(foo.Blah(GetParam())); - ... -} - -TEST_P(FooTest, HasBlahBlah) { - ... -} - -// Finally, you can use INSTANTIATE_TEST_CASE_P to instantiate the test -// case with any set of parameters you want. Google Test defines a number -// of functions for generating test parameters. They return what we call -// (surprise!) parameter generators. Here is a summary of them, which -// are all in the testing namespace: -// -// -// Range(begin, end [, step]) - Yields values {begin, begin+step, -// begin+step+step, ...}. The values do not -// include end. step defaults to 1. -// Values(v1, v2, ..., vN) - Yields values {v1, v2, ..., vN}. -// ValuesIn(container) - Yields values from a C-style array, an STL -// ValuesIn(begin,end) container, or an iterator range [begin, end). -// Bool() - Yields sequence {false, true}. -// Combine(g1, g2, ..., gN) - Yields all combinations (the Cartesian product -// for the math savvy) of the values generated -// by the N generators. -// -// For more details, see comments at the definitions of these functions below -// in this file. -// -// The following statement will instantiate tests from the FooTest test case -// each with parameter values "meeny", "miny", and "moe". - -INSTANTIATE_TEST_CASE_P(InstantiationName, - FooTest, - Values("meeny", "miny", "moe")); - -// To distinguish different instances of the pattern, (yes, you -// can instantiate it more then once) the first argument to the -// INSTANTIATE_TEST_CASE_P macro is a prefix that will be added to the -// actual test case name. Remember to pick unique prefixes for different -// instantiations. The tests from the instantiation above will have -// these names: -// -// * InstantiationName/FooTest.DoesBlah/0 for "meeny" -// * InstantiationName/FooTest.DoesBlah/1 for "miny" -// * InstantiationName/FooTest.DoesBlah/2 for "moe" -// * InstantiationName/FooTest.HasBlahBlah/0 for "meeny" -// * InstantiationName/FooTest.HasBlahBlah/1 for "miny" -// * InstantiationName/FooTest.HasBlahBlah/2 for "moe" -// -// You can use these names in --gtest_filter. -// -// This statement will instantiate all tests from FooTest again, each -// with parameter values "cat" and "dog": - -const char* pets[] = {"cat", "dog"}; -INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets)); - -// The tests from the instantiation above will have these names: -// -// * AnotherInstantiationName/FooTest.DoesBlah/0 for "cat" -// * AnotherInstantiationName/FooTest.DoesBlah/1 for "dog" -// * AnotherInstantiationName/FooTest.HasBlahBlah/0 for "cat" -// * AnotherInstantiationName/FooTest.HasBlahBlah/1 for "dog" -// -// Please note that INSTANTIATE_TEST_CASE_P will instantiate all tests -// in the given test case, whether their definitions come before or -// AFTER the INSTANTIATE_TEST_CASE_P statement. -// -// Please also note that generator expressions (including parameters to the -// generators) are evaluated in InitGoogleTest(), after main() has started. -// This allows the user on one hand, to adjust generator parameters in order -// to dynamically determine a set of tests to run and on the other hand, -// give the user a chance to inspect the generated tests with Google Test -// reflection API before RUN_ALL_TESTS() is executed. -// -// You can see samples/sample7_unittest.cc and samples/sample8_unittest.cc -// for more examples. -// -// In the future, we plan to publish the API for defining new parameter -// generators. But for now this interface remains part of the internal -// implementation and is subject to change. -// -// -// A parameterized test fixture must be derived from testing::Test and from -// testing::WithParamInterface, where T is the type of the parameter -// values. Inheriting from TestWithParam satisfies that requirement because -// TestWithParam inherits from both Test and WithParamInterface. In more -// complicated hierarchies, however, it is occasionally useful to inherit -// separately from Test and WithParamInterface. For example: - -class BaseTest : public ::testing::Test { - // You can inherit all the usual members for a non-parameterized test - // fixture here. -}; - -class DerivedTest : public BaseTest, public ::testing::WithParamInterface { - // The usual test fixture members go here too. -}; - -TEST_F(BaseTest, HasFoo) { - // This is an ordinary non-parameterized test. -} - -TEST_P(DerivedTest, DoesBlah) { - // GetParam works just the same here as if you inherit from TestWithParam. - EXPECT_TRUE(foo.Blah(GetParam())); -} - -#endif // 0 - -#include "gtest/internal/gtest-port.h" - -#if !GTEST_OS_SYMBIAN -# include -#endif - -// scripts/fuse_gtest.py depends on gtest's own header being #included -// *unconditionally*. Therefore these #includes cannot be moved -// inside #if GTEST_HAS_PARAM_TEST. -#include "gtest/internal/gtest-internal.h" -#include "gtest/internal/gtest-param-util.h" -#include "gtest/internal/gtest-param-util-generated.h" - -#if GTEST_HAS_PARAM_TEST - -namespace testing { - -// Functions producing parameter generators. -// -// Google Test uses these generators to produce parameters for value- -// parameterized tests. When a parameterized test case is instantiated -// with a particular generator, Google Test creates and runs tests -// for each element in the sequence produced by the generator. -// -// In the following sample, tests from test case FooTest are instantiated -// each three times with parameter values 3, 5, and 8: -// -// class FooTest : public TestWithParam { ... }; -// -// TEST_P(FooTest, TestThis) { -// } -// TEST_P(FooTest, TestThat) { -// } -// INSTANTIATE_TEST_CASE_P(TestSequence, FooTest, Values(3, 5, 8)); -// - -// Range() returns generators providing sequences of values in a range. -// -// Synopsis: -// Range(start, end) -// - returns a generator producing a sequence of values {start, start+1, -// start+2, ..., }. -// Range(start, end, step) -// - returns a generator producing a sequence of values {start, start+step, -// start+step+step, ..., }. -// Notes: -// * The generated sequences never include end. For example, Range(1, 5) -// returns a generator producing a sequence {1, 2, 3, 4}. Range(1, 9, 2) -// returns a generator producing {1, 3, 5, 7}. -// * start and end must have the same type. That type may be any integral or -// floating-point type or a user defined type satisfying these conditions: -// * It must be assignable (have operator=() defined). -// * It must have operator+() (operator+(int-compatible type) for -// two-operand version). -// * It must have operator<() defined. -// Elements in the resulting sequences will also have that type. -// * Condition start < end must be satisfied in order for resulting sequences -// to contain any elements. -// -template -internal::ParamGenerator Range(T start, T end, IncrementT step) { - return internal::ParamGenerator( - new internal::RangeGenerator(start, end, step)); -} - -template -internal::ParamGenerator Range(T start, T end) { - return Range(start, end, 1); -} - -// ValuesIn() function allows generation of tests with parameters coming from -// a container. -// -// Synopsis: -// ValuesIn(const T (&array)[N]) -// - returns a generator producing sequences with elements from -// a C-style array. -// ValuesIn(const Container& container) -// - returns a generator producing sequences with elements from -// an STL-style container. -// ValuesIn(Iterator begin, Iterator end) -// - returns a generator producing sequences with elements from -// a range [begin, end) defined by a pair of STL-style iterators. These -// iterators can also be plain C pointers. -// -// Please note that ValuesIn copies the values from the containers -// passed in and keeps them to generate tests in RUN_ALL_TESTS(). -// -// Examples: -// -// This instantiates tests from test case StringTest -// each with C-string values of "foo", "bar", and "baz": -// -// const char* strings[] = {"foo", "bar", "baz"}; -// INSTANTIATE_TEST_CASE_P(StringSequence, SrtingTest, ValuesIn(strings)); -// -// This instantiates tests from test case StlStringTest -// each with STL strings with values "a" and "b": -// -// ::std::vector< ::std::string> GetParameterStrings() { -// ::std::vector< ::std::string> v; -// v.push_back("a"); -// v.push_back("b"); -// return v; -// } -// -// INSTANTIATE_TEST_CASE_P(CharSequence, -// StlStringTest, -// ValuesIn(GetParameterStrings())); -// -// -// This will also instantiate tests from CharTest -// each with parameter values 'a' and 'b': -// -// ::std::list GetParameterChars() { -// ::std::list list; -// list.push_back('a'); -// list.push_back('b'); -// return list; -// } -// ::std::list l = GetParameterChars(); -// INSTANTIATE_TEST_CASE_P(CharSequence2, -// CharTest, -// ValuesIn(l.begin(), l.end())); -// -template -internal::ParamGenerator< - typename ::testing::internal::IteratorTraits::value_type> -ValuesIn(ForwardIterator begin, ForwardIterator end) { - typedef typename ::testing::internal::IteratorTraits - ::value_type ParamType; - return internal::ParamGenerator( - new internal::ValuesInIteratorRangeGenerator(begin, end)); -} - -template -internal::ParamGenerator ValuesIn(const T (&array)[N]) { - return ValuesIn(array, array + N); -} - -template -internal::ParamGenerator ValuesIn( - const Container& container) { - return ValuesIn(container.begin(), container.end()); -} - -// Values() allows generating tests from explicitly specified list of -// parameters. -// -// Synopsis: -// Values(T v1, T v2, ..., T vN) -// - returns a generator producing sequences with elements v1, v2, ..., vN. -// -// For example, this instantiates tests from test case BarTest each -// with values "one", "two", and "three": -// -// INSTANTIATE_TEST_CASE_P(NumSequence, BarTest, Values("one", "two", "three")); -// -// This instantiates tests from test case BazTest each with values 1, 2, 3.5. -// The exact type of values will depend on the type of parameter in BazTest. -// -// INSTANTIATE_TEST_CASE_P(FloatingNumbers, BazTest, Values(1, 2, 3.5)); -// -// Currently, Values() supports from 1 to 50 parameters. -// -template -internal::ValueArray1 Values(T1 v1) { - return internal::ValueArray1(v1); -} - -template -internal::ValueArray2 Values(T1 v1, T2 v2) { - return internal::ValueArray2(v1, v2); -} - -template -internal::ValueArray3 Values(T1 v1, T2 v2, T3 v3) { - return internal::ValueArray3(v1, v2, v3); -} - -template -internal::ValueArray4 Values(T1 v1, T2 v2, T3 v3, T4 v4) { - return internal::ValueArray4(v1, v2, v3, v4); -} - -template -internal::ValueArray5 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5) { - return internal::ValueArray5(v1, v2, v3, v4, v5); -} - -template -internal::ValueArray6 Values(T1 v1, T2 v2, T3 v3, - T4 v4, T5 v5, T6 v6) { - return internal::ValueArray6(v1, v2, v3, v4, v5, v6); -} - -template -internal::ValueArray7 Values(T1 v1, T2 v2, T3 v3, - T4 v4, T5 v5, T6 v6, T7 v7) { - return internal::ValueArray7(v1, v2, v3, v4, v5, - v6, v7); -} - -template -internal::ValueArray8 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8) { - return internal::ValueArray8(v1, v2, v3, v4, - v5, v6, v7, v8); -} - -template -internal::ValueArray9 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9) { - return internal::ValueArray9(v1, v2, v3, - v4, v5, v6, v7, v8, v9); -} - -template -internal::ValueArray10 Values(T1 v1, - T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10) { - return internal::ValueArray10(v1, - v2, v3, v4, v5, v6, v7, v8, v9, v10); -} - -template -internal::ValueArray11 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11) { - return internal::ValueArray11(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11); -} - -template -internal::ValueArray12 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12) { - return internal::ValueArray12(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12); -} - -template -internal::ValueArray13 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13) { - return internal::ValueArray13(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13); -} - -template -internal::ValueArray14 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14) { - return internal::ValueArray14(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, - v14); -} - -template -internal::ValueArray15 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, - T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15) { - return internal::ValueArray15(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, - v13, v14, v15); -} - -template -internal::ValueArray16 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16) { - return internal::ValueArray16(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, - v12, v13, v14, v15, v16); -} - -template -internal::ValueArray17 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17) { - return internal::ValueArray17(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, - v11, v12, v13, v14, v15, v16, v17); -} - -template -internal::ValueArray18 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, - T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18) { - return internal::ValueArray18(v1, v2, v3, v4, v5, v6, v7, v8, v9, - v10, v11, v12, v13, v14, v15, v16, v17, v18); -} - -template -internal::ValueArray19 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, - T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, - T15 v15, T16 v16, T17 v17, T18 v18, T19 v19) { - return internal::ValueArray19(v1, v2, v3, v4, v5, v6, v7, v8, - v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19); -} - -template -internal::ValueArray20 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, - T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20) { - return internal::ValueArray20(v1, v2, v3, v4, v5, v6, v7, - v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20); -} - -template -internal::ValueArray21 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, - T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21) { - return internal::ValueArray21(v1, v2, v3, v4, v5, v6, - v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21); -} - -template -internal::ValueArray22 Values(T1 v1, T2 v2, T3 v3, - T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22) { - return internal::ValueArray22(v1, v2, v3, v4, - v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, - v20, v21, v22); -} - -template -internal::ValueArray23 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22, T23 v23) { - return internal::ValueArray23(v1, v2, v3, - v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, - v20, v21, v22, v23); -} - -template -internal::ValueArray24 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22, T23 v23, T24 v24) { - return internal::ValueArray24(v1, v2, - v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, - v19, v20, v21, v22, v23, v24); -} - -template -internal::ValueArray25 Values(T1 v1, - T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, - T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, - T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25) { - return internal::ValueArray25(v1, - v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, - v18, v19, v20, v21, v22, v23, v24, v25); -} - -template -internal::ValueArray26 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26) { - return internal::ValueArray26(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, - v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26); -} - -template -internal::ValueArray27 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27) { - return internal::ValueArray27(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, - v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, v27); -} - -template -internal::ValueArray28 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28) { - return internal::ValueArray28(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, - v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, v27, - v28); -} - -template -internal::ValueArray29 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29) { - return internal::ValueArray29(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, - v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, - v27, v28, v29); -} - -template -internal::ValueArray30 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, - T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, - T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, - T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30) { - return internal::ValueArray30(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, - v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, - v26, v27, v28, v29, v30); -} - -template -internal::ValueArray31 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31) { - return internal::ValueArray31(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, - v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, - v25, v26, v27, v28, v29, v30, v31); -} - -template -internal::ValueArray32 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, - T32 v32) { - return internal::ValueArray32(v1, v2, v3, v4, v5, v6, v7, v8, v9, - v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, - v24, v25, v26, v27, v28, v29, v30, v31, v32); -} - -template -internal::ValueArray33 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, - T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, - T32 v32, T33 v33) { - return internal::ValueArray33(v1, v2, v3, v4, v5, v6, v7, v8, - v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, - v24, v25, v26, v27, v28, v29, v30, v31, v32, v33); -} - -template -internal::ValueArray34 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, - T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, - T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, - T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, - T31 v31, T32 v32, T33 v33, T34 v34) { - return internal::ValueArray34(v1, v2, v3, v4, v5, v6, v7, - v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, - v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34); -} - -template -internal::ValueArray35 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, - T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, - T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, - T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35) { - return internal::ValueArray35(v1, v2, v3, v4, v5, v6, - v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, - v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35); -} - -template -internal::ValueArray36 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, - T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, - T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, - T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36) { - return internal::ValueArray36(v1, v2, v3, v4, - v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, - v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, - v34, v35, v36); -} - -template -internal::ValueArray37 Values(T1 v1, T2 v2, T3 v3, - T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, - T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, - T37 v37) { - return internal::ValueArray37(v1, v2, v3, - v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, - v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, - v34, v35, v36, v37); -} - -template -internal::ValueArray38 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, - T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, - T37 v37, T38 v38) { - return internal::ValueArray38(v1, v2, - v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, - v19, v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, - v33, v34, v35, v36, v37, v38); -} - -template -internal::ValueArray39 Values(T1 v1, T2 v2, - T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, - T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, - T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, - T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, - T37 v37, T38 v38, T39 v39) { - return internal::ValueArray39(v1, - v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, - v18, v19, v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, - v32, v33, v34, v35, v36, v37, v38, v39); -} - -template -internal::ValueArray40 Values(T1 v1, - T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, - T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, - T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, - T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, - T36 v36, T37 v37, T38 v38, T39 v39, T40 v40) { - return internal::ValueArray40(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, - v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, - v30, v31, v32, v33, v34, v35, v36, v37, v38, v39, v40); -} - -template -internal::ValueArray41 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41) { - return internal::ValueArray41(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, - v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, v27, v28, - v29, v30, v31, v32, v33, v34, v35, v36, v37, v38, v39, v40, v41); -} - -template -internal::ValueArray42 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42) { - return internal::ValueArray42(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, v13, - v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, v27, - v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, v38, v39, v40, v41, - v42); -} - -template -internal::ValueArray43 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43) { - return internal::ValueArray43(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, v12, - v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, v26, - v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, v38, v39, v40, - v41, v42, v43); -} - -template -internal::ValueArray44 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44) { - return internal::ValueArray44(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, v11, - v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, v25, - v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, v38, v39, - v40, v41, v42, v43, v44); -} - -template -internal::ValueArray45 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, - T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, - T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, - T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, - T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, - T41 v41, T42 v42, T43 v43, T44 v44, T45 v45) { - return internal::ValueArray45(v1, v2, v3, v4, v5, v6, v7, v8, v9, v10, - v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, v24, - v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, v38, - v39, v40, v41, v42, v43, v44, v45); -} - -template -internal::ValueArray46 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, - T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, - T40 v40, T41 v41, T42 v42, T43 v43, T44 v44, T45 v45, T46 v46) { - return internal::ValueArray46(v1, v2, v3, v4, v5, v6, v7, v8, v9, - v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, - v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, - v38, v39, v40, v41, v42, v43, v44, v45, v46); -} - -template -internal::ValueArray47 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, - T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, - T40 v40, T41 v41, T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47) { - return internal::ValueArray47(v1, v2, v3, v4, v5, v6, v7, v8, - v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, v23, - v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, v37, - v38, v39, v40, v41, v42, v43, v44, v45, v46, v47); -} - -template -internal::ValueArray48 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, - T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, - T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, - T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, - T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, - T40 v40, T41 v41, T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47, - T48 v48) { - return internal::ValueArray48(v1, v2, v3, v4, v5, v6, v7, - v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, v22, - v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, v36, - v37, v38, v39, v40, v41, v42, v43, v44, v45, v46, v47, v48); -} - -template -internal::ValueArray49 Values(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, - T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, - T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, - T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, - T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, - T39 v39, T40 v40, T41 v41, T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, - T47 v47, T48 v48, T49 v49) { - return internal::ValueArray49(v1, v2, v3, v4, v5, v6, - v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, v20, v21, - v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, v34, v35, - v36, v37, v38, v39, v40, v41, v42, v43, v44, v45, v46, v47, v48, v49); -} - -template -internal::ValueArray50 Values(T1 v1, T2 v2, T3 v3, T4 v4, - T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, T10 v10, T11 v11, T12 v12, T13 v13, - T14 v14, T15 v15, T16 v16, T17 v17, T18 v18, T19 v19, T20 v20, T21 v21, - T22 v22, T23 v23, T24 v24, T25 v25, T26 v26, T27 v27, T28 v28, T29 v29, - T30 v30, T31 v31, T32 v32, T33 v33, T34 v34, T35 v35, T36 v36, T37 v37, - T38 v38, T39 v39, T40 v40, T41 v41, T42 v42, T43 v43, T44 v44, T45 v45, - T46 v46, T47 v47, T48 v48, T49 v49, T50 v50) { - return internal::ValueArray50(v1, v2, v3, v4, - v5, v6, v7, v8, v9, v10, v11, v12, v13, v14, v15, v16, v17, v18, v19, - v20, v21, v22, v23, v24, v25, v26, v27, v28, v29, v30, v31, v32, v33, - v34, v35, v36, v37, v38, v39, v40, v41, v42, v43, v44, v45, v46, v47, - v48, v49, v50); -} - -// Bool() allows generating tests with parameters in a set of (false, true). -// -// Synopsis: -// Bool() -// - returns a generator producing sequences with elements {false, true}. -// -// It is useful when testing code that depends on Boolean flags. Combinations -// of multiple flags can be tested when several Bool()'s are combined using -// Combine() function. -// -// In the following example all tests in the test case FlagDependentTest -// will be instantiated twice with parameters false and true. -// -// class FlagDependentTest : public testing::TestWithParam { -// virtual void SetUp() { -// external_flag = GetParam(); -// } -// } -// INSTANTIATE_TEST_CASE_P(BoolSequence, FlagDependentTest, Bool()); -// -inline internal::ParamGenerator Bool() { - return Values(false, true); -} - -# if GTEST_HAS_COMBINE -// Combine() allows the user to combine two or more sequences to produce -// values of a Cartesian product of those sequences' elements. -// -// Synopsis: -// Combine(gen1, gen2, ..., genN) -// - returns a generator producing sequences with elements coming from -// the Cartesian product of elements from the sequences generated by -// gen1, gen2, ..., genN. The sequence elements will have a type of -// tuple where T1, T2, ..., TN are the types -// of elements from sequences produces by gen1, gen2, ..., genN. -// -// Combine can have up to 10 arguments. This number is currently limited -// by the maximum number of elements in the tuple implementation used by Google -// Test. -// -// Example: -// -// This will instantiate tests in test case AnimalTest each one with -// the parameter values tuple("cat", BLACK), tuple("cat", WHITE), -// tuple("dog", BLACK), and tuple("dog", WHITE): -// -// enum Color { BLACK, GRAY, WHITE }; -// class AnimalTest -// : public testing::TestWithParam > {...}; -// -// TEST_P(AnimalTest, AnimalLooksNice) {...} -// -// INSTANTIATE_TEST_CASE_P(AnimalVariations, AnimalTest, -// Combine(Values("cat", "dog"), -// Values(BLACK, WHITE))); -// -// This will instantiate tests in FlagDependentTest with all variations of two -// Boolean flags: -// -// class FlagDependentTest -// : public testing::TestWithParam > { -// virtual void SetUp() { -// // Assigns external_flag_1 and external_flag_2 values from the tuple. -// tie(external_flag_1, external_flag_2) = GetParam(); -// } -// }; -// -// TEST_P(FlagDependentTest, TestFeature1) { -// // Test your code using external_flag_1 and external_flag_2 here. -// } -// INSTANTIATE_TEST_CASE_P(TwoBoolSequence, FlagDependentTest, -// Combine(Bool(), Bool())); -// -template -internal::CartesianProductHolder2 Combine( - const Generator1& g1, const Generator2& g2) { - return internal::CartesianProductHolder2( - g1, g2); -} - -template -internal::CartesianProductHolder3 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3) { - return internal::CartesianProductHolder3( - g1, g2, g3); -} - -template -internal::CartesianProductHolder4 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4) { - return internal::CartesianProductHolder4( - g1, g2, g3, g4); -} - -template -internal::CartesianProductHolder5 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5) { - return internal::CartesianProductHolder5( - g1, g2, g3, g4, g5); -} - -template -internal::CartesianProductHolder6 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5, const Generator6& g6) { - return internal::CartesianProductHolder6( - g1, g2, g3, g4, g5, g6); -} - -template -internal::CartesianProductHolder7 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5, const Generator6& g6, - const Generator7& g7) { - return internal::CartesianProductHolder7( - g1, g2, g3, g4, g5, g6, g7); -} - -template -internal::CartesianProductHolder8 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5, const Generator6& g6, - const Generator7& g7, const Generator8& g8) { - return internal::CartesianProductHolder8( - g1, g2, g3, g4, g5, g6, g7, g8); -} - -template -internal::CartesianProductHolder9 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5, const Generator6& g6, - const Generator7& g7, const Generator8& g8, const Generator9& g9) { - return internal::CartesianProductHolder9( - g1, g2, g3, g4, g5, g6, g7, g8, g9); -} - -template -internal::CartesianProductHolder10 Combine( - const Generator1& g1, const Generator2& g2, const Generator3& g3, - const Generator4& g4, const Generator5& g5, const Generator6& g6, - const Generator7& g7, const Generator8& g8, const Generator9& g9, - const Generator10& g10) { - return internal::CartesianProductHolder10( - g1, g2, g3, g4, g5, g6, g7, g8, g9, g10); -} -# endif // GTEST_HAS_COMBINE - - - -# define TEST_P(test_case_name, test_name) \ - class GTEST_TEST_CLASS_NAME_(test_case_name, test_name) \ - : public test_case_name { \ - public: \ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)() {} \ - virtual void TestBody(); \ - private: \ - static int AddToRegistry() { \ - ::testing::UnitTest::GetInstance()->parameterized_test_registry(). \ - GetTestCasePatternHolder(\ - #test_case_name, \ - ::testing::internal::CodeLocation(\ - __FILE__, __LINE__))->AddTestPattern(\ - #test_case_name, \ - #test_name, \ - new ::testing::internal::TestMetaFactory< \ - GTEST_TEST_CLASS_NAME_(\ - test_case_name, test_name)>()); \ - return 0; \ - } \ - static int gtest_registering_dummy_ GTEST_ATTRIBUTE_UNUSED_; \ - GTEST_DISALLOW_COPY_AND_ASSIGN_(\ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)); \ - }; \ - int GTEST_TEST_CLASS_NAME_(test_case_name, \ - test_name)::gtest_registering_dummy_ = \ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::AddToRegistry(); \ - void GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::TestBody() - -// The optional last argument to INSTANTIATE_TEST_CASE_P allows the user -// to specify a function or functor that generates custom test name suffixes -// based on the test parameters. The function should accept one argument of -// type testing::TestParamInfo, and return std::string. -// -// testing::PrintToStringParamName is a builtin test suffix generator that -// returns the value of testing::PrintToString(GetParam()). It does not work -// for std::string or C strings. -// -// Note: test names must be non-empty, unique, and may only contain ASCII -// alphanumeric characters or underscore. - -# define INSTANTIATE_TEST_CASE_P(prefix, test_case_name, generator, ...) \ - ::testing::internal::ParamGenerator \ - gtest_##prefix##test_case_name##_EvalGenerator_() { return generator; } \ - ::std::string gtest_##prefix##test_case_name##_EvalGenerateName_( \ - const ::testing::TestParamInfo& info) { \ - return ::testing::internal::GetParamNameGen \ - (__VA_ARGS__)(info); \ - } \ - int gtest_##prefix##test_case_name##_dummy_ GTEST_ATTRIBUTE_UNUSED_ = \ - ::testing::UnitTest::GetInstance()->parameterized_test_registry(). \ - GetTestCasePatternHolder(\ - #test_case_name, \ - ::testing::internal::CodeLocation(\ - __FILE__, __LINE__))->AddTestCaseInstantiation(\ - #prefix, \ - >est_##prefix##test_case_name##_EvalGenerator_, \ - >est_##prefix##test_case_name##_EvalGenerateName_, \ - __FILE__, __LINE__) - -} // namespace testing - -#endif // GTEST_HAS_PARAM_TEST - -#endif // GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h.pump b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h.pump deleted file mode 100644 index 3078d6d2a19..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-param-test.h.pump +++ /dev/null @@ -1,510 +0,0 @@ -$$ -*- mode: c++; -*- -$var n = 50 $$ Maximum length of Values arguments we want to support. -$var maxtuple = 10 $$ Maximum number of Combine arguments we want to support. -// Copyright 2008, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: vladl@google.com (Vlad Losev) -// -// Macros and functions for implementing parameterized tests -// in Google C++ Testing Framework (Google Test) -// -// This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -#ifndef GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ -#define GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ - - -// Value-parameterized tests allow you to test your code with different -// parameters without writing multiple copies of the same test. -// -// Here is how you use value-parameterized tests: - -#if 0 - -// To write value-parameterized tests, first you should define a fixture -// class. It is usually derived from testing::TestWithParam (see below for -// another inheritance scheme that's sometimes useful in more complicated -// class hierarchies), where the type of your parameter values. -// TestWithParam is itself derived from testing::Test. T can be any -// copyable type. If it's a raw pointer, you are responsible for managing the -// lifespan of the pointed values. - -class FooTest : public ::testing::TestWithParam { - // You can implement all the usual class fixture members here. -}; - -// Then, use the TEST_P macro to define as many parameterized tests -// for this fixture as you want. The _P suffix is for "parameterized" -// or "pattern", whichever you prefer to think. - -TEST_P(FooTest, DoesBlah) { - // Inside a test, access the test parameter with the GetParam() method - // of the TestWithParam class: - EXPECT_TRUE(foo.Blah(GetParam())); - ... -} - -TEST_P(FooTest, HasBlahBlah) { - ... -} - -// Finally, you can use INSTANTIATE_TEST_CASE_P to instantiate the test -// case with any set of parameters you want. Google Test defines a number -// of functions for generating test parameters. They return what we call -// (surprise!) parameter generators. Here is a summary of them, which -// are all in the testing namespace: -// -// -// Range(begin, end [, step]) - Yields values {begin, begin+step, -// begin+step+step, ...}. The values do not -// include end. step defaults to 1. -// Values(v1, v2, ..., vN) - Yields values {v1, v2, ..., vN}. -// ValuesIn(container) - Yields values from a C-style array, an STL -// ValuesIn(begin,end) container, or an iterator range [begin, end). -// Bool() - Yields sequence {false, true}. -// Combine(g1, g2, ..., gN) - Yields all combinations (the Cartesian product -// for the math savvy) of the values generated -// by the N generators. -// -// For more details, see comments at the definitions of these functions below -// in this file. -// -// The following statement will instantiate tests from the FooTest test case -// each with parameter values "meeny", "miny", and "moe". - -INSTANTIATE_TEST_CASE_P(InstantiationName, - FooTest, - Values("meeny", "miny", "moe")); - -// To distinguish different instances of the pattern, (yes, you -// can instantiate it more then once) the first argument to the -// INSTANTIATE_TEST_CASE_P macro is a prefix that will be added to the -// actual test case name. Remember to pick unique prefixes for different -// instantiations. The tests from the instantiation above will have -// these names: -// -// * InstantiationName/FooTest.DoesBlah/0 for "meeny" -// * InstantiationName/FooTest.DoesBlah/1 for "miny" -// * InstantiationName/FooTest.DoesBlah/2 for "moe" -// * InstantiationName/FooTest.HasBlahBlah/0 for "meeny" -// * InstantiationName/FooTest.HasBlahBlah/1 for "miny" -// * InstantiationName/FooTest.HasBlahBlah/2 for "moe" -// -// You can use these names in --gtest_filter. -// -// This statement will instantiate all tests from FooTest again, each -// with parameter values "cat" and "dog": - -const char* pets[] = {"cat", "dog"}; -INSTANTIATE_TEST_CASE_P(AnotherInstantiationName, FooTest, ValuesIn(pets)); - -// The tests from the instantiation above will have these names: -// -// * AnotherInstantiationName/FooTest.DoesBlah/0 for "cat" -// * AnotherInstantiationName/FooTest.DoesBlah/1 for "dog" -// * AnotherInstantiationName/FooTest.HasBlahBlah/0 for "cat" -// * AnotherInstantiationName/FooTest.HasBlahBlah/1 for "dog" -// -// Please note that INSTANTIATE_TEST_CASE_P will instantiate all tests -// in the given test case, whether their definitions come before or -// AFTER the INSTANTIATE_TEST_CASE_P statement. -// -// Please also note that generator expressions (including parameters to the -// generators) are evaluated in InitGoogleTest(), after main() has started. -// This allows the user on one hand, to adjust generator parameters in order -// to dynamically determine a set of tests to run and on the other hand, -// give the user a chance to inspect the generated tests with Google Test -// reflection API before RUN_ALL_TESTS() is executed. -// -// You can see samples/sample7_unittest.cc and samples/sample8_unittest.cc -// for more examples. -// -// In the future, we plan to publish the API for defining new parameter -// generators. But for now this interface remains part of the internal -// implementation and is subject to change. -// -// -// A parameterized test fixture must be derived from testing::Test and from -// testing::WithParamInterface, where T is the type of the parameter -// values. Inheriting from TestWithParam satisfies that requirement because -// TestWithParam inherits from both Test and WithParamInterface. In more -// complicated hierarchies, however, it is occasionally useful to inherit -// separately from Test and WithParamInterface. For example: - -class BaseTest : public ::testing::Test { - // You can inherit all the usual members for a non-parameterized test - // fixture here. -}; - -class DerivedTest : public BaseTest, public ::testing::WithParamInterface { - // The usual test fixture members go here too. -}; - -TEST_F(BaseTest, HasFoo) { - // This is an ordinary non-parameterized test. -} - -TEST_P(DerivedTest, DoesBlah) { - // GetParam works just the same here as if you inherit from TestWithParam. - EXPECT_TRUE(foo.Blah(GetParam())); -} - -#endif // 0 - -#include "gtest/internal/gtest-port.h" - -#if !GTEST_OS_SYMBIAN -# include -#endif - -// scripts/fuse_gtest.py depends on gtest's own header being #included -// *unconditionally*. Therefore these #includes cannot be moved -// inside #if GTEST_HAS_PARAM_TEST. -#include "gtest/internal/gtest-internal.h" -#include "gtest/internal/gtest-param-util.h" -#include "gtest/internal/gtest-param-util-generated.h" - -#if GTEST_HAS_PARAM_TEST - -namespace testing { - -// Functions producing parameter generators. -// -// Google Test uses these generators to produce parameters for value- -// parameterized tests. When a parameterized test case is instantiated -// with a particular generator, Google Test creates and runs tests -// for each element in the sequence produced by the generator. -// -// In the following sample, tests from test case FooTest are instantiated -// each three times with parameter values 3, 5, and 8: -// -// class FooTest : public TestWithParam { ... }; -// -// TEST_P(FooTest, TestThis) { -// } -// TEST_P(FooTest, TestThat) { -// } -// INSTANTIATE_TEST_CASE_P(TestSequence, FooTest, Values(3, 5, 8)); -// - -// Range() returns generators providing sequences of values in a range. -// -// Synopsis: -// Range(start, end) -// - returns a generator producing a sequence of values {start, start+1, -// start+2, ..., }. -// Range(start, end, step) -// - returns a generator producing a sequence of values {start, start+step, -// start+step+step, ..., }. -// Notes: -// * The generated sequences never include end. For example, Range(1, 5) -// returns a generator producing a sequence {1, 2, 3, 4}. Range(1, 9, 2) -// returns a generator producing {1, 3, 5, 7}. -// * start and end must have the same type. That type may be any integral or -// floating-point type or a user defined type satisfying these conditions: -// * It must be assignable (have operator=() defined). -// * It must have operator+() (operator+(int-compatible type) for -// two-operand version). -// * It must have operator<() defined. -// Elements in the resulting sequences will also have that type. -// * Condition start < end must be satisfied in order for resulting sequences -// to contain any elements. -// -template -internal::ParamGenerator Range(T start, T end, IncrementT step) { - return internal::ParamGenerator( - new internal::RangeGenerator(start, end, step)); -} - -template -internal::ParamGenerator Range(T start, T end) { - return Range(start, end, 1); -} - -// ValuesIn() function allows generation of tests with parameters coming from -// a container. -// -// Synopsis: -// ValuesIn(const T (&array)[N]) -// - returns a generator producing sequences with elements from -// a C-style array. -// ValuesIn(const Container& container) -// - returns a generator producing sequences with elements from -// an STL-style container. -// ValuesIn(Iterator begin, Iterator end) -// - returns a generator producing sequences with elements from -// a range [begin, end) defined by a pair of STL-style iterators. These -// iterators can also be plain C pointers. -// -// Please note that ValuesIn copies the values from the containers -// passed in and keeps them to generate tests in RUN_ALL_TESTS(). -// -// Examples: -// -// This instantiates tests from test case StringTest -// each with C-string values of "foo", "bar", and "baz": -// -// const char* strings[] = {"foo", "bar", "baz"}; -// INSTANTIATE_TEST_CASE_P(StringSequence, SrtingTest, ValuesIn(strings)); -// -// This instantiates tests from test case StlStringTest -// each with STL strings with values "a" and "b": -// -// ::std::vector< ::std::string> GetParameterStrings() { -// ::std::vector< ::std::string> v; -// v.push_back("a"); -// v.push_back("b"); -// return v; -// } -// -// INSTANTIATE_TEST_CASE_P(CharSequence, -// StlStringTest, -// ValuesIn(GetParameterStrings())); -// -// -// This will also instantiate tests from CharTest -// each with parameter values 'a' and 'b': -// -// ::std::list GetParameterChars() { -// ::std::list list; -// list.push_back('a'); -// list.push_back('b'); -// return list; -// } -// ::std::list l = GetParameterChars(); -// INSTANTIATE_TEST_CASE_P(CharSequence2, -// CharTest, -// ValuesIn(l.begin(), l.end())); -// -template -internal::ParamGenerator< - typename ::testing::internal::IteratorTraits::value_type> -ValuesIn(ForwardIterator begin, ForwardIterator end) { - typedef typename ::testing::internal::IteratorTraits - ::value_type ParamType; - return internal::ParamGenerator( - new internal::ValuesInIteratorRangeGenerator(begin, end)); -} - -template -internal::ParamGenerator ValuesIn(const T (&array)[N]) { - return ValuesIn(array, array + N); -} - -template -internal::ParamGenerator ValuesIn( - const Container& container) { - return ValuesIn(container.begin(), container.end()); -} - -// Values() allows generating tests from explicitly specified list of -// parameters. -// -// Synopsis: -// Values(T v1, T v2, ..., T vN) -// - returns a generator producing sequences with elements v1, v2, ..., vN. -// -// For example, this instantiates tests from test case BarTest each -// with values "one", "two", and "three": -// -// INSTANTIATE_TEST_CASE_P(NumSequence, BarTest, Values("one", "two", "three")); -// -// This instantiates tests from test case BazTest each with values 1, 2, 3.5. -// The exact type of values will depend on the type of parameter in BazTest. -// -// INSTANTIATE_TEST_CASE_P(FloatingNumbers, BazTest, Values(1, 2, 3.5)); -// -// Currently, Values() supports from 1 to $n parameters. -// -$range i 1..n -$for i [[ -$range j 1..i - -template <$for j, [[typename T$j]]> -internal::ValueArray$i<$for j, [[T$j]]> Values($for j, [[T$j v$j]]) { - return internal::ValueArray$i<$for j, [[T$j]]>($for j, [[v$j]]); -} - -]] - -// Bool() allows generating tests with parameters in a set of (false, true). -// -// Synopsis: -// Bool() -// - returns a generator producing sequences with elements {false, true}. -// -// It is useful when testing code that depends on Boolean flags. Combinations -// of multiple flags can be tested when several Bool()'s are combined using -// Combine() function. -// -// In the following example all tests in the test case FlagDependentTest -// will be instantiated twice with parameters false and true. -// -// class FlagDependentTest : public testing::TestWithParam { -// virtual void SetUp() { -// external_flag = GetParam(); -// } -// } -// INSTANTIATE_TEST_CASE_P(BoolSequence, FlagDependentTest, Bool()); -// -inline internal::ParamGenerator Bool() { - return Values(false, true); -} - -# if GTEST_HAS_COMBINE -// Combine() allows the user to combine two or more sequences to produce -// values of a Cartesian product of those sequences' elements. -// -// Synopsis: -// Combine(gen1, gen2, ..., genN) -// - returns a generator producing sequences with elements coming from -// the Cartesian product of elements from the sequences generated by -// gen1, gen2, ..., genN. The sequence elements will have a type of -// tuple where T1, T2, ..., TN are the types -// of elements from sequences produces by gen1, gen2, ..., genN. -// -// Combine can have up to $maxtuple arguments. This number is currently limited -// by the maximum number of elements in the tuple implementation used by Google -// Test. -// -// Example: -// -// This will instantiate tests in test case AnimalTest each one with -// the parameter values tuple("cat", BLACK), tuple("cat", WHITE), -// tuple("dog", BLACK), and tuple("dog", WHITE): -// -// enum Color { BLACK, GRAY, WHITE }; -// class AnimalTest -// : public testing::TestWithParam > {...}; -// -// TEST_P(AnimalTest, AnimalLooksNice) {...} -// -// INSTANTIATE_TEST_CASE_P(AnimalVariations, AnimalTest, -// Combine(Values("cat", "dog"), -// Values(BLACK, WHITE))); -// -// This will instantiate tests in FlagDependentTest with all variations of two -// Boolean flags: -// -// class FlagDependentTest -// : public testing::TestWithParam > { -// virtual void SetUp() { -// // Assigns external_flag_1 and external_flag_2 values from the tuple. -// tie(external_flag_1, external_flag_2) = GetParam(); -// } -// }; -// -// TEST_P(FlagDependentTest, TestFeature1) { -// // Test your code using external_flag_1 and external_flag_2 here. -// } -// INSTANTIATE_TEST_CASE_P(TwoBoolSequence, FlagDependentTest, -// Combine(Bool(), Bool())); -// -$range i 2..maxtuple -$for i [[ -$range j 1..i - -template <$for j, [[typename Generator$j]]> -internal::CartesianProductHolder$i<$for j, [[Generator$j]]> Combine( - $for j, [[const Generator$j& g$j]]) { - return internal::CartesianProductHolder$i<$for j, [[Generator$j]]>( - $for j, [[g$j]]); -} - -]] -# endif // GTEST_HAS_COMBINE - - - -# define TEST_P(test_case_name, test_name) \ - class GTEST_TEST_CLASS_NAME_(test_case_name, test_name) \ - : public test_case_name { \ - public: \ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)() {} \ - virtual void TestBody(); \ - private: \ - static int AddToRegistry() { \ - ::testing::UnitTest::GetInstance()->parameterized_test_registry(). \ - GetTestCasePatternHolder(\ - #test_case_name, \ - ::testing::internal::CodeLocation(\ - __FILE__, __LINE__))->AddTestPattern(\ - #test_case_name, \ - #test_name, \ - new ::testing::internal::TestMetaFactory< \ - GTEST_TEST_CLASS_NAME_(\ - test_case_name, test_name)>()); \ - return 0; \ - } \ - static int gtest_registering_dummy_ GTEST_ATTRIBUTE_UNUSED_; \ - GTEST_DISALLOW_COPY_AND_ASSIGN_(\ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)); \ - }; \ - int GTEST_TEST_CLASS_NAME_(test_case_name, \ - test_name)::gtest_registering_dummy_ = \ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::AddToRegistry(); \ - void GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::TestBody() - -// The optional last argument to INSTANTIATE_TEST_CASE_P allows the user -// to specify a function or functor that generates custom test name suffixes -// based on the test parameters. The function should accept one argument of -// type testing::TestParamInfo, and return std::string. -// -// testing::PrintToStringParamName is a builtin test suffix generator that -// returns the value of testing::PrintToString(GetParam()). -// -// Note: test names must be non-empty, unique, and may only contain ASCII -// alphanumeric characters or underscore. Because PrintToString adds quotes -// to std::string and C strings, it won't work for these types. - -# define INSTANTIATE_TEST_CASE_P(prefix, test_case_name, generator, ...) \ - ::testing::internal::ParamGenerator \ - gtest_##prefix##test_case_name##_EvalGenerator_() { return generator; } \ - ::std::string gtest_##prefix##test_case_name##_EvalGenerateName_( \ - const ::testing::TestParamInfo& info) { \ - return ::testing::internal::GetParamNameGen \ - (__VA_ARGS__)(info); \ - } \ - int gtest_##prefix##test_case_name##_dummy_ GTEST_ATTRIBUTE_UNUSED_ = \ - ::testing::UnitTest::GetInstance()->parameterized_test_registry(). \ - GetTestCasePatternHolder(\ - #test_case_name, \ - ::testing::internal::CodeLocation(\ - __FILE__, __LINE__))->AddTestCaseInstantiation(\ - #prefix, \ - >est_##prefix##test_case_name##_EvalGenerator_, \ - >est_##prefix##test_case_name##_EvalGenerateName_, \ - __FILE__, __LINE__) - -} // namespace testing - -#endif // GTEST_HAS_PARAM_TEST - -#endif // GTEST_INCLUDE_GTEST_GTEST_PARAM_TEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-printers.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-printers.h deleted file mode 100644 index 8a33164cb38..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-printers.h +++ /dev/null @@ -1,993 +0,0 @@ -// Copyright 2007, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -// Google Test - The Google C++ Testing Framework -// -// This file implements a universal value printer that can print a -// value of any type T: -// -// void ::testing::internal::UniversalPrinter::Print(value, ostream_ptr); -// -// A user can teach this function how to print a class type T by -// defining either operator<<() or PrintTo() in the namespace that -// defines T. More specifically, the FIRST defined function in the -// following list will be used (assuming T is defined in namespace -// foo): -// -// 1. foo::PrintTo(const T&, ostream*) -// 2. operator<<(ostream&, const T&) defined in either foo or the -// global namespace. -// -// If none of the above is defined, it will print the debug string of -// the value if it is a protocol buffer, or print the raw bytes in the -// value otherwise. -// -// To aid debugging: when T is a reference type, the address of the -// value is also printed; when T is a (const) char pointer, both the -// pointer value and the NUL-terminated string it points to are -// printed. -// -// We also provide some convenient wrappers: -// -// // Prints a value to a string. For a (const or not) char -// // pointer, the NUL-terminated string (but not the pointer) is -// // printed. -// std::string ::testing::PrintToString(const T& value); -// -// // Prints a value tersely: for a reference type, the referenced -// // value (but not the address) is printed; for a (const or not) char -// // pointer, the NUL-terminated string (but not the pointer) is -// // printed. -// void ::testing::internal::UniversalTersePrint(const T& value, ostream*); -// -// // Prints value using the type inferred by the compiler. The difference -// // from UniversalTersePrint() is that this function prints both the -// // pointer and the NUL-terminated string for a (const or not) char pointer. -// void ::testing::internal::UniversalPrint(const T& value, ostream*); -// -// // Prints the fields of a tuple tersely to a string vector, one -// // element for each field. Tuple support must be enabled in -// // gtest-port.h. -// std::vector UniversalTersePrintTupleFieldsToStrings( -// const Tuple& value); -// -// Known limitation: -// -// The print primitives print the elements of an STL-style container -// using the compiler-inferred type of *iter where iter is a -// const_iterator of the container. When const_iterator is an input -// iterator but not a forward iterator, this inferred type may not -// match value_type, and the print output may be incorrect. In -// practice, this is rarely a problem as for most containers -// const_iterator is a forward iterator. We'll fix this if there's an -// actual need for it. Note that this fix cannot rely on value_type -// being defined as many user-defined container types don't have -// value_type. - -#ifndef GTEST_INCLUDE_GTEST_GTEST_PRINTERS_H_ -#define GTEST_INCLUDE_GTEST_GTEST_PRINTERS_H_ - -#include // NOLINT -#include -#include -#include -#include -#include "gtest/internal/gtest-port.h" -#include "gtest/internal/gtest-internal.h" - -#if GTEST_HAS_STD_TUPLE_ -# include -#endif - -namespace testing { - -// Definitions in the 'internal' and 'internal2' name spaces are -// subject to change without notice. DO NOT USE THEM IN USER CODE! -namespace internal2 { - -// Prints the given number of bytes in the given object to the given -// ostream. -GTEST_API_ void PrintBytesInObjectTo(const unsigned char* obj_bytes, - size_t count, - ::std::ostream* os); - -// For selecting which printer to use when a given type has neither << -// nor PrintTo(). -enum TypeKind { - kProtobuf, // a protobuf type - kConvertibleToInteger, // a type implicitly convertible to BiggestInt - // (e.g. a named or unnamed enum type) - kOtherType // anything else -}; - -// TypeWithoutFormatter::PrintValue(value, os) is called -// by the universal printer to print a value of type T when neither -// operator<< nor PrintTo() is defined for T, where kTypeKind is the -// "kind" of T as defined by enum TypeKind. -template -class TypeWithoutFormatter { - public: - // This default version is called when kTypeKind is kOtherType. - static void PrintValue(const T& value, ::std::ostream* os) { - PrintBytesInObjectTo(reinterpret_cast(&value), - sizeof(value), os); - } -}; - -// We print a protobuf using its ShortDebugString() when the string -// doesn't exceed this many characters; otherwise we print it using -// DebugString() for better readability. -const size_t kProtobufOneLinerMaxLength = 50; - -template -class TypeWithoutFormatter { - public: - static void PrintValue(const T& value, ::std::ostream* os) { - const ::testing::internal::string short_str = value.ShortDebugString(); - const ::testing::internal::string pretty_str = - short_str.length() <= kProtobufOneLinerMaxLength ? - short_str : ("\n" + value.DebugString()); - *os << ("<" + pretty_str + ">"); - } -}; - -template -class TypeWithoutFormatter { - public: - // Since T has no << operator or PrintTo() but can be implicitly - // converted to BiggestInt, we print it as a BiggestInt. - // - // Most likely T is an enum type (either named or unnamed), in which - // case printing it as an integer is the desired behavior. In case - // T is not an enum, printing it as an integer is the best we can do - // given that it has no user-defined printer. - static void PrintValue(const T& value, ::std::ostream* os) { - const internal::BiggestInt kBigInt = value; - *os << kBigInt; - } -}; - -// Prints the given value to the given ostream. If the value is a -// protocol message, its debug string is printed; if it's an enum or -// of a type implicitly convertible to BiggestInt, it's printed as an -// integer; otherwise the bytes in the value are printed. This is -// what UniversalPrinter::Print() does when it knows nothing about -// type T and T has neither << operator nor PrintTo(). -// -// A user can override this behavior for a class type Foo by defining -// a << operator in the namespace where Foo is defined. -// -// We put this operator in namespace 'internal2' instead of 'internal' -// to simplify the implementation, as much code in 'internal' needs to -// use << in STL, which would conflict with our own << were it defined -// in 'internal'. -// -// Note that this operator<< takes a generic std::basic_ostream type instead of the more restricted std::ostream. If -// we define it to take an std::ostream instead, we'll get an -// "ambiguous overloads" compiler error when trying to print a type -// Foo that supports streaming to std::basic_ostream, as the compiler cannot tell whether -// operator<<(std::ostream&, const T&) or -// operator<<(std::basic_stream, const Foo&) is more -// specific. -template -::std::basic_ostream& operator<<( - ::std::basic_ostream& os, const T& x) { - TypeWithoutFormatter::value ? kProtobuf : - internal::ImplicitlyConvertible::value ? - kConvertibleToInteger : kOtherType)>::PrintValue(x, &os); - return os; -} - -} // namespace internal2 -} // namespace testing - -// This namespace MUST NOT BE NESTED IN ::testing, or the name look-up -// magic needed for implementing UniversalPrinter won't work. -namespace testing_internal { - -// Used to print a value that is not an STL-style container when the -// user doesn't define PrintTo() for it. -template -void DefaultPrintNonContainerTo(const T& value, ::std::ostream* os) { - // With the following statement, during unqualified name lookup, - // testing::internal2::operator<< appears as if it was declared in - // the nearest enclosing namespace that contains both - // ::testing_internal and ::testing::internal2, i.e. the global - // namespace. For more details, refer to the C++ Standard section - // 7.3.4-1 [namespace.udir]. This allows us to fall back onto - // testing::internal2::operator<< in case T doesn't come with a << - // operator. - // - // We cannot write 'using ::testing::internal2::operator<<;', which - // gcc 3.3 fails to compile due to a compiler bug. - using namespace ::testing::internal2; // NOLINT - - // Assuming T is defined in namespace foo, in the next statement, - // the compiler will consider all of: - // - // 1. foo::operator<< (thanks to Koenig look-up), - // 2. ::operator<< (as the current namespace is enclosed in ::), - // 3. testing::internal2::operator<< (thanks to the using statement above). - // - // The operator<< whose type matches T best will be picked. - // - // We deliberately allow #2 to be a candidate, as sometimes it's - // impossible to define #1 (e.g. when foo is ::std, defining - // anything in it is undefined behavior unless you are a compiler - // vendor.). - *os << value; -} - -} // namespace testing_internal - -namespace testing { -namespace internal { - -// FormatForComparison::Format(value) formats a -// value of type ToPrint that is an operand of a comparison assertion -// (e.g. ASSERT_EQ). OtherOperand is the type of the other operand in -// the comparison, and is used to help determine the best way to -// format the value. In particular, when the value is a C string -// (char pointer) and the other operand is an STL string object, we -// want to format the C string as a string, since we know it is -// compared by value with the string object. If the value is a char -// pointer but the other operand is not an STL string object, we don't -// know whether the pointer is supposed to point to a NUL-terminated -// string, and thus want to print it as a pointer to be safe. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - -// The default case. -template -class FormatForComparison { - public: - static ::std::string Format(const ToPrint& value) { - return ::testing::PrintToString(value); - } -}; - -// Array. -template -class FormatForComparison { - public: - static ::std::string Format(const ToPrint* value) { - return FormatForComparison::Format(value); - } -}; - -// By default, print C string as pointers to be safe, as we don't know -// whether they actually point to a NUL-terminated string. - -#define GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_(CharType) \ - template \ - class FormatForComparison { \ - public: \ - static ::std::string Format(CharType* value) { \ - return ::testing::PrintToString(static_cast(value)); \ - } \ - } - -GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_(char); -GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_(const char); -GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_(wchar_t); -GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_(const wchar_t); - -#undef GTEST_IMPL_FORMAT_C_STRING_AS_POINTER_ - -// If a C string is compared with an STL string object, we know it's meant -// to point to a NUL-terminated string, and thus can print it as a string. - -#define GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(CharType, OtherStringType) \ - template <> \ - class FormatForComparison { \ - public: \ - static ::std::string Format(CharType* value) { \ - return ::testing::PrintToString(value); \ - } \ - } - -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(char, ::std::string); -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(const char, ::std::string); - -#if GTEST_HAS_GLOBAL_STRING -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(char, ::string); -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(const char, ::string); -#endif - -#if GTEST_HAS_GLOBAL_WSTRING -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(wchar_t, ::wstring); -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(const wchar_t, ::wstring); -#endif - -#if GTEST_HAS_STD_WSTRING -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(wchar_t, ::std::wstring); -GTEST_IMPL_FORMAT_C_STRING_AS_STRING_(const wchar_t, ::std::wstring); -#endif - -#undef GTEST_IMPL_FORMAT_C_STRING_AS_STRING_ - -// Formats a comparison assertion (e.g. ASSERT_EQ, EXPECT_LT, and etc) -// operand to be used in a failure message. The type (but not value) -// of the other operand may affect the format. This allows us to -// print a char* as a raw pointer when it is compared against another -// char* or void*, and print it as a C string when it is compared -// against an std::string object, for example. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -template -std::string FormatForComparisonFailureMessage( - const T1& value, const T2& /* other_operand */) { - return FormatForComparison::Format(value); -} - -// UniversalPrinter::Print(value, ostream_ptr) prints the given -// value to the given ostream. The caller must ensure that -// 'ostream_ptr' is not NULL, or the behavior is undefined. -// -// We define UniversalPrinter as a class template (as opposed to a -// function template), as we need to partially specialize it for -// reference types, which cannot be done with function templates. -template -class UniversalPrinter; - -template -void UniversalPrint(const T& value, ::std::ostream* os); - -// Used to print an STL-style container when the user doesn't define -// a PrintTo() for it. -template -void DefaultPrintTo(IsContainer /* dummy */, - false_type /* is not a pointer */, - const C& container, ::std::ostream* os) { - const size_t kMaxCount = 32; // The maximum number of elements to print. - *os << '{'; - size_t count = 0; - for (typename C::const_iterator it = container.begin(); - it != container.end(); ++it, ++count) { - if (count > 0) { - *os << ','; - if (count == kMaxCount) { // Enough has been printed. - *os << " ..."; - break; - } - } - *os << ' '; - // We cannot call PrintTo(*it, os) here as PrintTo() doesn't - // handle *it being a native array. - internal::UniversalPrint(*it, os); - } - - if (count > 0) { - *os << ' '; - } - *os << '}'; -} - -// Used to print a pointer that is neither a char pointer nor a member -// pointer, when the user doesn't define PrintTo() for it. (A member -// variable pointer or member function pointer doesn't really point to -// a location in the address space. Their representation is -// implementation-defined. Therefore they will be printed as raw -// bytes.) -template -void DefaultPrintTo(IsNotContainer /* dummy */, - true_type /* is a pointer */, - T* p, ::std::ostream* os) { - if (p == NULL) { - *os << "NULL"; - } else { - // C++ doesn't allow casting from a function pointer to any object - // pointer. - // - // IsTrue() silences warnings: "Condition is always true", - // "unreachable code". - if (IsTrue(ImplicitlyConvertible::value)) { - // T is not a function type. We just call << to print p, - // relying on ADL to pick up user-defined << for their pointer - // types, if any. - *os << p; - } else { - // T is a function type, so '*os << p' doesn't do what we want - // (it just prints p as bool). We want to print p as a const - // void*. However, we cannot cast it to const void* directly, - // even using reinterpret_cast, as earlier versions of gcc - // (e.g. 3.4.5) cannot compile the cast when p is a function - // pointer. Casting to UInt64 first solves the problem. - *os << reinterpret_cast( - reinterpret_cast(p)); - } - } -} - -// Used to print a non-container, non-pointer value when the user -// doesn't define PrintTo() for it. -template -void DefaultPrintTo(IsNotContainer /* dummy */, - false_type /* is not a pointer */, - const T& value, ::std::ostream* os) { - ::testing_internal::DefaultPrintNonContainerTo(value, os); -} - -// Prints the given value using the << operator if it has one; -// otherwise prints the bytes in it. This is what -// UniversalPrinter::Print() does when PrintTo() is not specialized -// or overloaded for type T. -// -// A user can override this behavior for a class type Foo by defining -// an overload of PrintTo() in the namespace where Foo is defined. We -// give the user this option as sometimes defining a << operator for -// Foo is not desirable (e.g. the coding style may prevent doing it, -// or there is already a << operator but it doesn't do what the user -// wants). -template -void PrintTo(const T& value, ::std::ostream* os) { - // DefaultPrintTo() is overloaded. The type of its first two - // arguments determine which version will be picked. If T is an - // STL-style container, the version for container will be called; if - // T is a pointer, the pointer version will be called; otherwise the - // generic version will be called. - // - // Note that we check for container types here, prior to we check - // for protocol message types in our operator<<. The rationale is: - // - // For protocol messages, we want to give people a chance to - // override Google Mock's format by defining a PrintTo() or - // operator<<. For STL containers, other formats can be - // incompatible with Google Mock's format for the container - // elements; therefore we check for container types here to ensure - // that our format is used. - // - // The second argument of DefaultPrintTo() is needed to bypass a bug - // in Symbian's C++ compiler that prevents it from picking the right - // overload between: - // - // PrintTo(const T& x, ...); - // PrintTo(T* x, ...); - DefaultPrintTo(IsContainerTest(0), is_pointer(), value, os); -} - -// The following list of PrintTo() overloads tells -// UniversalPrinter::Print() how to print standard types (built-in -// types, strings, plain arrays, and pointers). - -// Overloads for various char types. -GTEST_API_ void PrintTo(unsigned char c, ::std::ostream* os); -GTEST_API_ void PrintTo(signed char c, ::std::ostream* os); -inline void PrintTo(char c, ::std::ostream* os) { - // When printing a plain char, we always treat it as unsigned. This - // way, the output won't be affected by whether the compiler thinks - // char is signed or not. - PrintTo(static_cast(c), os); -} - -// Overloads for other simple built-in types. -inline void PrintTo(bool x, ::std::ostream* os) { - *os << (x ? "true" : "false"); -} - -// Overload for wchar_t type. -// Prints a wchar_t as a symbol if it is printable or as its internal -// code otherwise and also as its decimal code (except for L'\0'). -// The L'\0' char is printed as "L'\\0'". The decimal code is printed -// as signed integer when wchar_t is implemented by the compiler -// as a signed type and is printed as an unsigned integer when wchar_t -// is implemented as an unsigned type. -GTEST_API_ void PrintTo(wchar_t wc, ::std::ostream* os); - -// Overloads for C strings. -GTEST_API_ void PrintTo(const char* s, ::std::ostream* os); -inline void PrintTo(char* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} - -// signed/unsigned char is often used for representing binary data, so -// we print pointers to it as void* to be safe. -inline void PrintTo(const signed char* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} -inline void PrintTo(signed char* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} -inline void PrintTo(const unsigned char* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} -inline void PrintTo(unsigned char* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} - -// MSVC can be configured to define wchar_t as a typedef of unsigned -// short. It defines _NATIVE_WCHAR_T_DEFINED when wchar_t is a native -// type. When wchar_t is a typedef, defining an overload for const -// wchar_t* would cause unsigned short* be printed as a wide string, -// possibly causing invalid memory accesses. -#if !defined(_MSC_VER) || defined(_NATIVE_WCHAR_T_DEFINED) -// Overloads for wide C strings -GTEST_API_ void PrintTo(const wchar_t* s, ::std::ostream* os); -inline void PrintTo(wchar_t* s, ::std::ostream* os) { - PrintTo(ImplicitCast_(s), os); -} -#endif - -// Overload for C arrays. Multi-dimensional arrays are printed -// properly. - -// Prints the given number of elements in an array, without printing -// the curly braces. -template -void PrintRawArrayTo(const T a[], size_t count, ::std::ostream* os) { - UniversalPrint(a[0], os); - for (size_t i = 1; i != count; i++) { - *os << ", "; - UniversalPrint(a[i], os); - } -} - -// Overloads for ::string and ::std::string. -#if GTEST_HAS_GLOBAL_STRING -GTEST_API_ void PrintStringTo(const ::string&s, ::std::ostream* os); -inline void PrintTo(const ::string& s, ::std::ostream* os) { - PrintStringTo(s, os); -} -#endif // GTEST_HAS_GLOBAL_STRING - -GTEST_API_ void PrintStringTo(const ::std::string&s, ::std::ostream* os); -inline void PrintTo(const ::std::string& s, ::std::ostream* os) { - PrintStringTo(s, os); -} - -// Overloads for ::wstring and ::std::wstring. -#if GTEST_HAS_GLOBAL_WSTRING -GTEST_API_ void PrintWideStringTo(const ::wstring&s, ::std::ostream* os); -inline void PrintTo(const ::wstring& s, ::std::ostream* os) { - PrintWideStringTo(s, os); -} -#endif // GTEST_HAS_GLOBAL_WSTRING - -#if GTEST_HAS_STD_WSTRING -GTEST_API_ void PrintWideStringTo(const ::std::wstring&s, ::std::ostream* os); -inline void PrintTo(const ::std::wstring& s, ::std::ostream* os) { - PrintWideStringTo(s, os); -} -#endif // GTEST_HAS_STD_WSTRING - -#if GTEST_HAS_TR1_TUPLE || GTEST_HAS_STD_TUPLE_ -// Helper function for printing a tuple. T must be instantiated with -// a tuple type. -template -void PrintTupleTo(const T& t, ::std::ostream* os); -#endif // GTEST_HAS_TR1_TUPLE || GTEST_HAS_STD_TUPLE_ - -#if GTEST_HAS_TR1_TUPLE -// Overload for ::std::tr1::tuple. Needed for printing function arguments, -// which are packed as tuples. - -// Overloaded PrintTo() for tuples of various arities. We support -// tuples of up-to 10 fields. The following implementation works -// regardless of whether tr1::tuple is implemented using the -// non-standard variadic template feature or not. - -inline void PrintTo(const ::std::tr1::tuple<>& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo(const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} - -template -void PrintTo( - const ::std::tr1::tuple& t, - ::std::ostream* os) { - PrintTupleTo(t, os); -} -#endif // GTEST_HAS_TR1_TUPLE - -#if GTEST_HAS_STD_TUPLE_ -template -void PrintTo(const ::std::tuple& t, ::std::ostream* os) { - PrintTupleTo(t, os); -} -#endif // GTEST_HAS_STD_TUPLE_ - -// Overload for std::pair. -template -void PrintTo(const ::std::pair& value, ::std::ostream* os) { - *os << '('; - // We cannot use UniversalPrint(value.first, os) here, as T1 may be - // a reference type. The same for printing value.second. - UniversalPrinter::Print(value.first, os); - *os << ", "; - UniversalPrinter::Print(value.second, os); - *os << ')'; -} - -// Implements printing a non-reference type T by letting the compiler -// pick the right overload of PrintTo() for T. -template -class UniversalPrinter { - public: - // MSVC warns about adding const to a function type, so we want to - // disable the warning. - GTEST_DISABLE_MSC_WARNINGS_PUSH_(4180) - - // Note: we deliberately don't call this PrintTo(), as that name - // conflicts with ::testing::internal::PrintTo in the body of the - // function. - static void Print(const T& value, ::std::ostream* os) { - // By default, ::testing::internal::PrintTo() is used for printing - // the value. - // - // Thanks to Koenig look-up, if T is a class and has its own - // PrintTo() function defined in its namespace, that function will - // be visible here. Since it is more specific than the generic ones - // in ::testing::internal, it will be picked by the compiler in the - // following statement - exactly what we want. - PrintTo(value, os); - } - - GTEST_DISABLE_MSC_WARNINGS_POP_() -}; - -// UniversalPrintArray(begin, len, os) prints an array of 'len' -// elements, starting at address 'begin'. -template -void UniversalPrintArray(const T* begin, size_t len, ::std::ostream* os) { - if (len == 0) { - *os << "{}"; - } else { - *os << "{ "; - const size_t kThreshold = 18; - const size_t kChunkSize = 8; - // If the array has more than kThreshold elements, we'll have to - // omit some details by printing only the first and the last - // kChunkSize elements. - // TODO(wan@google.com): let the user control the threshold using a flag. - if (len <= kThreshold) { - PrintRawArrayTo(begin, len, os); - } else { - PrintRawArrayTo(begin, kChunkSize, os); - *os << ", ..., "; - PrintRawArrayTo(begin + len - kChunkSize, kChunkSize, os); - } - *os << " }"; - } -} -// This overload prints a (const) char array compactly. -GTEST_API_ void UniversalPrintArray( - const char* begin, size_t len, ::std::ostream* os); - -// This overload prints a (const) wchar_t array compactly. -GTEST_API_ void UniversalPrintArray( - const wchar_t* begin, size_t len, ::std::ostream* os); - -// Implements printing an array type T[N]. -template -class UniversalPrinter { - public: - // Prints the given array, omitting some elements when there are too - // many. - static void Print(const T (&a)[N], ::std::ostream* os) { - UniversalPrintArray(a, N, os); - } -}; - -// Implements printing a reference type T&. -template -class UniversalPrinter { - public: - // MSVC warns about adding const to a function type, so we want to - // disable the warning. - GTEST_DISABLE_MSC_WARNINGS_PUSH_(4180) - - static void Print(const T& value, ::std::ostream* os) { - // Prints the address of the value. We use reinterpret_cast here - // as static_cast doesn't compile when T is a function type. - *os << "@" << reinterpret_cast(&value) << " "; - - // Then prints the value itself. - UniversalPrint(value, os); - } - - GTEST_DISABLE_MSC_WARNINGS_POP_() -}; - -// Prints a value tersely: for a reference type, the referenced value -// (but not the address) is printed; for a (const) char pointer, the -// NUL-terminated string (but not the pointer) is printed. - -template -class UniversalTersePrinter { - public: - static void Print(const T& value, ::std::ostream* os) { - UniversalPrint(value, os); - } -}; -template -class UniversalTersePrinter { - public: - static void Print(const T& value, ::std::ostream* os) { - UniversalPrint(value, os); - } -}; -template -class UniversalTersePrinter { - public: - static void Print(const T (&value)[N], ::std::ostream* os) { - UniversalPrinter::Print(value, os); - } -}; -template <> -class UniversalTersePrinter { - public: - static void Print(const char* str, ::std::ostream* os) { - if (str == NULL) { - *os << "NULL"; - } else { - UniversalPrint(string(str), os); - } - } -}; -template <> -class UniversalTersePrinter { - public: - static void Print(char* str, ::std::ostream* os) { - UniversalTersePrinter::Print(str, os); - } -}; - -#if GTEST_HAS_STD_WSTRING -template <> -class UniversalTersePrinter { - public: - static void Print(const wchar_t* str, ::std::ostream* os) { - if (str == NULL) { - *os << "NULL"; - } else { - UniversalPrint(::std::wstring(str), os); - } - } -}; -#endif - -template <> -class UniversalTersePrinter { - public: - static void Print(wchar_t* str, ::std::ostream* os) { - UniversalTersePrinter::Print(str, os); - } -}; - -template -void UniversalTersePrint(const T& value, ::std::ostream* os) { - UniversalTersePrinter::Print(value, os); -} - -// Prints a value using the type inferred by the compiler. The -// difference between this and UniversalTersePrint() is that for a -// (const) char pointer, this prints both the pointer and the -// NUL-terminated string. -template -void UniversalPrint(const T& value, ::std::ostream* os) { - // A workarond for the bug in VC++ 7.1 that prevents us from instantiating - // UniversalPrinter with T directly. - typedef T T1; - UniversalPrinter::Print(value, os); -} - -typedef ::std::vector Strings; - -// TuplePolicy must provide: -// - tuple_size -// size of tuple TupleT. -// - get(const TupleT& t) -// static function extracting element I of tuple TupleT. -// - tuple_element::type -// type of element I of tuple TupleT. -template -struct TuplePolicy; - -#if GTEST_HAS_TR1_TUPLE -template -struct TuplePolicy { - typedef TupleT Tuple; - static const size_t tuple_size = ::std::tr1::tuple_size::value; - - template - struct tuple_element : ::std::tr1::tuple_element {}; - - template - static typename AddReference< - const typename ::std::tr1::tuple_element::type>::type get( - const Tuple& tuple) { - return ::std::tr1::get(tuple); - } -}; -template -const size_t TuplePolicy::tuple_size; -#endif // GTEST_HAS_TR1_TUPLE - -#if GTEST_HAS_STD_TUPLE_ -template -struct TuplePolicy< ::std::tuple > { - typedef ::std::tuple Tuple; - static const size_t tuple_size = ::std::tuple_size::value; - - template - struct tuple_element : ::std::tuple_element {}; - - template - static const typename ::std::tuple_element::type& get( - const Tuple& tuple) { - return ::std::get(tuple); - } -}; -template -const size_t TuplePolicy< ::std::tuple >::tuple_size; -#endif // GTEST_HAS_STD_TUPLE_ - -#if GTEST_HAS_TR1_TUPLE || GTEST_HAS_STD_TUPLE_ -// This helper template allows PrintTo() for tuples and -// UniversalTersePrintTupleFieldsToStrings() to be defined by -// induction on the number of tuple fields. The idea is that -// TuplePrefixPrinter::PrintPrefixTo(t, os) prints the first N -// fields in tuple t, and can be defined in terms of -// TuplePrefixPrinter. -// -// The inductive case. -template -struct TuplePrefixPrinter { - // Prints the first N fields of a tuple. - template - static void PrintPrefixTo(const Tuple& t, ::std::ostream* os) { - TuplePrefixPrinter::PrintPrefixTo(t, os); - GTEST_INTENTIONAL_CONST_COND_PUSH_() - if (N > 1) { - GTEST_INTENTIONAL_CONST_COND_POP_() - *os << ", "; - } - UniversalPrinter< - typename TuplePolicy::template tuple_element::type> - ::Print(TuplePolicy::template get(t), os); - } - - // Tersely prints the first N fields of a tuple to a string vector, - // one element for each field. - template - static void TersePrintPrefixToStrings(const Tuple& t, Strings* strings) { - TuplePrefixPrinter::TersePrintPrefixToStrings(t, strings); - ::std::stringstream ss; - UniversalTersePrint(TuplePolicy::template get(t), &ss); - strings->push_back(ss.str()); - } -}; - -// Base case. -template <> -struct TuplePrefixPrinter<0> { - template - static void PrintPrefixTo(const Tuple&, ::std::ostream*) {} - - template - static void TersePrintPrefixToStrings(const Tuple&, Strings*) {} -}; - -// Helper function for printing a tuple. -// Tuple must be either std::tr1::tuple or std::tuple type. -template -void PrintTupleTo(const Tuple& t, ::std::ostream* os) { - *os << "("; - TuplePrefixPrinter::tuple_size>::PrintPrefixTo(t, os); - *os << ")"; -} - -// Prints the fields of a tuple tersely to a string vector, one -// element for each field. See the comment before -// UniversalTersePrint() for how we define "tersely". -template -Strings UniversalTersePrintTupleFieldsToStrings(const Tuple& value) { - Strings result; - TuplePrefixPrinter::tuple_size>:: - TersePrintPrefixToStrings(value, &result); - return result; -} -#endif // GTEST_HAS_TR1_TUPLE || GTEST_HAS_STD_TUPLE_ - -} // namespace internal - -template -::std::string PrintToString(const T& value) { - ::std::stringstream ss; - internal::UniversalTersePrinter::Print(value, &ss); - return ss.str(); -} - -} // namespace testing - -// Include any custom printer added by the local installation. -// We must include this header at the end to make sure it can use the -// declarations from this file. -#include "gtest/internal/custom/gtest-printers.h" - -#endif // GTEST_INCLUDE_GTEST_GTEST_PRINTERS_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-spi.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-spi.h deleted file mode 100644 index f63fa9a1b2a..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-spi.h +++ /dev/null @@ -1,232 +0,0 @@ -// Copyright 2007, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) -// -// Utilities for testing Google Test itself and code that uses Google Test -// (e.g. frameworks built on top of Google Test). - -#ifndef GTEST_INCLUDE_GTEST_GTEST_SPI_H_ -#define GTEST_INCLUDE_GTEST_GTEST_SPI_H_ - -#include "gtest/gtest.h" - -namespace testing { - -// This helper class can be used to mock out Google Test failure reporting -// so that we can test Google Test or code that builds on Google Test. -// -// An object of this class appends a TestPartResult object to the -// TestPartResultArray object given in the constructor whenever a Google Test -// failure is reported. It can either intercept only failures that are -// generated in the same thread that created this object or it can intercept -// all generated failures. The scope of this mock object can be controlled with -// the second argument to the two arguments constructor. -class GTEST_API_ ScopedFakeTestPartResultReporter - : public TestPartResultReporterInterface { - public: - // The two possible mocking modes of this object. - enum InterceptMode { - INTERCEPT_ONLY_CURRENT_THREAD, // Intercepts only thread local failures. - INTERCEPT_ALL_THREADS // Intercepts all failures. - }; - - // The c'tor sets this object as the test part result reporter used - // by Google Test. The 'result' parameter specifies where to report the - // results. This reporter will only catch failures generated in the current - // thread. DEPRECATED - explicit ScopedFakeTestPartResultReporter(TestPartResultArray* result); - - // Same as above, but you can choose the interception scope of this object. - ScopedFakeTestPartResultReporter(InterceptMode intercept_mode, - TestPartResultArray* result); - - // The d'tor restores the previous test part result reporter. - virtual ~ScopedFakeTestPartResultReporter(); - - // Appends the TestPartResult object to the TestPartResultArray - // received in the constructor. - // - // This method is from the TestPartResultReporterInterface - // interface. - virtual void ReportTestPartResult(const TestPartResult& result); - private: - void Init(); - - const InterceptMode intercept_mode_; - TestPartResultReporterInterface* old_reporter_; - TestPartResultArray* const result_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ScopedFakeTestPartResultReporter); -}; - -namespace internal { - -// A helper class for implementing EXPECT_FATAL_FAILURE() and -// EXPECT_NONFATAL_FAILURE(). Its destructor verifies that the given -// TestPartResultArray contains exactly one failure that has the given -// type and contains the given substring. If that's not the case, a -// non-fatal failure will be generated. -class GTEST_API_ SingleFailureChecker { - public: - // The constructor remembers the arguments. - SingleFailureChecker(const TestPartResultArray* results, - TestPartResult::Type type, - const string& substr); - ~SingleFailureChecker(); - private: - const TestPartResultArray* const results_; - const TestPartResult::Type type_; - const string substr_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(SingleFailureChecker); -}; - -} // namespace internal - -} // namespace testing - -// A set of macros for testing Google Test assertions or code that's expected -// to generate Google Test fatal failures. It verifies that the given -// statement will cause exactly one fatal Google Test failure with 'substr' -// being part of the failure message. -// -// There are two different versions of this macro. EXPECT_FATAL_FAILURE only -// affects and considers failures generated in the current thread and -// EXPECT_FATAL_FAILURE_ON_ALL_THREADS does the same but for all threads. -// -// The verification of the assertion is done correctly even when the statement -// throws an exception or aborts the current function. -// -// Known restrictions: -// - 'statement' cannot reference local non-static variables or -// non-static members of the current object. -// - 'statement' cannot return a value. -// - You cannot stream a failure message to this macro. -// -// Note that even though the implementations of the following two -// macros are much alike, we cannot refactor them to use a common -// helper macro, due to some peculiarity in how the preprocessor -// works. The AcceptsMacroThatExpandsToUnprotectedComma test in -// gtest_unittest.cc will fail to compile if we do that. -#define EXPECT_FATAL_FAILURE(statement, substr) \ - do { \ - class GTestExpectFatalFailureHelper {\ - public:\ - static void Execute() { statement; }\ - };\ - ::testing::TestPartResultArray gtest_failures;\ - ::testing::internal::SingleFailureChecker gtest_checker(\ - >est_failures, ::testing::TestPartResult::kFatalFailure, (substr));\ - {\ - ::testing::ScopedFakeTestPartResultReporter gtest_reporter(\ - ::testing::ScopedFakeTestPartResultReporter:: \ - INTERCEPT_ONLY_CURRENT_THREAD, >est_failures);\ - GTestExpectFatalFailureHelper::Execute();\ - }\ - } while (::testing::internal::AlwaysFalse()) - -#define EXPECT_FATAL_FAILURE_ON_ALL_THREADS(statement, substr) \ - do { \ - class GTestExpectFatalFailureHelper {\ - public:\ - static void Execute() { statement; }\ - };\ - ::testing::TestPartResultArray gtest_failures;\ - ::testing::internal::SingleFailureChecker gtest_checker(\ - >est_failures, ::testing::TestPartResult::kFatalFailure, (substr));\ - {\ - ::testing::ScopedFakeTestPartResultReporter gtest_reporter(\ - ::testing::ScopedFakeTestPartResultReporter:: \ - INTERCEPT_ALL_THREADS, >est_failures);\ - GTestExpectFatalFailureHelper::Execute();\ - }\ - } while (::testing::internal::AlwaysFalse()) - -// A macro for testing Google Test assertions or code that's expected to -// generate Google Test non-fatal failures. It asserts that the given -// statement will cause exactly one non-fatal Google Test failure with 'substr' -// being part of the failure message. -// -// There are two different versions of this macro. EXPECT_NONFATAL_FAILURE only -// affects and considers failures generated in the current thread and -// EXPECT_NONFATAL_FAILURE_ON_ALL_THREADS does the same but for all threads. -// -// 'statement' is allowed to reference local variables and members of -// the current object. -// -// The verification of the assertion is done correctly even when the statement -// throws an exception or aborts the current function. -// -// Known restrictions: -// - You cannot stream a failure message to this macro. -// -// Note that even though the implementations of the following two -// macros are much alike, we cannot refactor them to use a common -// helper macro, due to some peculiarity in how the preprocessor -// works. If we do that, the code won't compile when the user gives -// EXPECT_NONFATAL_FAILURE() a statement that contains a macro that -// expands to code containing an unprotected comma. The -// AcceptsMacroThatExpandsToUnprotectedComma test in gtest_unittest.cc -// catches that. -// -// For the same reason, we have to write -// if (::testing::internal::AlwaysTrue()) { statement; } -// instead of -// GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement) -// to avoid an MSVC warning on unreachable code. -#define EXPECT_NONFATAL_FAILURE(statement, substr) \ - do {\ - ::testing::TestPartResultArray gtest_failures;\ - ::testing::internal::SingleFailureChecker gtest_checker(\ - >est_failures, ::testing::TestPartResult::kNonFatalFailure, \ - (substr));\ - {\ - ::testing::ScopedFakeTestPartResultReporter gtest_reporter(\ - ::testing::ScopedFakeTestPartResultReporter:: \ - INTERCEPT_ONLY_CURRENT_THREAD, >est_failures);\ - if (::testing::internal::AlwaysTrue()) { statement; }\ - }\ - } while (::testing::internal::AlwaysFalse()) - -#define EXPECT_NONFATAL_FAILURE_ON_ALL_THREADS(statement, substr) \ - do {\ - ::testing::TestPartResultArray gtest_failures;\ - ::testing::internal::SingleFailureChecker gtest_checker(\ - >est_failures, ::testing::TestPartResult::kNonFatalFailure, \ - (substr));\ - {\ - ::testing::ScopedFakeTestPartResultReporter gtest_reporter(\ - ::testing::ScopedFakeTestPartResultReporter::INTERCEPT_ALL_THREADS, \ - >est_failures);\ - if (::testing::internal::AlwaysTrue()) { statement; }\ - }\ - } while (::testing::internal::AlwaysFalse()) - -#endif // GTEST_INCLUDE_GTEST_GTEST_SPI_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-test-part.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-test-part.h deleted file mode 100644 index 77eb844839d..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-test-part.h +++ /dev/null @@ -1,179 +0,0 @@ -// Copyright 2008, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: mheule@google.com (Markus Heule) -// - -#ifndef GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ -#define GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ - -#include -#include -#include "gtest/internal/gtest-internal.h" -#include "gtest/internal/gtest-string.h" - -namespace testing { - -// A copyable object representing the result of a test part (i.e. an -// assertion or an explicit FAIL(), ADD_FAILURE(), or SUCCESS()). -// -// Don't inherit from TestPartResult as its destructor is not virtual. -class GTEST_API_ TestPartResult { - public: - // The possible outcomes of a test part (i.e. an assertion or an - // explicit SUCCEED(), FAIL(), or ADD_FAILURE()). - enum Type { - kSuccess, // Succeeded. - kNonFatalFailure, // Failed but the test can continue. - kFatalFailure // Failed and the test should be terminated. - }; - - // C'tor. TestPartResult does NOT have a default constructor. - // Always use this constructor (with parameters) to create a - // TestPartResult object. - TestPartResult(Type a_type, - const char* a_file_name, - int a_line_number, - const char* a_message) - : type_(a_type), - file_name_(a_file_name == NULL ? "" : a_file_name), - line_number_(a_line_number), - summary_(ExtractSummary(a_message)), - message_(a_message) { - } - - // Gets the outcome of the test part. - Type type() const { return type_; } - - // Gets the name of the source file where the test part took place, or - // NULL if it's unknown. - const char* file_name() const { - return file_name_.empty() ? NULL : file_name_.c_str(); - } - - // Gets the line in the source file where the test part took place, - // or -1 if it's unknown. - int line_number() const { return line_number_; } - - // Gets the summary of the failure message. - const char* summary() const { return summary_.c_str(); } - - // Gets the message associated with the test part. - const char* message() const { return message_.c_str(); } - - // Returns true iff the test part passed. - bool passed() const { return type_ == kSuccess; } - - // Returns true iff the test part failed. - bool failed() const { return type_ != kSuccess; } - - // Returns true iff the test part non-fatally failed. - bool nonfatally_failed() const { return type_ == kNonFatalFailure; } - - // Returns true iff the test part fatally failed. - bool fatally_failed() const { return type_ == kFatalFailure; } - - private: - Type type_; - - // Gets the summary of the failure message by omitting the stack - // trace in it. - static std::string ExtractSummary(const char* message); - - // The name of the source file where the test part took place, or - // "" if the source file is unknown. - std::string file_name_; - // The line in the source file where the test part took place, or -1 - // if the line number is unknown. - int line_number_; - std::string summary_; // The test failure summary. - std::string message_; // The test failure message. -}; - -// Prints a TestPartResult object. -std::ostream& operator<<(std::ostream& os, const TestPartResult& result); - -// An array of TestPartResult objects. -// -// Don't inherit from TestPartResultArray as its destructor is not -// virtual. -class GTEST_API_ TestPartResultArray { - public: - TestPartResultArray() {} - - // Appends the given TestPartResult to the array. - void Append(const TestPartResult& result); - - // Returns the TestPartResult at the given index (0-based). - const TestPartResult& GetTestPartResult(int index) const; - - // Returns the number of TestPartResult objects in the array. - int size() const; - - private: - std::vector array_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestPartResultArray); -}; - -// This interface knows how to report a test part result. -class TestPartResultReporterInterface { - public: - virtual ~TestPartResultReporterInterface() {} - - virtual void ReportTestPartResult(const TestPartResult& result) = 0; -}; - -namespace internal { - -// This helper class is used by {ASSERT|EXPECT}_NO_FATAL_FAILURE to check if a -// statement generates new fatal failures. To do so it registers itself as the -// current test part result reporter. Besides checking if fatal failures were -// reported, it only delegates the reporting to the former result reporter. -// The original result reporter is restored in the destructor. -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -class GTEST_API_ HasNewFatalFailureHelper - : public TestPartResultReporterInterface { - public: - HasNewFatalFailureHelper(); - virtual ~HasNewFatalFailureHelper(); - virtual void ReportTestPartResult(const TestPartResult& result); - bool has_new_fatal_failure() const { return has_new_fatal_failure_; } - private: - bool has_new_fatal_failure_; - TestPartResultReporterInterface* original_reporter_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(HasNewFatalFailureHelper); -}; - -} // namespace internal - -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_GTEST_TEST_PART_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-typed-test.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-typed-test.h deleted file mode 100644 index 5f69d5678ea..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest-typed-test.h +++ /dev/null @@ -1,263 +0,0 @@ -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -#ifndef GTEST_INCLUDE_GTEST_GTEST_TYPED_TEST_H_ -#define GTEST_INCLUDE_GTEST_GTEST_TYPED_TEST_H_ - -// This header implements typed tests and type-parameterized tests. - -// Typed (aka type-driven) tests repeat the same test for types in a -// list. You must know which types you want to test with when writing -// typed tests. Here's how you do it: - -#if 0 - -// First, define a fixture class template. It should be parameterized -// by a type. Remember to derive it from testing::Test. -template -class FooTest : public testing::Test { - public: - ... - typedef std::list List; - static T shared_; - T value_; -}; - -// Next, associate a list of types with the test case, which will be -// repeated for each type in the list. The typedef is necessary for -// the macro to parse correctly. -typedef testing::Types MyTypes; -TYPED_TEST_CASE(FooTest, MyTypes); - -// If the type list contains only one type, you can write that type -// directly without Types<...>: -// TYPED_TEST_CASE(FooTest, int); - -// Then, use TYPED_TEST() instead of TEST_F() to define as many typed -// tests for this test case as you want. -TYPED_TEST(FooTest, DoesBlah) { - // Inside a test, refer to TypeParam to get the type parameter. - // Since we are inside a derived class template, C++ requires use to - // visit the members of FooTest via 'this'. - TypeParam n = this->value_; - - // To visit static members of the fixture, add the TestFixture:: - // prefix. - n += TestFixture::shared_; - - // To refer to typedefs in the fixture, add the "typename - // TestFixture::" prefix. - typename TestFixture::List values; - values.push_back(n); - ... -} - -TYPED_TEST(FooTest, HasPropertyA) { ... } - -#endif // 0 - -// Type-parameterized tests are abstract test patterns parameterized -// by a type. Compared with typed tests, type-parameterized tests -// allow you to define the test pattern without knowing what the type -// parameters are. The defined pattern can be instantiated with -// different types any number of times, in any number of translation -// units. -// -// If you are designing an interface or concept, you can define a -// suite of type-parameterized tests to verify properties that any -// valid implementation of the interface/concept should have. Then, -// each implementation can easily instantiate the test suite to verify -// that it conforms to the requirements, without having to write -// similar tests repeatedly. Here's an example: - -#if 0 - -// First, define a fixture class template. It should be parameterized -// by a type. Remember to derive it from testing::Test. -template -class FooTest : public testing::Test { - ... -}; - -// Next, declare that you will define a type-parameterized test case -// (the _P suffix is for "parameterized" or "pattern", whichever you -// prefer): -TYPED_TEST_CASE_P(FooTest); - -// Then, use TYPED_TEST_P() to define as many type-parameterized tests -// for this type-parameterized test case as you want. -TYPED_TEST_P(FooTest, DoesBlah) { - // Inside a test, refer to TypeParam to get the type parameter. - TypeParam n = 0; - ... -} - -TYPED_TEST_P(FooTest, HasPropertyA) { ... } - -// Now the tricky part: you need to register all test patterns before -// you can instantiate them. The first argument of the macro is the -// test case name; the rest are the names of the tests in this test -// case. -REGISTER_TYPED_TEST_CASE_P(FooTest, - DoesBlah, HasPropertyA); - -// Finally, you are free to instantiate the pattern with the types you -// want. If you put the above code in a header file, you can #include -// it in multiple C++ source files and instantiate it multiple times. -// -// To distinguish different instances of the pattern, the first -// argument to the INSTANTIATE_* macro is a prefix that will be added -// to the actual test case name. Remember to pick unique prefixes for -// different instances. -typedef testing::Types MyTypes; -INSTANTIATE_TYPED_TEST_CASE_P(My, FooTest, MyTypes); - -// If the type list contains only one type, you can write that type -// directly without Types<...>: -// INSTANTIATE_TYPED_TEST_CASE_P(My, FooTest, int); - -#endif // 0 - -#include "gtest/internal/gtest-port.h" -#include "gtest/internal/gtest-type-util.h" - -// Implements typed tests. - -#if GTEST_HAS_TYPED_TEST - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Expands to the name of the typedef for the type parameters of the -// given test case. -# define GTEST_TYPE_PARAMS_(TestCaseName) gtest_type_params_##TestCaseName##_ - -// The 'Types' template argument below must have spaces around it -// since some compilers may choke on '>>' when passing a template -// instance (e.g. Types) -# define TYPED_TEST_CASE(CaseName, Types) \ - typedef ::testing::internal::TypeList< Types >::type \ - GTEST_TYPE_PARAMS_(CaseName) - -# define TYPED_TEST(CaseName, TestName) \ - template \ - class GTEST_TEST_CLASS_NAME_(CaseName, TestName) \ - : public CaseName { \ - private: \ - typedef CaseName TestFixture; \ - typedef gtest_TypeParam_ TypeParam; \ - virtual void TestBody(); \ - }; \ - bool gtest_##CaseName##_##TestName##_registered_ GTEST_ATTRIBUTE_UNUSED_ = \ - ::testing::internal::TypeParameterizedTest< \ - CaseName, \ - ::testing::internal::TemplateSel< \ - GTEST_TEST_CLASS_NAME_(CaseName, TestName)>, \ - GTEST_TYPE_PARAMS_(CaseName)>::Register(\ - "", ::testing::internal::CodeLocation(__FILE__, __LINE__), \ - #CaseName, #TestName, 0); \ - template \ - void GTEST_TEST_CLASS_NAME_(CaseName, TestName)::TestBody() - -#endif // GTEST_HAS_TYPED_TEST - -// Implements type-parameterized tests. - -#if GTEST_HAS_TYPED_TEST_P - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Expands to the namespace name that the type-parameterized tests for -// the given type-parameterized test case are defined in. The exact -// name of the namespace is subject to change without notice. -# define GTEST_CASE_NAMESPACE_(TestCaseName) \ - gtest_case_##TestCaseName##_ - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Expands to the name of the variable used to remember the names of -// the defined tests in the given test case. -# define GTEST_TYPED_TEST_CASE_P_STATE_(TestCaseName) \ - gtest_typed_test_case_p_state_##TestCaseName##_ - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE DIRECTLY. -// -// Expands to the name of the variable used to remember the names of -// the registered tests in the given test case. -# define GTEST_REGISTERED_TEST_NAMES_(TestCaseName) \ - gtest_registered_test_names_##TestCaseName##_ - -// The variables defined in the type-parameterized test macros are -// static as typically these macros are used in a .h file that can be -// #included in multiple translation units linked together. -# define TYPED_TEST_CASE_P(CaseName) \ - static ::testing::internal::TypedTestCasePState \ - GTEST_TYPED_TEST_CASE_P_STATE_(CaseName) - -# define TYPED_TEST_P(CaseName, TestName) \ - namespace GTEST_CASE_NAMESPACE_(CaseName) { \ - template \ - class TestName : public CaseName { \ - private: \ - typedef CaseName TestFixture; \ - typedef gtest_TypeParam_ TypeParam; \ - virtual void TestBody(); \ - }; \ - static bool gtest_##TestName##_defined_ GTEST_ATTRIBUTE_UNUSED_ = \ - GTEST_TYPED_TEST_CASE_P_STATE_(CaseName).AddTestName(\ - __FILE__, __LINE__, #CaseName, #TestName); \ - } \ - template \ - void GTEST_CASE_NAMESPACE_(CaseName)::TestName::TestBody() - -# define REGISTER_TYPED_TEST_CASE_P(CaseName, ...) \ - namespace GTEST_CASE_NAMESPACE_(CaseName) { \ - typedef ::testing::internal::Templates<__VA_ARGS__>::type gtest_AllTests_; \ - } \ - static const char* const GTEST_REGISTERED_TEST_NAMES_(CaseName) = \ - GTEST_TYPED_TEST_CASE_P_STATE_(CaseName).VerifyRegisteredTestNames(\ - __FILE__, __LINE__, #__VA_ARGS__) - -// The 'Types' template argument below must have spaces around it -// since some compilers may choke on '>>' when passing a template -// instance (e.g. Types) -# define INSTANTIATE_TYPED_TEST_CASE_P(Prefix, CaseName, Types) \ - bool gtest_##Prefix##_##CaseName GTEST_ATTRIBUTE_UNUSED_ = \ - ::testing::internal::TypeParameterizedTestCase::type>::Register(\ - #Prefix, \ - ::testing::internal::CodeLocation(__FILE__, __LINE__), \ - >EST_TYPED_TEST_CASE_P_STATE_(CaseName), \ - #CaseName, GTEST_REGISTERED_TEST_NAMES_(CaseName)) - -#endif // GTEST_HAS_TYPED_TEST_P - -#endif // GTEST_INCLUDE_GTEST_GTEST_TYPED_TEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest.h deleted file mode 100644 index f846c5bd669..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest.h +++ /dev/null @@ -1,2236 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file defines the public API for Google Test. It should be -// included by any test program that uses Google Test. -// -// IMPORTANT NOTE: Due to limitation of the C++ language, we have to -// leave some internal implementation details in this header file. -// They are clearly marked by comments like this: -// -// // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -// -// Such code is NOT meant to be used by a user directly, and is subject -// to CHANGE WITHOUT NOTICE. Therefore DO NOT DEPEND ON IT in a user -// program! -// -// Acknowledgment: Google Test borrowed the idea of automatic test -// registration from Barthelemy Dagenais' (barthelemy@prologique.com) -// easyUnit framework. - -#ifndef GTEST_INCLUDE_GTEST_GTEST_H_ -#define GTEST_INCLUDE_GTEST_GTEST_H_ - -#include -#include -#include - -#include "gtest/internal/gtest-internal.h" -#include "gtest/internal/gtest-string.h" -#include "gtest/gtest-death-test.h" -#include "gtest/gtest-message.h" -#include "gtest/gtest-param-test.h" -#include "gtest/gtest-printers.h" -#include "gtest/gtest_prod.h" -#include "gtest/gtest-test-part.h" -#include "gtest/gtest-typed-test.h" - -// Depending on the platform, different string classes are available. -// On Linux, in addition to ::std::string, Google also makes use of -// class ::string, which has the same interface as ::std::string, but -// has a different implementation. -// -// You can define GTEST_HAS_GLOBAL_STRING to 1 to indicate that -// ::string is available AND is a distinct type to ::std::string, or -// define it to 0 to indicate otherwise. -// -// If ::std::string and ::string are the same class on your platform -// due to aliasing, you should define GTEST_HAS_GLOBAL_STRING to 0. -// -// If you do not define GTEST_HAS_GLOBAL_STRING, it is defined -// heuristically. - -namespace testing { - -// Declares the flags. - -// This flag temporary enables the disabled tests. -GTEST_DECLARE_bool_(also_run_disabled_tests); - -// This flag brings the debugger on an assertion failure. -GTEST_DECLARE_bool_(break_on_failure); - -// This flag controls whether Google Test catches all test-thrown exceptions -// and logs them as failures. -GTEST_DECLARE_bool_(catch_exceptions); - -// This flag enables using colors in terminal output. Available values are -// "yes" to enable colors, "no" (disable colors), or "auto" (the default) -// to let Google Test decide. -GTEST_DECLARE_string_(color); - -// This flag sets up the filter to select by name using a glob pattern -// the tests to run. If the filter is not given all tests are executed. -GTEST_DECLARE_string_(filter); - -// This flag causes the Google Test to list tests. None of the tests listed -// are actually run if the flag is provided. -GTEST_DECLARE_bool_(list_tests); - -// This flag controls whether Google Test emits a detailed XML report to a file -// in addition to its normal textual output. -GTEST_DECLARE_string_(output); - -// This flags control whether Google Test prints the elapsed time for each -// test. -GTEST_DECLARE_bool_(print_time); - -// This flag specifies the random number seed. -GTEST_DECLARE_int32_(random_seed); - -// This flag sets how many times the tests are repeated. The default value -// is 1. If the value is -1 the tests are repeating forever. -GTEST_DECLARE_int32_(repeat); - -// This flag controls whether Google Test includes Google Test internal -// stack frames in failure stack traces. -GTEST_DECLARE_bool_(show_internal_stack_frames); - -// When this flag is specified, tests' order is randomized on every iteration. -GTEST_DECLARE_bool_(shuffle); - -// This flag specifies the maximum number of stack frames to be -// printed in a failure message. -GTEST_DECLARE_int32_(stack_trace_depth); - -// When this flag is specified, a failed assertion will throw an -// exception if exceptions are enabled, or exit the program with a -// non-zero code otherwise. -GTEST_DECLARE_bool_(throw_on_failure); - -// When this flag is set with a "host:port" string, on supported -// platforms test results are streamed to the specified port on -// the specified host machine. -GTEST_DECLARE_string_(stream_result_to); - -// The upper limit for valid stack trace depths. -const int kMaxStackTraceDepth = 100; - -namespace internal { - -class AssertHelper; -class DefaultGlobalTestPartResultReporter; -class ExecDeathTest; -class NoExecDeathTest; -class FinalSuccessChecker; -class GTestFlagSaver; -class StreamingListenerTest; -class TestResultAccessor; -class TestEventListenersAccessor; -class TestEventRepeater; -class UnitTestRecordPropertyTestHelper; -class WindowsDeathTest; -class UnitTestImpl* GetUnitTestImpl(); -void ReportFailureInUnknownLocation(TestPartResult::Type result_type, - const std::string& message); - -} // namespace internal - -// The friend relationship of some of these classes is cyclic. -// If we don't forward declare them the compiler might confuse the classes -// in friendship clauses with same named classes on the scope. -class Test; -class TestCase; -class TestInfo; -class UnitTest; - -// A class for indicating whether an assertion was successful. When -// the assertion wasn't successful, the AssertionResult object -// remembers a non-empty message that describes how it failed. -// -// To create an instance of this class, use one of the factory functions -// (AssertionSuccess() and AssertionFailure()). -// -// This class is useful for two purposes: -// 1. Defining predicate functions to be used with Boolean test assertions -// EXPECT_TRUE/EXPECT_FALSE and their ASSERT_ counterparts -// 2. Defining predicate-format functions to be -// used with predicate assertions (ASSERT_PRED_FORMAT*, etc). -// -// For example, if you define IsEven predicate: -// -// testing::AssertionResult IsEven(int n) { -// if ((n % 2) == 0) -// return testing::AssertionSuccess(); -// else -// return testing::AssertionFailure() << n << " is odd"; -// } -// -// Then the failed expectation EXPECT_TRUE(IsEven(Fib(5))) -// will print the message -// -// Value of: IsEven(Fib(5)) -// Actual: false (5 is odd) -// Expected: true -// -// instead of a more opaque -// -// Value of: IsEven(Fib(5)) -// Actual: false -// Expected: true -// -// in case IsEven is a simple Boolean predicate. -// -// If you expect your predicate to be reused and want to support informative -// messages in EXPECT_FALSE and ASSERT_FALSE (negative assertions show up -// about half as often as positive ones in our tests), supply messages for -// both success and failure cases: -// -// testing::AssertionResult IsEven(int n) { -// if ((n % 2) == 0) -// return testing::AssertionSuccess() << n << " is even"; -// else -// return testing::AssertionFailure() << n << " is odd"; -// } -// -// Then a statement EXPECT_FALSE(IsEven(Fib(6))) will print -// -// Value of: IsEven(Fib(6)) -// Actual: true (8 is even) -// Expected: false -// -// NB: Predicates that support negative Boolean assertions have reduced -// performance in positive ones so be careful not to use them in tests -// that have lots (tens of thousands) of positive Boolean assertions. -// -// To use this class with EXPECT_PRED_FORMAT assertions such as: -// -// // Verifies that Foo() returns an even number. -// EXPECT_PRED_FORMAT1(IsEven, Foo()); -// -// you need to define: -// -// testing::AssertionResult IsEven(const char* expr, int n) { -// if ((n % 2) == 0) -// return testing::AssertionSuccess(); -// else -// return testing::AssertionFailure() -// << "Expected: " << expr << " is even\n Actual: it's " << n; -// } -// -// If Foo() returns 5, you will see the following message: -// -// Expected: Foo() is even -// Actual: it's 5 -// -class GTEST_API_ AssertionResult { - public: - // Copy constructor. - // Used in EXPECT_TRUE/FALSE(assertion_result). - AssertionResult(const AssertionResult& other); - - GTEST_DISABLE_MSC_WARNINGS_PUSH_(4800 /* forcing value to bool */) - - // Used in the EXPECT_TRUE/FALSE(bool_expression). - // - // T must be contextually convertible to bool. - // - // The second parameter prevents this overload from being considered if - // the argument is implicitly convertible to AssertionResult. In that case - // we want AssertionResult's copy constructor to be used. - template - explicit AssertionResult( - const T& success, - typename internal::EnableIf< - !internal::ImplicitlyConvertible::value>::type* - /*enabler*/ = NULL) - : success_(success) {} - - GTEST_DISABLE_MSC_WARNINGS_POP_() - - // Assignment operator. - AssertionResult& operator=(AssertionResult other) { - swap(other); - return *this; - } - - // Returns true iff the assertion succeeded. - operator bool() const { return success_; } // NOLINT - - // Returns the assertion's negation. Used with EXPECT/ASSERT_FALSE. - AssertionResult operator!() const; - - // Returns the text streamed into this AssertionResult. Test assertions - // use it when they fail (i.e., the predicate's outcome doesn't match the - // assertion's expectation). When nothing has been streamed into the - // object, returns an empty string. - const char* message() const { - return message_.get() != NULL ? message_->c_str() : ""; - } - // TODO(vladl@google.com): Remove this after making sure no clients use it. - // Deprecated; please use message() instead. - const char* failure_message() const { return message(); } - - // Streams a custom failure message into this object. - template AssertionResult& operator<<(const T& value) { - AppendMessage(Message() << value); - return *this; - } - - // Allows streaming basic output manipulators such as endl or flush into - // this object. - AssertionResult& operator<<( - ::std::ostream& (*basic_manipulator)(::std::ostream& stream)) { - AppendMessage(Message() << basic_manipulator); - return *this; - } - - private: - // Appends the contents of message to message_. - void AppendMessage(const Message& a_message) { - if (message_.get() == NULL) - message_.reset(new ::std::string); - message_->append(a_message.GetString().c_str()); - } - - // Swap the contents of this AssertionResult with other. - void swap(AssertionResult& other); - - // Stores result of the assertion predicate. - bool success_; - // Stores the message describing the condition in case the expectation - // construct is not satisfied with the predicate's outcome. - // Referenced via a pointer to avoid taking too much stack frame space - // with test assertions. - internal::scoped_ptr< ::std::string> message_; -}; - -// Makes a successful assertion result. -GTEST_API_ AssertionResult AssertionSuccess(); - -// Makes a failed assertion result. -GTEST_API_ AssertionResult AssertionFailure(); - -// Makes a failed assertion result with the given failure message. -// Deprecated; use AssertionFailure() << msg. -GTEST_API_ AssertionResult AssertionFailure(const Message& msg); - -// The abstract class that all tests inherit from. -// -// In Google Test, a unit test program contains one or many TestCases, and -// each TestCase contains one or many Tests. -// -// When you define a test using the TEST macro, you don't need to -// explicitly derive from Test - the TEST macro automatically does -// this for you. -// -// The only time you derive from Test is when defining a test fixture -// to be used a TEST_F. For example: -// -// class FooTest : public testing::Test { -// protected: -// void SetUp() override { ... } -// void TearDown() override { ... } -// ... -// }; -// -// TEST_F(FooTest, Bar) { ... } -// TEST_F(FooTest, Baz) { ... } -// -// Test is not copyable. -class GTEST_API_ Test { - public: - friend class TestInfo; - - // Defines types for pointers to functions that set up and tear down - // a test case. - typedef internal::SetUpTestCaseFunc SetUpTestCaseFunc; - typedef internal::TearDownTestCaseFunc TearDownTestCaseFunc; - - // The d'tor is virtual as we intend to inherit from Test. - virtual ~Test(); - - // Sets up the stuff shared by all tests in this test case. - // - // Google Test will call Foo::SetUpTestCase() before running the first - // test in test case Foo. Hence a sub-class can define its own - // SetUpTestCase() method to shadow the one defined in the super - // class. - static void SetUpTestCase() {} - - // Tears down the stuff shared by all tests in this test case. - // - // Google Test will call Foo::TearDownTestCase() after running the last - // test in test case Foo. Hence a sub-class can define its own - // TearDownTestCase() method to shadow the one defined in the super - // class. - static void TearDownTestCase() {} - - // Returns true iff the current test has a fatal failure. - static bool HasFatalFailure(); - - // Returns true iff the current test has a non-fatal failure. - static bool HasNonfatalFailure(); - - // Returns true iff the current test has a (either fatal or - // non-fatal) failure. - static bool HasFailure() { return HasFatalFailure() || HasNonfatalFailure(); } - - // Logs a property for the current test, test case, or for the entire - // invocation of the test program when used outside of the context of a - // test case. Only the last value for a given key is remembered. These - // are public static so they can be called from utility functions that are - // not members of the test fixture. Calls to RecordProperty made during - // lifespan of the test (from the moment its constructor starts to the - // moment its destructor finishes) will be output in XML as attributes of - // the element. Properties recorded from fixture's - // SetUpTestCase or TearDownTestCase are logged as attributes of the - // corresponding element. Calls to RecordProperty made in the - // global context (before or after invocation of RUN_ALL_TESTS and from - // SetUp/TearDown method of Environment objects registered with Google - // Test) will be output as attributes of the element. - static void RecordProperty(const std::string& key, const std::string& value); - static void RecordProperty(const std::string& key, int value); - - protected: - // Creates a Test object. - Test(); - - // Sets up the test fixture. - virtual void SetUp(); - - // Tears down the test fixture. - virtual void TearDown(); - - private: - // Returns true iff the current test has the same fixture class as - // the first test in the current test case. - static bool HasSameFixtureClass(); - - // Runs the test after the test fixture has been set up. - // - // A sub-class must implement this to define the test logic. - // - // DO NOT OVERRIDE THIS FUNCTION DIRECTLY IN A USER PROGRAM. - // Instead, use the TEST or TEST_F macro. - virtual void TestBody() = 0; - - // Sets up, executes, and tears down the test. - void Run(); - - // Deletes self. We deliberately pick an unusual name for this - // internal method to avoid clashing with names used in user TESTs. - void DeleteSelf_() { delete this; } - - const internal::scoped_ptr< GTEST_FLAG_SAVER_ > gtest_flag_saver_; - - // Often a user misspells SetUp() as Setup() and spends a long time - // wondering why it is never called by Google Test. The declaration of - // the following method is solely for catching such an error at - // compile time: - // - // - The return type is deliberately chosen to be not void, so it - // will be a conflict if void Setup() is declared in the user's - // test fixture. - // - // - This method is private, so it will be another compiler error - // if the method is called from the user's test fixture. - // - // DO NOT OVERRIDE THIS FUNCTION. - // - // If you see an error about overriding the following function or - // about it being private, you have mis-spelled SetUp() as Setup(). - struct Setup_should_be_spelled_SetUp {}; - virtual Setup_should_be_spelled_SetUp* Setup() { return NULL; } - - // We disallow copying Tests. - GTEST_DISALLOW_COPY_AND_ASSIGN_(Test); -}; - -typedef internal::TimeInMillis TimeInMillis; - -// A copyable object representing a user specified test property which can be -// output as a key/value string pair. -// -// Don't inherit from TestProperty as its destructor is not virtual. -class TestProperty { - public: - // C'tor. TestProperty does NOT have a default constructor. - // Always use this constructor (with parameters) to create a - // TestProperty object. - TestProperty(const std::string& a_key, const std::string& a_value) : - key_(a_key), value_(a_value) { - } - - // Gets the user supplied key. - const char* key() const { - return key_.c_str(); - } - - // Gets the user supplied value. - const char* value() const { - return value_.c_str(); - } - - // Sets a new value, overriding the one supplied in the constructor. - void SetValue(const std::string& new_value) { - value_ = new_value; - } - - private: - // The key supplied by the user. - std::string key_; - // The value supplied by the user. - std::string value_; -}; - -// The result of a single Test. This includes a list of -// TestPartResults, a list of TestProperties, a count of how many -// death tests there are in the Test, and how much time it took to run -// the Test. -// -// TestResult is not copyable. -class GTEST_API_ TestResult { - public: - // Creates an empty TestResult. - TestResult(); - - // D'tor. Do not inherit from TestResult. - ~TestResult(); - - // Gets the number of all test parts. This is the sum of the number - // of successful test parts and the number of failed test parts. - int total_part_count() const; - - // Returns the number of the test properties. - int test_property_count() const; - - // Returns true iff the test passed (i.e. no test part failed). - bool Passed() const { return !Failed(); } - - // Returns true iff the test failed. - bool Failed() const; - - // Returns true iff the test fatally failed. - bool HasFatalFailure() const; - - // Returns true iff the test has a non-fatal failure. - bool HasNonfatalFailure() const; - - // Returns the elapsed time, in milliseconds. - TimeInMillis elapsed_time() const { return elapsed_time_; } - - // Returns the i-th test part result among all the results. i can range - // from 0 to test_property_count() - 1. If i is not in that range, aborts - // the program. - const TestPartResult& GetTestPartResult(int i) const; - - // Returns the i-th test property. i can range from 0 to - // test_property_count() - 1. If i is not in that range, aborts the - // program. - const TestProperty& GetTestProperty(int i) const; - - private: - friend class TestInfo; - friend class TestCase; - friend class UnitTest; - friend class internal::DefaultGlobalTestPartResultReporter; - friend class internal::ExecDeathTest; - friend class internal::TestResultAccessor; - friend class internal::UnitTestImpl; - friend class internal::WindowsDeathTest; - - // Gets the vector of TestPartResults. - const std::vector& test_part_results() const { - return test_part_results_; - } - - // Gets the vector of TestProperties. - const std::vector& test_properties() const { - return test_properties_; - } - - // Sets the elapsed time. - void set_elapsed_time(TimeInMillis elapsed) { elapsed_time_ = elapsed; } - - // Adds a test property to the list. The property is validated and may add - // a non-fatal failure if invalid (e.g., if it conflicts with reserved - // key names). If a property is already recorded for the same key, the - // value will be updated, rather than storing multiple values for the same - // key. xml_element specifies the element for which the property is being - // recorded and is used for validation. - void RecordProperty(const std::string& xml_element, - const TestProperty& test_property); - - // Adds a failure if the key is a reserved attribute of Google Test - // testcase tags. Returns true if the property is valid. - // TODO(russr): Validate attribute names are legal and human readable. - static bool ValidateTestProperty(const std::string& xml_element, - const TestProperty& test_property); - - // Adds a test part result to the list. - void AddTestPartResult(const TestPartResult& test_part_result); - - // Returns the death test count. - int death_test_count() const { return death_test_count_; } - - // Increments the death test count, returning the new count. - int increment_death_test_count() { return ++death_test_count_; } - - // Clears the test part results. - void ClearTestPartResults(); - - // Clears the object. - void Clear(); - - // Protects mutable state of the property vector and of owned - // properties, whose values may be updated. - internal::Mutex test_properites_mutex_; - - // The vector of TestPartResults - std::vector test_part_results_; - // The vector of TestProperties - std::vector test_properties_; - // Running count of death tests. - int death_test_count_; - // The elapsed time, in milliseconds. - TimeInMillis elapsed_time_; - - // We disallow copying TestResult. - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestResult); -}; // class TestResult - -// A TestInfo object stores the following information about a test: -// -// Test case name -// Test name -// Whether the test should be run -// A function pointer that creates the test object when invoked -// Test result -// -// The constructor of TestInfo registers itself with the UnitTest -// singleton such that the RUN_ALL_TESTS() macro knows which tests to -// run. -class GTEST_API_ TestInfo { - public: - // Destructs a TestInfo object. This function is not virtual, so - // don't inherit from TestInfo. - ~TestInfo(); - - // Returns the test case name. - const char* test_case_name() const { return test_case_name_.c_str(); } - - // Returns the test name. - const char* name() const { return name_.c_str(); } - - // Returns the name of the parameter type, or NULL if this is not a typed - // or a type-parameterized test. - const char* type_param() const { - if (type_param_.get() != NULL) - return type_param_->c_str(); - return NULL; - } - - // Returns the text representation of the value parameter, or NULL if this - // is not a value-parameterized test. - const char* value_param() const { - if (value_param_.get() != NULL) - return value_param_->c_str(); - return NULL; - } - - // Returns the file name where this test is defined. - const char* file() const { return location_.file.c_str(); } - - // Returns the line where this test is defined. - int line() const { return location_.line; } - - // Returns true if this test should run, that is if the test is not - // disabled (or it is disabled but the also_run_disabled_tests flag has - // been specified) and its full name matches the user-specified filter. - // - // Google Test allows the user to filter the tests by their full names. - // The full name of a test Bar in test case Foo is defined as - // "Foo.Bar". Only the tests that match the filter will run. - // - // A filter is a colon-separated list of glob (not regex) patterns, - // optionally followed by a '-' and a colon-separated list of - // negative patterns (tests to exclude). A test is run if it - // matches one of the positive patterns and does not match any of - // the negative patterns. - // - // For example, *A*:Foo.* is a filter that matches any string that - // contains the character 'A' or starts with "Foo.". - bool should_run() const { return should_run_; } - - // Returns true iff this test will appear in the XML report. - bool is_reportable() const { - // For now, the XML report includes all tests matching the filter. - // In the future, we may trim tests that are excluded because of - // sharding. - return matches_filter_; - } - - // Returns the result of the test. - const TestResult* result() const { return &result_; } - - private: -#if GTEST_HAS_DEATH_TEST - friend class internal::DefaultDeathTestFactory; -#endif // GTEST_HAS_DEATH_TEST - friend class Test; - friend class TestCase; - friend class internal::UnitTestImpl; - friend class internal::StreamingListenerTest; - friend TestInfo* internal::MakeAndRegisterTestInfo( - const char* test_case_name, - const char* name, - const char* type_param, - const char* value_param, - internal::CodeLocation code_location, - internal::TypeId fixture_class_id, - Test::SetUpTestCaseFunc set_up_tc, - Test::TearDownTestCaseFunc tear_down_tc, - internal::TestFactoryBase* factory); - - // Constructs a TestInfo object. The newly constructed instance assumes - // ownership of the factory object. - TestInfo(const std::string& test_case_name, - const std::string& name, - const char* a_type_param, // NULL if not a type-parameterized test - const char* a_value_param, // NULL if not a value-parameterized test - internal::CodeLocation a_code_location, - internal::TypeId fixture_class_id, - internal::TestFactoryBase* factory); - - // Increments the number of death tests encountered in this test so - // far. - int increment_death_test_count() { - return result_.increment_death_test_count(); - } - - // Creates the test object, runs it, records its result, and then - // deletes it. - void Run(); - - static void ClearTestResult(TestInfo* test_info) { - test_info->result_.Clear(); - } - - // These fields are immutable properties of the test. - const std::string test_case_name_; // Test case name - const std::string name_; // Test name - // Name of the parameter type, or NULL if this is not a typed or a - // type-parameterized test. - const internal::scoped_ptr type_param_; - // Text representation of the value parameter, or NULL if this is not a - // value-parameterized test. - const internal::scoped_ptr value_param_; - internal::CodeLocation location_; - const internal::TypeId fixture_class_id_; // ID of the test fixture class - bool should_run_; // True iff this test should run - bool is_disabled_; // True iff this test is disabled - bool matches_filter_; // True if this test matches the - // user-specified filter. - internal::TestFactoryBase* const factory_; // The factory that creates - // the test object - - // This field is mutable and needs to be reset before running the - // test for the second time. - TestResult result_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestInfo); -}; - -// A test case, which consists of a vector of TestInfos. -// -// TestCase is not copyable. -class GTEST_API_ TestCase { - public: - // Creates a TestCase with the given name. - // - // TestCase does NOT have a default constructor. Always use this - // constructor to create a TestCase object. - // - // Arguments: - // - // name: name of the test case - // a_type_param: the name of the test's type parameter, or NULL if - // this is not a type-parameterized test. - // set_up_tc: pointer to the function that sets up the test case - // tear_down_tc: pointer to the function that tears down the test case - TestCase(const char* name, const char* a_type_param, - Test::SetUpTestCaseFunc set_up_tc, - Test::TearDownTestCaseFunc tear_down_tc); - - // Destructor of TestCase. - virtual ~TestCase(); - - // Gets the name of the TestCase. - const char* name() const { return name_.c_str(); } - - // Returns the name of the parameter type, or NULL if this is not a - // type-parameterized test case. - const char* type_param() const { - if (type_param_.get() != NULL) - return type_param_->c_str(); - return NULL; - } - - // Returns true if any test in this test case should run. - bool should_run() const { return should_run_; } - - // Gets the number of successful tests in this test case. - int successful_test_count() const; - - // Gets the number of failed tests in this test case. - int failed_test_count() const; - - // Gets the number of disabled tests that will be reported in the XML report. - int reportable_disabled_test_count() const; - - // Gets the number of disabled tests in this test case. - int disabled_test_count() const; - - // Gets the number of tests to be printed in the XML report. - int reportable_test_count() const; - - // Get the number of tests in this test case that should run. - int test_to_run_count() const; - - // Gets the number of all tests in this test case. - int total_test_count() const; - - // Returns true iff the test case passed. - bool Passed() const { return !Failed(); } - - // Returns true iff the test case failed. - bool Failed() const { return failed_test_count() > 0; } - - // Returns the elapsed time, in milliseconds. - TimeInMillis elapsed_time() const { return elapsed_time_; } - - // Returns the i-th test among all the tests. i can range from 0 to - // total_test_count() - 1. If i is not in that range, returns NULL. - const TestInfo* GetTestInfo(int i) const; - - // Returns the TestResult that holds test properties recorded during - // execution of SetUpTestCase and TearDownTestCase. - const TestResult& ad_hoc_test_result() const { return ad_hoc_test_result_; } - - private: - friend class Test; - friend class internal::UnitTestImpl; - - // Gets the (mutable) vector of TestInfos in this TestCase. - std::vector& test_info_list() { return test_info_list_; } - - // Gets the (immutable) vector of TestInfos in this TestCase. - const std::vector& test_info_list() const { - return test_info_list_; - } - - // Returns the i-th test among all the tests. i can range from 0 to - // total_test_count() - 1. If i is not in that range, returns NULL. - TestInfo* GetMutableTestInfo(int i); - - // Sets the should_run member. - void set_should_run(bool should) { should_run_ = should; } - - // Adds a TestInfo to this test case. Will delete the TestInfo upon - // destruction of the TestCase object. - void AddTestInfo(TestInfo * test_info); - - // Clears the results of all tests in this test case. - void ClearResult(); - - // Clears the results of all tests in the given test case. - static void ClearTestCaseResult(TestCase* test_case) { - test_case->ClearResult(); - } - - // Runs every test in this TestCase. - void Run(); - - // Runs SetUpTestCase() for this TestCase. This wrapper is needed - // for catching exceptions thrown from SetUpTestCase(). - void RunSetUpTestCase() { (*set_up_tc_)(); } - - // Runs TearDownTestCase() for this TestCase. This wrapper is - // needed for catching exceptions thrown from TearDownTestCase(). - void RunTearDownTestCase() { (*tear_down_tc_)(); } - - // Returns true iff test passed. - static bool TestPassed(const TestInfo* test_info) { - return test_info->should_run() && test_info->result()->Passed(); - } - - // Returns true iff test failed. - static bool TestFailed(const TestInfo* test_info) { - return test_info->should_run() && test_info->result()->Failed(); - } - - // Returns true iff the test is disabled and will be reported in the XML - // report. - static bool TestReportableDisabled(const TestInfo* test_info) { - return test_info->is_reportable() && test_info->is_disabled_; - } - - // Returns true iff test is disabled. - static bool TestDisabled(const TestInfo* test_info) { - return test_info->is_disabled_; - } - - // Returns true iff this test will appear in the XML report. - static bool TestReportable(const TestInfo* test_info) { - return test_info->is_reportable(); - } - - // Returns true if the given test should run. - static bool ShouldRunTest(const TestInfo* test_info) { - return test_info->should_run(); - } - - // Shuffles the tests in this test case. - void ShuffleTests(internal::Random* random); - - // Restores the test order to before the first shuffle. - void UnshuffleTests(); - - // Name of the test case. - std::string name_; - // Name of the parameter type, or NULL if this is not a typed or a - // type-parameterized test. - const internal::scoped_ptr type_param_; - // The vector of TestInfos in their original order. It owns the - // elements in the vector. - std::vector test_info_list_; - // Provides a level of indirection for the test list to allow easy - // shuffling and restoring the test order. The i-th element in this - // vector is the index of the i-th test in the shuffled test list. - std::vector test_indices_; - // Pointer to the function that sets up the test case. - Test::SetUpTestCaseFunc set_up_tc_; - // Pointer to the function that tears down the test case. - Test::TearDownTestCaseFunc tear_down_tc_; - // True iff any test in this test case should run. - bool should_run_; - // Elapsed time, in milliseconds. - TimeInMillis elapsed_time_; - // Holds test properties recorded during execution of SetUpTestCase and - // TearDownTestCase. - TestResult ad_hoc_test_result_; - - // We disallow copying TestCases. - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestCase); -}; - -// An Environment object is capable of setting up and tearing down an -// environment. You should subclass this to define your own -// environment(s). -// -// An Environment object does the set-up and tear-down in virtual -// methods SetUp() and TearDown() instead of the constructor and the -// destructor, as: -// -// 1. You cannot safely throw from a destructor. This is a problem -// as in some cases Google Test is used where exceptions are enabled, and -// we may want to implement ASSERT_* using exceptions where they are -// available. -// 2. You cannot use ASSERT_* directly in a constructor or -// destructor. -class Environment { - public: - // The d'tor is virtual as we need to subclass Environment. - virtual ~Environment() {} - - // Override this to define how to set up the environment. - virtual void SetUp() {} - - // Override this to define how to tear down the environment. - virtual void TearDown() {} - private: - // If you see an error about overriding the following function or - // about it being private, you have mis-spelled SetUp() as Setup(). - struct Setup_should_be_spelled_SetUp {}; - virtual Setup_should_be_spelled_SetUp* Setup() { return NULL; } -}; - -// The interface for tracing execution of tests. The methods are organized in -// the order the corresponding events are fired. -class TestEventListener { - public: - virtual ~TestEventListener() {} - - // Fired before any test activity starts. - virtual void OnTestProgramStart(const UnitTest& unit_test) = 0; - - // Fired before each iteration of tests starts. There may be more than - // one iteration if GTEST_FLAG(repeat) is set. iteration is the iteration - // index, starting from 0. - virtual void OnTestIterationStart(const UnitTest& unit_test, - int iteration) = 0; - - // Fired before environment set-up for each iteration of tests starts. - virtual void OnEnvironmentsSetUpStart(const UnitTest& unit_test) = 0; - - // Fired after environment set-up for each iteration of tests ends. - virtual void OnEnvironmentsSetUpEnd(const UnitTest& unit_test) = 0; - - // Fired before the test case starts. - virtual void OnTestCaseStart(const TestCase& test_case) = 0; - - // Fired before the test starts. - virtual void OnTestStart(const TestInfo& test_info) = 0; - - // Fired after a failed assertion or a SUCCEED() invocation. - virtual void OnTestPartResult(const TestPartResult& test_part_result) = 0; - - // Fired after the test ends. - virtual void OnTestEnd(const TestInfo& test_info) = 0; - - // Fired after the test case ends. - virtual void OnTestCaseEnd(const TestCase& test_case) = 0; - - // Fired before environment tear-down for each iteration of tests starts. - virtual void OnEnvironmentsTearDownStart(const UnitTest& unit_test) = 0; - - // Fired after environment tear-down for each iteration of tests ends. - virtual void OnEnvironmentsTearDownEnd(const UnitTest& unit_test) = 0; - - // Fired after each iteration of tests finishes. - virtual void OnTestIterationEnd(const UnitTest& unit_test, - int iteration) = 0; - - // Fired after all test activities have ended. - virtual void OnTestProgramEnd(const UnitTest& unit_test) = 0; -}; - -// The convenience class for users who need to override just one or two -// methods and are not concerned that a possible change to a signature of -// the methods they override will not be caught during the build. For -// comments about each method please see the definition of TestEventListener -// above. -class EmptyTestEventListener : public TestEventListener { - public: - virtual void OnTestProgramStart(const UnitTest& /*unit_test*/) {} - virtual void OnTestIterationStart(const UnitTest& /*unit_test*/, - int /*iteration*/) {} - virtual void OnEnvironmentsSetUpStart(const UnitTest& /*unit_test*/) {} - virtual void OnEnvironmentsSetUpEnd(const UnitTest& /*unit_test*/) {} - virtual void OnTestCaseStart(const TestCase& /*test_case*/) {} - virtual void OnTestStart(const TestInfo& /*test_info*/) {} - virtual void OnTestPartResult(const TestPartResult& /*test_part_result*/) {} - virtual void OnTestEnd(const TestInfo& /*test_info*/) {} - virtual void OnTestCaseEnd(const TestCase& /*test_case*/) {} - virtual void OnEnvironmentsTearDownStart(const UnitTest& /*unit_test*/) {} - virtual void OnEnvironmentsTearDownEnd(const UnitTest& /*unit_test*/) {} - virtual void OnTestIterationEnd(const UnitTest& /*unit_test*/, - int /*iteration*/) {} - virtual void OnTestProgramEnd(const UnitTest& /*unit_test*/) {} -}; - -// TestEventListeners lets users add listeners to track events in Google Test. -class GTEST_API_ TestEventListeners { - public: - TestEventListeners(); - ~TestEventListeners(); - - // Appends an event listener to the end of the list. Google Test assumes - // the ownership of the listener (i.e. it will delete the listener when - // the test program finishes). - void Append(TestEventListener* listener); - - // Removes the given event listener from the list and returns it. It then - // becomes the caller's responsibility to delete the listener. Returns - // NULL if the listener is not found in the list. - TestEventListener* Release(TestEventListener* listener); - - // Returns the standard listener responsible for the default console - // output. Can be removed from the listeners list to shut down default - // console output. Note that removing this object from the listener list - // with Release transfers its ownership to the caller and makes this - // function return NULL the next time. - TestEventListener* default_result_printer() const { - return default_result_printer_; - } - - // Returns the standard listener responsible for the default XML output - // controlled by the --gtest_output=xml flag. Can be removed from the - // listeners list by users who want to shut down the default XML output - // controlled by this flag and substitute it with custom one. Note that - // removing this object from the listener list with Release transfers its - // ownership to the caller and makes this function return NULL the next - // time. - TestEventListener* default_xml_generator() const { - return default_xml_generator_; - } - - private: - friend class TestCase; - friend class TestInfo; - friend class internal::DefaultGlobalTestPartResultReporter; - friend class internal::NoExecDeathTest; - friend class internal::TestEventListenersAccessor; - friend class internal::UnitTestImpl; - - // Returns repeater that broadcasts the TestEventListener events to all - // subscribers. - TestEventListener* repeater(); - - // Sets the default_result_printer attribute to the provided listener. - // The listener is also added to the listener list and previous - // default_result_printer is removed from it and deleted. The listener can - // also be NULL in which case it will not be added to the list. Does - // nothing if the previous and the current listener objects are the same. - void SetDefaultResultPrinter(TestEventListener* listener); - - // Sets the default_xml_generator attribute to the provided listener. The - // listener is also added to the listener list and previous - // default_xml_generator is removed from it and deleted. The listener can - // also be NULL in which case it will not be added to the list. Does - // nothing if the previous and the current listener objects are the same. - void SetDefaultXmlGenerator(TestEventListener* listener); - - // Controls whether events will be forwarded by the repeater to the - // listeners in the list. - bool EventForwardingEnabled() const; - void SuppressEventForwarding(); - - // The actual list of listeners. - internal::TestEventRepeater* repeater_; - // Listener responsible for the standard result output. - TestEventListener* default_result_printer_; - // Listener responsible for the creation of the XML output file. - TestEventListener* default_xml_generator_; - - // We disallow copying TestEventListeners. - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestEventListeners); -}; - -// A UnitTest consists of a vector of TestCases. -// -// This is a singleton class. The only instance of UnitTest is -// created when UnitTest::GetInstance() is first called. This -// instance is never deleted. -// -// UnitTest is not copyable. -// -// This class is thread-safe as long as the methods are called -// according to their specification. -class GTEST_API_ UnitTest { - public: - // Gets the singleton UnitTest object. The first time this method - // is called, a UnitTest object is constructed and returned. - // Consecutive calls will return the same object. - static UnitTest* GetInstance(); - - // Runs all tests in this UnitTest object and prints the result. - // Returns 0 if successful, or 1 otherwise. - // - // This method can only be called from the main thread. - // - // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - int Run() GTEST_MUST_USE_RESULT_; - - // Returns the working directory when the first TEST() or TEST_F() - // was executed. The UnitTest object owns the string. - const char* original_working_dir() const; - - // Returns the TestCase object for the test that's currently running, - // or NULL if no test is running. - const TestCase* current_test_case() const - GTEST_LOCK_EXCLUDED_(mutex_); - - // Returns the TestInfo object for the test that's currently running, - // or NULL if no test is running. - const TestInfo* current_test_info() const - GTEST_LOCK_EXCLUDED_(mutex_); - - // Returns the random seed used at the start of the current test run. - int random_seed() const; - -#if GTEST_HAS_PARAM_TEST - // Returns the ParameterizedTestCaseRegistry object used to keep track of - // value-parameterized tests and instantiate and register them. - // - // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - internal::ParameterizedTestCaseRegistry& parameterized_test_registry() - GTEST_LOCK_EXCLUDED_(mutex_); -#endif // GTEST_HAS_PARAM_TEST - - // Gets the number of successful test cases. - int successful_test_case_count() const; - - // Gets the number of failed test cases. - int failed_test_case_count() const; - - // Gets the number of all test cases. - int total_test_case_count() const; - - // Gets the number of all test cases that contain at least one test - // that should run. - int test_case_to_run_count() const; - - // Gets the number of successful tests. - int successful_test_count() const; - - // Gets the number of failed tests. - int failed_test_count() const; - - // Gets the number of disabled tests that will be reported in the XML report. - int reportable_disabled_test_count() const; - - // Gets the number of disabled tests. - int disabled_test_count() const; - - // Gets the number of tests to be printed in the XML report. - int reportable_test_count() const; - - // Gets the number of all tests. - int total_test_count() const; - - // Gets the number of tests that should run. - int test_to_run_count() const; - - // Gets the time of the test program start, in ms from the start of the - // UNIX epoch. - TimeInMillis start_timestamp() const; - - // Gets the elapsed time, in milliseconds. - TimeInMillis elapsed_time() const; - - // Returns true iff the unit test passed (i.e. all test cases passed). - bool Passed() const; - - // Returns true iff the unit test failed (i.e. some test case failed - // or something outside of all tests failed). - bool Failed() const; - - // Gets the i-th test case among all the test cases. i can range from 0 to - // total_test_case_count() - 1. If i is not in that range, returns NULL. - const TestCase* GetTestCase(int i) const; - - // Returns the TestResult containing information on test failures and - // properties logged outside of individual test cases. - const TestResult& ad_hoc_test_result() const; - - // Returns the list of event listeners that can be used to track events - // inside Google Test. - TestEventListeners& listeners(); - - private: - // Registers and returns a global test environment. When a test - // program is run, all global test environments will be set-up in - // the order they were registered. After all tests in the program - // have finished, all global test environments will be torn-down in - // the *reverse* order they were registered. - // - // The UnitTest object takes ownership of the given environment. - // - // This method can only be called from the main thread. - Environment* AddEnvironment(Environment* env); - - // Adds a TestPartResult to the current TestResult object. All - // Google Test assertion macros (e.g. ASSERT_TRUE, EXPECT_EQ, etc) - // eventually call this to report their results. The user code - // should use the assertion macros instead of calling this directly. - void AddTestPartResult(TestPartResult::Type result_type, - const char* file_name, - int line_number, - const std::string& message, - const std::string& os_stack_trace) - GTEST_LOCK_EXCLUDED_(mutex_); - - // Adds a TestProperty to the current TestResult object when invoked from - // inside a test, to current TestCase's ad_hoc_test_result_ when invoked - // from SetUpTestCase or TearDownTestCase, or to the global property set - // when invoked elsewhere. If the result already contains a property with - // the same key, the value will be updated. - void RecordProperty(const std::string& key, const std::string& value); - - // Gets the i-th test case among all the test cases. i can range from 0 to - // total_test_case_count() - 1. If i is not in that range, returns NULL. - TestCase* GetMutableTestCase(int i); - - // Accessors for the implementation object. - internal::UnitTestImpl* impl() { return impl_; } - const internal::UnitTestImpl* impl() const { return impl_; } - - // These classes and funcions are friends as they need to access private - // members of UnitTest. - friend class Test; - friend class internal::AssertHelper; - friend class internal::ScopedTrace; - friend class internal::StreamingListenerTest; - friend class internal::UnitTestRecordPropertyTestHelper; - friend Environment* AddGlobalTestEnvironment(Environment* env); - friend internal::UnitTestImpl* internal::GetUnitTestImpl(); - friend void internal::ReportFailureInUnknownLocation( - TestPartResult::Type result_type, - const std::string& message); - - // Creates an empty UnitTest. - UnitTest(); - - // D'tor - virtual ~UnitTest(); - - // Pushes a trace defined by SCOPED_TRACE() on to the per-thread - // Google Test trace stack. - void PushGTestTrace(const internal::TraceInfo& trace) - GTEST_LOCK_EXCLUDED_(mutex_); - - // Pops a trace from the per-thread Google Test trace stack. - void PopGTestTrace() - GTEST_LOCK_EXCLUDED_(mutex_); - - // Protects mutable state in *impl_. This is mutable as some const - // methods need to lock it too. - mutable internal::Mutex mutex_; - - // Opaque implementation object. This field is never changed once - // the object is constructed. We don't mark it as const here, as - // doing so will cause a warning in the constructor of UnitTest. - // Mutable state in *impl_ is protected by mutex_. - internal::UnitTestImpl* impl_; - - // We disallow copying UnitTest. - GTEST_DISALLOW_COPY_AND_ASSIGN_(UnitTest); -}; - -// A convenient wrapper for adding an environment for the test -// program. -// -// You should call this before RUN_ALL_TESTS() is called, probably in -// main(). If you use gtest_main, you need to call this before main() -// starts for it to take effect. For example, you can define a global -// variable like this: -// -// testing::Environment* const foo_env = -// testing::AddGlobalTestEnvironment(new FooEnvironment); -// -// However, we strongly recommend you to write your own main() and -// call AddGlobalTestEnvironment() there, as relying on initialization -// of global variables makes the code harder to read and may cause -// problems when you register multiple environments from different -// translation units and the environments have dependencies among them -// (remember that the compiler doesn't guarantee the order in which -// global variables from different translation units are initialized). -inline Environment* AddGlobalTestEnvironment(Environment* env) { - return UnitTest::GetInstance()->AddEnvironment(env); -} - -// Initializes Google Test. This must be called before calling -// RUN_ALL_TESTS(). In particular, it parses a command line for the -// flags that Google Test recognizes. Whenever a Google Test flag is -// seen, it is removed from argv, and *argc is decremented. -// -// No value is returned. Instead, the Google Test flag variables are -// updated. -// -// Calling the function for the second time has no user-visible effect. -GTEST_API_ void InitGoogleTest(int* argc, char** argv); - -// This overloaded version can be used in Windows programs compiled in -// UNICODE mode. -GTEST_API_ void InitGoogleTest(int* argc, wchar_t** argv); - -namespace internal { - -// Separate the error generating code from the code path to reduce the stack -// frame size of CmpHelperEQ. This helps reduce the overhead of some sanitizers -// when calling EXPECT_* in a tight loop. -template -AssertionResult CmpHelperEQFailure(const char* lhs_expression, - const char* rhs_expression, - const T1& lhs, const T2& rhs) { - return EqFailure(lhs_expression, - rhs_expression, - FormatForComparisonFailureMessage(lhs, rhs), - FormatForComparisonFailureMessage(rhs, lhs), - false); -} - -// The helper function for {ASSERT|EXPECT}_EQ. -template -AssertionResult CmpHelperEQ(const char* lhs_expression, - const char* rhs_expression, - const T1& lhs, - const T2& rhs) { -GTEST_DISABLE_MSC_WARNINGS_PUSH_(4389 /* signed/unsigned mismatch */) - if (lhs == rhs) { - return AssertionSuccess(); - } -GTEST_DISABLE_MSC_WARNINGS_POP_() - - return CmpHelperEQFailure(lhs_expression, rhs_expression, lhs, rhs); -} - -// With this overloaded version, we allow anonymous enums to be used -// in {ASSERT|EXPECT}_EQ when compiled with gcc 4, as anonymous enums -// can be implicitly cast to BiggestInt. -GTEST_API_ AssertionResult CmpHelperEQ(const char* lhs_expression, - const char* rhs_expression, - BiggestInt lhs, - BiggestInt rhs); - -// The helper class for {ASSERT|EXPECT}_EQ. The template argument -// lhs_is_null_literal is true iff the first argument to ASSERT_EQ() -// is a null pointer literal. The following default implementation is -// for lhs_is_null_literal being false. -template -class EqHelper { - public: - // This templatized version is for the general case. - template - static AssertionResult Compare(const char* lhs_expression, - const char* rhs_expression, - const T1& lhs, - const T2& rhs) { - return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs); - } - - // With this overloaded version, we allow anonymous enums to be used - // in {ASSERT|EXPECT}_EQ when compiled with gcc 4, as anonymous - // enums can be implicitly cast to BiggestInt. - // - // Even though its body looks the same as the above version, we - // cannot merge the two, as it will make anonymous enums unhappy. - static AssertionResult Compare(const char* lhs_expression, - const char* rhs_expression, - BiggestInt lhs, - BiggestInt rhs) { - return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs); - } -}; - -// This specialization is used when the first argument to ASSERT_EQ() -// is a null pointer literal, like NULL, false, or 0. -template <> -class EqHelper { - public: - // We define two overloaded versions of Compare(). The first - // version will be picked when the second argument to ASSERT_EQ() is - // NOT a pointer, e.g. ASSERT_EQ(0, AnIntFunction()) or - // EXPECT_EQ(false, a_bool). - template - static AssertionResult Compare( - const char* lhs_expression, - const char* rhs_expression, - const T1& lhs, - const T2& rhs, - // The following line prevents this overload from being considered if T2 - // is not a pointer type. We need this because ASSERT_EQ(NULL, my_ptr) - // expands to Compare("", "", NULL, my_ptr), which requires a conversion - // to match the Secret* in the other overload, which would otherwise make - // this template match better. - typename EnableIf::value>::type* = 0) { - return CmpHelperEQ(lhs_expression, rhs_expression, lhs, rhs); - } - - // This version will be picked when the second argument to ASSERT_EQ() is a - // pointer, e.g. ASSERT_EQ(NULL, a_pointer). - template - static AssertionResult Compare( - const char* lhs_expression, - const char* rhs_expression, - // We used to have a second template parameter instead of Secret*. That - // template parameter would deduce to 'long', making this a better match - // than the first overload even without the first overload's EnableIf. - // Unfortunately, gcc with -Wconversion-null warns when "passing NULL to - // non-pointer argument" (even a deduced integral argument), so the old - // implementation caused warnings in user code. - Secret* /* lhs (NULL) */, - T* rhs) { - // We already know that 'lhs' is a null pointer. - return CmpHelperEQ(lhs_expression, rhs_expression, - static_cast(NULL), rhs); - } -}; - -// Separate the error generating code from the code path to reduce the stack -// frame size of CmpHelperOP. This helps reduce the overhead of some sanitizers -// when calling EXPECT_OP in a tight loop. -template -AssertionResult CmpHelperOpFailure(const char* expr1, const char* expr2, - const T1& val1, const T2& val2, - const char* op) { - return AssertionFailure() - << "Expected: (" << expr1 << ") " << op << " (" << expr2 - << "), actual: " << FormatForComparisonFailureMessage(val1, val2) - << " vs " << FormatForComparisonFailureMessage(val2, val1); -} - -// A macro for implementing the helper functions needed to implement -// ASSERT_?? and EXPECT_??. It is here just to avoid copy-and-paste -// of similar code. -// -// For each templatized helper function, we also define an overloaded -// version for BiggestInt in order to reduce code bloat and allow -// anonymous enums to be used with {ASSERT|EXPECT}_?? when compiled -// with gcc 4. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - -#define GTEST_IMPL_CMP_HELPER_(op_name, op)\ -template \ -AssertionResult CmpHelper##op_name(const char* expr1, const char* expr2, \ - const T1& val1, const T2& val2) {\ - if (val1 op val2) {\ - return AssertionSuccess();\ - } else {\ - return CmpHelperOpFailure(expr1, expr2, val1, val2, #op);\ - }\ -}\ -GTEST_API_ AssertionResult CmpHelper##op_name(\ - const char* expr1, const char* expr2, BiggestInt val1, BiggestInt val2) - -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. - -// Implements the helper function for {ASSERT|EXPECT}_NE -GTEST_IMPL_CMP_HELPER_(NE, !=); -// Implements the helper function for {ASSERT|EXPECT}_LE -GTEST_IMPL_CMP_HELPER_(LE, <=); -// Implements the helper function for {ASSERT|EXPECT}_LT -GTEST_IMPL_CMP_HELPER_(LT, <); -// Implements the helper function for {ASSERT|EXPECT}_GE -GTEST_IMPL_CMP_HELPER_(GE, >=); -// Implements the helper function for {ASSERT|EXPECT}_GT -GTEST_IMPL_CMP_HELPER_(GT, >); - -#undef GTEST_IMPL_CMP_HELPER_ - -// The helper function for {ASSERT|EXPECT}_STREQ. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTREQ(const char* s1_expression, - const char* s2_expression, - const char* s1, - const char* s2); - -// The helper function for {ASSERT|EXPECT}_STRCASEEQ. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTRCASEEQ(const char* s1_expression, - const char* s2_expression, - const char* s1, - const char* s2); - -// The helper function for {ASSERT|EXPECT}_STRNE. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTRNE(const char* s1_expression, - const char* s2_expression, - const char* s1, - const char* s2); - -// The helper function for {ASSERT|EXPECT}_STRCASENE. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTRCASENE(const char* s1_expression, - const char* s2_expression, - const char* s1, - const char* s2); - - -// Helper function for *_STREQ on wide strings. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTREQ(const char* s1_expression, - const char* s2_expression, - const wchar_t* s1, - const wchar_t* s2); - -// Helper function for *_STRNE on wide strings. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult CmpHelperSTRNE(const char* s1_expression, - const char* s2_expression, - const wchar_t* s1, - const wchar_t* s2); - -} // namespace internal - -// IsSubstring() and IsNotSubstring() are intended to be used as the -// first argument to {EXPECT,ASSERT}_PRED_FORMAT2(), not by -// themselves. They check whether needle is a substring of haystack -// (NULL is considered a substring of itself only), and return an -// appropriate error message when they fail. -// -// The {needle,haystack}_expr arguments are the stringified -// expressions that generated the two real arguments. -GTEST_API_ AssertionResult IsSubstring( - const char* needle_expr, const char* haystack_expr, - const char* needle, const char* haystack); -GTEST_API_ AssertionResult IsSubstring( - const char* needle_expr, const char* haystack_expr, - const wchar_t* needle, const wchar_t* haystack); -GTEST_API_ AssertionResult IsNotSubstring( - const char* needle_expr, const char* haystack_expr, - const char* needle, const char* haystack); -GTEST_API_ AssertionResult IsNotSubstring( - const char* needle_expr, const char* haystack_expr, - const wchar_t* needle, const wchar_t* haystack); -GTEST_API_ AssertionResult IsSubstring( - const char* needle_expr, const char* haystack_expr, - const ::std::string& needle, const ::std::string& haystack); -GTEST_API_ AssertionResult IsNotSubstring( - const char* needle_expr, const char* haystack_expr, - const ::std::string& needle, const ::std::string& haystack); - -#if GTEST_HAS_STD_WSTRING -GTEST_API_ AssertionResult IsSubstring( - const char* needle_expr, const char* haystack_expr, - const ::std::wstring& needle, const ::std::wstring& haystack); -GTEST_API_ AssertionResult IsNotSubstring( - const char* needle_expr, const char* haystack_expr, - const ::std::wstring& needle, const ::std::wstring& haystack); -#endif // GTEST_HAS_STD_WSTRING - -namespace internal { - -// Helper template function for comparing floating-points. -// -// Template parameter: -// -// RawType: the raw floating-point type (either float or double) -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -template -AssertionResult CmpHelperFloatingPointEQ(const char* lhs_expression, - const char* rhs_expression, - RawType lhs_value, - RawType rhs_value) { - const FloatingPoint lhs(lhs_value), rhs(rhs_value); - - if (lhs.AlmostEquals(rhs)) { - return AssertionSuccess(); - } - - ::std::stringstream lhs_ss; - lhs_ss << std::setprecision(std::numeric_limits::digits10 + 2) - << lhs_value; - - ::std::stringstream rhs_ss; - rhs_ss << std::setprecision(std::numeric_limits::digits10 + 2) - << rhs_value; - - return EqFailure(lhs_expression, - rhs_expression, - StringStreamToString(&lhs_ss), - StringStreamToString(&rhs_ss), - false); -} - -// Helper function for implementing ASSERT_NEAR. -// -// INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. -GTEST_API_ AssertionResult DoubleNearPredFormat(const char* expr1, - const char* expr2, - const char* abs_error_expr, - double val1, - double val2, - double abs_error); - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// A class that enables one to stream messages to assertion macros -class GTEST_API_ AssertHelper { - public: - // Constructor. - AssertHelper(TestPartResult::Type type, - const char* file, - int line, - const char* message); - ~AssertHelper(); - - // Message assignment is a semantic trick to enable assertion - // streaming; see the GTEST_MESSAGE_ macro below. - void operator=(const Message& message) const; - - private: - // We put our data in a struct so that the size of the AssertHelper class can - // be as small as possible. This is important because gcc is incapable of - // re-using stack space even for temporary variables, so every EXPECT_EQ - // reserves stack space for another AssertHelper. - struct AssertHelperData { - AssertHelperData(TestPartResult::Type t, - const char* srcfile, - int line_num, - const char* msg) - : type(t), file(srcfile), line(line_num), message(msg) { } - - TestPartResult::Type const type; - const char* const file; - int const line; - std::string const message; - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(AssertHelperData); - }; - - AssertHelperData* const data_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(AssertHelper); -}; - -} // namespace internal - -#if GTEST_HAS_PARAM_TEST -// The pure interface class that all value-parameterized tests inherit from. -// A value-parameterized class must inherit from both ::testing::Test and -// ::testing::WithParamInterface. In most cases that just means inheriting -// from ::testing::TestWithParam, but more complicated test hierarchies -// may need to inherit from Test and WithParamInterface at different levels. -// -// This interface has support for accessing the test parameter value via -// the GetParam() method. -// -// Use it with one of the parameter generator defining functions, like Range(), -// Values(), ValuesIn(), Bool(), and Combine(). -// -// class FooTest : public ::testing::TestWithParam { -// protected: -// FooTest() { -// // Can use GetParam() here. -// } -// virtual ~FooTest() { -// // Can use GetParam() here. -// } -// virtual void SetUp() { -// // Can use GetParam() here. -// } -// virtual void TearDown { -// // Can use GetParam() here. -// } -// }; -// TEST_P(FooTest, DoesBar) { -// // Can use GetParam() method here. -// Foo foo; -// ASSERT_TRUE(foo.DoesBar(GetParam())); -// } -// INSTANTIATE_TEST_CASE_P(OneToTenRange, FooTest, ::testing::Range(1, 10)); - -template -class WithParamInterface { - public: - typedef T ParamType; - virtual ~WithParamInterface() {} - - // The current parameter value. Is also available in the test fixture's - // constructor. This member function is non-static, even though it only - // references static data, to reduce the opportunity for incorrect uses - // like writing 'WithParamInterface::GetParam()' for a test that - // uses a fixture whose parameter type is int. - const ParamType& GetParam() const { - GTEST_CHECK_(parameter_ != NULL) - << "GetParam() can only be called inside a value-parameterized test " - << "-- did you intend to write TEST_P instead of TEST_F?"; - return *parameter_; - } - - private: - // Sets parameter value. The caller is responsible for making sure the value - // remains alive and unchanged throughout the current test. - static void SetParam(const ParamType* parameter) { - parameter_ = parameter; - } - - // Static value used for accessing parameter during a test lifetime. - static const ParamType* parameter_; - - // TestClass must be a subclass of WithParamInterface and Test. - template friend class internal::ParameterizedTestFactory; -}; - -template -const T* WithParamInterface::parameter_ = NULL; - -// Most value-parameterized classes can ignore the existence of -// WithParamInterface, and can just inherit from ::testing::TestWithParam. - -template -class TestWithParam : public Test, public WithParamInterface { -}; - -#endif // GTEST_HAS_PARAM_TEST - -// Macros for indicating success/failure in test code. - -// ADD_FAILURE unconditionally adds a failure to the current test. -// SUCCEED generates a success - it doesn't automatically make the -// current test successful, as a test is only successful when it has -// no failure. -// -// EXPECT_* verifies that a certain condition is satisfied. If not, -// it behaves like ADD_FAILURE. In particular: -// -// EXPECT_TRUE verifies that a Boolean condition is true. -// EXPECT_FALSE verifies that a Boolean condition is false. -// -// FAIL and ASSERT_* are similar to ADD_FAILURE and EXPECT_*, except -// that they will also abort the current function on failure. People -// usually want the fail-fast behavior of FAIL and ASSERT_*, but those -// writing data-driven tests often find themselves using ADD_FAILURE -// and EXPECT_* more. - -// Generates a nonfatal failure with a generic message. -#define ADD_FAILURE() GTEST_NONFATAL_FAILURE_("Failed") - -// Generates a nonfatal failure at the given source file location with -// a generic message. -#define ADD_FAILURE_AT(file, line) \ - GTEST_MESSAGE_AT_(file, line, "Failed", \ - ::testing::TestPartResult::kNonFatalFailure) - -// Generates a fatal failure with a generic message. -#define GTEST_FAIL() GTEST_FATAL_FAILURE_("Failed") - -// Define this macro to 1 to omit the definition of FAIL(), which is a -// generic name and clashes with some other libraries. -#if !GTEST_DONT_DEFINE_FAIL -# define FAIL() GTEST_FAIL() -#endif - -// Generates a success with a generic message. -#define GTEST_SUCCEED() GTEST_SUCCESS_("Succeeded") - -// Define this macro to 1 to omit the definition of SUCCEED(), which -// is a generic name and clashes with some other libraries. -#if !GTEST_DONT_DEFINE_SUCCEED -# define SUCCEED() GTEST_SUCCEED() -#endif - -// Macros for testing exceptions. -// -// * {ASSERT|EXPECT}_THROW(statement, expected_exception): -// Tests that the statement throws the expected exception. -// * {ASSERT|EXPECT}_NO_THROW(statement): -// Tests that the statement doesn't throw any exception. -// * {ASSERT|EXPECT}_ANY_THROW(statement): -// Tests that the statement throws an exception. - -#define EXPECT_THROW(statement, expected_exception) \ - GTEST_TEST_THROW_(statement, expected_exception, GTEST_NONFATAL_FAILURE_) -#define EXPECT_NO_THROW(statement) \ - GTEST_TEST_NO_THROW_(statement, GTEST_NONFATAL_FAILURE_) -#define EXPECT_ANY_THROW(statement) \ - GTEST_TEST_ANY_THROW_(statement, GTEST_NONFATAL_FAILURE_) -#define ASSERT_THROW(statement, expected_exception) \ - GTEST_TEST_THROW_(statement, expected_exception, GTEST_FATAL_FAILURE_) -#define ASSERT_NO_THROW(statement) \ - GTEST_TEST_NO_THROW_(statement, GTEST_FATAL_FAILURE_) -#define ASSERT_ANY_THROW(statement) \ - GTEST_TEST_ANY_THROW_(statement, GTEST_FATAL_FAILURE_) - -// Boolean assertions. Condition can be either a Boolean expression or an -// AssertionResult. For more information on how to use AssertionResult with -// these macros see comments on that class. -#define EXPECT_TRUE(condition) \ - GTEST_TEST_BOOLEAN_((condition), #condition, false, true, \ - GTEST_NONFATAL_FAILURE_) -#define EXPECT_FALSE(condition) \ - GTEST_TEST_BOOLEAN_(!(condition), #condition, true, false, \ - GTEST_NONFATAL_FAILURE_) -#define ASSERT_TRUE(condition) \ - GTEST_TEST_BOOLEAN_((condition), #condition, false, true, \ - GTEST_FATAL_FAILURE_) -#define ASSERT_FALSE(condition) \ - GTEST_TEST_BOOLEAN_(!(condition), #condition, true, false, \ - GTEST_FATAL_FAILURE_) - -// Includes the auto-generated header that implements a family of -// generic predicate assertion macros. -#include "gtest/gtest_pred_impl.h" - -// Macros for testing equalities and inequalities. -// -// * {ASSERT|EXPECT}_EQ(v1, v2): Tests that v1 == v2 -// * {ASSERT|EXPECT}_NE(v1, v2): Tests that v1 != v2 -// * {ASSERT|EXPECT}_LT(v1, v2): Tests that v1 < v2 -// * {ASSERT|EXPECT}_LE(v1, v2): Tests that v1 <= v2 -// * {ASSERT|EXPECT}_GT(v1, v2): Tests that v1 > v2 -// * {ASSERT|EXPECT}_GE(v1, v2): Tests that v1 >= v2 -// -// When they are not, Google Test prints both the tested expressions and -// their actual values. The values must be compatible built-in types, -// or you will get a compiler error. By "compatible" we mean that the -// values can be compared by the respective operator. -// -// Note: -// -// 1. It is possible to make a user-defined type work with -// {ASSERT|EXPECT}_??(), but that requires overloading the -// comparison operators and is thus discouraged by the Google C++ -// Usage Guide. Therefore, you are advised to use the -// {ASSERT|EXPECT}_TRUE() macro to assert that two objects are -// equal. -// -// 2. The {ASSERT|EXPECT}_??() macros do pointer comparisons on -// pointers (in particular, C strings). Therefore, if you use it -// with two C strings, you are testing how their locations in memory -// are related, not how their content is related. To compare two C -// strings by content, use {ASSERT|EXPECT}_STR*(). -// -// 3. {ASSERT|EXPECT}_EQ(v1, v2) is preferred to -// {ASSERT|EXPECT}_TRUE(v1 == v2), as the former tells you -// what the actual value is when it fails, and similarly for the -// other comparisons. -// -// 4. Do not depend on the order in which {ASSERT|EXPECT}_??() -// evaluate their arguments, which is undefined. -// -// 5. These macros evaluate their arguments exactly once. -// -// Examples: -// -// EXPECT_NE(5, Foo()); -// EXPECT_EQ(NULL, a_pointer); -// ASSERT_LT(i, array_size); -// ASSERT_GT(records.size(), 0) << "There is no record left."; - -#define EXPECT_EQ(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal:: \ - EqHelper::Compare, \ - val1, val2) -#define EXPECT_NE(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperNE, val1, val2) -#define EXPECT_LE(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperLE, val1, val2) -#define EXPECT_LT(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperLT, val1, val2) -#define EXPECT_GE(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperGE, val1, val2) -#define EXPECT_GT(val1, val2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperGT, val1, val2) - -#define GTEST_ASSERT_EQ(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal:: \ - EqHelper::Compare, \ - val1, val2) -#define GTEST_ASSERT_NE(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperNE, val1, val2) -#define GTEST_ASSERT_LE(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperLE, val1, val2) -#define GTEST_ASSERT_LT(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperLT, val1, val2) -#define GTEST_ASSERT_GE(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperGE, val1, val2) -#define GTEST_ASSERT_GT(val1, val2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperGT, val1, val2) - -// Define macro GTEST_DONT_DEFINE_ASSERT_XY to 1 to omit the definition of -// ASSERT_XY(), which clashes with some users' own code. - -#if !GTEST_DONT_DEFINE_ASSERT_EQ -# define ASSERT_EQ(val1, val2) GTEST_ASSERT_EQ(val1, val2) -#endif - -#if !GTEST_DONT_DEFINE_ASSERT_NE -# define ASSERT_NE(val1, val2) GTEST_ASSERT_NE(val1, val2) -#endif - -#if !GTEST_DONT_DEFINE_ASSERT_LE -# define ASSERT_LE(val1, val2) GTEST_ASSERT_LE(val1, val2) -#endif - -#if !GTEST_DONT_DEFINE_ASSERT_LT -# define ASSERT_LT(val1, val2) GTEST_ASSERT_LT(val1, val2) -#endif - -#if !GTEST_DONT_DEFINE_ASSERT_GE -# define ASSERT_GE(val1, val2) GTEST_ASSERT_GE(val1, val2) -#endif - -#if !GTEST_DONT_DEFINE_ASSERT_GT -# define ASSERT_GT(val1, val2) GTEST_ASSERT_GT(val1, val2) -#endif - -// C-string Comparisons. All tests treat NULL and any non-NULL string -// as different. Two NULLs are equal. -// -// * {ASSERT|EXPECT}_STREQ(s1, s2): Tests that s1 == s2 -// * {ASSERT|EXPECT}_STRNE(s1, s2): Tests that s1 != s2 -// * {ASSERT|EXPECT}_STRCASEEQ(s1, s2): Tests that s1 == s2, ignoring case -// * {ASSERT|EXPECT}_STRCASENE(s1, s2): Tests that s1 != s2, ignoring case -// -// For wide or narrow string objects, you can use the -// {ASSERT|EXPECT}_??() macros. -// -// Don't depend on the order in which the arguments are evaluated, -// which is undefined. -// -// These macros evaluate their arguments exactly once. - -#define EXPECT_STREQ(s1, s2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperSTREQ, s1, s2) -#define EXPECT_STRNE(s1, s2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperSTRNE, s1, s2) -#define EXPECT_STRCASEEQ(s1, s2) \ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperSTRCASEEQ, s1, s2) -#define EXPECT_STRCASENE(s1, s2)\ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperSTRCASENE, s1, s2) - -#define ASSERT_STREQ(s1, s2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperSTREQ, s1, s2) -#define ASSERT_STRNE(s1, s2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperSTRNE, s1, s2) -#define ASSERT_STRCASEEQ(s1, s2) \ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperSTRCASEEQ, s1, s2) -#define ASSERT_STRCASENE(s1, s2)\ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperSTRCASENE, s1, s2) - -// Macros for comparing floating-point numbers. -// -// * {ASSERT|EXPECT}_FLOAT_EQ(val1, val2): -// Tests that two float values are almost equal. -// * {ASSERT|EXPECT}_DOUBLE_EQ(val1, val2): -// Tests that two double values are almost equal. -// * {ASSERT|EXPECT}_NEAR(v1, v2, abs_error): -// Tests that v1 and v2 are within the given distance to each other. -// -// Google Test uses ULP-based comparison to automatically pick a default -// error bound that is appropriate for the operands. See the -// FloatingPoint template class in gtest-internal.h if you are -// interested in the implementation details. - -#define EXPECT_FLOAT_EQ(val1, val2)\ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperFloatingPointEQ, \ - val1, val2) - -#define EXPECT_DOUBLE_EQ(val1, val2)\ - EXPECT_PRED_FORMAT2(::testing::internal::CmpHelperFloatingPointEQ, \ - val1, val2) - -#define ASSERT_FLOAT_EQ(val1, val2)\ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperFloatingPointEQ, \ - val1, val2) - -#define ASSERT_DOUBLE_EQ(val1, val2)\ - ASSERT_PRED_FORMAT2(::testing::internal::CmpHelperFloatingPointEQ, \ - val1, val2) - -#define EXPECT_NEAR(val1, val2, abs_error)\ - EXPECT_PRED_FORMAT3(::testing::internal::DoubleNearPredFormat, \ - val1, val2, abs_error) - -#define ASSERT_NEAR(val1, val2, abs_error)\ - ASSERT_PRED_FORMAT3(::testing::internal::DoubleNearPredFormat, \ - val1, val2, abs_error) - -// These predicate format functions work on floating-point values, and -// can be used in {ASSERT|EXPECT}_PRED_FORMAT2*(), e.g. -// -// EXPECT_PRED_FORMAT2(testing::DoubleLE, Foo(), 5.0); - -// Asserts that val1 is less than, or almost equal to, val2. Fails -// otherwise. In particular, it fails if either val1 or val2 is NaN. -GTEST_API_ AssertionResult FloatLE(const char* expr1, const char* expr2, - float val1, float val2); -GTEST_API_ AssertionResult DoubleLE(const char* expr1, const char* expr2, - double val1, double val2); - - -#if GTEST_OS_WINDOWS - -// Macros that test for HRESULT failure and success, these are only useful -// on Windows, and rely on Windows SDK macros and APIs to compile. -// -// * {ASSERT|EXPECT}_HRESULT_{SUCCEEDED|FAILED}(expr) -// -// When expr unexpectedly fails or succeeds, Google Test prints the -// expected result and the actual result with both a human-readable -// string representation of the error, if available, as well as the -// hex result code. -# define EXPECT_HRESULT_SUCCEEDED(expr) \ - EXPECT_PRED_FORMAT1(::testing::internal::IsHRESULTSuccess, (expr)) - -# define ASSERT_HRESULT_SUCCEEDED(expr) \ - ASSERT_PRED_FORMAT1(::testing::internal::IsHRESULTSuccess, (expr)) - -# define EXPECT_HRESULT_FAILED(expr) \ - EXPECT_PRED_FORMAT1(::testing::internal::IsHRESULTFailure, (expr)) - -# define ASSERT_HRESULT_FAILED(expr) \ - ASSERT_PRED_FORMAT1(::testing::internal::IsHRESULTFailure, (expr)) - -#endif // GTEST_OS_WINDOWS - -// Macros that execute statement and check that it doesn't generate new fatal -// failures in the current thread. -// -// * {ASSERT|EXPECT}_NO_FATAL_FAILURE(statement); -// -// Examples: -// -// EXPECT_NO_FATAL_FAILURE(Process()); -// ASSERT_NO_FATAL_FAILURE(Process()) << "Process() failed"; -// -#define ASSERT_NO_FATAL_FAILURE(statement) \ - GTEST_TEST_NO_FATAL_FAILURE_(statement, GTEST_FATAL_FAILURE_) -#define EXPECT_NO_FATAL_FAILURE(statement) \ - GTEST_TEST_NO_FATAL_FAILURE_(statement, GTEST_NONFATAL_FAILURE_) - -// Causes a trace (including the source file path, the current line -// number, and the given message) to be included in every test failure -// message generated by code in the current scope. The effect is -// undone when the control leaves the current scope. -// -// The message argument can be anything streamable to std::ostream. -// -// In the implementation, we include the current line number as part -// of the dummy variable name, thus allowing multiple SCOPED_TRACE()s -// to appear in the same block - as long as they are on different -// lines. -#define SCOPED_TRACE(message) \ - ::testing::internal::ScopedTrace GTEST_CONCAT_TOKEN_(gtest_trace_, __LINE__)(\ - __FILE__, __LINE__, ::testing::Message() << (message)) - -// Compile-time assertion for type equality. -// StaticAssertTypeEq() compiles iff type1 and type2 are -// the same type. The value it returns is not interesting. -// -// Instead of making StaticAssertTypeEq a class template, we make it a -// function template that invokes a helper class template. This -// prevents a user from misusing StaticAssertTypeEq by -// defining objects of that type. -// -// CAVEAT: -// -// When used inside a method of a class template, -// StaticAssertTypeEq() is effective ONLY IF the method is -// instantiated. For example, given: -// -// template class Foo { -// public: -// void Bar() { testing::StaticAssertTypeEq(); } -// }; -// -// the code: -// -// void Test1() { Foo foo; } -// -// will NOT generate a compiler error, as Foo::Bar() is never -// actually instantiated. Instead, you need: -// -// void Test2() { Foo foo; foo.Bar(); } -// -// to cause a compiler error. -template -bool StaticAssertTypeEq() { - (void)internal::StaticAssertTypeEqHelper(); - return true; -} - -// Defines a test. -// -// The first parameter is the name of the test case, and the second -// parameter is the name of the test within the test case. -// -// The convention is to end the test case name with "Test". For -// example, a test case for the Foo class can be named FooTest. -// -// Test code should appear between braces after an invocation of -// this macro. Example: -// -// TEST(FooTest, InitializesCorrectly) { -// Foo foo; -// EXPECT_TRUE(foo.StatusIsOK()); -// } - -// Note that we call GetTestTypeId() instead of GetTypeId< -// ::testing::Test>() here to get the type ID of testing::Test. This -// is to work around a suspected linker bug when using Google Test as -// a framework on Mac OS X. The bug causes GetTypeId< -// ::testing::Test>() to return different values depending on whether -// the call is from the Google Test framework itself or from user test -// code. GetTestTypeId() is guaranteed to always return the same -// value, as it always calls GetTypeId<>() from the Google Test -// framework. -#define GTEST_TEST(test_case_name, test_name)\ - GTEST_TEST_(test_case_name, test_name, \ - ::testing::Test, ::testing::internal::GetTestTypeId()) - -// Define this macro to 1 to omit the definition of TEST(), which -// is a generic name and clashes with some other libraries. -#if !GTEST_DONT_DEFINE_TEST -# define TEST(test_case_name, test_name) GTEST_TEST(test_case_name, test_name) -#endif - -// Defines a test that uses a test fixture. -// -// The first parameter is the name of the test fixture class, which -// also doubles as the test case name. The second parameter is the -// name of the test within the test case. -// -// A test fixture class must be declared earlier. The user should put -// his test code between braces after using this macro. Example: -// -// class FooTest : public testing::Test { -// protected: -// virtual void SetUp() { b_.AddElement(3); } -// -// Foo a_; -// Foo b_; -// }; -// -// TEST_F(FooTest, InitializesCorrectly) { -// EXPECT_TRUE(a_.StatusIsOK()); -// } -// -// TEST_F(FooTest, ReturnsElementCountCorrectly) { -// EXPECT_EQ(0, a_.size()); -// EXPECT_EQ(1, b_.size()); -// } - -#define TEST_F(test_fixture, test_name)\ - GTEST_TEST_(test_fixture, test_name, test_fixture, \ - ::testing::internal::GetTypeId()) - -} // namespace testing - -// Use this function in main() to run all tests. It returns 0 if all -// tests are successful, or 1 otherwise. -// -// RUN_ALL_TESTS() should be invoked after the command line has been -// parsed by InitGoogleTest(). -// -// This function was formerly a macro; thus, it is in the global -// namespace and has an all-caps name. -int RUN_ALL_TESTS() GTEST_MUST_USE_RESULT_; - -inline int RUN_ALL_TESTS() { - return ::testing::UnitTest::GetInstance()->Run(); -} - -#endif // GTEST_INCLUDE_GTEST_GTEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_pred_impl.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_pred_impl.h deleted file mode 100644 index 30ae712f50e..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_pred_impl.h +++ /dev/null @@ -1,358 +0,0 @@ -// Copyright 2006, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -// This file is AUTOMATICALLY GENERATED on 10/31/2011 by command -// 'gen_gtest_pred_impl.py 5'. DO NOT EDIT BY HAND! -// -// Implements a family of generic predicate assertion macros. - -#ifndef GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ -#define GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ - -// Makes sure this header is not included before gtest.h. -#ifndef GTEST_INCLUDE_GTEST_GTEST_H_ -# error Do not include gtest_pred_impl.h directly. Include gtest.h instead. -#endif // GTEST_INCLUDE_GTEST_GTEST_H_ - -// This header implements a family of generic predicate assertion -// macros: -// -// ASSERT_PRED_FORMAT1(pred_format, v1) -// ASSERT_PRED_FORMAT2(pred_format, v1, v2) -// ... -// -// where pred_format is a function or functor that takes n (in the -// case of ASSERT_PRED_FORMATn) values and their source expression -// text, and returns a testing::AssertionResult. See the definition -// of ASSERT_EQ in gtest.h for an example. -// -// If you don't care about formatting, you can use the more -// restrictive version: -// -// ASSERT_PRED1(pred, v1) -// ASSERT_PRED2(pred, v1, v2) -// ... -// -// where pred is an n-ary function or functor that returns bool, -// and the values v1, v2, ..., must support the << operator for -// streaming to std::ostream. -// -// We also define the EXPECT_* variations. -// -// For now we only support predicates whose arity is at most 5. -// Please email googletestframework@googlegroups.com if you need -// support for higher arities. - -// GTEST_ASSERT_ is the basic statement to which all of the assertions -// in this file reduce. Don't use this in your code. - -#define GTEST_ASSERT_(expression, on_failure) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (const ::testing::AssertionResult gtest_ar = (expression)) \ - ; \ - else \ - on_failure(gtest_ar.failure_message()) - - -// Helper function for implementing {EXPECT|ASSERT}_PRED1. Don't use -// this in your code. -template -AssertionResult AssertPred1Helper(const char* pred_text, - const char* e1, - Pred pred, - const T1& v1) { - if (pred(v1)) return AssertionSuccess(); - - return AssertionFailure() << pred_text << "(" - << e1 << ") evaluates to false, where" - << "\n" << e1 << " evaluates to " << v1; -} - -// Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT1. -// Don't use this in your code. -#define GTEST_PRED_FORMAT1_(pred_format, v1, on_failure)\ - GTEST_ASSERT_(pred_format(#v1, v1), \ - on_failure) - -// Internal macro for implementing {EXPECT|ASSERT}_PRED1. Don't use -// this in your code. -#define GTEST_PRED1_(pred, v1, on_failure)\ - GTEST_ASSERT_(::testing::AssertPred1Helper(#pred, \ - #v1, \ - pred, \ - v1), on_failure) - -// Unary predicate assertion macros. -#define EXPECT_PRED_FORMAT1(pred_format, v1) \ - GTEST_PRED_FORMAT1_(pred_format, v1, GTEST_NONFATAL_FAILURE_) -#define EXPECT_PRED1(pred, v1) \ - GTEST_PRED1_(pred, v1, GTEST_NONFATAL_FAILURE_) -#define ASSERT_PRED_FORMAT1(pred_format, v1) \ - GTEST_PRED_FORMAT1_(pred_format, v1, GTEST_FATAL_FAILURE_) -#define ASSERT_PRED1(pred, v1) \ - GTEST_PRED1_(pred, v1, GTEST_FATAL_FAILURE_) - - - -// Helper function for implementing {EXPECT|ASSERT}_PRED2. Don't use -// this in your code. -template -AssertionResult AssertPred2Helper(const char* pred_text, - const char* e1, - const char* e2, - Pred pred, - const T1& v1, - const T2& v2) { - if (pred(v1, v2)) return AssertionSuccess(); - - return AssertionFailure() << pred_text << "(" - << e1 << ", " - << e2 << ") evaluates to false, where" - << "\n" << e1 << " evaluates to " << v1 - << "\n" << e2 << " evaluates to " << v2; -} - -// Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT2. -// Don't use this in your code. -#define GTEST_PRED_FORMAT2_(pred_format, v1, v2, on_failure)\ - GTEST_ASSERT_(pred_format(#v1, #v2, v1, v2), \ - on_failure) - -// Internal macro for implementing {EXPECT|ASSERT}_PRED2. Don't use -// this in your code. -#define GTEST_PRED2_(pred, v1, v2, on_failure)\ - GTEST_ASSERT_(::testing::AssertPred2Helper(#pred, \ - #v1, \ - #v2, \ - pred, \ - v1, \ - v2), on_failure) - -// Binary predicate assertion macros. -#define EXPECT_PRED_FORMAT2(pred_format, v1, v2) \ - GTEST_PRED_FORMAT2_(pred_format, v1, v2, GTEST_NONFATAL_FAILURE_) -#define EXPECT_PRED2(pred, v1, v2) \ - GTEST_PRED2_(pred, v1, v2, GTEST_NONFATAL_FAILURE_) -#define ASSERT_PRED_FORMAT2(pred_format, v1, v2) \ - GTEST_PRED_FORMAT2_(pred_format, v1, v2, GTEST_FATAL_FAILURE_) -#define ASSERT_PRED2(pred, v1, v2) \ - GTEST_PRED2_(pred, v1, v2, GTEST_FATAL_FAILURE_) - - - -// Helper function for implementing {EXPECT|ASSERT}_PRED3. Don't use -// this in your code. -template -AssertionResult AssertPred3Helper(const char* pred_text, - const char* e1, - const char* e2, - const char* e3, - Pred pred, - const T1& v1, - const T2& v2, - const T3& v3) { - if (pred(v1, v2, v3)) return AssertionSuccess(); - - return AssertionFailure() << pred_text << "(" - << e1 << ", " - << e2 << ", " - << e3 << ") evaluates to false, where" - << "\n" << e1 << " evaluates to " << v1 - << "\n" << e2 << " evaluates to " << v2 - << "\n" << e3 << " evaluates to " << v3; -} - -// Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT3. -// Don't use this in your code. -#define GTEST_PRED_FORMAT3_(pred_format, v1, v2, v3, on_failure)\ - GTEST_ASSERT_(pred_format(#v1, #v2, #v3, v1, v2, v3), \ - on_failure) - -// Internal macro for implementing {EXPECT|ASSERT}_PRED3. Don't use -// this in your code. -#define GTEST_PRED3_(pred, v1, v2, v3, on_failure)\ - GTEST_ASSERT_(::testing::AssertPred3Helper(#pred, \ - #v1, \ - #v2, \ - #v3, \ - pred, \ - v1, \ - v2, \ - v3), on_failure) - -// Ternary predicate assertion macros. -#define EXPECT_PRED_FORMAT3(pred_format, v1, v2, v3) \ - GTEST_PRED_FORMAT3_(pred_format, v1, v2, v3, GTEST_NONFATAL_FAILURE_) -#define EXPECT_PRED3(pred, v1, v2, v3) \ - GTEST_PRED3_(pred, v1, v2, v3, GTEST_NONFATAL_FAILURE_) -#define ASSERT_PRED_FORMAT3(pred_format, v1, v2, v3) \ - GTEST_PRED_FORMAT3_(pred_format, v1, v2, v3, GTEST_FATAL_FAILURE_) -#define ASSERT_PRED3(pred, v1, v2, v3) \ - GTEST_PRED3_(pred, v1, v2, v3, GTEST_FATAL_FAILURE_) - - - -// Helper function for implementing {EXPECT|ASSERT}_PRED4. Don't use -// this in your code. -template -AssertionResult AssertPred4Helper(const char* pred_text, - const char* e1, - const char* e2, - const char* e3, - const char* e4, - Pred pred, - const T1& v1, - const T2& v2, - const T3& v3, - const T4& v4) { - if (pred(v1, v2, v3, v4)) return AssertionSuccess(); - - return AssertionFailure() << pred_text << "(" - << e1 << ", " - << e2 << ", " - << e3 << ", " - << e4 << ") evaluates to false, where" - << "\n" << e1 << " evaluates to " << v1 - << "\n" << e2 << " evaluates to " << v2 - << "\n" << e3 << " evaluates to " << v3 - << "\n" << e4 << " evaluates to " << v4; -} - -// Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT4. -// Don't use this in your code. -#define GTEST_PRED_FORMAT4_(pred_format, v1, v2, v3, v4, on_failure)\ - GTEST_ASSERT_(pred_format(#v1, #v2, #v3, #v4, v1, v2, v3, v4), \ - on_failure) - -// Internal macro for implementing {EXPECT|ASSERT}_PRED4. Don't use -// this in your code. -#define GTEST_PRED4_(pred, v1, v2, v3, v4, on_failure)\ - GTEST_ASSERT_(::testing::AssertPred4Helper(#pred, \ - #v1, \ - #v2, \ - #v3, \ - #v4, \ - pred, \ - v1, \ - v2, \ - v3, \ - v4), on_failure) - -// 4-ary predicate assertion macros. -#define EXPECT_PRED_FORMAT4(pred_format, v1, v2, v3, v4) \ - GTEST_PRED_FORMAT4_(pred_format, v1, v2, v3, v4, GTEST_NONFATAL_FAILURE_) -#define EXPECT_PRED4(pred, v1, v2, v3, v4) \ - GTEST_PRED4_(pred, v1, v2, v3, v4, GTEST_NONFATAL_FAILURE_) -#define ASSERT_PRED_FORMAT4(pred_format, v1, v2, v3, v4) \ - GTEST_PRED_FORMAT4_(pred_format, v1, v2, v3, v4, GTEST_FATAL_FAILURE_) -#define ASSERT_PRED4(pred, v1, v2, v3, v4) \ - GTEST_PRED4_(pred, v1, v2, v3, v4, GTEST_FATAL_FAILURE_) - - - -// Helper function for implementing {EXPECT|ASSERT}_PRED5. Don't use -// this in your code. -template -AssertionResult AssertPred5Helper(const char* pred_text, - const char* e1, - const char* e2, - const char* e3, - const char* e4, - const char* e5, - Pred pred, - const T1& v1, - const T2& v2, - const T3& v3, - const T4& v4, - const T5& v5) { - if (pred(v1, v2, v3, v4, v5)) return AssertionSuccess(); - - return AssertionFailure() << pred_text << "(" - << e1 << ", " - << e2 << ", " - << e3 << ", " - << e4 << ", " - << e5 << ") evaluates to false, where" - << "\n" << e1 << " evaluates to " << v1 - << "\n" << e2 << " evaluates to " << v2 - << "\n" << e3 << " evaluates to " << v3 - << "\n" << e4 << " evaluates to " << v4 - << "\n" << e5 << " evaluates to " << v5; -} - -// Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT5. -// Don't use this in your code. -#define GTEST_PRED_FORMAT5_(pred_format, v1, v2, v3, v4, v5, on_failure)\ - GTEST_ASSERT_(pred_format(#v1, #v2, #v3, #v4, #v5, v1, v2, v3, v4, v5), \ - on_failure) - -// Internal macro for implementing {EXPECT|ASSERT}_PRED5. Don't use -// this in your code. -#define GTEST_PRED5_(pred, v1, v2, v3, v4, v5, on_failure)\ - GTEST_ASSERT_(::testing::AssertPred5Helper(#pred, \ - #v1, \ - #v2, \ - #v3, \ - #v4, \ - #v5, \ - pred, \ - v1, \ - v2, \ - v3, \ - v4, \ - v5), on_failure) - -// 5-ary predicate assertion macros. -#define EXPECT_PRED_FORMAT5(pred_format, v1, v2, v3, v4, v5) \ - GTEST_PRED_FORMAT5_(pred_format, v1, v2, v3, v4, v5, GTEST_NONFATAL_FAILURE_) -#define EXPECT_PRED5(pred, v1, v2, v3, v4, v5) \ - GTEST_PRED5_(pred, v1, v2, v3, v4, v5, GTEST_NONFATAL_FAILURE_) -#define ASSERT_PRED_FORMAT5(pred_format, v1, v2, v3, v4, v5) \ - GTEST_PRED_FORMAT5_(pred_format, v1, v2, v3, v4, v5, GTEST_FATAL_FAILURE_) -#define ASSERT_PRED5(pred, v1, v2, v3, v4, v5) \ - GTEST_PRED5_(pred, v1, v2, v3, v4, v5, GTEST_FATAL_FAILURE_) - - - -#endif // GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_prod.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_prod.h deleted file mode 100644 index da80ddc6c70..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/gtest_prod.h +++ /dev/null @@ -1,58 +0,0 @@ -// Copyright 2006, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) -// -// Google C++ Testing Framework definitions useful in production code. - -#ifndef GTEST_INCLUDE_GTEST_GTEST_PROD_H_ -#define GTEST_INCLUDE_GTEST_GTEST_PROD_H_ - -// When you need to test the private or protected members of a class, -// use the FRIEND_TEST macro to declare your tests as friends of the -// class. For example: -// -// class MyClass { -// private: -// void MyMethod(); -// FRIEND_TEST(MyClassTest, MyMethod); -// }; -// -// class MyClassTest : public testing::Test { -// // ... -// }; -// -// TEST_F(MyClassTest, MyMethod) { -// // Can call MyClass::MyMethod() here. -// } - -#define FRIEND_TEST(test_case_name, test_name)\ -friend class test_case_name##_##test_name##_Test - -#endif // GTEST_INCLUDE_GTEST_GTEST_PROD_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-port.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-port.h deleted file mode 100644 index 7e744bd3bb3..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-port.h +++ /dev/null @@ -1,69 +0,0 @@ -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Injection point for custom user configurations. -// The following macros can be defined: -// -// Flag related macros: -// GTEST_FLAG(flag_name) -// GTEST_USE_OWN_FLAGFILE_FLAG_ - Define to 0 when the system provides its -// own flagfile flag parsing. -// GTEST_DECLARE_bool_(name) -// GTEST_DECLARE_int32_(name) -// GTEST_DECLARE_string_(name) -// GTEST_DEFINE_bool_(name, default_val, doc) -// GTEST_DEFINE_int32_(name, default_val, doc) -// GTEST_DEFINE_string_(name, default_val, doc) -// -// Test filtering: -// GTEST_TEST_FILTER_ENV_VAR_ - The name of an environment variable that -// will be used if --GTEST_FLAG(test_filter) -// is not provided. -// -// Logging: -// GTEST_LOG_(severity) -// GTEST_CHECK_(condition) -// Functions LogToStderr() and FlushInfoLog() have to be provided too. -// -// Threading: -// GTEST_HAS_NOTIFICATION_ - Enabled if Notification is already provided. -// GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ - Enabled if Mutex and ThreadLocal are -// already provided. -// Must also provide GTEST_DECLARE_STATIC_MUTEX_(mutex) and -// GTEST_DEFINE_STATIC_MUTEX_(mutex) -// -// GTEST_EXCLUSIVE_LOCK_REQUIRED_(locks) -// GTEST_LOCK_EXCLUDED_(locks) -// -// ** Custom implementation starts here ** - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-printers.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-printers.h deleted file mode 100644 index 60c1ea050b6..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest-printers.h +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// This file provides an injection point for custom printers in a local -// installation of gTest. -// It will be included from gtest-printers.h and the overrides in this file -// will be visible to everyone. -// See documentation at gtest/gtest-printers.h for details on how to define a -// custom printer. -// -// ** Custom implementation starts here ** - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest.h deleted file mode 100644 index c27412a8981..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/custom/gtest.h +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Injection point for custom user configurations. -// The following macros can be defined: -// -// GTEST_OS_STACK_TRACE_GETTER_ - The name of an implementation of -// OsStackTraceGetterInterface. -// -// ** Custom implementation starts here ** - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-death-test-internal.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-death-test-internal.h deleted file mode 100644 index 2b3a78f5bf8..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-death-test-internal.h +++ /dev/null @@ -1,319 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: wan@google.com (Zhanyong Wan), eefacm@gmail.com (Sean Mcafee) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file defines internal utilities needed for implementing -// death tests. They are subject to change without notice. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_DEATH_TEST_INTERNAL_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_DEATH_TEST_INTERNAL_H_ - -#include "gtest/internal/gtest-internal.h" - -#include - -namespace testing { -namespace internal { - -GTEST_DECLARE_string_(internal_run_death_test); - -// Names of the flags (needed for parsing Google Test flags). -const char kDeathTestStyleFlag[] = "death_test_style"; -const char kDeathTestUseFork[] = "death_test_use_fork"; -const char kInternalRunDeathTestFlag[] = "internal_run_death_test"; - -#if GTEST_HAS_DEATH_TEST - -// DeathTest is a class that hides much of the complexity of the -// GTEST_DEATH_TEST_ macro. It is abstract; its static Create method -// returns a concrete class that depends on the prevailing death test -// style, as defined by the --gtest_death_test_style and/or -// --gtest_internal_run_death_test flags. - -// In describing the results of death tests, these terms are used with -// the corresponding definitions: -// -// exit status: The integer exit information in the format specified -// by wait(2) -// exit code: The integer code passed to exit(3), _exit(2), or -// returned from main() -class GTEST_API_ DeathTest { - public: - // Create returns false if there was an error determining the - // appropriate action to take for the current death test; for example, - // if the gtest_death_test_style flag is set to an invalid value. - // The LastMessage method will return a more detailed message in that - // case. Otherwise, the DeathTest pointer pointed to by the "test" - // argument is set. If the death test should be skipped, the pointer - // is set to NULL; otherwise, it is set to the address of a new concrete - // DeathTest object that controls the execution of the current test. - static bool Create(const char* statement, const RE* regex, - const char* file, int line, DeathTest** test); - DeathTest(); - virtual ~DeathTest() { } - - // A helper class that aborts a death test when it's deleted. - class ReturnSentinel { - public: - explicit ReturnSentinel(DeathTest* test) : test_(test) { } - ~ReturnSentinel() { test_->Abort(TEST_ENCOUNTERED_RETURN_STATEMENT); } - private: - DeathTest* const test_; - GTEST_DISALLOW_COPY_AND_ASSIGN_(ReturnSentinel); - } GTEST_ATTRIBUTE_UNUSED_; - - // An enumeration of possible roles that may be taken when a death - // test is encountered. EXECUTE means that the death test logic should - // be executed immediately. OVERSEE means that the program should prepare - // the appropriate environment for a child process to execute the death - // test, then wait for it to complete. - enum TestRole { OVERSEE_TEST, EXECUTE_TEST }; - - // An enumeration of the three reasons that a test might be aborted. - enum AbortReason { - TEST_ENCOUNTERED_RETURN_STATEMENT, - TEST_THREW_EXCEPTION, - TEST_DID_NOT_DIE - }; - - // Assumes one of the above roles. - virtual TestRole AssumeRole() = 0; - - // Waits for the death test to finish and returns its status. - virtual int Wait() = 0; - - // Returns true if the death test passed; that is, the test process - // exited during the test, its exit status matches a user-supplied - // predicate, and its stderr output matches a user-supplied regular - // expression. - // The user-supplied predicate may be a macro expression rather - // than a function pointer or functor, or else Wait and Passed could - // be combined. - virtual bool Passed(bool exit_status_ok) = 0; - - // Signals that the death test did not die as expected. - virtual void Abort(AbortReason reason) = 0; - - // Returns a human-readable outcome message regarding the outcome of - // the last death test. - static const char* LastMessage(); - - static void set_last_death_test_message(const std::string& message); - - private: - // A string containing a description of the outcome of the last death test. - static std::string last_death_test_message_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(DeathTest); -}; - -// Factory interface for death tests. May be mocked out for testing. -class DeathTestFactory { - public: - virtual ~DeathTestFactory() { } - virtual bool Create(const char* statement, const RE* regex, - const char* file, int line, DeathTest** test) = 0; -}; - -// A concrete DeathTestFactory implementation for normal use. -class DefaultDeathTestFactory : public DeathTestFactory { - public: - virtual bool Create(const char* statement, const RE* regex, - const char* file, int line, DeathTest** test); -}; - -// Returns true if exit_status describes a process that was terminated -// by a signal, or exited normally with a nonzero exit code. -GTEST_API_ bool ExitedUnsuccessfully(int exit_status); - -// Traps C++ exceptions escaping statement and reports them as test -// failures. Note that trapping SEH exceptions is not implemented here. -# if GTEST_HAS_EXCEPTIONS -# define GTEST_EXECUTE_DEATH_TEST_STATEMENT_(statement, death_test) \ - try { \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - } catch (const ::std::exception& gtest_exception) { \ - fprintf(\ - stderr, \ - "\n%s: Caught std::exception-derived exception escaping the " \ - "death test statement. Exception message: %s\n", \ - ::testing::internal::FormatFileLocation(__FILE__, __LINE__).c_str(), \ - gtest_exception.what()); \ - fflush(stderr); \ - death_test->Abort(::testing::internal::DeathTest::TEST_THREW_EXCEPTION); \ - } catch (...) { \ - death_test->Abort(::testing::internal::DeathTest::TEST_THREW_EXCEPTION); \ - } - -# else -# define GTEST_EXECUTE_DEATH_TEST_STATEMENT_(statement, death_test) \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement) - -# endif - -// This macro is for implementing ASSERT_DEATH*, EXPECT_DEATH*, -// ASSERT_EXIT*, and EXPECT_EXIT*. -# define GTEST_DEATH_TEST_(statement, predicate, regex, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - const ::testing::internal::RE& gtest_regex = (regex); \ - ::testing::internal::DeathTest* gtest_dt; \ - if (!::testing::internal::DeathTest::Create(#statement, >est_regex, \ - __FILE__, __LINE__, >est_dt)) { \ - goto GTEST_CONCAT_TOKEN_(gtest_label_, __LINE__); \ - } \ - if (gtest_dt != NULL) { \ - ::testing::internal::scoped_ptr< ::testing::internal::DeathTest> \ - gtest_dt_ptr(gtest_dt); \ - switch (gtest_dt->AssumeRole()) { \ - case ::testing::internal::DeathTest::OVERSEE_TEST: \ - if (!gtest_dt->Passed(predicate(gtest_dt->Wait()))) { \ - goto GTEST_CONCAT_TOKEN_(gtest_label_, __LINE__); \ - } \ - break; \ - case ::testing::internal::DeathTest::EXECUTE_TEST: { \ - ::testing::internal::DeathTest::ReturnSentinel \ - gtest_sentinel(gtest_dt); \ - GTEST_EXECUTE_DEATH_TEST_STATEMENT_(statement, gtest_dt); \ - gtest_dt->Abort(::testing::internal::DeathTest::TEST_DID_NOT_DIE); \ - break; \ - } \ - default: \ - break; \ - } \ - } \ - } else \ - GTEST_CONCAT_TOKEN_(gtest_label_, __LINE__): \ - fail(::testing::internal::DeathTest::LastMessage()) -// The symbol "fail" here expands to something into which a message -// can be streamed. - -// This macro is for implementing ASSERT/EXPECT_DEBUG_DEATH when compiled in -// NDEBUG mode. In this case we need the statements to be executed, the regex is -// ignored, and the macro must accept a streamed message even though the message -// is never printed. -# define GTEST_EXECUTE_STATEMENT_(statement, regex) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - } else \ - ::testing::Message() - -// A class representing the parsed contents of the -// --gtest_internal_run_death_test flag, as it existed when -// RUN_ALL_TESTS was called. -class InternalRunDeathTestFlag { - public: - InternalRunDeathTestFlag(const std::string& a_file, - int a_line, - int an_index, - int a_write_fd) - : file_(a_file), line_(a_line), index_(an_index), - write_fd_(a_write_fd) {} - - ~InternalRunDeathTestFlag() { - if (write_fd_ >= 0) - posix::Close(write_fd_); - } - - const std::string& file() const { return file_; } - int line() const { return line_; } - int index() const { return index_; } - int write_fd() const { return write_fd_; } - - private: - std::string file_; - int line_; - int index_; - int write_fd_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(InternalRunDeathTestFlag); -}; - -// Returns a newly created InternalRunDeathTestFlag object with fields -// initialized from the GTEST_FLAG(internal_run_death_test) flag if -// the flag is specified; otherwise returns NULL. -InternalRunDeathTestFlag* ParseInternalRunDeathTestFlag(); - -#else // GTEST_HAS_DEATH_TEST - -// This macro is used for implementing macros such as -// EXPECT_DEATH_IF_SUPPORTED and ASSERT_DEATH_IF_SUPPORTED on systems where -// death tests are not supported. Those macros must compile on such systems -// iff EXPECT_DEATH and ASSERT_DEATH compile with the same parameters on -// systems that support death tests. This allows one to write such a macro -// on a system that does not support death tests and be sure that it will -// compile on a death-test supporting system. -// -// Parameters: -// statement - A statement that a macro such as EXPECT_DEATH would test -// for program termination. This macro has to make sure this -// statement is compiled but not executed, to ensure that -// EXPECT_DEATH_IF_SUPPORTED compiles with a certain -// parameter iff EXPECT_DEATH compiles with it. -// regex - A regex that a macro such as EXPECT_DEATH would use to test -// the output of statement. This parameter has to be -// compiled but not evaluated by this macro, to ensure that -// this macro only accepts expressions that a macro such as -// EXPECT_DEATH would accept. -// terminator - Must be an empty statement for EXPECT_DEATH_IF_SUPPORTED -// and a return statement for ASSERT_DEATH_IF_SUPPORTED. -// This ensures that ASSERT_DEATH_IF_SUPPORTED will not -// compile inside functions where ASSERT_DEATH doesn't -// compile. -// -// The branch that has an always false condition is used to ensure that -// statement and regex are compiled (and thus syntactically correct) but -// never executed. The unreachable code macro protects the terminator -// statement from generating an 'unreachable code' warning in case -// statement unconditionally returns or throws. The Message constructor at -// the end allows the syntax of streaming additional messages into the -// macro, for compilational compatibility with EXPECT_DEATH/ASSERT_DEATH. -# define GTEST_UNSUPPORTED_DEATH_TEST_(statement, regex, terminator) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - GTEST_LOG_(WARNING) \ - << "Death tests are not supported on this platform.\n" \ - << "Statement '" #statement "' cannot be verified."; \ - } else if (::testing::internal::AlwaysFalse()) { \ - ::testing::internal::RE::PartialMatch(".*", (regex)); \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - terminator; \ - } else \ - ::testing::Message() - -#endif // GTEST_HAS_DEATH_TEST - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_DEATH_TEST_INTERNAL_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-filepath.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-filepath.h deleted file mode 100644 index 7a13b4b0de6..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-filepath.h +++ /dev/null @@ -1,206 +0,0 @@ -// Copyright 2008, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: keith.ray@gmail.com (Keith Ray) -// -// Google Test filepath utilities -// -// This header file declares classes and functions used internally by -// Google Test. They are subject to change without notice. -// -// This file is #included in . -// Do not include this header file separately! - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_FILEPATH_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_FILEPATH_H_ - -#include "gtest/internal/gtest-string.h" - -namespace testing { -namespace internal { - -// FilePath - a class for file and directory pathname manipulation which -// handles platform-specific conventions (like the pathname separator). -// Used for helper functions for naming files in a directory for xml output. -// Except for Set methods, all methods are const or static, which provides an -// "immutable value object" -- useful for peace of mind. -// A FilePath with a value ending in a path separator ("like/this/") represents -// a directory, otherwise it is assumed to represent a file. In either case, -// it may or may not represent an actual file or directory in the file system. -// Names are NOT checked for syntax correctness -- no checking for illegal -// characters, malformed paths, etc. - -class GTEST_API_ FilePath { - public: - FilePath() : pathname_("") { } - FilePath(const FilePath& rhs) : pathname_(rhs.pathname_) { } - - explicit FilePath(const std::string& pathname) : pathname_(pathname) { - Normalize(); - } - - FilePath& operator=(const FilePath& rhs) { - Set(rhs); - return *this; - } - - void Set(const FilePath& rhs) { - pathname_ = rhs.pathname_; - } - - const std::string& string() const { return pathname_; } - const char* c_str() const { return pathname_.c_str(); } - - // Returns the current working directory, or "" if unsuccessful. - static FilePath GetCurrentDir(); - - // Given directory = "dir", base_name = "test", number = 0, - // extension = "xml", returns "dir/test.xml". If number is greater - // than zero (e.g., 12), returns "dir/test_12.xml". - // On Windows platform, uses \ as the separator rather than /. - static FilePath MakeFileName(const FilePath& directory, - const FilePath& base_name, - int number, - const char* extension); - - // Given directory = "dir", relative_path = "test.xml", - // returns "dir/test.xml". - // On Windows, uses \ as the separator rather than /. - static FilePath ConcatPaths(const FilePath& directory, - const FilePath& relative_path); - - // Returns a pathname for a file that does not currently exist. The pathname - // will be directory/base_name.extension or - // directory/base_name_.extension if directory/base_name.extension - // already exists. The number will be incremented until a pathname is found - // that does not already exist. - // Examples: 'dir/foo_test.xml' or 'dir/foo_test_1.xml'. - // There could be a race condition if two or more processes are calling this - // function at the same time -- they could both pick the same filename. - static FilePath GenerateUniqueFileName(const FilePath& directory, - const FilePath& base_name, - const char* extension); - - // Returns true iff the path is "". - bool IsEmpty() const { return pathname_.empty(); } - - // If input name has a trailing separator character, removes it and returns - // the name, otherwise return the name string unmodified. - // On Windows platform, uses \ as the separator, other platforms use /. - FilePath RemoveTrailingPathSeparator() const; - - // Returns a copy of the FilePath with the directory part removed. - // Example: FilePath("path/to/file").RemoveDirectoryName() returns - // FilePath("file"). If there is no directory part ("just_a_file"), it returns - // the FilePath unmodified. If there is no file part ("just_a_dir/") it - // returns an empty FilePath (""). - // On Windows platform, '\' is the path separator, otherwise it is '/'. - FilePath RemoveDirectoryName() const; - - // RemoveFileName returns the directory path with the filename removed. - // Example: FilePath("path/to/file").RemoveFileName() returns "path/to/". - // If the FilePath is "a_file" or "/a_file", RemoveFileName returns - // FilePath("./") or, on Windows, FilePath(".\\"). If the filepath does - // not have a file, like "just/a/dir/", it returns the FilePath unmodified. - // On Windows platform, '\' is the path separator, otherwise it is '/'. - FilePath RemoveFileName() const; - - // Returns a copy of the FilePath with the case-insensitive extension removed. - // Example: FilePath("dir/file.exe").RemoveExtension("EXE") returns - // FilePath("dir/file"). If a case-insensitive extension is not - // found, returns a copy of the original FilePath. - FilePath RemoveExtension(const char* extension) const; - - // Creates directories so that path exists. Returns true if successful or if - // the directories already exist; returns false if unable to create - // directories for any reason. Will also return false if the FilePath does - // not represent a directory (that is, it doesn't end with a path separator). - bool CreateDirectoriesRecursively() const; - - // Create the directory so that path exists. Returns true if successful or - // if the directory already exists; returns false if unable to create the - // directory for any reason, including if the parent directory does not - // exist. Not named "CreateDirectory" because that's a macro on Windows. - bool CreateFolder() const; - - // Returns true if FilePath describes something in the file-system, - // either a file, directory, or whatever, and that something exists. - bool FileOrDirectoryExists() const; - - // Returns true if pathname describes a directory in the file-system - // that exists. - bool DirectoryExists() const; - - // Returns true if FilePath ends with a path separator, which indicates that - // it is intended to represent a directory. Returns false otherwise. - // This does NOT check that a directory (or file) actually exists. - bool IsDirectory() const; - - // Returns true if pathname describes a root directory. (Windows has one - // root directory per disk drive.) - bool IsRootDirectory() const; - - // Returns true if pathname describes an absolute path. - bool IsAbsolutePath() const; - - private: - // Replaces multiple consecutive separators with a single separator. - // For example, "bar///foo" becomes "bar/foo". Does not eliminate other - // redundancies that might be in a pathname involving "." or "..". - // - // A pathname with multiple consecutive separators may occur either through - // user error or as a result of some scripts or APIs that generate a pathname - // with a trailing separator. On other platforms the same API or script - // may NOT generate a pathname with a trailing "/". Then elsewhere that - // pathname may have another "/" and pathname components added to it, - // without checking for the separator already being there. - // The script language and operating system may allow paths like "foo//bar" - // but some of the functions in FilePath will not handle that correctly. In - // particular, RemoveTrailingPathSeparator() only removes one separator, and - // it is called in CreateDirectoriesRecursively() assuming that it will change - // a pathname from directory syntax (trailing separator) to filename syntax. - // - // On Windows this method also replaces the alternate path separator '/' with - // the primary path separator '\\', so that for example "bar\\/\\foo" becomes - // "bar\\foo". - - void Normalize(); - - // Returns a pointer to the last occurence of a valid path separator in - // the FilePath. On Windows, for example, both '/' and '\' are valid path - // separators. Returns NULL if no path separator was found. - const char* FindLastPathSeparator() const; - - std::string pathname_; -}; // class FilePath - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_FILEPATH_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-internal.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-internal.h deleted file mode 100644 index ebd1cf615de..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-internal.h +++ /dev/null @@ -1,1238 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: wan@google.com (Zhanyong Wan), eefacm@gmail.com (Sean Mcafee) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file declares functions and macros used internally by -// Google Test. They are subject to change without notice. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_INTERNAL_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_INTERNAL_H_ - -#include "gtest/internal/gtest-port.h" - -#if GTEST_OS_LINUX -# include -# include -# include -# include -#endif // GTEST_OS_LINUX - -#if GTEST_HAS_EXCEPTIONS -# include -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "gtest/gtest-message.h" -#include "gtest/internal/gtest-string.h" -#include "gtest/internal/gtest-filepath.h" -#include "gtest/internal/gtest-type-util.h" - -// Due to C++ preprocessor weirdness, we need double indirection to -// concatenate two tokens when one of them is __LINE__. Writing -// -// foo ## __LINE__ -// -// will result in the token foo__LINE__, instead of foo followed by -// the current line number. For more details, see -// http://www.parashift.com/c++-faq-lite/misc-technical-issues.html#faq-39.6 -#define GTEST_CONCAT_TOKEN_(foo, bar) GTEST_CONCAT_TOKEN_IMPL_(foo, bar) -#define GTEST_CONCAT_TOKEN_IMPL_(foo, bar) foo ## bar - -class ProtocolMessage; -namespace proto2 { class Message; } - -namespace testing { - -// Forward declarations. - -class AssertionResult; // Result of an assertion. -class Message; // Represents a failure message. -class Test; // Represents a test. -class TestInfo; // Information about a test. -class TestPartResult; // Result of a test part. -class UnitTest; // A collection of test cases. - -template -::std::string PrintToString(const T& value); - -namespace internal { - -struct TraceInfo; // Information about a trace point. -class ScopedTrace; // Implements scoped trace. -class TestInfoImpl; // Opaque implementation of TestInfo -class UnitTestImpl; // Opaque implementation of UnitTest - -// The text used in failure messages to indicate the start of the -// stack trace. -GTEST_API_ extern const char kStackTraceMarker[]; - -// Two overloaded helpers for checking at compile time whether an -// expression is a null pointer literal (i.e. NULL or any 0-valued -// compile-time integral constant). Their return values have -// different sizes, so we can use sizeof() to test which version is -// picked by the compiler. These helpers have no implementations, as -// we only need their signatures. -// -// Given IsNullLiteralHelper(x), the compiler will pick the first -// version if x can be implicitly converted to Secret*, and pick the -// second version otherwise. Since Secret is a secret and incomplete -// type, the only expression a user can write that has type Secret* is -// a null pointer literal. Therefore, we know that x is a null -// pointer literal if and only if the first version is picked by the -// compiler. -char IsNullLiteralHelper(Secret* p); -char (&IsNullLiteralHelper(...))[2]; // NOLINT - -// A compile-time bool constant that is true if and only if x is a -// null pointer literal (i.e. NULL or any 0-valued compile-time -// integral constant). -#ifdef GTEST_ELLIPSIS_NEEDS_POD_ -// We lose support for NULL detection where the compiler doesn't like -// passing non-POD classes through ellipsis (...). -# define GTEST_IS_NULL_LITERAL_(x) false -#else -# define GTEST_IS_NULL_LITERAL_(x) \ - (sizeof(::testing::internal::IsNullLiteralHelper(x)) == 1) -#endif // GTEST_ELLIPSIS_NEEDS_POD_ - -// Appends the user-supplied message to the Google-Test-generated message. -GTEST_API_ std::string AppendUserMessage( - const std::string& gtest_msg, const Message& user_msg); - -#if GTEST_HAS_EXCEPTIONS - -// This exception is thrown by (and only by) a failed Google Test -// assertion when GTEST_FLAG(throw_on_failure) is true (if exceptions -// are enabled). We derive it from std::runtime_error, which is for -// errors presumably detectable only at run time. Since -// std::runtime_error inherits from std::exception, many testing -// frameworks know how to extract and print the message inside it. -class GTEST_API_ GoogleTestFailureException : public ::std::runtime_error { - public: - explicit GoogleTestFailureException(const TestPartResult& failure); -}; - -#endif // GTEST_HAS_EXCEPTIONS - -// A helper class for creating scoped traces in user programs. -class GTEST_API_ ScopedTrace { - public: - // The c'tor pushes the given source file location and message onto - // a trace stack maintained by Google Test. - ScopedTrace(const char* file, int line, const Message& message); - - // The d'tor pops the info pushed by the c'tor. - // - // Note that the d'tor is not virtual in order to be efficient. - // Don't inherit from ScopedTrace! - ~ScopedTrace(); - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(ScopedTrace); -} GTEST_ATTRIBUTE_UNUSED_; // A ScopedTrace object does its job in its - // c'tor and d'tor. Therefore it doesn't - // need to be used otherwise. - -namespace edit_distance { -// Returns the optimal edits to go from 'left' to 'right'. -// All edits cost the same, with replace having lower priority than -// add/remove. -// Simple implementation of the Wagner–Fischer algorithm. -// See http://en.wikipedia.org/wiki/Wagner-Fischer_algorithm -enum EditType { kMatch, kAdd, kRemove, kReplace }; -GTEST_API_ std::vector CalculateOptimalEdits( - const std::vector& left, const std::vector& right); - -// Same as above, but the input is represented as strings. -GTEST_API_ std::vector CalculateOptimalEdits( - const std::vector& left, - const std::vector& right); - -// Create a diff of the input strings in Unified diff format. -GTEST_API_ std::string CreateUnifiedDiff(const std::vector& left, - const std::vector& right, - size_t context = 2); - -} // namespace edit_distance - -// Calculate the diff between 'left' and 'right' and return it in unified diff -// format. -// If not null, stores in 'total_line_count' the total number of lines found -// in left + right. -GTEST_API_ std::string DiffStrings(const std::string& left, - const std::string& right, - size_t* total_line_count); - -// Constructs and returns the message for an equality assertion -// (e.g. ASSERT_EQ, EXPECT_STREQ, etc) failure. -// -// The first four parameters are the expressions used in the assertion -// and their values, as strings. For example, for ASSERT_EQ(foo, bar) -// where foo is 5 and bar is 6, we have: -// -// expected_expression: "foo" -// actual_expression: "bar" -// expected_value: "5" -// actual_value: "6" -// -// The ignoring_case parameter is true iff the assertion is a -// *_STRCASEEQ*. When it's true, the string " (ignoring case)" will -// be inserted into the message. -GTEST_API_ AssertionResult EqFailure(const char* expected_expression, - const char* actual_expression, - const std::string& expected_value, - const std::string& actual_value, - bool ignoring_case); - -// Constructs a failure message for Boolean assertions such as EXPECT_TRUE. -GTEST_API_ std::string GetBoolAssertionFailureMessage( - const AssertionResult& assertion_result, - const char* expression_text, - const char* actual_predicate_value, - const char* expected_predicate_value); - -// This template class represents an IEEE floating-point number -// (either single-precision or double-precision, depending on the -// template parameters). -// -// The purpose of this class is to do more sophisticated number -// comparison. (Due to round-off error, etc, it's very unlikely that -// two floating-points will be equal exactly. Hence a naive -// comparison by the == operation often doesn't work.) -// -// Format of IEEE floating-point: -// -// The most-significant bit being the leftmost, an IEEE -// floating-point looks like -// -// sign_bit exponent_bits fraction_bits -// -// Here, sign_bit is a single bit that designates the sign of the -// number. -// -// For float, there are 8 exponent bits and 23 fraction bits. -// -// For double, there are 11 exponent bits and 52 fraction bits. -// -// More details can be found at -// http://en.wikipedia.org/wiki/IEEE_floating-point_standard. -// -// Template parameter: -// -// RawType: the raw floating-point type (either float or double) -template -class FloatingPoint { - public: - // Defines the unsigned integer type that has the same size as the - // floating point number. - typedef typename TypeWithSize::UInt Bits; - - // Constants. - - // # of bits in a number. - static const size_t kBitCount = 8*sizeof(RawType); - - // # of fraction bits in a number. - static const size_t kFractionBitCount = - std::numeric_limits::digits - 1; - - // # of exponent bits in a number. - static const size_t kExponentBitCount = kBitCount - 1 - kFractionBitCount; - - // The mask for the sign bit. - static const Bits kSignBitMask = static_cast(1) << (kBitCount - 1); - - // The mask for the fraction bits. - static const Bits kFractionBitMask = - ~static_cast(0) >> (kExponentBitCount + 1); - - // The mask for the exponent bits. - static const Bits kExponentBitMask = ~(kSignBitMask | kFractionBitMask); - - // How many ULP's (Units in the Last Place) we want to tolerate when - // comparing two numbers. The larger the value, the more error we - // allow. A 0 value means that two numbers must be exactly the same - // to be considered equal. - // - // The maximum error of a single floating-point operation is 0.5 - // units in the last place. On Intel CPU's, all floating-point - // calculations are done with 80-bit precision, while double has 64 - // bits. Therefore, 4 should be enough for ordinary use. - // - // See the following article for more details on ULP: - // http://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/ - static const size_t kMaxUlps = 4; - - // Constructs a FloatingPoint from a raw floating-point number. - // - // On an Intel CPU, passing a non-normalized NAN (Not a Number) - // around may change its bits, although the new value is guaranteed - // to be also a NAN. Therefore, don't expect this constructor to - // preserve the bits in x when x is a NAN. - explicit FloatingPoint(const RawType& x) { u_.value_ = x; } - - // Static methods - - // Reinterprets a bit pattern as a floating-point number. - // - // This function is needed to test the AlmostEquals() method. - static RawType ReinterpretBits(const Bits bits) { - FloatingPoint fp(0); - fp.u_.bits_ = bits; - return fp.u_.value_; - } - - // Returns the floating-point number that represent positive infinity. - static RawType Infinity() { - return ReinterpretBits(kExponentBitMask); - } - - // Returns the maximum representable finite floating-point number. - static RawType Max(); - - // Non-static methods - - // Returns the bits that represents this number. - const Bits &bits() const { return u_.bits_; } - - // Returns the exponent bits of this number. - Bits exponent_bits() const { return kExponentBitMask & u_.bits_; } - - // Returns the fraction bits of this number. - Bits fraction_bits() const { return kFractionBitMask & u_.bits_; } - - // Returns the sign bit of this number. - Bits sign_bit() const { return kSignBitMask & u_.bits_; } - - // Returns true iff this is NAN (not a number). - bool is_nan() const { - // It's a NAN if the exponent bits are all ones and the fraction - // bits are not entirely zeros. - return (exponent_bits() == kExponentBitMask) && (fraction_bits() != 0); - } - - // Returns true iff this number is at most kMaxUlps ULP's away from - // rhs. In particular, this function: - // - // - returns false if either number is (or both are) NAN. - // - treats really large numbers as almost equal to infinity. - // - thinks +0.0 and -0.0 are 0 DLP's apart. - bool AlmostEquals(const FloatingPoint& rhs) const { - // The IEEE standard says that any comparison operation involving - // a NAN must return false. - if (is_nan() || rhs.is_nan()) return false; - - return DistanceBetweenSignAndMagnitudeNumbers(u_.bits_, rhs.u_.bits_) - <= kMaxUlps; - } - - private: - // The data type used to store the actual floating-point number. - union FloatingPointUnion { - RawType value_; // The raw floating-point number. - Bits bits_; // The bits that represent the number. - }; - - // Converts an integer from the sign-and-magnitude representation to - // the biased representation. More precisely, let N be 2 to the - // power of (kBitCount - 1), an integer x is represented by the - // unsigned number x + N. - // - // For instance, - // - // -N + 1 (the most negative number representable using - // sign-and-magnitude) is represented by 1; - // 0 is represented by N; and - // N - 1 (the biggest number representable using - // sign-and-magnitude) is represented by 2N - 1. - // - // Read http://en.wikipedia.org/wiki/Signed_number_representations - // for more details on signed number representations. - static Bits SignAndMagnitudeToBiased(const Bits &sam) { - if (kSignBitMask & sam) { - // sam represents a negative number. - return ~sam + 1; - } else { - // sam represents a positive number. - return kSignBitMask | sam; - } - } - - // Given two numbers in the sign-and-magnitude representation, - // returns the distance between them as an unsigned number. - static Bits DistanceBetweenSignAndMagnitudeNumbers(const Bits &sam1, - const Bits &sam2) { - const Bits biased1 = SignAndMagnitudeToBiased(sam1); - const Bits biased2 = SignAndMagnitudeToBiased(sam2); - return (biased1 >= biased2) ? (biased1 - biased2) : (biased2 - biased1); - } - - FloatingPointUnion u_; -}; - -// We cannot use std::numeric_limits::max() as it clashes with the max() -// macro defined by . -template <> -inline float FloatingPoint::Max() { return FLT_MAX; } -template <> -inline double FloatingPoint::Max() { return DBL_MAX; } - -// Typedefs the instances of the FloatingPoint template class that we -// care to use. -typedef FloatingPoint Float; -typedef FloatingPoint Double; - -// In order to catch the mistake of putting tests that use different -// test fixture classes in the same test case, we need to assign -// unique IDs to fixture classes and compare them. The TypeId type is -// used to hold such IDs. The user should treat TypeId as an opaque -// type: the only operation allowed on TypeId values is to compare -// them for equality using the == operator. -typedef const void* TypeId; - -template -class TypeIdHelper { - public: - // dummy_ must not have a const type. Otherwise an overly eager - // compiler (e.g. MSVC 7.1 & 8.0) may try to merge - // TypeIdHelper::dummy_ for different Ts as an "optimization". - static bool dummy_; -}; - -template -bool TypeIdHelper::dummy_ = false; - -// GetTypeId() returns the ID of type T. Different values will be -// returned for different types. Calling the function twice with the -// same type argument is guaranteed to return the same ID. -template -TypeId GetTypeId() { - // The compiler is required to allocate a different - // TypeIdHelper::dummy_ variable for each T used to instantiate - // the template. Therefore, the address of dummy_ is guaranteed to - // be unique. - return &(TypeIdHelper::dummy_); -} - -// Returns the type ID of ::testing::Test. Always call this instead -// of GetTypeId< ::testing::Test>() to get the type ID of -// ::testing::Test, as the latter may give the wrong result due to a -// suspected linker bug when compiling Google Test as a Mac OS X -// framework. -GTEST_API_ TypeId GetTestTypeId(); - -// Defines the abstract factory interface that creates instances -// of a Test object. -class TestFactoryBase { - public: - virtual ~TestFactoryBase() {} - - // Creates a test instance to run. The instance is both created and destroyed - // within TestInfoImpl::Run() - virtual Test* CreateTest() = 0; - - protected: - TestFactoryBase() {} - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestFactoryBase); -}; - -// This class provides implementation of TeastFactoryBase interface. -// It is used in TEST and TEST_F macros. -template -class TestFactoryImpl : public TestFactoryBase { - public: - virtual Test* CreateTest() { return new TestClass; } -}; - -#if GTEST_OS_WINDOWS - -// Predicate-formatters for implementing the HRESULT checking macros -// {ASSERT|EXPECT}_HRESULT_{SUCCEEDED|FAILED} -// We pass a long instead of HRESULT to avoid causing an -// include dependency for the HRESULT type. -GTEST_API_ AssertionResult IsHRESULTSuccess(const char* expr, - long hr); // NOLINT -GTEST_API_ AssertionResult IsHRESULTFailure(const char* expr, - long hr); // NOLINT - -#endif // GTEST_OS_WINDOWS - -// Types of SetUpTestCase() and TearDownTestCase() functions. -typedef void (*SetUpTestCaseFunc)(); -typedef void (*TearDownTestCaseFunc)(); - -struct CodeLocation { - CodeLocation(const string& a_file, int a_line) : file(a_file), line(a_line) {} - - string file; - int line; -}; - -// Creates a new TestInfo object and registers it with Google Test; -// returns the created object. -// -// Arguments: -// -// test_case_name: name of the test case -// name: name of the test -// type_param the name of the test's type parameter, or NULL if -// this is not a typed or a type-parameterized test. -// value_param text representation of the test's value parameter, -// or NULL if this is not a type-parameterized test. -// code_location: code location where the test is defined -// fixture_class_id: ID of the test fixture class -// set_up_tc: pointer to the function that sets up the test case -// tear_down_tc: pointer to the function that tears down the test case -// factory: pointer to the factory that creates a test object. -// The newly created TestInfo instance will assume -// ownership of the factory object. -GTEST_API_ TestInfo* MakeAndRegisterTestInfo( - const char* test_case_name, - const char* name, - const char* type_param, - const char* value_param, - CodeLocation code_location, - TypeId fixture_class_id, - SetUpTestCaseFunc set_up_tc, - TearDownTestCaseFunc tear_down_tc, - TestFactoryBase* factory); - -// If *pstr starts with the given prefix, modifies *pstr to be right -// past the prefix and returns true; otherwise leaves *pstr unchanged -// and returns false. None of pstr, *pstr, and prefix can be NULL. -GTEST_API_ bool SkipPrefix(const char* prefix, const char** pstr); - -#if GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -// State of the definition of a type-parameterized test case. -class GTEST_API_ TypedTestCasePState { - public: - TypedTestCasePState() : registered_(false) {} - - // Adds the given test name to defined_test_names_ and return true - // if the test case hasn't been registered; otherwise aborts the - // program. - bool AddTestName(const char* file, int line, const char* case_name, - const char* test_name) { - if (registered_) { - fprintf(stderr, "%s Test %s must be defined before " - "REGISTER_TYPED_TEST_CASE_P(%s, ...).\n", - FormatFileLocation(file, line).c_str(), test_name, case_name); - fflush(stderr); - posix::Abort(); - } - registered_tests_.insert( - ::std::make_pair(test_name, CodeLocation(file, line))); - return true; - } - - bool TestExists(const std::string& test_name) const { - return registered_tests_.count(test_name) > 0; - } - - const CodeLocation& GetCodeLocation(const std::string& test_name) const { - RegisteredTestsMap::const_iterator it = registered_tests_.find(test_name); - GTEST_CHECK_(it != registered_tests_.end()); - return it->second; - } - - // Verifies that registered_tests match the test names in - // defined_test_names_; returns registered_tests if successful, or - // aborts the program otherwise. - const char* VerifyRegisteredTestNames( - const char* file, int line, const char* registered_tests); - - private: - typedef ::std::map RegisteredTestsMap; - - bool registered_; - RegisteredTestsMap registered_tests_; -}; - -// Skips to the first non-space char after the first comma in 'str'; -// returns NULL if no comma is found in 'str'. -inline const char* SkipComma(const char* str) { - const char* comma = strchr(str, ','); - if (comma == NULL) { - return NULL; - } - while (IsSpace(*(++comma))) {} - return comma; -} - -// Returns the prefix of 'str' before the first comma in it; returns -// the entire string if it contains no comma. -inline std::string GetPrefixUntilComma(const char* str) { - const char* comma = strchr(str, ','); - return comma == NULL ? str : std::string(str, comma); -} - -// Splits a given string on a given delimiter, populating a given -// vector with the fields. -void SplitString(const ::std::string& str, char delimiter, - ::std::vector< ::std::string>* dest); - -// TypeParameterizedTest::Register() -// registers a list of type-parameterized tests with Google Test. The -// return value is insignificant - we just need to return something -// such that we can call this function in a namespace scope. -// -// Implementation note: The GTEST_TEMPLATE_ macro declares a template -// template parameter. It's defined in gtest-type-util.h. -template -class TypeParameterizedTest { - public: - // 'index' is the index of the test in the type list 'Types' - // specified in INSTANTIATE_TYPED_TEST_CASE_P(Prefix, TestCase, - // Types). Valid values for 'index' are [0, N - 1] where N is the - // length of Types. - static bool Register(const char* prefix, - CodeLocation code_location, - const char* case_name, const char* test_names, - int index) { - typedef typename Types::Head Type; - typedef Fixture FixtureClass; - typedef typename GTEST_BIND_(TestSel, Type) TestClass; - - // First, registers the first type-parameterized test in the type - // list. - MakeAndRegisterTestInfo( - (std::string(prefix) + (prefix[0] == '\0' ? "" : "/") + case_name + "/" - + StreamableToString(index)).c_str(), - StripTrailingSpaces(GetPrefixUntilComma(test_names)).c_str(), - GetTypeName().c_str(), - NULL, // No value parameter. - code_location, - GetTypeId(), - TestClass::SetUpTestCase, - TestClass::TearDownTestCase, - new TestFactoryImpl); - - // Next, recurses (at compile time) with the tail of the type list. - return TypeParameterizedTest - ::Register(prefix, code_location, case_name, test_names, index + 1); - } -}; - -// The base case for the compile time recursion. -template -class TypeParameterizedTest { - public: - static bool Register(const char* /*prefix*/, CodeLocation, - const char* /*case_name*/, const char* /*test_names*/, - int /*index*/) { - return true; - } -}; - -// TypeParameterizedTestCase::Register() -// registers *all combinations* of 'Tests' and 'Types' with Google -// Test. The return value is insignificant - we just need to return -// something such that we can call this function in a namespace scope. -template -class TypeParameterizedTestCase { - public: - static bool Register(const char* prefix, CodeLocation code_location, - const TypedTestCasePState* state, - const char* case_name, const char* test_names) { - std::string test_name = StripTrailingSpaces( - GetPrefixUntilComma(test_names)); - if (!state->TestExists(test_name)) { - fprintf(stderr, "Failed to get code location for test %s.%s at %s.", - case_name, test_name.c_str(), - FormatFileLocation(code_location.file.c_str(), - code_location.line).c_str()); - fflush(stderr); - posix::Abort(); - } - const CodeLocation& test_location = state->GetCodeLocation(test_name); - - typedef typename Tests::Head Head; - - // First, register the first test in 'Test' for each type in 'Types'. - TypeParameterizedTest::Register( - prefix, test_location, case_name, test_names, 0); - - // Next, recurses (at compile time) with the tail of the test list. - return TypeParameterizedTestCase - ::Register(prefix, code_location, state, - case_name, SkipComma(test_names)); - } -}; - -// The base case for the compile time recursion. -template -class TypeParameterizedTestCase { - public: - static bool Register(const char* /*prefix*/, CodeLocation, - const TypedTestCasePState* /*state*/, - const char* /*case_name*/, const char* /*test_names*/) { - return true; - } -}; - -#endif // GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -// Returns the current OS stack trace as an std::string. -// -// The maximum number of stack frames to be included is specified by -// the gtest_stack_trace_depth flag. The skip_count parameter -// specifies the number of top frames to be skipped, which doesn't -// count against the number of frames to be included. -// -// For example, if Foo() calls Bar(), which in turn calls -// GetCurrentOsStackTraceExceptTop(..., 1), Foo() will be included in -// the trace but Bar() and GetCurrentOsStackTraceExceptTop() won't. -GTEST_API_ std::string GetCurrentOsStackTraceExceptTop( - UnitTest* unit_test, int skip_count); - -// Helpers for suppressing warnings on unreachable code or constant -// condition. - -// Always returns true. -GTEST_API_ bool AlwaysTrue(); - -// Always returns false. -inline bool AlwaysFalse() { return !AlwaysTrue(); } - -// Helper for suppressing false warning from Clang on a const char* -// variable declared in a conditional expression always being NULL in -// the else branch. -struct GTEST_API_ ConstCharPtr { - ConstCharPtr(const char* str) : value(str) {} - operator bool() const { return true; } - const char* value; -}; - -// A simple Linear Congruential Generator for generating random -// numbers with a uniform distribution. Unlike rand() and srand(), it -// doesn't use global state (and therefore can't interfere with user -// code). Unlike rand_r(), it's portable. An LCG isn't very random, -// but it's good enough for our purposes. -class GTEST_API_ Random { - public: - static const UInt32 kMaxRange = 1u << 31; - - explicit Random(UInt32 seed) : state_(seed) {} - - void Reseed(UInt32 seed) { state_ = seed; } - - // Generates a random number from [0, range). Crashes if 'range' is - // 0 or greater than kMaxRange. - UInt32 Generate(UInt32 range); - - private: - UInt32 state_; - GTEST_DISALLOW_COPY_AND_ASSIGN_(Random); -}; - -// Defining a variable of type CompileAssertTypesEqual will cause a -// compiler error iff T1 and T2 are different types. -template -struct CompileAssertTypesEqual; - -template -struct CompileAssertTypesEqual { -}; - -// Removes the reference from a type if it is a reference type, -// otherwise leaves it unchanged. This is the same as -// tr1::remove_reference, which is not widely available yet. -template -struct RemoveReference { typedef T type; }; // NOLINT -template -struct RemoveReference { typedef T type; }; // NOLINT - -// A handy wrapper around RemoveReference that works when the argument -// T depends on template parameters. -#define GTEST_REMOVE_REFERENCE_(T) \ - typename ::testing::internal::RemoveReference::type - -// Removes const from a type if it is a const type, otherwise leaves -// it unchanged. This is the same as tr1::remove_const, which is not -// widely available yet. -template -struct RemoveConst { typedef T type; }; // NOLINT -template -struct RemoveConst { typedef T type; }; // NOLINT - -// MSVC 8.0, Sun C++, and IBM XL C++ have a bug which causes the above -// definition to fail to remove the const in 'const int[3]' and 'const -// char[3][4]'. The following specialization works around the bug. -template -struct RemoveConst { - typedef typename RemoveConst::type type[N]; -}; - -#if defined(_MSC_VER) && _MSC_VER < 1400 -// This is the only specialization that allows VC++ 7.1 to remove const in -// 'const int[3] and 'const int[3][4]'. However, it causes trouble with GCC -// and thus needs to be conditionally compiled. -template -struct RemoveConst { - typedef typename RemoveConst::type type[N]; -}; -#endif - -// A handy wrapper around RemoveConst that works when the argument -// T depends on template parameters. -#define GTEST_REMOVE_CONST_(T) \ - typename ::testing::internal::RemoveConst::type - -// Turns const U&, U&, const U, and U all into U. -#define GTEST_REMOVE_REFERENCE_AND_CONST_(T) \ - GTEST_REMOVE_CONST_(GTEST_REMOVE_REFERENCE_(T)) - -// Adds reference to a type if it is not a reference type, -// otherwise leaves it unchanged. This is the same as -// tr1::add_reference, which is not widely available yet. -template -struct AddReference { typedef T& type; }; // NOLINT -template -struct AddReference { typedef T& type; }; // NOLINT - -// A handy wrapper around AddReference that works when the argument T -// depends on template parameters. -#define GTEST_ADD_REFERENCE_(T) \ - typename ::testing::internal::AddReference::type - -// Adds a reference to const on top of T as necessary. For example, -// it transforms -// -// char ==> const char& -// const char ==> const char& -// char& ==> const char& -// const char& ==> const char& -// -// The argument T must depend on some template parameters. -#define GTEST_REFERENCE_TO_CONST_(T) \ - GTEST_ADD_REFERENCE_(const GTEST_REMOVE_REFERENCE_(T)) - -// ImplicitlyConvertible::value is a compile-time bool -// constant that's true iff type From can be implicitly converted to -// type To. -template -class ImplicitlyConvertible { - private: - // We need the following helper functions only for their types. - // They have no implementations. - - // MakeFrom() is an expression whose type is From. We cannot simply - // use From(), as the type From may not have a public default - // constructor. - static typename AddReference::type MakeFrom(); - - // These two functions are overloaded. Given an expression - // Helper(x), the compiler will pick the first version if x can be - // implicitly converted to type To; otherwise it will pick the - // second version. - // - // The first version returns a value of size 1, and the second - // version returns a value of size 2. Therefore, by checking the - // size of Helper(x), which can be done at compile time, we can tell - // which version of Helper() is used, and hence whether x can be - // implicitly converted to type To. - static char Helper(To); - static char (&Helper(...))[2]; // NOLINT - - // We have to put the 'public' section after the 'private' section, - // or MSVC refuses to compile the code. - public: -#if defined(__BORLANDC__) - // C++Builder cannot use member overload resolution during template - // instantiation. The simplest workaround is to use its C++0x type traits - // functions (C++Builder 2009 and above only). - static const bool value = __is_convertible(From, To); -#else - // MSVC warns about implicitly converting from double to int for - // possible loss of data, so we need to temporarily disable the - // warning. - GTEST_DISABLE_MSC_WARNINGS_PUSH_(4244) - static const bool value = - sizeof(Helper(ImplicitlyConvertible::MakeFrom())) == 1; - GTEST_DISABLE_MSC_WARNINGS_POP_() -#endif // __BORLANDC__ -}; -template -const bool ImplicitlyConvertible::value; - -// IsAProtocolMessage::value is a compile-time bool constant that's -// true iff T is type ProtocolMessage, proto2::Message, or a subclass -// of those. -template -struct IsAProtocolMessage - : public bool_constant< - ImplicitlyConvertible::value || - ImplicitlyConvertible::value> { -}; - -// When the compiler sees expression IsContainerTest(0), if C is an -// STL-style container class, the first overload of IsContainerTest -// will be viable (since both C::iterator* and C::const_iterator* are -// valid types and NULL can be implicitly converted to them). It will -// be picked over the second overload as 'int' is a perfect match for -// the type of argument 0. If C::iterator or C::const_iterator is not -// a valid type, the first overload is not viable, and the second -// overload will be picked. Therefore, we can determine whether C is -// a container class by checking the type of IsContainerTest(0). -// The value of the expression is insignificant. -// -// Note that we look for both C::iterator and C::const_iterator. The -// reason is that C++ injects the name of a class as a member of the -// class itself (e.g. you can refer to class iterator as either -// 'iterator' or 'iterator::iterator'). If we look for C::iterator -// only, for example, we would mistakenly think that a class named -// iterator is an STL container. -// -// Also note that the simpler approach of overloading -// IsContainerTest(typename C::const_iterator*) and -// IsContainerTest(...) doesn't work with Visual Age C++ and Sun C++. -typedef int IsContainer; -template -IsContainer IsContainerTest(int /* dummy */, - typename C::iterator* /* it */ = NULL, - typename C::const_iterator* /* const_it */ = NULL) { - return 0; -} - -typedef char IsNotContainer; -template -IsNotContainer IsContainerTest(long /* dummy */) { return '\0'; } - -// EnableIf::type is void when 'Cond' is true, and -// undefined when 'Cond' is false. To use SFINAE to make a function -// overload only apply when a particular expression is true, add -// "typename EnableIf::type* = 0" as the last parameter. -template struct EnableIf; -template<> struct EnableIf { typedef void type; }; // NOLINT - -// Utilities for native arrays. - -// ArrayEq() compares two k-dimensional native arrays using the -// elements' operator==, where k can be any integer >= 0. When k is -// 0, ArrayEq() degenerates into comparing a single pair of values. - -template -bool ArrayEq(const T* lhs, size_t size, const U* rhs); - -// This generic version is used when k is 0. -template -inline bool ArrayEq(const T& lhs, const U& rhs) { return lhs == rhs; } - -// This overload is used when k >= 1. -template -inline bool ArrayEq(const T(&lhs)[N], const U(&rhs)[N]) { - return internal::ArrayEq(lhs, N, rhs); -} - -// This helper reduces code bloat. If we instead put its logic inside -// the previous ArrayEq() function, arrays with different sizes would -// lead to different copies of the template code. -template -bool ArrayEq(const T* lhs, size_t size, const U* rhs) { - for (size_t i = 0; i != size; i++) { - if (!internal::ArrayEq(lhs[i], rhs[i])) - return false; - } - return true; -} - -// Finds the first element in the iterator range [begin, end) that -// equals elem. Element may be a native array type itself. -template -Iter ArrayAwareFind(Iter begin, Iter end, const Element& elem) { - for (Iter it = begin; it != end; ++it) { - if (internal::ArrayEq(*it, elem)) - return it; - } - return end; -} - -// CopyArray() copies a k-dimensional native array using the elements' -// operator=, where k can be any integer >= 0. When k is 0, -// CopyArray() degenerates into copying a single value. - -template -void CopyArray(const T* from, size_t size, U* to); - -// This generic version is used when k is 0. -template -inline void CopyArray(const T& from, U* to) { *to = from; } - -// This overload is used when k >= 1. -template -inline void CopyArray(const T(&from)[N], U(*to)[N]) { - internal::CopyArray(from, N, *to); -} - -// This helper reduces code bloat. If we instead put its logic inside -// the previous CopyArray() function, arrays with different sizes -// would lead to different copies of the template code. -template -void CopyArray(const T* from, size_t size, U* to) { - for (size_t i = 0; i != size; i++) { - internal::CopyArray(from[i], to + i); - } -} - -// The relation between an NativeArray object (see below) and the -// native array it represents. -// We use 2 different structs to allow non-copyable types to be used, as long -// as RelationToSourceReference() is passed. -struct RelationToSourceReference {}; -struct RelationToSourceCopy {}; - -// Adapts a native array to a read-only STL-style container. Instead -// of the complete STL container concept, this adaptor only implements -// members useful for Google Mock's container matchers. New members -// should be added as needed. To simplify the implementation, we only -// support Element being a raw type (i.e. having no top-level const or -// reference modifier). It's the client's responsibility to satisfy -// this requirement. Element can be an array type itself (hence -// multi-dimensional arrays are supported). -template -class NativeArray { - public: - // STL-style container typedefs. - typedef Element value_type; - typedef Element* iterator; - typedef const Element* const_iterator; - - // Constructs from a native array. References the source. - NativeArray(const Element* array, size_t count, RelationToSourceReference) { - InitRef(array, count); - } - - // Constructs from a native array. Copies the source. - NativeArray(const Element* array, size_t count, RelationToSourceCopy) { - InitCopy(array, count); - } - - // Copy constructor. - NativeArray(const NativeArray& rhs) { - (this->*rhs.clone_)(rhs.array_, rhs.size_); - } - - ~NativeArray() { - if (clone_ != &NativeArray::InitRef) - delete[] array_; - } - - // STL-style container methods. - size_t size() const { return size_; } - const_iterator begin() const { return array_; } - const_iterator end() const { return array_ + size_; } - bool operator==(const NativeArray& rhs) const { - return size() == rhs.size() && - ArrayEq(begin(), size(), rhs.begin()); - } - - private: - enum { - kCheckTypeIsNotConstOrAReference = StaticAssertTypeEqHelper< - Element, GTEST_REMOVE_REFERENCE_AND_CONST_(Element)>::value, - }; - - // Initializes this object with a copy of the input. - void InitCopy(const Element* array, size_t a_size) { - Element* const copy = new Element[a_size]; - CopyArray(array, a_size, copy); - array_ = copy; - size_ = a_size; - clone_ = &NativeArray::InitCopy; - } - - // Initializes this object with a reference of the input. - void InitRef(const Element* array, size_t a_size) { - array_ = array; - size_ = a_size; - clone_ = &NativeArray::InitRef; - } - - const Element* array_; - size_t size_; - void (NativeArray::*clone_)(const Element*, size_t); - - GTEST_DISALLOW_ASSIGN_(NativeArray); -}; - -} // namespace internal -} // namespace testing - -#define GTEST_MESSAGE_AT_(file, line, message, result_type) \ - ::testing::internal::AssertHelper(result_type, file, line, message) \ - = ::testing::Message() - -#define GTEST_MESSAGE_(message, result_type) \ - GTEST_MESSAGE_AT_(__FILE__, __LINE__, message, result_type) - -#define GTEST_FATAL_FAILURE_(message) \ - return GTEST_MESSAGE_(message, ::testing::TestPartResult::kFatalFailure) - -#define GTEST_NONFATAL_FAILURE_(message) \ - GTEST_MESSAGE_(message, ::testing::TestPartResult::kNonFatalFailure) - -#define GTEST_SUCCESS_(message) \ - GTEST_MESSAGE_(message, ::testing::TestPartResult::kSuccess) - -// Suppresses MSVC warnings 4072 (unreachable code) for the code following -// statement if it returns or throws (or doesn't return or throw in some -// situations). -#define GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement) \ - if (::testing::internal::AlwaysTrue()) { statement; } - -#define GTEST_TEST_THROW_(statement, expected_exception, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::ConstCharPtr gtest_msg = "") { \ - bool gtest_caught_expected = false; \ - try { \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - } \ - catch (expected_exception const&) { \ - gtest_caught_expected = true; \ - } \ - catch (...) { \ - gtest_msg.value = \ - "Expected: " #statement " throws an exception of type " \ - #expected_exception ".\n Actual: it throws a different type."; \ - goto GTEST_CONCAT_TOKEN_(gtest_label_testthrow_, __LINE__); \ - } \ - if (!gtest_caught_expected) { \ - gtest_msg.value = \ - "Expected: " #statement " throws an exception of type " \ - #expected_exception ".\n Actual: it throws nothing."; \ - goto GTEST_CONCAT_TOKEN_(gtest_label_testthrow_, __LINE__); \ - } \ - } else \ - GTEST_CONCAT_TOKEN_(gtest_label_testthrow_, __LINE__): \ - fail(gtest_msg.value) - -#define GTEST_TEST_NO_THROW_(statement, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - try { \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - } \ - catch (...) { \ - goto GTEST_CONCAT_TOKEN_(gtest_label_testnothrow_, __LINE__); \ - } \ - } else \ - GTEST_CONCAT_TOKEN_(gtest_label_testnothrow_, __LINE__): \ - fail("Expected: " #statement " doesn't throw an exception.\n" \ - " Actual: it throws.") - -#define GTEST_TEST_ANY_THROW_(statement, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - bool gtest_caught_any = false; \ - try { \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - } \ - catch (...) { \ - gtest_caught_any = true; \ - } \ - if (!gtest_caught_any) { \ - goto GTEST_CONCAT_TOKEN_(gtest_label_testanythrow_, __LINE__); \ - } \ - } else \ - GTEST_CONCAT_TOKEN_(gtest_label_testanythrow_, __LINE__): \ - fail("Expected: " #statement " throws an exception.\n" \ - " Actual: it doesn't.") - - -// Implements Boolean test assertions such as EXPECT_TRUE. expression can be -// either a boolean expression or an AssertionResult. text is a textual -// represenation of expression as it was passed into the EXPECT_TRUE. -#define GTEST_TEST_BOOLEAN_(expression, text, actual, expected, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (const ::testing::AssertionResult gtest_ar_ = \ - ::testing::AssertionResult(expression)) \ - ; \ - else \ - fail(::testing::internal::GetBoolAssertionFailureMessage(\ - gtest_ar_, text, #actual, #expected).c_str()) - -#define GTEST_TEST_NO_FATAL_FAILURE_(statement, fail) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::AlwaysTrue()) { \ - ::testing::internal::HasNewFatalFailureHelper gtest_fatal_failure_checker; \ - GTEST_SUPPRESS_UNREACHABLE_CODE_WARNING_BELOW_(statement); \ - if (gtest_fatal_failure_checker.has_new_fatal_failure()) { \ - goto GTEST_CONCAT_TOKEN_(gtest_label_testnofatal_, __LINE__); \ - } \ - } else \ - GTEST_CONCAT_TOKEN_(gtest_label_testnofatal_, __LINE__): \ - fail("Expected: " #statement " doesn't generate new fatal " \ - "failures in the current thread.\n" \ - " Actual: it does.") - -// Expands to the name of the class that implements the given test. -#define GTEST_TEST_CLASS_NAME_(test_case_name, test_name) \ - test_case_name##_##test_name##_Test - -// Helper macro for defining tests. -#define GTEST_TEST_(test_case_name, test_name, parent_class, parent_id)\ -class GTEST_TEST_CLASS_NAME_(test_case_name, test_name) : public parent_class {\ - public:\ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)() {}\ - private:\ - virtual void TestBody();\ - static ::testing::TestInfo* const test_info_ GTEST_ATTRIBUTE_UNUSED_;\ - GTEST_DISALLOW_COPY_AND_ASSIGN_(\ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name));\ -};\ -\ -::testing::TestInfo* const GTEST_TEST_CLASS_NAME_(test_case_name, test_name)\ - ::test_info_ =\ - ::testing::internal::MakeAndRegisterTestInfo(\ - #test_case_name, #test_name, NULL, NULL, \ - ::testing::internal::CodeLocation(__FILE__, __LINE__), \ - (parent_id), \ - parent_class::SetUpTestCase, \ - parent_class::TearDownTestCase, \ - new ::testing::internal::TestFactoryImpl<\ - GTEST_TEST_CLASS_NAME_(test_case_name, test_name)>);\ -void GTEST_TEST_CLASS_NAME_(test_case_name, test_name)::TestBody() - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_INTERNAL_H_ - diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-linked_ptr.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-linked_ptr.h deleted file mode 100644 index 36029422174..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-linked_ptr.h +++ /dev/null @@ -1,243 +0,0 @@ -// Copyright 2003 Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: Dan Egnor (egnor@google.com) -// -// A "smart" pointer type with reference tracking. Every pointer to a -// particular object is kept on a circular linked list. When the last pointer -// to an object is destroyed or reassigned, the object is deleted. -// -// Used properly, this deletes the object when the last reference goes away. -// There are several caveats: -// - Like all reference counting schemes, cycles lead to leaks. -// - Each smart pointer is actually two pointers (8 bytes instead of 4). -// - Every time a pointer is assigned, the entire list of pointers to that -// object is traversed. This class is therefore NOT SUITABLE when there -// will often be more than two or three pointers to a particular object. -// - References are only tracked as long as linked_ptr<> objects are copied. -// If a linked_ptr<> is converted to a raw pointer and back, BAD THINGS -// will happen (double deletion). -// -// A good use of this class is storing object references in STL containers. -// You can safely put linked_ptr<> in a vector<>. -// Other uses may not be as good. -// -// Note: If you use an incomplete type with linked_ptr<>, the class -// *containing* linked_ptr<> must have a constructor and destructor (even -// if they do nothing!). -// -// Bill Gibbons suggested we use something like this. -// -// Thread Safety: -// Unlike other linked_ptr implementations, in this implementation -// a linked_ptr object is thread-safe in the sense that: -// - it's safe to copy linked_ptr objects concurrently, -// - it's safe to copy *from* a linked_ptr and read its underlying -// raw pointer (e.g. via get()) concurrently, and -// - it's safe to write to two linked_ptrs that point to the same -// shared object concurrently. -// TODO(wan@google.com): rename this to safe_linked_ptr to avoid -// confusion with normal linked_ptr. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_LINKED_PTR_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_LINKED_PTR_H_ - -#include -#include - -#include "gtest/internal/gtest-port.h" - -namespace testing { -namespace internal { - -// Protects copying of all linked_ptr objects. -GTEST_API_ GTEST_DECLARE_STATIC_MUTEX_(g_linked_ptr_mutex); - -// This is used internally by all instances of linked_ptr<>. It needs to be -// a non-template class because different types of linked_ptr<> can refer to -// the same object (linked_ptr(obj) vs linked_ptr(obj)). -// So, it needs to be possible for different types of linked_ptr to participate -// in the same circular linked list, so we need a single class type here. -// -// DO NOT USE THIS CLASS DIRECTLY YOURSELF. Use linked_ptr. -class linked_ptr_internal { - public: - // Create a new circle that includes only this instance. - void join_new() { - next_ = this; - } - - // Many linked_ptr operations may change p.link_ for some linked_ptr - // variable p in the same circle as this object. Therefore we need - // to prevent two such operations from occurring concurrently. - // - // Note that different types of linked_ptr objects can coexist in a - // circle (e.g. linked_ptr, linked_ptr, and - // linked_ptr). Therefore we must use a single mutex to - // protect all linked_ptr objects. This can create serious - // contention in production code, but is acceptable in a testing - // framework. - - // Join an existing circle. - void join(linked_ptr_internal const* ptr) - GTEST_LOCK_EXCLUDED_(g_linked_ptr_mutex) { - MutexLock lock(&g_linked_ptr_mutex); - - linked_ptr_internal const* p = ptr; - while (p->next_ != ptr) { - assert(p->next_ != this && - "Trying to join() a linked ring we are already in. " - "Is GMock thread safety enabled?"); - p = p->next_; - } - p->next_ = this; - next_ = ptr; - } - - // Leave whatever circle we're part of. Returns true if we were the - // last member of the circle. Once this is done, you can join() another. - bool depart() - GTEST_LOCK_EXCLUDED_(g_linked_ptr_mutex) { - MutexLock lock(&g_linked_ptr_mutex); - - if (next_ == this) return true; - linked_ptr_internal const* p = next_; - while (p->next_ != this) { - assert(p->next_ != next_ && - "Trying to depart() a linked ring we are not in. " - "Is GMock thread safety enabled?"); - p = p->next_; - } - p->next_ = next_; - return false; - } - - private: - mutable linked_ptr_internal const* next_; -}; - -template -class linked_ptr { - public: - typedef T element_type; - - // Take over ownership of a raw pointer. This should happen as soon as - // possible after the object is created. - explicit linked_ptr(T* ptr = NULL) { capture(ptr); } - ~linked_ptr() { depart(); } - - // Copy an existing linked_ptr<>, adding ourselves to the list of references. - template linked_ptr(linked_ptr const& ptr) { copy(&ptr); } - linked_ptr(linked_ptr const& ptr) { // NOLINT - assert(&ptr != this); - copy(&ptr); - } - - // Assignment releases the old value and acquires the new. - template linked_ptr& operator=(linked_ptr const& ptr) { - depart(); - copy(&ptr); - return *this; - } - - linked_ptr& operator=(linked_ptr const& ptr) { - if (&ptr != this) { - depart(); - copy(&ptr); - } - return *this; - } - - // Smart pointer members. - void reset(T* ptr = NULL) { - depart(); - capture(ptr); - } - T* get() const { return value_; } - T* operator->() const { return value_; } - T& operator*() const { return *value_; } - - bool operator==(T* p) const { return value_ == p; } - bool operator!=(T* p) const { return value_ != p; } - template - bool operator==(linked_ptr const& ptr) const { - return value_ == ptr.get(); - } - template - bool operator!=(linked_ptr const& ptr) const { - return value_ != ptr.get(); - } - - private: - template - friend class linked_ptr; - - T* value_; - linked_ptr_internal link_; - - void depart() { - if (link_.depart()) delete value_; - } - - void capture(T* ptr) { - value_ = ptr; - link_.join_new(); - } - - template void copy(linked_ptr const* ptr) { - value_ = ptr->get(); - if (value_) - link_.join(&ptr->link_); - else - link_.join_new(); - } -}; - -template inline -bool operator==(T* ptr, const linked_ptr& x) { - return ptr == x.get(); -} - -template inline -bool operator!=(T* ptr, const linked_ptr& x) { - return ptr != x.get(); -} - -// A function to convert T* into linked_ptr -// Doing e.g. make_linked_ptr(new FooBarBaz(arg)) is a shorter notation -// for linked_ptr >(new FooBarBaz(arg)) -template -linked_ptr make_linked_ptr(T* ptr) { - return linked_ptr(ptr); -} - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_LINKED_PTR_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h deleted file mode 100644 index 4d1d81d20ff..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h +++ /dev/null @@ -1,5146 +0,0 @@ -// This file was GENERATED by command: -// pump.py gtest-param-util-generated.h.pump -// DO NOT EDIT BY HAND!!! - -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: vladl@google.com (Vlad Losev) - -// Type and function utilities for implementing parameterized tests. -// This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -// Currently Google Test supports at most 50 arguments in Values, -// and at most 10 arguments in Combine. Please contact -// googletestframework@googlegroups.com if you need more. -// Please note that the number of arguments to Combine is limited -// by the maximum arity of the implementation of tuple which is -// currently set at 10. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ - -// scripts/fuse_gtest.py depends on gtest's own header being #included -// *unconditionally*. Therefore these #includes cannot be moved -// inside #if GTEST_HAS_PARAM_TEST. -#include "gtest/internal/gtest-param-util.h" -#include "gtest/internal/gtest-port.h" - -#if GTEST_HAS_PARAM_TEST - -namespace testing { - -// Forward declarations of ValuesIn(), which is implemented in -// include/gtest/gtest-param-test.h. -template -internal::ParamGenerator< - typename ::testing::internal::IteratorTraits::value_type> -ValuesIn(ForwardIterator begin, ForwardIterator end); - -template -internal::ParamGenerator ValuesIn(const T (&array)[N]); - -template -internal::ParamGenerator ValuesIn( - const Container& container); - -namespace internal { - -// Used in the Values() function to provide polymorphic capabilities. -template -class ValueArray1 { - public: - explicit ValueArray1(T1 v1) : v1_(v1) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray1& other); - - const T1 v1_; -}; - -template -class ValueArray2 { - public: - ValueArray2(T1 v1, T2 v2) : v1_(v1), v2_(v2) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray2& other); - - const T1 v1_; - const T2 v2_; -}; - -template -class ValueArray3 { - public: - ValueArray3(T1 v1, T2 v2, T3 v3) : v1_(v1), v2_(v2), v3_(v3) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray3& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; -}; - -template -class ValueArray4 { - public: - ValueArray4(T1 v1, T2 v2, T3 v3, T4 v4) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray4& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; -}; - -template -class ValueArray5 { - public: - ValueArray5(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray5& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; -}; - -template -class ValueArray6 { - public: - ValueArray6(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray6& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; -}; - -template -class ValueArray7 { - public: - ValueArray7(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray7& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; -}; - -template -class ValueArray8 { - public: - ValueArray8(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, - T8 v8) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray8& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; -}; - -template -class ValueArray9 { - public: - ValueArray9(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, - T9 v9) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray9& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; -}; - -template -class ValueArray10 { - public: - ValueArray10(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray10& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; -}; - -template -class ValueArray11 { - public: - ValueArray11(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), - v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray11& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; -}; - -template -class ValueArray12 { - public: - ValueArray12(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), - v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray12& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; -}; - -template -class ValueArray13 { - public: - ValueArray13(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), - v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), - v12_(v12), v13_(v13) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray13& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; -}; - -template -class ValueArray14 { - public: - ValueArray14(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray14& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; -}; - -template -class ValueArray15 { - public: - ValueArray15(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray15& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; -}; - -template -class ValueArray16 { - public: - ValueArray16(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), - v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), - v16_(v16) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray16& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; -}; - -template -class ValueArray17 { - public: - ValueArray17(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, - T17 v17) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray17& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; -}; - -template -class ValueArray18 { - public: - ValueArray18(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray18& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; -}; - -template -class ValueArray19 { - public: - ValueArray19(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), - v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), - v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray19& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; -}; - -template -class ValueArray20 { - public: - ValueArray20(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), - v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), - v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), - v19_(v19), v20_(v20) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray20& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; -}; - -template -class ValueArray21 { - public: - ValueArray21(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), - v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), - v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), - v18_(v18), v19_(v19), v20_(v20), v21_(v21) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray21& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; -}; - -template -class ValueArray22 { - public: - ValueArray22(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray22& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; -}; - -template -class ValueArray23 { - public: - ValueArray23(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray23& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; -}; - -template -class ValueArray24 { - public: - ValueArray24(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), - v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), - v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), - v22_(v22), v23_(v23), v24_(v24) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray24& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; -}; - -template -class ValueArray25 { - public: - ValueArray25(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, - T25 v25) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray25& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; -}; - -template -class ValueArray26 { - public: - ValueArray26(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray26& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; -}; - -template -class ValueArray27 { - public: - ValueArray27(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), - v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), - v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), - v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), - v26_(v26), v27_(v27) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray27& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; -}; - -template -class ValueArray28 { - public: - ValueArray28(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), - v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), - v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), - v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), - v25_(v25), v26_(v26), v27_(v27), v28_(v28) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray28& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; -}; - -template -class ValueArray29 { - public: - ValueArray29(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), - v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), - v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), - v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), - v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), v29_(v29) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray29& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; -}; - -template -class ValueArray30 { - public: - ValueArray30(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray30& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; -}; - -template -class ValueArray31 { - public: - ValueArray31(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30), v31_(v31) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray31& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; -}; - -template -class ValueArray32 { - public: - ValueArray32(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), - v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), - v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), - v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), - v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray32& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; -}; - -template -class ValueArray33 { - public: - ValueArray33(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, - T33 v33) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray33& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; -}; - -template -class ValueArray34 { - public: - ValueArray34(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33), v34_(v34) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray34& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; -}; - -template -class ValueArray35 { - public: - ValueArray35(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), - v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), - v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), - v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), - v26_(v26), v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), - v32_(v32), v33_(v33), v34_(v34), v35_(v35) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray35& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; -}; - -template -class ValueArray36 { - public: - ValueArray36(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), - v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), - v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), - v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), - v25_(v25), v26_(v26), v27_(v27), v28_(v28), v29_(v29), v30_(v30), - v31_(v31), v32_(v32), v33_(v33), v34_(v34), v35_(v35), v36_(v36) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray36& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; -}; - -template -class ValueArray37 { - public: - ValueArray37(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), - v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), - v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), - v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), - v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), v29_(v29), - v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), v35_(v35), - v36_(v36), v37_(v37) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray37& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; -}; - -template -class ValueArray38 { - public: - ValueArray38(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), - v35_(v35), v36_(v36), v37_(v37), v38_(v38) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray38& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; -}; - -template -class ValueArray39 { - public: - ValueArray39(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), - v35_(v35), v36_(v36), v37_(v37), v38_(v38), v39_(v39) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray39& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; -}; - -template -class ValueArray40 { - public: - ValueArray40(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), - v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), - v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), - v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), - v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), - v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), v39_(v39), - v40_(v40) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray40& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; -}; - -template -class ValueArray41 { - public: - ValueArray41(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, - T41 v41) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33), v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), - v39_(v39), v40_(v40), v41_(v41) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray41& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; -}; - -template -class ValueArray42 { - public: - ValueArray42(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33), v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), - v39_(v39), v40_(v40), v41_(v41), v42_(v42) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray42& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; -}; - -template -class ValueArray43 { - public: - ValueArray43(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), - v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), - v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), - v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), - v26_(v26), v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), - v32_(v32), v33_(v33), v34_(v34), v35_(v35), v36_(v36), v37_(v37), - v38_(v38), v39_(v39), v40_(v40), v41_(v41), v42_(v42), v43_(v43) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray43& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; -}; - -template -class ValueArray44 { - public: - ValueArray44(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), - v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), - v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), v18_(v18), - v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), v24_(v24), - v25_(v25), v26_(v26), v27_(v27), v28_(v28), v29_(v29), v30_(v30), - v31_(v31), v32_(v32), v33_(v33), v34_(v34), v35_(v35), v36_(v36), - v37_(v37), v38_(v38), v39_(v39), v40_(v40), v41_(v41), v42_(v42), - v43_(v43), v44_(v44) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray44& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; -}; - -template -class ValueArray45 { - public: - ValueArray45(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), - v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), v11_(v11), - v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), v17_(v17), - v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), v23_(v23), - v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), v29_(v29), - v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), v35_(v35), - v36_(v36), v37_(v37), v38_(v38), v39_(v39), v40_(v40), v41_(v41), - v42_(v42), v43_(v43), v44_(v44), v45_(v45) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray45& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; -}; - -template -class ValueArray46 { - public: - ValueArray46(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45, T46 v46) : v1_(v1), v2_(v2), v3_(v3), - v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), - v35_(v35), v36_(v36), v37_(v37), v38_(v38), v39_(v39), v40_(v40), - v41_(v41), v42_(v42), v43_(v43), v44_(v44), v45_(v45), v46_(v46) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_), static_cast(v46_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray46& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; - const T46 v46_; -}; - -template -class ValueArray47 { - public: - ValueArray47(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47) : v1_(v1), v2_(v2), - v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), v10_(v10), - v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), v16_(v16), - v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), v22_(v22), - v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), v28_(v28), - v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), v34_(v34), - v35_(v35), v36_(v36), v37_(v37), v38_(v38), v39_(v39), v40_(v40), - v41_(v41), v42_(v42), v43_(v43), v44_(v44), v45_(v45), v46_(v46), - v47_(v47) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_), static_cast(v46_), static_cast(v47_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray47& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; - const T46 v46_; - const T47 v47_; -}; - -template -class ValueArray48 { - public: - ValueArray48(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47, T48 v48) : v1_(v1), - v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), v8_(v8), v9_(v9), - v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), v15_(v15), - v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), v21_(v21), - v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), v27_(v27), - v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), v33_(v33), - v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), v39_(v39), - v40_(v40), v41_(v41), v42_(v42), v43_(v43), v44_(v44), v45_(v45), - v46_(v46), v47_(v47), v48_(v48) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_), static_cast(v46_), static_cast(v47_), - static_cast(v48_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray48& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; - const T46 v46_; - const T47 v47_; - const T48 v48_; -}; - -template -class ValueArray49 { - public: - ValueArray49(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47, T48 v48, - T49 v49) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33), v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), - v39_(v39), v40_(v40), v41_(v41), v42_(v42), v43_(v43), v44_(v44), - v45_(v45), v46_(v46), v47_(v47), v48_(v48), v49_(v49) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_), static_cast(v46_), static_cast(v47_), - static_cast(v48_), static_cast(v49_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray49& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; - const T46 v46_; - const T47 v47_; - const T48 v48_; - const T49 v49_; -}; - -template -class ValueArray50 { - public: - ValueArray50(T1 v1, T2 v2, T3 v3, T4 v4, T5 v5, T6 v6, T7 v7, T8 v8, T9 v9, - T10 v10, T11 v11, T12 v12, T13 v13, T14 v14, T15 v15, T16 v16, T17 v17, - T18 v18, T19 v19, T20 v20, T21 v21, T22 v22, T23 v23, T24 v24, T25 v25, - T26 v26, T27 v27, T28 v28, T29 v29, T30 v30, T31 v31, T32 v32, T33 v33, - T34 v34, T35 v35, T36 v36, T37 v37, T38 v38, T39 v39, T40 v40, T41 v41, - T42 v42, T43 v43, T44 v44, T45 v45, T46 v46, T47 v47, T48 v48, T49 v49, - T50 v50) : v1_(v1), v2_(v2), v3_(v3), v4_(v4), v5_(v5), v6_(v6), v7_(v7), - v8_(v8), v9_(v9), v10_(v10), v11_(v11), v12_(v12), v13_(v13), v14_(v14), - v15_(v15), v16_(v16), v17_(v17), v18_(v18), v19_(v19), v20_(v20), - v21_(v21), v22_(v22), v23_(v23), v24_(v24), v25_(v25), v26_(v26), - v27_(v27), v28_(v28), v29_(v29), v30_(v30), v31_(v31), v32_(v32), - v33_(v33), v34_(v34), v35_(v35), v36_(v36), v37_(v37), v38_(v38), - v39_(v39), v40_(v40), v41_(v41), v42_(v42), v43_(v43), v44_(v44), - v45_(v45), v46_(v46), v47_(v47), v48_(v48), v49_(v49), v50_(v50) {} - - template - operator ParamGenerator() const { - const T array[] = {static_cast(v1_), static_cast(v2_), - static_cast(v3_), static_cast(v4_), static_cast(v5_), - static_cast(v6_), static_cast(v7_), static_cast(v8_), - static_cast(v9_), static_cast(v10_), static_cast(v11_), - static_cast(v12_), static_cast(v13_), static_cast(v14_), - static_cast(v15_), static_cast(v16_), static_cast(v17_), - static_cast(v18_), static_cast(v19_), static_cast(v20_), - static_cast(v21_), static_cast(v22_), static_cast(v23_), - static_cast(v24_), static_cast(v25_), static_cast(v26_), - static_cast(v27_), static_cast(v28_), static_cast(v29_), - static_cast(v30_), static_cast(v31_), static_cast(v32_), - static_cast(v33_), static_cast(v34_), static_cast(v35_), - static_cast(v36_), static_cast(v37_), static_cast(v38_), - static_cast(v39_), static_cast(v40_), static_cast(v41_), - static_cast(v42_), static_cast(v43_), static_cast(v44_), - static_cast(v45_), static_cast(v46_), static_cast(v47_), - static_cast(v48_), static_cast(v49_), static_cast(v50_)}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray50& other); - - const T1 v1_; - const T2 v2_; - const T3 v3_; - const T4 v4_; - const T5 v5_; - const T6 v6_; - const T7 v7_; - const T8 v8_; - const T9 v9_; - const T10 v10_; - const T11 v11_; - const T12 v12_; - const T13 v13_; - const T14 v14_; - const T15 v15_; - const T16 v16_; - const T17 v17_; - const T18 v18_; - const T19 v19_; - const T20 v20_; - const T21 v21_; - const T22 v22_; - const T23 v23_; - const T24 v24_; - const T25 v25_; - const T26 v26_; - const T27 v27_; - const T28 v28_; - const T29 v29_; - const T30 v30_; - const T31 v31_; - const T32 v32_; - const T33 v33_; - const T34 v34_; - const T35 v35_; - const T36 v36_; - const T37 v37_; - const T38 v38_; - const T39 v39_; - const T40 v40_; - const T41 v41_; - const T42 v42_; - const T43 v43_; - const T44 v44_; - const T45 v45_; - const T46 v46_; - const T47 v47_; - const T48 v48_; - const T49 v49_; - const T50 v50_; -}; - -# if GTEST_HAS_COMBINE -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Generates values from the Cartesian product of values produced -// by the argument generators. -// -template -class CartesianProductGenerator2 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator2(const ParamGenerator& g1, - const ParamGenerator& g2) - : g1_(g1), g2_(g2) {} - virtual ~CartesianProductGenerator2() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current2_; - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - ParamType current_value_; - }; // class CartesianProductGenerator2::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator2& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; -}; // class CartesianProductGenerator2 - - -template -class CartesianProductGenerator3 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator3(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3) - : g1_(g1), g2_(g2), g3_(g3) {} - virtual ~CartesianProductGenerator3() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current3_; - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - ParamType current_value_; - }; // class CartesianProductGenerator3::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator3& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; -}; // class CartesianProductGenerator3 - - -template -class CartesianProductGenerator4 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator4(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4) {} - virtual ~CartesianProductGenerator4() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current4_; - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - ParamType current_value_; - }; // class CartesianProductGenerator4::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator4& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; -}; // class CartesianProductGenerator4 - - -template -class CartesianProductGenerator5 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator5(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5) {} - virtual ~CartesianProductGenerator5() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current5_; - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - ParamType current_value_; - }; // class CartesianProductGenerator5::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator5& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; -}; // class CartesianProductGenerator5 - - -template -class CartesianProductGenerator6 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator6(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5, - const ParamGenerator& g6) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6) {} - virtual ~CartesianProductGenerator6() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin(), g6_, g6_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end(), g6_, g6_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5, - const ParamGenerator& g6, - const typename ParamGenerator::iterator& current6) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5), - begin6_(g6.begin()), end6_(g6.end()), current6_(current6) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current6_; - if (current6_ == end6_) { - current6_ = begin6_; - ++current5_; - } - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_ && - current6_ == typed_other->current6_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_), - begin6_(other.begin6_), - end6_(other.end6_), - current6_(other.current6_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_, *current6_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_ || - current6_ == end6_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - const typename ParamGenerator::iterator begin6_; - const typename ParamGenerator::iterator end6_; - typename ParamGenerator::iterator current6_; - ParamType current_value_; - }; // class CartesianProductGenerator6::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator6& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; - const ParamGenerator g6_; -}; // class CartesianProductGenerator6 - - -template -class CartesianProductGenerator7 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator7(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5, - const ParamGenerator& g6, const ParamGenerator& g7) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7) {} - virtual ~CartesianProductGenerator7() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin(), g6_, g6_.begin(), g7_, - g7_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end(), g6_, g6_.end(), g7_, g7_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5, - const ParamGenerator& g6, - const typename ParamGenerator::iterator& current6, - const ParamGenerator& g7, - const typename ParamGenerator::iterator& current7) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5), - begin6_(g6.begin()), end6_(g6.end()), current6_(current6), - begin7_(g7.begin()), end7_(g7.end()), current7_(current7) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current7_; - if (current7_ == end7_) { - current7_ = begin7_; - ++current6_; - } - if (current6_ == end6_) { - current6_ = begin6_; - ++current5_; - } - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_ && - current6_ == typed_other->current6_ && - current7_ == typed_other->current7_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_), - begin6_(other.begin6_), - end6_(other.end6_), - current6_(other.current6_), - begin7_(other.begin7_), - end7_(other.end7_), - current7_(other.current7_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_, *current6_, *current7_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_ || - current6_ == end6_ || - current7_ == end7_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - const typename ParamGenerator::iterator begin6_; - const typename ParamGenerator::iterator end6_; - typename ParamGenerator::iterator current6_; - const typename ParamGenerator::iterator begin7_; - const typename ParamGenerator::iterator end7_; - typename ParamGenerator::iterator current7_; - ParamType current_value_; - }; // class CartesianProductGenerator7::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator7& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; - const ParamGenerator g6_; - const ParamGenerator g7_; -}; // class CartesianProductGenerator7 - - -template -class CartesianProductGenerator8 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator8(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5, - const ParamGenerator& g6, const ParamGenerator& g7, - const ParamGenerator& g8) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), - g8_(g8) {} - virtual ~CartesianProductGenerator8() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin(), g6_, g6_.begin(), g7_, - g7_.begin(), g8_, g8_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end(), g6_, g6_.end(), g7_, g7_.end(), g8_, - g8_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5, - const ParamGenerator& g6, - const typename ParamGenerator::iterator& current6, - const ParamGenerator& g7, - const typename ParamGenerator::iterator& current7, - const ParamGenerator& g8, - const typename ParamGenerator::iterator& current8) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5), - begin6_(g6.begin()), end6_(g6.end()), current6_(current6), - begin7_(g7.begin()), end7_(g7.end()), current7_(current7), - begin8_(g8.begin()), end8_(g8.end()), current8_(current8) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current8_; - if (current8_ == end8_) { - current8_ = begin8_; - ++current7_; - } - if (current7_ == end7_) { - current7_ = begin7_; - ++current6_; - } - if (current6_ == end6_) { - current6_ = begin6_; - ++current5_; - } - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_ && - current6_ == typed_other->current6_ && - current7_ == typed_other->current7_ && - current8_ == typed_other->current8_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_), - begin6_(other.begin6_), - end6_(other.end6_), - current6_(other.current6_), - begin7_(other.begin7_), - end7_(other.end7_), - current7_(other.current7_), - begin8_(other.begin8_), - end8_(other.end8_), - current8_(other.current8_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_, *current6_, *current7_, *current8_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_ || - current6_ == end6_ || - current7_ == end7_ || - current8_ == end8_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - const typename ParamGenerator::iterator begin6_; - const typename ParamGenerator::iterator end6_; - typename ParamGenerator::iterator current6_; - const typename ParamGenerator::iterator begin7_; - const typename ParamGenerator::iterator end7_; - typename ParamGenerator::iterator current7_; - const typename ParamGenerator::iterator begin8_; - const typename ParamGenerator::iterator end8_; - typename ParamGenerator::iterator current8_; - ParamType current_value_; - }; // class CartesianProductGenerator8::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator8& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; - const ParamGenerator g6_; - const ParamGenerator g7_; - const ParamGenerator g8_; -}; // class CartesianProductGenerator8 - - -template -class CartesianProductGenerator9 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator9(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5, - const ParamGenerator& g6, const ParamGenerator& g7, - const ParamGenerator& g8, const ParamGenerator& g9) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), g8_(g8), - g9_(g9) {} - virtual ~CartesianProductGenerator9() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin(), g6_, g6_.begin(), g7_, - g7_.begin(), g8_, g8_.begin(), g9_, g9_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end(), g6_, g6_.end(), g7_, g7_.end(), g8_, - g8_.end(), g9_, g9_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5, - const ParamGenerator& g6, - const typename ParamGenerator::iterator& current6, - const ParamGenerator& g7, - const typename ParamGenerator::iterator& current7, - const ParamGenerator& g8, - const typename ParamGenerator::iterator& current8, - const ParamGenerator& g9, - const typename ParamGenerator::iterator& current9) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5), - begin6_(g6.begin()), end6_(g6.end()), current6_(current6), - begin7_(g7.begin()), end7_(g7.end()), current7_(current7), - begin8_(g8.begin()), end8_(g8.end()), current8_(current8), - begin9_(g9.begin()), end9_(g9.end()), current9_(current9) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current9_; - if (current9_ == end9_) { - current9_ = begin9_; - ++current8_; - } - if (current8_ == end8_) { - current8_ = begin8_; - ++current7_; - } - if (current7_ == end7_) { - current7_ = begin7_; - ++current6_; - } - if (current6_ == end6_) { - current6_ = begin6_; - ++current5_; - } - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_ && - current6_ == typed_other->current6_ && - current7_ == typed_other->current7_ && - current8_ == typed_other->current8_ && - current9_ == typed_other->current9_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_), - begin6_(other.begin6_), - end6_(other.end6_), - current6_(other.current6_), - begin7_(other.begin7_), - end7_(other.end7_), - current7_(other.current7_), - begin8_(other.begin8_), - end8_(other.end8_), - current8_(other.current8_), - begin9_(other.begin9_), - end9_(other.end9_), - current9_(other.current9_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_, *current6_, *current7_, *current8_, - *current9_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_ || - current6_ == end6_ || - current7_ == end7_ || - current8_ == end8_ || - current9_ == end9_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - const typename ParamGenerator::iterator begin6_; - const typename ParamGenerator::iterator end6_; - typename ParamGenerator::iterator current6_; - const typename ParamGenerator::iterator begin7_; - const typename ParamGenerator::iterator end7_; - typename ParamGenerator::iterator current7_; - const typename ParamGenerator::iterator begin8_; - const typename ParamGenerator::iterator end8_; - typename ParamGenerator::iterator current8_; - const typename ParamGenerator::iterator begin9_; - const typename ParamGenerator::iterator end9_; - typename ParamGenerator::iterator current9_; - ParamType current_value_; - }; // class CartesianProductGenerator9::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator9& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; - const ParamGenerator g6_; - const ParamGenerator g7_; - const ParamGenerator g8_; - const ParamGenerator g9_; -}; // class CartesianProductGenerator9 - - -template -class CartesianProductGenerator10 - : public ParamGeneratorInterface< ::testing::tuple > { - public: - typedef ::testing::tuple ParamType; - - CartesianProductGenerator10(const ParamGenerator& g1, - const ParamGenerator& g2, const ParamGenerator& g3, - const ParamGenerator& g4, const ParamGenerator& g5, - const ParamGenerator& g6, const ParamGenerator& g7, - const ParamGenerator& g8, const ParamGenerator& g9, - const ParamGenerator& g10) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), g8_(g8), - g9_(g9), g10_(g10) {} - virtual ~CartesianProductGenerator10() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, g1_, g1_.begin(), g2_, g2_.begin(), g3_, - g3_.begin(), g4_, g4_.begin(), g5_, g5_.begin(), g6_, g6_.begin(), g7_, - g7_.begin(), g8_, g8_.begin(), g9_, g9_.begin(), g10_, g10_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, g1_, g1_.end(), g2_, g2_.end(), g3_, g3_.end(), - g4_, g4_.end(), g5_, g5_.end(), g6_, g6_.end(), g7_, g7_.end(), g8_, - g8_.end(), g9_, g9_.end(), g10_, g10_.end()); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - const ParamGenerator& g1, - const typename ParamGenerator::iterator& current1, - const ParamGenerator& g2, - const typename ParamGenerator::iterator& current2, - const ParamGenerator& g3, - const typename ParamGenerator::iterator& current3, - const ParamGenerator& g4, - const typename ParamGenerator::iterator& current4, - const ParamGenerator& g5, - const typename ParamGenerator::iterator& current5, - const ParamGenerator& g6, - const typename ParamGenerator::iterator& current6, - const ParamGenerator& g7, - const typename ParamGenerator::iterator& current7, - const ParamGenerator& g8, - const typename ParamGenerator::iterator& current8, - const ParamGenerator& g9, - const typename ParamGenerator::iterator& current9, - const ParamGenerator& g10, - const typename ParamGenerator::iterator& current10) - : base_(base), - begin1_(g1.begin()), end1_(g1.end()), current1_(current1), - begin2_(g2.begin()), end2_(g2.end()), current2_(current2), - begin3_(g3.begin()), end3_(g3.end()), current3_(current3), - begin4_(g4.begin()), end4_(g4.end()), current4_(current4), - begin5_(g5.begin()), end5_(g5.end()), current5_(current5), - begin6_(g6.begin()), end6_(g6.end()), current6_(current6), - begin7_(g7.begin()), end7_(g7.end()), current7_(current7), - begin8_(g8.begin()), end8_(g8.end()), current8_(current8), - begin9_(g9.begin()), end9_(g9.end()), current9_(current9), - begin10_(g10.begin()), end10_(g10.end()), current10_(current10) { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current10_; - if (current10_ == end10_) { - current10_ = begin10_; - ++current9_; - } - if (current9_ == end9_) { - current9_ = begin9_; - ++current8_; - } - if (current8_ == end8_) { - current8_ = begin8_; - ++current7_; - } - if (current7_ == end7_) { - current7_ = begin7_; - ++current6_; - } - if (current6_ == end6_) { - current6_ = begin6_; - ++current5_; - } - if (current5_ == end5_) { - current5_ = begin5_; - ++current4_; - } - if (current4_ == end4_) { - current4_ = begin4_; - ++current3_; - } - if (current3_ == end3_) { - current3_ = begin3_; - ++current2_; - } - if (current2_ == end2_) { - current2_ = begin2_; - ++current1_; - } - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ( - current1_ == typed_other->current1_ && - current2_ == typed_other->current2_ && - current3_ == typed_other->current3_ && - current4_ == typed_other->current4_ && - current5_ == typed_other->current5_ && - current6_ == typed_other->current6_ && - current7_ == typed_other->current7_ && - current8_ == typed_other->current8_ && - current9_ == typed_other->current9_ && - current10_ == typed_other->current10_); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), - begin1_(other.begin1_), - end1_(other.end1_), - current1_(other.current1_), - begin2_(other.begin2_), - end2_(other.end2_), - current2_(other.current2_), - begin3_(other.begin3_), - end3_(other.end3_), - current3_(other.current3_), - begin4_(other.begin4_), - end4_(other.end4_), - current4_(other.current4_), - begin5_(other.begin5_), - end5_(other.end5_), - current5_(other.current5_), - begin6_(other.begin6_), - end6_(other.end6_), - current6_(other.current6_), - begin7_(other.begin7_), - end7_(other.end7_), - current7_(other.current7_), - begin8_(other.begin8_), - end8_(other.end8_), - current8_(other.current8_), - begin9_(other.begin9_), - end9_(other.end9_), - current9_(other.current9_), - begin10_(other.begin10_), - end10_(other.end10_), - current10_(other.current10_) { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType(*current1_, *current2_, *current3_, - *current4_, *current5_, *current6_, *current7_, *current8_, - *current9_, *current10_); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return - current1_ == end1_ || - current2_ == end2_ || - current3_ == end3_ || - current4_ == end4_ || - current5_ == end5_ || - current6_ == end6_ || - current7_ == end7_ || - current8_ == end8_ || - current9_ == end9_ || - current10_ == end10_; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. - const typename ParamGenerator::iterator begin1_; - const typename ParamGenerator::iterator end1_; - typename ParamGenerator::iterator current1_; - const typename ParamGenerator::iterator begin2_; - const typename ParamGenerator::iterator end2_; - typename ParamGenerator::iterator current2_; - const typename ParamGenerator::iterator begin3_; - const typename ParamGenerator::iterator end3_; - typename ParamGenerator::iterator current3_; - const typename ParamGenerator::iterator begin4_; - const typename ParamGenerator::iterator end4_; - typename ParamGenerator::iterator current4_; - const typename ParamGenerator::iterator begin5_; - const typename ParamGenerator::iterator end5_; - typename ParamGenerator::iterator current5_; - const typename ParamGenerator::iterator begin6_; - const typename ParamGenerator::iterator end6_; - typename ParamGenerator::iterator current6_; - const typename ParamGenerator::iterator begin7_; - const typename ParamGenerator::iterator end7_; - typename ParamGenerator::iterator current7_; - const typename ParamGenerator::iterator begin8_; - const typename ParamGenerator::iterator end8_; - typename ParamGenerator::iterator current8_; - const typename ParamGenerator::iterator begin9_; - const typename ParamGenerator::iterator end9_; - typename ParamGenerator::iterator current9_; - const typename ParamGenerator::iterator begin10_; - const typename ParamGenerator::iterator end10_; - typename ParamGenerator::iterator current10_; - ParamType current_value_; - }; // class CartesianProductGenerator10::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator10& other); - - const ParamGenerator g1_; - const ParamGenerator g2_; - const ParamGenerator g3_; - const ParamGenerator g4_; - const ParamGenerator g5_; - const ParamGenerator g6_; - const ParamGenerator g7_; - const ParamGenerator g8_; - const ParamGenerator g9_; - const ParamGenerator g10_; -}; // class CartesianProductGenerator10 - - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Helper classes providing Combine() with polymorphic features. They allow -// casting CartesianProductGeneratorN to ParamGenerator if T is -// convertible to U. -// -template -class CartesianProductHolder2 { - public: -CartesianProductHolder2(const Generator1& g1, const Generator2& g2) - : g1_(g1), g2_(g2) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator2( - static_cast >(g1_), - static_cast >(g2_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder2& other); - - const Generator1 g1_; - const Generator2 g2_; -}; // class CartesianProductHolder2 - -template -class CartesianProductHolder3 { - public: -CartesianProductHolder3(const Generator1& g1, const Generator2& g2, - const Generator3& g3) - : g1_(g1), g2_(g2), g3_(g3) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator3( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder3& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; -}; // class CartesianProductHolder3 - -template -class CartesianProductHolder4 { - public: -CartesianProductHolder4(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator4( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder4& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; -}; // class CartesianProductHolder4 - -template -class CartesianProductHolder5 { - public: -CartesianProductHolder5(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator5( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder5& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; -}; // class CartesianProductHolder5 - -template -class CartesianProductHolder6 { - public: -CartesianProductHolder6(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5, - const Generator6& g6) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator6( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_), - static_cast >(g6_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder6& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; - const Generator6 g6_; -}; // class CartesianProductHolder6 - -template -class CartesianProductHolder7 { - public: -CartesianProductHolder7(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5, - const Generator6& g6, const Generator7& g7) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator7( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_), - static_cast >(g6_), - static_cast >(g7_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder7& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; - const Generator6 g6_; - const Generator7 g7_; -}; // class CartesianProductHolder7 - -template -class CartesianProductHolder8 { - public: -CartesianProductHolder8(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5, - const Generator6& g6, const Generator7& g7, const Generator8& g8) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), - g8_(g8) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator8( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_), - static_cast >(g6_), - static_cast >(g7_), - static_cast >(g8_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder8& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; - const Generator6 g6_; - const Generator7 g7_; - const Generator8 g8_; -}; // class CartesianProductHolder8 - -template -class CartesianProductHolder9 { - public: -CartesianProductHolder9(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5, - const Generator6& g6, const Generator7& g7, const Generator8& g8, - const Generator9& g9) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), g8_(g8), - g9_(g9) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator9( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_), - static_cast >(g6_), - static_cast >(g7_), - static_cast >(g8_), - static_cast >(g9_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder9& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; - const Generator6 g6_; - const Generator7 g7_; - const Generator8 g8_; - const Generator9 g9_; -}; // class CartesianProductHolder9 - -template -class CartesianProductHolder10 { - public: -CartesianProductHolder10(const Generator1& g1, const Generator2& g2, - const Generator3& g3, const Generator4& g4, const Generator5& g5, - const Generator6& g6, const Generator7& g7, const Generator8& g8, - const Generator9& g9, const Generator10& g10) - : g1_(g1), g2_(g2), g3_(g3), g4_(g4), g5_(g5), g6_(g6), g7_(g7), g8_(g8), - g9_(g9), g10_(g10) {} - template - operator ParamGenerator< ::testing::tuple >() const { - return ParamGenerator< ::testing::tuple >( - new CartesianProductGenerator10( - static_cast >(g1_), - static_cast >(g2_), - static_cast >(g3_), - static_cast >(g4_), - static_cast >(g5_), - static_cast >(g6_), - static_cast >(g7_), - static_cast >(g8_), - static_cast >(g9_), - static_cast >(g10_))); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder10& other); - - const Generator1 g1_; - const Generator2 g2_; - const Generator3 g3_; - const Generator4 g4_; - const Generator5 g5_; - const Generator6 g6_; - const Generator7 g7_; - const Generator8 g8_; - const Generator9 g9_; - const Generator10 g10_; -}; // class CartesianProductHolder10 - -# endif // GTEST_HAS_COMBINE - -} // namespace internal -} // namespace testing - -#endif // GTEST_HAS_PARAM_TEST - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump deleted file mode 100644 index 5c7c47af0bb..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util-generated.h.pump +++ /dev/null @@ -1,286 +0,0 @@ -$$ -*- mode: c++; -*- -$var n = 50 $$ Maximum length of Values arguments we want to support. -$var maxtuple = 10 $$ Maximum number of Combine arguments we want to support. -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: vladl@google.com (Vlad Losev) - -// Type and function utilities for implementing parameterized tests. -// This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -// Currently Google Test supports at most $n arguments in Values, -// and at most $maxtuple arguments in Combine. Please contact -// googletestframework@googlegroups.com if you need more. -// Please note that the number of arguments to Combine is limited -// by the maximum arity of the implementation of tuple which is -// currently set at $maxtuple. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ - -// scripts/fuse_gtest.py depends on gtest's own header being #included -// *unconditionally*. Therefore these #includes cannot be moved -// inside #if GTEST_HAS_PARAM_TEST. -#include "gtest/internal/gtest-param-util.h" -#include "gtest/internal/gtest-port.h" - -#if GTEST_HAS_PARAM_TEST - -namespace testing { - -// Forward declarations of ValuesIn(), which is implemented in -// include/gtest/gtest-param-test.h. -template -internal::ParamGenerator< - typename ::testing::internal::IteratorTraits::value_type> -ValuesIn(ForwardIterator begin, ForwardIterator end); - -template -internal::ParamGenerator ValuesIn(const T (&array)[N]); - -template -internal::ParamGenerator ValuesIn( - const Container& container); - -namespace internal { - -// Used in the Values() function to provide polymorphic capabilities. -$range i 1..n -$for i [[ -$range j 1..i - -template <$for j, [[typename T$j]]> -class ValueArray$i { - public: - $if i==1 [[explicit ]]ValueArray$i($for j, [[T$j v$j]]) : $for j, [[v$(j)_(v$j)]] {} - - template - operator ParamGenerator() const { - const T array[] = {$for j, [[static_cast(v$(j)_)]]}; - return ValuesIn(array); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const ValueArray$i& other); - -$for j [[ - - const T$j v$(j)_; -]] - -}; - -]] - -# if GTEST_HAS_COMBINE -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Generates values from the Cartesian product of values produced -// by the argument generators. -// -$range i 2..maxtuple -$for i [[ -$range j 1..i -$range k 2..i - -template <$for j, [[typename T$j]]> -class CartesianProductGenerator$i - : public ParamGeneratorInterface< ::testing::tuple<$for j, [[T$j]]> > { - public: - typedef ::testing::tuple<$for j, [[T$j]]> ParamType; - - CartesianProductGenerator$i($for j, [[const ParamGenerator& g$j]]) - : $for j, [[g$(j)_(g$j)]] {} - virtual ~CartesianProductGenerator$i() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, $for j, [[g$(j)_, g$(j)_.begin()]]); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, $for j, [[g$(j)_, g$(j)_.end()]]); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, $for j, [[ - - const ParamGenerator& g$j, - const typename ParamGenerator::iterator& current$(j)]]) - : base_(base), -$for j, [[ - - begin$(j)_(g$j.begin()), end$(j)_(g$j.end()), current$(j)_(current$j) -]] { - ComputeCurrentValue(); - } - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - // Advance should not be called on beyond-of-range iterators - // so no component iterators must be beyond end of range, either. - virtual void Advance() { - assert(!AtEnd()); - ++current$(i)_; - -$for k [[ - if (current$(i+2-k)_ == end$(i+2-k)_) { - current$(i+2-k)_ = begin$(i+2-k)_; - ++current$(i+2-k-1)_; - } - -]] - ComputeCurrentValue(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const ParamType* Current() const { return ¤t_value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const Iterator* typed_other = - CheckedDowncastToActualType(&other); - // We must report iterators equal if they both point beyond their - // respective ranges. That can happen in a variety of fashions, - // so we have to consult AtEnd(). - return (AtEnd() && typed_other->AtEnd()) || - ($for j && [[ - - current$(j)_ == typed_other->current$(j)_ -]]); - } - - private: - Iterator(const Iterator& other) - : base_(other.base_), $for j, [[ - - begin$(j)_(other.begin$(j)_), - end$(j)_(other.end$(j)_), - current$(j)_(other.current$(j)_) -]] { - ComputeCurrentValue(); - } - - void ComputeCurrentValue() { - if (!AtEnd()) - current_value_ = ParamType($for j, [[*current$(j)_]]); - } - bool AtEnd() const { - // We must report iterator past the end of the range when either of the - // component iterators has reached the end of its range. - return -$for j || [[ - - current$(j)_ == end$(j)_ -]]; - } - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - // begin[i]_ and end[i]_ define the i-th range that Iterator traverses. - // current[i]_ is the actual traversing iterator. -$for j [[ - - const typename ParamGenerator::iterator begin$(j)_; - const typename ParamGenerator::iterator end$(j)_; - typename ParamGenerator::iterator current$(j)_; -]] - - ParamType current_value_; - }; // class CartesianProductGenerator$i::Iterator - - // No implementation - assignment is unsupported. - void operator=(const CartesianProductGenerator$i& other); - - -$for j [[ - const ParamGenerator g$(j)_; - -]] -}; // class CartesianProductGenerator$i - - -]] - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Helper classes providing Combine() with polymorphic features. They allow -// casting CartesianProductGeneratorN to ParamGenerator if T is -// convertible to U. -// -$range i 2..maxtuple -$for i [[ -$range j 1..i - -template <$for j, [[class Generator$j]]> -class CartesianProductHolder$i { - public: -CartesianProductHolder$i($for j, [[const Generator$j& g$j]]) - : $for j, [[g$(j)_(g$j)]] {} - template <$for j, [[typename T$j]]> - operator ParamGenerator< ::testing::tuple<$for j, [[T$j]]> >() const { - return ParamGenerator< ::testing::tuple<$for j, [[T$j]]> >( - new CartesianProductGenerator$i<$for j, [[T$j]]>( -$for j,[[ - - static_cast >(g$(j)_) -]])); - } - - private: - // No implementation - assignment is unsupported. - void operator=(const CartesianProductHolder$i& other); - - -$for j [[ - const Generator$j g$(j)_; - -]] -}; // class CartesianProductHolder$i - -]] - -# endif // GTEST_HAS_COMBINE - -} // namespace internal -} // namespace testing - -#endif // GTEST_HAS_PARAM_TEST - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_GENERATED_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util.h deleted file mode 100644 index 82cab9b0201..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-param-util.h +++ /dev/null @@ -1,731 +0,0 @@ -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: vladl@google.com (Vlad Losev) - -// Type and function utilities for implementing parameterized tests. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_H_ - -#include - -#include -#include -#include -#include - -// scripts/fuse_gtest.py depends on gtest's own header being #included -// *unconditionally*. Therefore these #includes cannot be moved -// inside #if GTEST_HAS_PARAM_TEST. -#include "gtest/internal/gtest-internal.h" -#include "gtest/internal/gtest-linked_ptr.h" -#include "gtest/internal/gtest-port.h" -#include "gtest/gtest-printers.h" - -#if GTEST_HAS_PARAM_TEST - -namespace testing { - -// Input to a parameterized test name generator, describing a test parameter. -// Consists of the parameter value and the integer parameter index. -template -struct TestParamInfo { - TestParamInfo(const ParamType& a_param, size_t an_index) : - param(a_param), - index(an_index) {} - ParamType param; - size_t index; -}; - -// A builtin parameterized test name generator which returns the result of -// testing::PrintToString. -struct PrintToStringParamName { - template - std::string operator()(const TestParamInfo& info) const { - return PrintToString(info.param); - } -}; - -namespace internal { - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Outputs a message explaining invalid registration of different -// fixture class for the same test case. This may happen when -// TEST_P macro is used to define two tests with the same name -// but in different namespaces. -GTEST_API_ void ReportInvalidTestCaseType(const char* test_case_name, - CodeLocation code_location); - -template class ParamGeneratorInterface; -template class ParamGenerator; - -// Interface for iterating over elements provided by an implementation -// of ParamGeneratorInterface. -template -class ParamIteratorInterface { - public: - virtual ~ParamIteratorInterface() {} - // A pointer to the base generator instance. - // Used only for the purposes of iterator comparison - // to make sure that two iterators belong to the same generator. - virtual const ParamGeneratorInterface* BaseGenerator() const = 0; - // Advances iterator to point to the next element - // provided by the generator. The caller is responsible - // for not calling Advance() on an iterator equal to - // BaseGenerator()->End(). - virtual void Advance() = 0; - // Clones the iterator object. Used for implementing copy semantics - // of ParamIterator. - virtual ParamIteratorInterface* Clone() const = 0; - // Dereferences the current iterator and provides (read-only) access - // to the pointed value. It is the caller's responsibility not to call - // Current() on an iterator equal to BaseGenerator()->End(). - // Used for implementing ParamGenerator::operator*(). - virtual const T* Current() const = 0; - // Determines whether the given iterator and other point to the same - // element in the sequence generated by the generator. - // Used for implementing ParamGenerator::operator==(). - virtual bool Equals(const ParamIteratorInterface& other) const = 0; -}; - -// Class iterating over elements provided by an implementation of -// ParamGeneratorInterface. It wraps ParamIteratorInterface -// and implements the const forward iterator concept. -template -class ParamIterator { - public: - typedef T value_type; - typedef const T& reference; - typedef ptrdiff_t difference_type; - - // ParamIterator assumes ownership of the impl_ pointer. - ParamIterator(const ParamIterator& other) : impl_(other.impl_->Clone()) {} - ParamIterator& operator=(const ParamIterator& other) { - if (this != &other) - impl_.reset(other.impl_->Clone()); - return *this; - } - - const T& operator*() const { return *impl_->Current(); } - const T* operator->() const { return impl_->Current(); } - // Prefix version of operator++. - ParamIterator& operator++() { - impl_->Advance(); - return *this; - } - // Postfix version of operator++. - ParamIterator operator++(int /*unused*/) { - ParamIteratorInterface* clone = impl_->Clone(); - impl_->Advance(); - return ParamIterator(clone); - } - bool operator==(const ParamIterator& other) const { - return impl_.get() == other.impl_.get() || impl_->Equals(*other.impl_); - } - bool operator!=(const ParamIterator& other) const { - return !(*this == other); - } - - private: - friend class ParamGenerator; - explicit ParamIterator(ParamIteratorInterface* impl) : impl_(impl) {} - scoped_ptr > impl_; -}; - -// ParamGeneratorInterface is the binary interface to access generators -// defined in other translation units. -template -class ParamGeneratorInterface { - public: - typedef T ParamType; - - virtual ~ParamGeneratorInterface() {} - - // Generator interface definition - virtual ParamIteratorInterface* Begin() const = 0; - virtual ParamIteratorInterface* End() const = 0; -}; - -// Wraps ParamGeneratorInterface and provides general generator syntax -// compatible with the STL Container concept. -// This class implements copy initialization semantics and the contained -// ParamGeneratorInterface instance is shared among all copies -// of the original object. This is possible because that instance is immutable. -template -class ParamGenerator { - public: - typedef ParamIterator iterator; - - explicit ParamGenerator(ParamGeneratorInterface* impl) : impl_(impl) {} - ParamGenerator(const ParamGenerator& other) : impl_(other.impl_) {} - - ParamGenerator& operator=(const ParamGenerator& other) { - impl_ = other.impl_; - return *this; - } - - iterator begin() const { return iterator(impl_->Begin()); } - iterator end() const { return iterator(impl_->End()); } - - private: - linked_ptr > impl_; -}; - -// Generates values from a range of two comparable values. Can be used to -// generate sequences of user-defined types that implement operator+() and -// operator<(). -// This class is used in the Range() function. -template -class RangeGenerator : public ParamGeneratorInterface { - public: - RangeGenerator(T begin, T end, IncrementT step) - : begin_(begin), end_(end), - step_(step), end_index_(CalculateEndIndex(begin, end, step)) {} - virtual ~RangeGenerator() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, begin_, 0, step_); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, end_, end_index_, step_); - } - - private: - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, T value, int index, - IncrementT step) - : base_(base), value_(value), index_(index), step_(step) {} - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - virtual void Advance() { - value_ = static_cast(value_ + step_); - index_++; - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - virtual const T* Current() const { return &value_; } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - const int other_index = - CheckedDowncastToActualType(&other)->index_; - return index_ == other_index; - } - - private: - Iterator(const Iterator& other) - : ParamIteratorInterface(), - base_(other.base_), value_(other.value_), index_(other.index_), - step_(other.step_) {} - - // No implementation - assignment is unsupported. - void operator=(const Iterator& other); - - const ParamGeneratorInterface* const base_; - T value_; - int index_; - const IncrementT step_; - }; // class RangeGenerator::Iterator - - static int CalculateEndIndex(const T& begin, - const T& end, - const IncrementT& step) { - int end_index = 0; - for (T i = begin; i < end; i = static_cast(i + step)) - end_index++; - return end_index; - } - - // No implementation - assignment is unsupported. - void operator=(const RangeGenerator& other); - - const T begin_; - const T end_; - const IncrementT step_; - // The index for the end() iterator. All the elements in the generated - // sequence are indexed (0-based) to aid iterator comparison. - const int end_index_; -}; // class RangeGenerator - - -// Generates values from a pair of STL-style iterators. Used in the -// ValuesIn() function. The elements are copied from the source range -// since the source can be located on the stack, and the generator -// is likely to persist beyond that stack frame. -template -class ValuesInIteratorRangeGenerator : public ParamGeneratorInterface { - public: - template - ValuesInIteratorRangeGenerator(ForwardIterator begin, ForwardIterator end) - : container_(begin, end) {} - virtual ~ValuesInIteratorRangeGenerator() {} - - virtual ParamIteratorInterface* Begin() const { - return new Iterator(this, container_.begin()); - } - virtual ParamIteratorInterface* End() const { - return new Iterator(this, container_.end()); - } - - private: - typedef typename ::std::vector ContainerType; - - class Iterator : public ParamIteratorInterface { - public: - Iterator(const ParamGeneratorInterface* base, - typename ContainerType::const_iterator iterator) - : base_(base), iterator_(iterator) {} - virtual ~Iterator() {} - - virtual const ParamGeneratorInterface* BaseGenerator() const { - return base_; - } - virtual void Advance() { - ++iterator_; - value_.reset(); - } - virtual ParamIteratorInterface* Clone() const { - return new Iterator(*this); - } - // We need to use cached value referenced by iterator_ because *iterator_ - // can return a temporary object (and of type other then T), so just - // having "return &*iterator_;" doesn't work. - // value_ is updated here and not in Advance() because Advance() - // can advance iterator_ beyond the end of the range, and we cannot - // detect that fact. The client code, on the other hand, is - // responsible for not calling Current() on an out-of-range iterator. - virtual const T* Current() const { - if (value_.get() == NULL) - value_.reset(new T(*iterator_)); - return value_.get(); - } - virtual bool Equals(const ParamIteratorInterface& other) const { - // Having the same base generator guarantees that the other - // iterator is of the same type and we can downcast. - GTEST_CHECK_(BaseGenerator() == other.BaseGenerator()) - << "The program attempted to compare iterators " - << "from different generators." << std::endl; - return iterator_ == - CheckedDowncastToActualType(&other)->iterator_; - } - - private: - Iterator(const Iterator& other) - // The explicit constructor call suppresses a false warning - // emitted by gcc when supplied with the -Wextra option. - : ParamIteratorInterface(), - base_(other.base_), - iterator_(other.iterator_) {} - - const ParamGeneratorInterface* const base_; - typename ContainerType::const_iterator iterator_; - // A cached value of *iterator_. We keep it here to allow access by - // pointer in the wrapping iterator's operator->(). - // value_ needs to be mutable to be accessed in Current(). - // Use of scoped_ptr helps manage cached value's lifetime, - // which is bound by the lifespan of the iterator itself. - mutable scoped_ptr value_; - }; // class ValuesInIteratorRangeGenerator::Iterator - - // No implementation - assignment is unsupported. - void operator=(const ValuesInIteratorRangeGenerator& other); - - const ContainerType container_; -}; // class ValuesInIteratorRangeGenerator - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Default parameterized test name generator, returns a string containing the -// integer test parameter index. -template -std::string DefaultParamName(const TestParamInfo& info) { - Message name_stream; - name_stream << info.index; - return name_stream.GetString(); -} - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Parameterized test name overload helpers, which help the -// INSTANTIATE_TEST_CASE_P macro choose between the default parameterized -// test name generator and user param name generator. -template -ParamNameGenFunctor GetParamNameGen(ParamNameGenFunctor func) { - return func; -} - -template -struct ParamNameGenFunc { - typedef std::string Type(const TestParamInfo&); -}; - -template -typename ParamNameGenFunc::Type *GetParamNameGen() { - return DefaultParamName; -} - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Stores a parameter value and later creates tests parameterized with that -// value. -template -class ParameterizedTestFactory : public TestFactoryBase { - public: - typedef typename TestClass::ParamType ParamType; - explicit ParameterizedTestFactory(ParamType parameter) : - parameter_(parameter) {} - virtual Test* CreateTest() { - TestClass::SetParam(¶meter_); - return new TestClass(); - } - - private: - const ParamType parameter_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ParameterizedTestFactory); -}; - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// TestMetaFactoryBase is a base class for meta-factories that create -// test factories for passing into MakeAndRegisterTestInfo function. -template -class TestMetaFactoryBase { - public: - virtual ~TestMetaFactoryBase() {} - - virtual TestFactoryBase* CreateTestFactory(ParamType parameter) = 0; -}; - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// TestMetaFactory creates test factories for passing into -// MakeAndRegisterTestInfo function. Since MakeAndRegisterTestInfo receives -// ownership of test factory pointer, same factory object cannot be passed -// into that method twice. But ParameterizedTestCaseInfo is going to call -// it for each Test/Parameter value combination. Thus it needs meta factory -// creator class. -template -class TestMetaFactory - : public TestMetaFactoryBase { - public: - typedef typename TestCase::ParamType ParamType; - - TestMetaFactory() {} - - virtual TestFactoryBase* CreateTestFactory(ParamType parameter) { - return new ParameterizedTestFactory(parameter); - } - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(TestMetaFactory); -}; - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// ParameterizedTestCaseInfoBase is a generic interface -// to ParameterizedTestCaseInfo classes. ParameterizedTestCaseInfoBase -// accumulates test information provided by TEST_P macro invocations -// and generators provided by INSTANTIATE_TEST_CASE_P macro invocations -// and uses that information to register all resulting test instances -// in RegisterTests method. The ParameterizeTestCaseRegistry class holds -// a collection of pointers to the ParameterizedTestCaseInfo objects -// and calls RegisterTests() on each of them when asked. -class ParameterizedTestCaseInfoBase { - public: - virtual ~ParameterizedTestCaseInfoBase() {} - - // Base part of test case name for display purposes. - virtual const string& GetTestCaseName() const = 0; - // Test case id to verify identity. - virtual TypeId GetTestCaseTypeId() const = 0; - // UnitTest class invokes this method to register tests in this - // test case right before running them in RUN_ALL_TESTS macro. - // This method should not be called more then once on any single - // instance of a ParameterizedTestCaseInfoBase derived class. - virtual void RegisterTests() = 0; - - protected: - ParameterizedTestCaseInfoBase() {} - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(ParameterizedTestCaseInfoBase); -}; - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// ParameterizedTestCaseInfo accumulates tests obtained from TEST_P -// macro invocations for a particular test case and generators -// obtained from INSTANTIATE_TEST_CASE_P macro invocations for that -// test case. It registers tests with all values generated by all -// generators when asked. -template -class ParameterizedTestCaseInfo : public ParameterizedTestCaseInfoBase { - public: - // ParamType and GeneratorCreationFunc are private types but are required - // for declarations of public methods AddTestPattern() and - // AddTestCaseInstantiation(). - typedef typename TestCase::ParamType ParamType; - // A function that returns an instance of appropriate generator type. - typedef ParamGenerator(GeneratorCreationFunc)(); - typedef typename ParamNameGenFunc::Type ParamNameGeneratorFunc; - - explicit ParameterizedTestCaseInfo( - const char* name, CodeLocation code_location) - : test_case_name_(name), code_location_(code_location) {} - - // Test case base name for display purposes. - virtual const string& GetTestCaseName() const { return test_case_name_; } - // Test case id to verify identity. - virtual TypeId GetTestCaseTypeId() const { return GetTypeId(); } - // TEST_P macro uses AddTestPattern() to record information - // about a single test in a LocalTestInfo structure. - // test_case_name is the base name of the test case (without invocation - // prefix). test_base_name is the name of an individual test without - // parameter index. For the test SequenceA/FooTest.DoBar/1 FooTest is - // test case base name and DoBar is test base name. - void AddTestPattern(const char* test_case_name, - const char* test_base_name, - TestMetaFactoryBase* meta_factory) { - tests_.push_back(linked_ptr(new TestInfo(test_case_name, - test_base_name, - meta_factory))); - } - // INSTANTIATE_TEST_CASE_P macro uses AddGenerator() to record information - // about a generator. - int AddTestCaseInstantiation(const string& instantiation_name, - GeneratorCreationFunc* func, - ParamNameGeneratorFunc* name_func, - const char* file, - int line) { - instantiations_.push_back( - InstantiationInfo(instantiation_name, func, name_func, file, line)); - return 0; // Return value used only to run this method in namespace scope. - } - // UnitTest class invokes this method to register tests in this test case - // test cases right before running tests in RUN_ALL_TESTS macro. - // This method should not be called more then once on any single - // instance of a ParameterizedTestCaseInfoBase derived class. - // UnitTest has a guard to prevent from calling this method more then once. - virtual void RegisterTests() { - for (typename TestInfoContainer::iterator test_it = tests_.begin(); - test_it != tests_.end(); ++test_it) { - linked_ptr test_info = *test_it; - for (typename InstantiationContainer::iterator gen_it = - instantiations_.begin(); gen_it != instantiations_.end(); - ++gen_it) { - const string& instantiation_name = gen_it->name; - ParamGenerator generator((*gen_it->generator)()); - ParamNameGeneratorFunc* name_func = gen_it->name_func; - const char* file = gen_it->file; - int line = gen_it->line; - - string test_case_name; - if ( !instantiation_name.empty() ) - test_case_name = instantiation_name + "/"; - test_case_name += test_info->test_case_base_name; - - size_t i = 0; - std::set test_param_names; - for (typename ParamGenerator::iterator param_it = - generator.begin(); - param_it != generator.end(); ++param_it, ++i) { - Message test_name_stream; - - std::string param_name = name_func( - TestParamInfo(*param_it, i)); - - GTEST_CHECK_(IsValidParamName(param_name)) - << "Parameterized test name '" << param_name - << "' is invalid, in " << file - << " line " << line << std::endl; - - GTEST_CHECK_(test_param_names.count(param_name) == 0) - << "Duplicate parameterized test name '" << param_name - << "', in " << file << " line " << line << std::endl; - - test_param_names.insert(param_name); - - test_name_stream << test_info->test_base_name << "/" << param_name; - MakeAndRegisterTestInfo( - test_case_name.c_str(), - test_name_stream.GetString().c_str(), - NULL, // No type parameter. - PrintToString(*param_it).c_str(), - code_location_, - GetTestCaseTypeId(), - TestCase::SetUpTestCase, - TestCase::TearDownTestCase, - test_info->test_meta_factory->CreateTestFactory(*param_it)); - } // for param_it - } // for gen_it - } // for test_it - } // RegisterTests - - private: - // LocalTestInfo structure keeps information about a single test registered - // with TEST_P macro. - struct TestInfo { - TestInfo(const char* a_test_case_base_name, - const char* a_test_base_name, - TestMetaFactoryBase* a_test_meta_factory) : - test_case_base_name(a_test_case_base_name), - test_base_name(a_test_base_name), - test_meta_factory(a_test_meta_factory) {} - - const string test_case_base_name; - const string test_base_name; - const scoped_ptr > test_meta_factory; - }; - typedef ::std::vector > TestInfoContainer; - // Records data received from INSTANTIATE_TEST_CASE_P macros: - // - struct InstantiationInfo { - InstantiationInfo(const std::string &name_in, - GeneratorCreationFunc* generator_in, - ParamNameGeneratorFunc* name_func_in, - const char* file_in, - int line_in) - : name(name_in), - generator(generator_in), - name_func(name_func_in), - file(file_in), - line(line_in) {} - - std::string name; - GeneratorCreationFunc* generator; - ParamNameGeneratorFunc* name_func; - const char* file; - int line; - }; - typedef ::std::vector InstantiationContainer; - - static bool IsValidParamName(const std::string& name) { - // Check for empty string - if (name.empty()) - return false; - - // Check for invalid characters - for (std::string::size_type index = 0; index < name.size(); ++index) { - if (!isalnum(name[index]) && name[index] != '_') - return false; - } - - return true; - } - - const string test_case_name_; - CodeLocation code_location_; - TestInfoContainer tests_; - InstantiationContainer instantiations_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ParameterizedTestCaseInfo); -}; // class ParameterizedTestCaseInfo - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// ParameterizedTestCaseRegistry contains a map of ParameterizedTestCaseInfoBase -// classes accessed by test case names. TEST_P and INSTANTIATE_TEST_CASE_P -// macros use it to locate their corresponding ParameterizedTestCaseInfo -// descriptors. -class ParameterizedTestCaseRegistry { - public: - ParameterizedTestCaseRegistry() {} - ~ParameterizedTestCaseRegistry() { - for (TestCaseInfoContainer::iterator it = test_case_infos_.begin(); - it != test_case_infos_.end(); ++it) { - delete *it; - } - } - - // Looks up or creates and returns a structure containing information about - // tests and instantiations of a particular test case. - template - ParameterizedTestCaseInfo* GetTestCasePatternHolder( - const char* test_case_name, - CodeLocation code_location) { - ParameterizedTestCaseInfo* typed_test_info = NULL; - for (TestCaseInfoContainer::iterator it = test_case_infos_.begin(); - it != test_case_infos_.end(); ++it) { - if ((*it)->GetTestCaseName() == test_case_name) { - if ((*it)->GetTestCaseTypeId() != GetTypeId()) { - // Complain about incorrect usage of Google Test facilities - // and terminate the program since we cannot guaranty correct - // test case setup and tear-down in this case. - ReportInvalidTestCaseType(test_case_name, code_location); - posix::Abort(); - } else { - // At this point we are sure that the object we found is of the same - // type we are looking for, so we downcast it to that type - // without further checks. - typed_test_info = CheckedDowncastToActualType< - ParameterizedTestCaseInfo >(*it); - } - break; - } - } - if (typed_test_info == NULL) { - typed_test_info = new ParameterizedTestCaseInfo( - test_case_name, code_location); - test_case_infos_.push_back(typed_test_info); - } - return typed_test_info; - } - void RegisterTests() { - for (TestCaseInfoContainer::iterator it = test_case_infos_.begin(); - it != test_case_infos_.end(); ++it) { - (*it)->RegisterTests(); - } - } - - private: - typedef ::std::vector TestCaseInfoContainer; - - TestCaseInfoContainer test_case_infos_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ParameterizedTestCaseRegistry); -}; - -} // namespace internal -} // namespace testing - -#endif // GTEST_HAS_PARAM_TEST - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PARAM_UTIL_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port-arch.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port-arch.h deleted file mode 100644 index 74ab949057c..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port-arch.h +++ /dev/null @@ -1,93 +0,0 @@ -// Copyright 2015, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// The Google C++ Testing Framework (Google Test) -// -// This header file defines the GTEST_OS_* macro. -// It is separate from gtest-port.h so that custom/gtest-port.h can include it. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_ARCH_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_ARCH_H_ - -// Determines the platform on which Google Test is compiled. -#ifdef __CYGWIN__ -# define GTEST_OS_CYGWIN 1 -#elif defined __SYMBIAN32__ -# define GTEST_OS_SYMBIAN 1 -#elif defined _WIN32 -# define GTEST_OS_WINDOWS 1 -# ifdef _WIN32_WCE -# define GTEST_OS_WINDOWS_MOBILE 1 -# elif defined(__MINGW__) || defined(__MINGW32__) -# define GTEST_OS_WINDOWS_MINGW 1 -# elif defined(WINAPI_FAMILY) -# include -# if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) -# define GTEST_OS_WINDOWS_DESKTOP 1 -# elif WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_PHONE_APP) -# define GTEST_OS_WINDOWS_PHONE 1 -# elif WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) -# define GTEST_OS_WINDOWS_RT 1 -# else - // WINAPI_FAMILY defined but no known partition matched. - // Default to desktop. -# define GTEST_OS_WINDOWS_DESKTOP 1 -# endif -# else -# define GTEST_OS_WINDOWS_DESKTOP 1 -# endif // _WIN32_WCE -#elif defined __APPLE__ -# define GTEST_OS_MAC 1 -# if TARGET_OS_IPHONE -# define GTEST_OS_IOS 1 -# endif -#elif defined __FreeBSD__ -# define GTEST_OS_FREEBSD 1 -#elif defined __linux__ -# define GTEST_OS_LINUX 1 -# if defined __ANDROID__ -# define GTEST_OS_LINUX_ANDROID 1 -# endif -#elif defined __MVS__ -# define GTEST_OS_ZOS 1 -#elif defined(__sun) && defined(__SVR4) -# define GTEST_OS_SOLARIS 1 -#elif defined(_AIX) -# define GTEST_OS_AIX 1 -#elif defined(__hpux) -# define GTEST_OS_HPUX 1 -#elif defined __native_client__ -# define GTEST_OS_NACL 1 -#elif defined __OpenBSD__ -# define GTEST_OS_OPENBSD 1 -#elif defined __QNX__ -# define GTEST_OS_QNX 1 -#endif // __CYGWIN__ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_ARCH_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port.h deleted file mode 100644 index 0094ed5077e..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-port.h +++ /dev/null @@ -1,2554 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: wan@google.com (Zhanyong Wan) -// -// Low-level types and utilities for porting Google Test to various -// platforms. All macros ending with _ and symbols defined in an -// internal namespace are subject to change without notice. Code -// outside Google Test MUST NOT USE THEM DIRECTLY. Macros that don't -// end with _ are part of Google Test's public API and can be used by -// code outside Google Test. -// -// This file is fundamental to Google Test. All other Google Test source -// files are expected to #include this. Therefore, it cannot #include -// any other Google Test header. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_H_ - -// Environment-describing macros -// ----------------------------- -// -// Google Test can be used in many different environments. Macros in -// this section tell Google Test what kind of environment it is being -// used in, such that Google Test can provide environment-specific -// features and implementations. -// -// Google Test tries to automatically detect the properties of its -// environment, so users usually don't need to worry about these -// macros. However, the automatic detection is not perfect. -// Sometimes it's necessary for a user to define some of the following -// macros in the build script to override Google Test's decisions. -// -// If the user doesn't define a macro in the list, Google Test will -// provide a default definition. After this header is #included, all -// macros in this list will be defined to either 1 or 0. -// -// Notes to maintainers: -// - Each macro here is a user-tweakable knob; do not grow the list -// lightly. -// - Use #if to key off these macros. Don't use #ifdef or "#if -// defined(...)", which will not work as these macros are ALWAYS -// defined. -// -// GTEST_HAS_CLONE - Define it to 1/0 to indicate that clone(2) -// is/isn't available. -// GTEST_HAS_EXCEPTIONS - Define it to 1/0 to indicate that exceptions -// are enabled. -// GTEST_HAS_GLOBAL_STRING - Define it to 1/0 to indicate that ::string -// is/isn't available (some systems define -// ::string, which is different to std::string). -// GTEST_HAS_GLOBAL_WSTRING - Define it to 1/0 to indicate that ::string -// is/isn't available (some systems define -// ::wstring, which is different to std::wstring). -// GTEST_HAS_POSIX_RE - Define it to 1/0 to indicate that POSIX regular -// expressions are/aren't available. -// GTEST_HAS_PTHREAD - Define it to 1/0 to indicate that -// is/isn't available. -// GTEST_HAS_RTTI - Define it to 1/0 to indicate that RTTI is/isn't -// enabled. -// GTEST_HAS_STD_WSTRING - Define it to 1/0 to indicate that -// std::wstring does/doesn't work (Google Test can -// be used where std::wstring is unavailable). -// GTEST_HAS_TR1_TUPLE - Define it to 1/0 to indicate tr1::tuple -// is/isn't available. -// GTEST_HAS_SEH - Define it to 1/0 to indicate whether the -// compiler supports Microsoft's "Structured -// Exception Handling". -// GTEST_HAS_STREAM_REDIRECTION -// - Define it to 1/0 to indicate whether the -// platform supports I/O stream redirection using -// dup() and dup2(). -// GTEST_USE_OWN_TR1_TUPLE - Define it to 1/0 to indicate whether Google -// Test's own tr1 tuple implementation should be -// used. Unused when the user sets -// GTEST_HAS_TR1_TUPLE to 0. -// GTEST_LANG_CXX11 - Define it to 1/0 to indicate that Google Test -// is building in C++11/C++98 mode. -// GTEST_LINKED_AS_SHARED_LIBRARY -// - Define to 1 when compiling tests that use -// Google Test as a shared library (known as -// DLL on Windows). -// GTEST_CREATE_SHARED_LIBRARY -// - Define to 1 when compiling Google Test itself -// as a shared library. - -// Platform-indicating macros -// -------------------------- -// -// Macros indicating the platform on which Google Test is being used -// (a macro is defined to 1 if compiled on the given platform; -// otherwise UNDEFINED -- it's never defined to 0.). Google Test -// defines these macros automatically. Code outside Google Test MUST -// NOT define them. -// -// GTEST_OS_AIX - IBM AIX -// GTEST_OS_CYGWIN - Cygwin -// GTEST_OS_FREEBSD - FreeBSD -// GTEST_OS_HPUX - HP-UX -// GTEST_OS_LINUX - Linux -// GTEST_OS_LINUX_ANDROID - Google Android -// GTEST_OS_MAC - Mac OS X -// GTEST_OS_IOS - iOS -// GTEST_OS_NACL - Google Native Client (NaCl) -// GTEST_OS_OPENBSD - OpenBSD -// GTEST_OS_QNX - QNX -// GTEST_OS_SOLARIS - Sun Solaris -// GTEST_OS_SYMBIAN - Symbian -// GTEST_OS_WINDOWS - Windows (Desktop, MinGW, or Mobile) -// GTEST_OS_WINDOWS_DESKTOP - Windows Desktop -// GTEST_OS_WINDOWS_MINGW - MinGW -// GTEST_OS_WINDOWS_MOBILE - Windows Mobile -// GTEST_OS_WINDOWS_PHONE - Windows Phone -// GTEST_OS_WINDOWS_RT - Windows Store App/WinRT -// GTEST_OS_ZOS - z/OS -// -// Among the platforms, Cygwin, Linux, Max OS X, and Windows have the -// most stable support. Since core members of the Google Test project -// don't have access to other platforms, support for them may be less -// stable. If you notice any problems on your platform, please notify -// googletestframework@googlegroups.com (patches for fixing them are -// even more welcome!). -// -// It is possible that none of the GTEST_OS_* macros are defined. - -// Feature-indicating macros -// ------------------------- -// -// Macros indicating which Google Test features are available (a macro -// is defined to 1 if the corresponding feature is supported; -// otherwise UNDEFINED -- it's never defined to 0.). Google Test -// defines these macros automatically. Code outside Google Test MUST -// NOT define them. -// -// These macros are public so that portable tests can be written. -// Such tests typically surround code using a feature with an #if -// which controls that code. For example: -// -// #if GTEST_HAS_DEATH_TEST -// EXPECT_DEATH(DoSomethingDeadly()); -// #endif -// -// GTEST_HAS_COMBINE - the Combine() function (for value-parameterized -// tests) -// GTEST_HAS_DEATH_TEST - death tests -// GTEST_HAS_PARAM_TEST - value-parameterized tests -// GTEST_HAS_TYPED_TEST - typed tests -// GTEST_HAS_TYPED_TEST_P - type-parameterized tests -// GTEST_IS_THREADSAFE - Google Test is thread-safe. -// GTEST_USES_POSIX_RE - enhanced POSIX regex is used. Do not confuse with -// GTEST_HAS_POSIX_RE (see above) which users can -// define themselves. -// GTEST_USES_SIMPLE_RE - our own simple regex is used; -// the above two are mutually exclusive. -// GTEST_CAN_COMPARE_NULL - accepts untyped NULL in EXPECT_EQ(). - -// Misc public macros -// ------------------ -// -// GTEST_FLAG(flag_name) - references the variable corresponding to -// the given Google Test flag. - -// Internal utilities -// ------------------ -// -// The following macros and utilities are for Google Test's INTERNAL -// use only. Code outside Google Test MUST NOT USE THEM DIRECTLY. -// -// Macros for basic C++ coding: -// GTEST_AMBIGUOUS_ELSE_BLOCKER_ - for disabling a gcc warning. -// GTEST_ATTRIBUTE_UNUSED_ - declares that a class' instances or a -// variable don't have to be used. -// GTEST_DISALLOW_ASSIGN_ - disables operator=. -// GTEST_DISALLOW_COPY_AND_ASSIGN_ - disables copy ctor and operator=. -// GTEST_MUST_USE_RESULT_ - declares that a function's result must be used. -// GTEST_INTENTIONAL_CONST_COND_PUSH_ - start code section where MSVC C4127 is -// suppressed (constant conditional). -// GTEST_INTENTIONAL_CONST_COND_POP_ - finish code section where MSVC C4127 -// is suppressed. -// -// C++11 feature wrappers: -// -// testing::internal::move - portability wrapper for std::move. -// -// Synchronization: -// Mutex, MutexLock, ThreadLocal, GetThreadCount() -// - synchronization primitives. -// -// Template meta programming: -// is_pointer - as in TR1; needed on Symbian and IBM XL C/C++ only. -// IteratorTraits - partial implementation of std::iterator_traits, which -// is not available in libCstd when compiled with Sun C++. -// -// Smart pointers: -// scoped_ptr - as in TR2. -// -// Regular expressions: -// RE - a simple regular expression class using the POSIX -// Extended Regular Expression syntax on UNIX-like -// platforms, or a reduced regular exception syntax on -// other platforms, including Windows. -// -// Logging: -// GTEST_LOG_() - logs messages at the specified severity level. -// LogToStderr() - directs all log messages to stderr. -// FlushInfoLog() - flushes informational log messages. -// -// Stdout and stderr capturing: -// CaptureStdout() - starts capturing stdout. -// GetCapturedStdout() - stops capturing stdout and returns the captured -// string. -// CaptureStderr() - starts capturing stderr. -// GetCapturedStderr() - stops capturing stderr and returns the captured -// string. -// -// Integer types: -// TypeWithSize - maps an integer to a int type. -// Int32, UInt32, Int64, UInt64, TimeInMillis -// - integers of known sizes. -// BiggestInt - the biggest signed integer type. -// -// Command-line utilities: -// GTEST_DECLARE_*() - declares a flag. -// GTEST_DEFINE_*() - defines a flag. -// GetInjectableArgvs() - returns the command line as a vector of strings. -// -// Environment variable utilities: -// GetEnv() - gets the value of an environment variable. -// BoolFromGTestEnv() - parses a bool environment variable. -// Int32FromGTestEnv() - parses an Int32 environment variable. -// StringFromGTestEnv() - parses a string environment variable. - -#include // for isspace, etc -#include // for ptrdiff_t -#include -#include -#include -#ifndef _WIN32_WCE -# include -# include -#endif // !_WIN32_WCE - -#if defined __APPLE__ -# include -# include -#endif - -#include // NOLINT -#include // NOLINT -#include // NOLINT -#include // NOLINT -#include -#include // NOLINT - -#include "gtest/internal/gtest-port-arch.h" -#include "gtest/internal/custom/gtest-port.h" - -#if !defined(GTEST_DEV_EMAIL_) -# define GTEST_DEV_EMAIL_ "googletestframework@@googlegroups.com" -# define GTEST_FLAG_PREFIX_ "gtest_" -# define GTEST_FLAG_PREFIX_DASH_ "gtest-" -# define GTEST_FLAG_PREFIX_UPPER_ "GTEST_" -# define GTEST_NAME_ "Google Test" -# define GTEST_PROJECT_URL_ "https://github.com/google/googletest/" -#endif // !defined(GTEST_DEV_EMAIL_) - -#if !defined(GTEST_INIT_GOOGLE_TEST_NAME_) -# define GTEST_INIT_GOOGLE_TEST_NAME_ "testing::InitGoogleTest" -#endif // !defined(GTEST_INIT_GOOGLE_TEST_NAME_) - -// Determines the version of gcc that is used to compile this. -#ifdef __GNUC__ -// 40302 means version 4.3.2. -# define GTEST_GCC_VER_ \ - (__GNUC__*10000 + __GNUC_MINOR__*100 + __GNUC_PATCHLEVEL__) -#endif // __GNUC__ - -// Macros for disabling Microsoft Visual C++ warnings. -// -// GTEST_DISABLE_MSC_WARNINGS_PUSH_(4800 4385) -// /* code that triggers warnings C4800 and C4385 */ -// GTEST_DISABLE_MSC_WARNINGS_POP_() -#if _MSC_VER >= 1500 -# define GTEST_DISABLE_MSC_WARNINGS_PUSH_(warnings) \ - __pragma(warning(push)) \ - __pragma(warning(disable: warnings)) -# define GTEST_DISABLE_MSC_WARNINGS_POP_() \ - __pragma(warning(pop)) -#else -// Older versions of MSVC don't have __pragma. -# define GTEST_DISABLE_MSC_WARNINGS_PUSH_(warnings) -# define GTEST_DISABLE_MSC_WARNINGS_POP_() -#endif - -#ifndef GTEST_LANG_CXX11 -// gcc and clang define __GXX_EXPERIMENTAL_CXX0X__ when -// -std={c,gnu}++{0x,11} is passed. The C++11 standard specifies a -// value for __cplusplus, and recent versions of clang, gcc, and -// probably other compilers set that too in C++11 mode. -# if __GXX_EXPERIMENTAL_CXX0X__ || __cplusplus >= 201103L -// Compiling in at least C++11 mode. -# define GTEST_LANG_CXX11 1 -# else -# define GTEST_LANG_CXX11 0 -# endif -#endif - -// Distinct from C++11 language support, some environments don't provide -// proper C++11 library support. Notably, it's possible to build in -// C++11 mode when targeting Mac OS X 10.6, which has an old libstdc++ -// with no C++11 support. -// -// libstdc++ has sufficient C++11 support as of GCC 4.6.0, __GLIBCXX__ -// 20110325, but maintenance releases in the 4.4 and 4.5 series followed -// this date, so check for those versions by their date stamps. -// https://gcc.gnu.org/onlinedocs/libstdc++/manual/abi.html#abi.versioning -#if GTEST_LANG_CXX11 && \ - (!defined(__GLIBCXX__) || ( \ - __GLIBCXX__ >= 20110325ul && /* GCC >= 4.6.0 */ \ - /* Blacklist of patch releases of older branches: */ \ - __GLIBCXX__ != 20110416ul && /* GCC 4.4.6 */ \ - __GLIBCXX__ != 20120313ul && /* GCC 4.4.7 */ \ - __GLIBCXX__ != 20110428ul && /* GCC 4.5.3 */ \ - __GLIBCXX__ != 20120702ul)) /* GCC 4.5.4 */ -# define GTEST_STDLIB_CXX11 1 -#endif - -// Only use C++11 library features if the library provides them. -#if GTEST_STDLIB_CXX11 -# define GTEST_HAS_STD_BEGIN_AND_END_ 1 -# define GTEST_HAS_STD_FORWARD_LIST_ 1 -# define GTEST_HAS_STD_FUNCTION_ 1 -# define GTEST_HAS_STD_INITIALIZER_LIST_ 1 -# define GTEST_HAS_STD_MOVE_ 1 -# define GTEST_HAS_STD_SHARED_PTR_ 1 -# define GTEST_HAS_STD_TYPE_TRAITS_ 1 -# define GTEST_HAS_STD_UNIQUE_PTR_ 1 -#endif - -// C++11 specifies that provides std::tuple. -// Some platforms still might not have it, however. -#if GTEST_LANG_CXX11 -# define GTEST_HAS_STD_TUPLE_ 1 -# if defined(__clang__) -// Inspired by http://clang.llvm.org/docs/LanguageExtensions.html#__has_include -# if defined(__has_include) && !__has_include() -# undef GTEST_HAS_STD_TUPLE_ -# endif -# elif defined(_MSC_VER) -// Inspired by boost/config/stdlib/dinkumware.hpp -# if defined(_CPPLIB_VER) && _CPPLIB_VER < 520 -# undef GTEST_HAS_STD_TUPLE_ -# endif -# elif defined(__GLIBCXX__) -// Inspired by boost/config/stdlib/libstdcpp3.hpp, -// http://gcc.gnu.org/gcc-4.2/changes.html and -// http://gcc.gnu.org/onlinedocs/libstdc++/manual/bk01pt01ch01.html#manual.intro.status.standard.200x -# if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 2) -# undef GTEST_HAS_STD_TUPLE_ -# endif -# endif -#endif - -// Brings in definitions for functions used in the testing::internal::posix -// namespace (read, write, close, chdir, isatty, stat). We do not currently -// use them on Windows Mobile. -#if GTEST_OS_WINDOWS -# if !GTEST_OS_WINDOWS_MOBILE -# include -# include -# endif -// In order to avoid having to include , use forward declaration -// assuming CRITICAL_SECTION is a typedef of _RTL_CRITICAL_SECTION. -// This assumption is verified by -// WindowsTypesTest.CRITICAL_SECTIONIs_RTL_CRITICAL_SECTION. -struct _RTL_CRITICAL_SECTION; -#else -// This assumes that non-Windows OSes provide unistd.h. For OSes where this -// is not the case, we need to include headers that provide the functions -// mentioned above. -# include -# include -#endif // GTEST_OS_WINDOWS - -#if GTEST_OS_LINUX_ANDROID -// Used to define __ANDROID_API__ matching the target NDK API level. -# include // NOLINT -#endif - -// Defines this to true iff Google Test can use POSIX regular expressions. -#ifndef GTEST_HAS_POSIX_RE -# if GTEST_OS_LINUX_ANDROID -// On Android, is only available starting with Gingerbread. -# define GTEST_HAS_POSIX_RE (__ANDROID_API__ >= 9) -# else -# define GTEST_HAS_POSIX_RE (!GTEST_OS_WINDOWS) -# endif -#endif - -#if GTEST_USES_PCRE -// The appropriate headers have already been included. - -#elif GTEST_HAS_POSIX_RE - -// On some platforms, needs someone to define size_t, and -// won't compile otherwise. We can #include it here as we already -// included , which is guaranteed to define size_t through -// . -# include // NOLINT - -# define GTEST_USES_POSIX_RE 1 - -#elif GTEST_OS_WINDOWS - -// is not available on Windows. Use our own simple regex -// implementation instead. -# define GTEST_USES_SIMPLE_RE 1 - -#else - -// may not be available on this platform. Use our own -// simple regex implementation instead. -# define GTEST_USES_SIMPLE_RE 1 - -#endif // GTEST_USES_PCRE - -#ifndef GTEST_HAS_EXCEPTIONS -// The user didn't tell us whether exceptions are enabled, so we need -// to figure it out. -# if defined(_MSC_VER) || defined(__BORLANDC__) -// MSVC's and C++Builder's implementations of the STL use the _HAS_EXCEPTIONS -// macro to enable exceptions, so we'll do the same. -// Assumes that exceptions are enabled by default. -# ifndef _HAS_EXCEPTIONS -# define _HAS_EXCEPTIONS 1 -# endif // _HAS_EXCEPTIONS -# define GTEST_HAS_EXCEPTIONS _HAS_EXCEPTIONS -# elif defined(__clang__) -// clang defines __EXCEPTIONS iff exceptions are enabled before clang 220714, -// but iff cleanups are enabled after that. In Obj-C++ files, there can be -// cleanups for ObjC exceptions which also need cleanups, even if C++ exceptions -// are disabled. clang has __has_feature(cxx_exceptions) which checks for C++ -// exceptions starting at clang r206352, but which checked for cleanups prior to -// that. To reliably check for C++ exception availability with clang, check for -// __EXCEPTIONS && __has_feature(cxx_exceptions). -# define GTEST_HAS_EXCEPTIONS (__EXCEPTIONS && __has_feature(cxx_exceptions)) -# elif defined(__GNUC__) && __EXCEPTIONS -// gcc defines __EXCEPTIONS to 1 iff exceptions are enabled. -# define GTEST_HAS_EXCEPTIONS 1 -# elif defined(__SUNPRO_CC) -// Sun Pro CC supports exceptions. However, there is no compile-time way of -// detecting whether they are enabled or not. Therefore, we assume that -// they are enabled unless the user tells us otherwise. -# define GTEST_HAS_EXCEPTIONS 1 -# elif defined(__IBMCPP__) && __EXCEPTIONS -// xlC defines __EXCEPTIONS to 1 iff exceptions are enabled. -# define GTEST_HAS_EXCEPTIONS 1 -# elif defined(__HP_aCC) -// Exception handling is in effect by default in HP aCC compiler. It has to -// be turned of by +noeh compiler option if desired. -# define GTEST_HAS_EXCEPTIONS 1 -# else -// For other compilers, we assume exceptions are disabled to be -// conservative. -# define GTEST_HAS_EXCEPTIONS 0 -# endif // defined(_MSC_VER) || defined(__BORLANDC__) -#endif // GTEST_HAS_EXCEPTIONS - -#if !defined(GTEST_HAS_STD_STRING) -// Even though we don't use this macro any longer, we keep it in case -// some clients still depend on it. -# define GTEST_HAS_STD_STRING 1 -#elif !GTEST_HAS_STD_STRING -// The user told us that ::std::string isn't available. -# error "Google Test cannot be used where ::std::string isn't available." -#endif // !defined(GTEST_HAS_STD_STRING) - -#ifndef GTEST_HAS_GLOBAL_STRING -// The user didn't tell us whether ::string is available, so we need -// to figure it out. - -# define GTEST_HAS_GLOBAL_STRING 0 - -#endif // GTEST_HAS_GLOBAL_STRING - -#ifndef GTEST_HAS_STD_WSTRING -// The user didn't tell us whether ::std::wstring is available, so we need -// to figure it out. -// TODO(wan@google.com): uses autoconf to detect whether ::std::wstring -// is available. - -// Cygwin 1.7 and below doesn't support ::std::wstring. -// Solaris' libc++ doesn't support it either. Android has -// no support for it at least as recent as Froyo (2.2). -# define GTEST_HAS_STD_WSTRING \ - (!(GTEST_OS_LINUX_ANDROID || GTEST_OS_CYGWIN || GTEST_OS_SOLARIS)) - -#endif // GTEST_HAS_STD_WSTRING - -#ifndef GTEST_HAS_GLOBAL_WSTRING -// The user didn't tell us whether ::wstring is available, so we need -// to figure it out. -# define GTEST_HAS_GLOBAL_WSTRING \ - (GTEST_HAS_STD_WSTRING && GTEST_HAS_GLOBAL_STRING) -#endif // GTEST_HAS_GLOBAL_WSTRING - -// Determines whether RTTI is available. -#ifndef GTEST_HAS_RTTI -// The user didn't tell us whether RTTI is enabled, so we need to -// figure it out. - -# ifdef _MSC_VER - -# ifdef _CPPRTTI // MSVC defines this macro iff RTTI is enabled. -# define GTEST_HAS_RTTI 1 -# else -# define GTEST_HAS_RTTI 0 -# endif - -// Starting with version 4.3.2, gcc defines __GXX_RTTI iff RTTI is enabled. -# elif defined(__GNUC__) && (GTEST_GCC_VER_ >= 40302) - -# ifdef __GXX_RTTI -// When building against STLport with the Android NDK and with -// -frtti -fno-exceptions, the build fails at link time with undefined -// references to __cxa_bad_typeid. Note sure if STL or toolchain bug, -// so disable RTTI when detected. -# if GTEST_OS_LINUX_ANDROID && defined(_STLPORT_MAJOR) && \ - !defined(__EXCEPTIONS) -# define GTEST_HAS_RTTI 0 -# else -# define GTEST_HAS_RTTI 1 -# endif // GTEST_OS_LINUX_ANDROID && __STLPORT_MAJOR && !__EXCEPTIONS -# else -# define GTEST_HAS_RTTI 0 -# endif // __GXX_RTTI - -// Clang defines __GXX_RTTI starting with version 3.0, but its manual recommends -// using has_feature instead. has_feature(cxx_rtti) is supported since 2.7, the -// first version with C++ support. -# elif defined(__clang__) - -# define GTEST_HAS_RTTI __has_feature(cxx_rtti) - -// Starting with version 9.0 IBM Visual Age defines __RTTI_ALL__ to 1 if -// both the typeid and dynamic_cast features are present. -# elif defined(__IBMCPP__) && (__IBMCPP__ >= 900) - -# ifdef __RTTI_ALL__ -# define GTEST_HAS_RTTI 1 -# else -# define GTEST_HAS_RTTI 0 -# endif - -# else - -// For all other compilers, we assume RTTI is enabled. -# define GTEST_HAS_RTTI 1 - -# endif // _MSC_VER - -#endif // GTEST_HAS_RTTI - -// It's this header's responsibility to #include when RTTI -// is enabled. -#if GTEST_HAS_RTTI -# include -#endif - -// Determines whether Google Test can use the pthreads library. -#ifndef GTEST_HAS_PTHREAD -// The user didn't tell us explicitly, so we make reasonable assumptions about -// which platforms have pthreads support. -// -// To disable threading support in Google Test, add -DGTEST_HAS_PTHREAD=0 -// to your compiler flags. -# define GTEST_HAS_PTHREAD (GTEST_OS_LINUX || GTEST_OS_MAC || GTEST_OS_HPUX \ - || GTEST_OS_QNX || GTEST_OS_FREEBSD || GTEST_OS_NACL) -#endif // GTEST_HAS_PTHREAD - -#if GTEST_HAS_PTHREAD -// gtest-port.h guarantees to #include when GTEST_HAS_PTHREAD is -// true. -# include // NOLINT - -// For timespec and nanosleep, used below. -# include // NOLINT -#endif - -// Determines if hash_map/hash_set are available. -// Only used for testing against those containers. -#if !defined(GTEST_HAS_HASH_MAP_) -# if _MSC_VER -# define GTEST_HAS_HASH_MAP_ 1 // Indicates that hash_map is available. -# define GTEST_HAS_HASH_SET_ 1 // Indicates that hash_set is available. -# endif // _MSC_VER -#endif // !defined(GTEST_HAS_HASH_MAP_) - -// Determines whether Google Test can use tr1/tuple. You can define -// this macro to 0 to prevent Google Test from using tuple (any -// feature depending on tuple with be disabled in this mode). -#ifndef GTEST_HAS_TR1_TUPLE -# if GTEST_OS_LINUX_ANDROID && defined(_STLPORT_MAJOR) -// STLport, provided with the Android NDK, has neither or . -# define GTEST_HAS_TR1_TUPLE 0 -# else -// The user didn't tell us not to do it, so we assume it's OK. -# define GTEST_HAS_TR1_TUPLE 1 -# endif -#endif // GTEST_HAS_TR1_TUPLE - -// Determines whether Google Test's own tr1 tuple implementation -// should be used. -#ifndef GTEST_USE_OWN_TR1_TUPLE -// The user didn't tell us, so we need to figure it out. - -// We use our own TR1 tuple if we aren't sure the user has an -// implementation of it already. At this time, libstdc++ 4.0.0+ and -// MSVC 2010 are the only mainstream standard libraries that come -// with a TR1 tuple implementation. NVIDIA's CUDA NVCC compiler -// pretends to be GCC by defining __GNUC__ and friends, but cannot -// compile GCC's tuple implementation. MSVC 2008 (9.0) provides TR1 -// tuple in a 323 MB Feature Pack download, which we cannot assume the -// user has. QNX's QCC compiler is a modified GCC but it doesn't -// support TR1 tuple. libc++ only provides std::tuple, in C++11 mode, -// and it can be used with some compilers that define __GNUC__. -# if (defined(__GNUC__) && !defined(__CUDACC__) && (GTEST_GCC_VER_ >= 40000) \ - && !GTEST_OS_QNX && !defined(_LIBCPP_VERSION)) || _MSC_VER >= 1600 -# define GTEST_ENV_HAS_TR1_TUPLE_ 1 -# endif - -// C++11 specifies that provides std::tuple. Use that if gtest is used -// in C++11 mode and libstdc++ isn't very old (binaries targeting OS X 10.6 -// can build with clang but need to use gcc4.2's libstdc++). -# if GTEST_LANG_CXX11 && (!defined(__GLIBCXX__) || __GLIBCXX__ > 20110325) -# define GTEST_ENV_HAS_STD_TUPLE_ 1 -# endif - -# if GTEST_ENV_HAS_TR1_TUPLE_ || GTEST_ENV_HAS_STD_TUPLE_ -# define GTEST_USE_OWN_TR1_TUPLE 0 -# else -# define GTEST_USE_OWN_TR1_TUPLE 1 -# endif - -#endif // GTEST_USE_OWN_TR1_TUPLE - -// To avoid conditional compilation everywhere, we make it -// gtest-port.h's responsibility to #include the header implementing -// tuple. -#if GTEST_HAS_STD_TUPLE_ -# include // IWYU pragma: export -# define GTEST_TUPLE_NAMESPACE_ ::std -#endif // GTEST_HAS_STD_TUPLE_ - -// We include tr1::tuple even if std::tuple is available to define printers for -// them. -#if GTEST_HAS_TR1_TUPLE -# ifndef GTEST_TUPLE_NAMESPACE_ -# define GTEST_TUPLE_NAMESPACE_ ::std::tr1 -# endif // GTEST_TUPLE_NAMESPACE_ - -# if GTEST_USE_OWN_TR1_TUPLE -# include "gtest/internal/gtest-tuple.h" // IWYU pragma: export // NOLINT -# elif GTEST_ENV_HAS_STD_TUPLE_ -# include -// C++11 puts its tuple into the ::std namespace rather than -// ::std::tr1. gtest expects tuple to live in ::std::tr1, so put it there. -// This causes undefined behavior, but supported compilers react in -// the way we intend. -namespace std { -namespace tr1 { -using ::std::get; -using ::std::make_tuple; -using ::std::tuple; -using ::std::tuple_element; -using ::std::tuple_size; -} -} - -# elif GTEST_OS_SYMBIAN - -// On Symbian, BOOST_HAS_TR1_TUPLE causes Boost's TR1 tuple library to -// use STLport's tuple implementation, which unfortunately doesn't -// work as the copy of STLport distributed with Symbian is incomplete. -// By making sure BOOST_HAS_TR1_TUPLE is undefined, we force Boost to -// use its own tuple implementation. -# ifdef BOOST_HAS_TR1_TUPLE -# undef BOOST_HAS_TR1_TUPLE -# endif // BOOST_HAS_TR1_TUPLE - -// This prevents , which defines -// BOOST_HAS_TR1_TUPLE, from being #included by Boost's . -# define BOOST_TR1_DETAIL_CONFIG_HPP_INCLUDED -# include // IWYU pragma: export // NOLINT - -# elif defined(__GNUC__) && (GTEST_GCC_VER_ >= 40000) -// GCC 4.0+ implements tr1/tuple in the header. This does -// not conform to the TR1 spec, which requires the header to be . - -# if !GTEST_HAS_RTTI && GTEST_GCC_VER_ < 40302 -// Until version 4.3.2, gcc has a bug that causes , -// which is #included by , to not compile when RTTI is -// disabled. _TR1_FUNCTIONAL is the header guard for -// . Hence the following #define is a hack to prevent -// from being included. -# define _TR1_FUNCTIONAL 1 -# include -# undef _TR1_FUNCTIONAL // Allows the user to #include - // if he chooses to. -# else -# include // NOLINT -# endif // !GTEST_HAS_RTTI && GTEST_GCC_VER_ < 40302 - -# else -// If the compiler is not GCC 4.0+, we assume the user is using a -// spec-conforming TR1 implementation. -# include // IWYU pragma: export // NOLINT -# endif // GTEST_USE_OWN_TR1_TUPLE - -#endif // GTEST_HAS_TR1_TUPLE - -// Determines whether clone(2) is supported. -// Usually it will only be available on Linux, excluding -// Linux on the Itanium architecture. -// Also see http://linux.die.net/man/2/clone. -#ifndef GTEST_HAS_CLONE -// The user didn't tell us, so we need to figure it out. - -# if GTEST_OS_LINUX && !defined(__ia64__) -# if GTEST_OS_LINUX_ANDROID -// On Android, clone() is only available on ARM starting with Gingerbread. -# if defined(__arm__) && __ANDROID_API__ >= 9 -# define GTEST_HAS_CLONE 1 -# else -# define GTEST_HAS_CLONE 0 -# endif -# else -# define GTEST_HAS_CLONE 1 -# endif -# else -# define GTEST_HAS_CLONE 0 -# endif // GTEST_OS_LINUX && !defined(__ia64__) - -#endif // GTEST_HAS_CLONE - -// Determines whether to support stream redirection. This is used to test -// output correctness and to implement death tests. -#ifndef GTEST_HAS_STREAM_REDIRECTION -// By default, we assume that stream redirection is supported on all -// platforms except known mobile ones. -# if GTEST_OS_WINDOWS_MOBILE || GTEST_OS_SYMBIAN || \ - GTEST_OS_WINDOWS_PHONE || GTEST_OS_WINDOWS_RT -# define GTEST_HAS_STREAM_REDIRECTION 0 -# else -# define GTEST_HAS_STREAM_REDIRECTION 1 -# endif // !GTEST_OS_WINDOWS_MOBILE && !GTEST_OS_SYMBIAN -#endif // GTEST_HAS_STREAM_REDIRECTION - -// Determines whether to support death tests. -// Google Test does not support death tests for VC 7.1 and earlier as -// abort() in a VC 7.1 application compiled as GUI in debug config -// pops up a dialog window that cannot be suppressed programmatically. -#if (GTEST_OS_LINUX || GTEST_OS_CYGWIN || GTEST_OS_SOLARIS || \ - (GTEST_OS_MAC && !GTEST_OS_IOS) || \ - (GTEST_OS_WINDOWS_DESKTOP && _MSC_VER >= 1400) || \ - GTEST_OS_WINDOWS_MINGW || GTEST_OS_AIX || GTEST_OS_HPUX || \ - GTEST_OS_OPENBSD || GTEST_OS_QNX || GTEST_OS_FREEBSD) -# define GTEST_HAS_DEATH_TEST 1 -#endif - -// We don't support MSVC 7.1 with exceptions disabled now. Therefore -// all the compilers we care about are adequate for supporting -// value-parameterized tests. -#define GTEST_HAS_PARAM_TEST 1 - -// Determines whether to support type-driven tests. - -// Typed tests need and variadic macros, which GCC, VC++ 8.0, -// Sun Pro CC, IBM Visual Age, and HP aCC support. -#if defined(__GNUC__) || (_MSC_VER >= 1400) || defined(__SUNPRO_CC) || \ - defined(__IBMCPP__) || defined(__HP_aCC) -# define GTEST_HAS_TYPED_TEST 1 -# define GTEST_HAS_TYPED_TEST_P 1 -#endif - -// Determines whether to support Combine(). This only makes sense when -// value-parameterized tests are enabled. The implementation doesn't -// work on Sun Studio since it doesn't understand templated conversion -// operators. -#if GTEST_HAS_PARAM_TEST && GTEST_HAS_TR1_TUPLE && !defined(__SUNPRO_CC) -# define GTEST_HAS_COMBINE 1 -#endif - -// Determines whether the system compiler uses UTF-16 for encoding wide strings. -#define GTEST_WIDE_STRING_USES_UTF16_ \ - (GTEST_OS_WINDOWS || GTEST_OS_CYGWIN || GTEST_OS_SYMBIAN || GTEST_OS_AIX) - -// Determines whether test results can be streamed to a socket. -#if GTEST_OS_LINUX -# define GTEST_CAN_STREAM_RESULTS_ 1 -#endif - -// Defines some utility macros. - -// The GNU compiler emits a warning if nested "if" statements are followed by -// an "else" statement and braces are not used to explicitly disambiguate the -// "else" binding. This leads to problems with code like: -// -// if (gate) -// ASSERT_*(condition) << "Some message"; -// -// The "switch (0) case 0:" idiom is used to suppress this. -#ifdef __INTEL_COMPILER -# define GTEST_AMBIGUOUS_ELSE_BLOCKER_ -#else -# define GTEST_AMBIGUOUS_ELSE_BLOCKER_ switch (0) case 0: default: // NOLINT -#endif - -// Use this annotation at the end of a struct/class definition to -// prevent the compiler from optimizing away instances that are never -// used. This is useful when all interesting logic happens inside the -// c'tor and / or d'tor. Example: -// -// struct Foo { -// Foo() { ... } -// } GTEST_ATTRIBUTE_UNUSED_; -// -// Also use it after a variable or parameter declaration to tell the -// compiler the variable/parameter does not have to be used. -#if defined(__GNUC__) && !defined(COMPILER_ICC) -# define GTEST_ATTRIBUTE_UNUSED_ __attribute__ ((unused)) -#elif defined(__clang__) -# if __has_attribute(unused) -# define GTEST_ATTRIBUTE_UNUSED_ __attribute__ ((unused)) -# endif -#endif -#ifndef GTEST_ATTRIBUTE_UNUSED_ -# define GTEST_ATTRIBUTE_UNUSED_ -#endif - -// A macro to disallow operator= -// This should be used in the private: declarations for a class. -#define GTEST_DISALLOW_ASSIGN_(type)\ - void operator=(type const &) - -// A macro to disallow copy constructor and operator= -// This should be used in the private: declarations for a class. -#define GTEST_DISALLOW_COPY_AND_ASSIGN_(type)\ - type(type const &);\ - GTEST_DISALLOW_ASSIGN_(type) - -// Tell the compiler to warn about unused return values for functions declared -// with this macro. The macro should be used on function declarations -// following the argument list: -// -// Sprocket* AllocateSprocket() GTEST_MUST_USE_RESULT_; -#if defined(__GNUC__) && (GTEST_GCC_VER_ >= 30400) && !defined(COMPILER_ICC) -# define GTEST_MUST_USE_RESULT_ __attribute__ ((warn_unused_result)) -#else -# define GTEST_MUST_USE_RESULT_ -#endif // __GNUC__ && (GTEST_GCC_VER_ >= 30400) && !COMPILER_ICC - -// MS C++ compiler emits warning when a conditional expression is compile time -// constant. In some contexts this warning is false positive and needs to be -// suppressed. Use the following two macros in such cases: -// -// GTEST_INTENTIONAL_CONST_COND_PUSH_() -// while (true) { -// GTEST_INTENTIONAL_CONST_COND_POP_() -// } -# define GTEST_INTENTIONAL_CONST_COND_PUSH_() \ - GTEST_DISABLE_MSC_WARNINGS_PUSH_(4127) -# define GTEST_INTENTIONAL_CONST_COND_POP_() \ - GTEST_DISABLE_MSC_WARNINGS_POP_() - -// Determine whether the compiler supports Microsoft's Structured Exception -// Handling. This is supported by several Windows compilers but generally -// does not exist on any other system. -#ifndef GTEST_HAS_SEH -// The user didn't tell us, so we need to figure it out. - -# if defined(_MSC_VER) || defined(__BORLANDC__) -// These two compilers are known to support SEH. -# define GTEST_HAS_SEH 1 -# else -// Assume no SEH. -# define GTEST_HAS_SEH 0 -# endif - -#define GTEST_IS_THREADSAFE \ - (GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ \ - || (GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT) \ - || GTEST_HAS_PTHREAD) - -#endif // GTEST_HAS_SEH - -#ifdef _MSC_VER -# if GTEST_LINKED_AS_SHARED_LIBRARY -# define GTEST_API_ __declspec(dllimport) -# elif GTEST_CREATE_SHARED_LIBRARY -# define GTEST_API_ __declspec(dllexport) -# endif -#elif __GNUC__ >= 4 || defined(__clang__) -# define GTEST_API_ __attribute__((visibility ("default"))) -#endif // _MSC_VER - -#ifndef GTEST_API_ -# define GTEST_API_ -#endif - -#ifdef __GNUC__ -// Ask the compiler to never inline a given function. -# define GTEST_NO_INLINE_ __attribute__((noinline)) -#else -# define GTEST_NO_INLINE_ -#endif - -// _LIBCPP_VERSION is defined by the libc++ library from the LLVM project. -#if defined(__GLIBCXX__) || defined(_LIBCPP_VERSION) -# define GTEST_HAS_CXXABI_H_ 1 -#else -# define GTEST_HAS_CXXABI_H_ 0 -#endif - -// A function level attribute to disable checking for use of uninitialized -// memory when built with MemorySanitizer. -#if defined(__clang__) -# if __has_feature(memory_sanitizer) -# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_ \ - __attribute__((no_sanitize_memory)) -# else -# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_ -# endif // __has_feature(memory_sanitizer) -#else -# define GTEST_ATTRIBUTE_NO_SANITIZE_MEMORY_ -#endif // __clang__ - -// A function level attribute to disable AddressSanitizer instrumentation. -#if defined(__clang__) -# if __has_feature(address_sanitizer) -# define GTEST_ATTRIBUTE_NO_SANITIZE_ADDRESS_ \ - __attribute__((no_sanitize_address)) -# else -# define GTEST_ATTRIBUTE_NO_SANITIZE_ADDRESS_ -# endif // __has_feature(address_sanitizer) -#else -# define GTEST_ATTRIBUTE_NO_SANITIZE_ADDRESS_ -#endif // __clang__ - -// A function level attribute to disable ThreadSanitizer instrumentation. -#if defined(__clang__) -# if __has_feature(thread_sanitizer) -# define GTEST_ATTRIBUTE_NO_SANITIZE_THREAD_ \ - __attribute__((no_sanitize_thread)) -# else -# define GTEST_ATTRIBUTE_NO_SANITIZE_THREAD_ -# endif // __has_feature(thread_sanitizer) -#else -# define GTEST_ATTRIBUTE_NO_SANITIZE_THREAD_ -#endif // __clang__ - -namespace testing { - -class Message; - -#if defined(GTEST_TUPLE_NAMESPACE_) -// Import tuple and friends into the ::testing namespace. -// It is part of our interface, having them in ::testing allows us to change -// their types as needed. -using GTEST_TUPLE_NAMESPACE_::get; -using GTEST_TUPLE_NAMESPACE_::make_tuple; -using GTEST_TUPLE_NAMESPACE_::tuple; -using GTEST_TUPLE_NAMESPACE_::tuple_size; -using GTEST_TUPLE_NAMESPACE_::tuple_element; -#endif // defined(GTEST_TUPLE_NAMESPACE_) - -namespace internal { - -// A secret type that Google Test users don't know about. It has no -// definition on purpose. Therefore it's impossible to create a -// Secret object, which is what we want. -class Secret; - -// The GTEST_COMPILE_ASSERT_ macro can be used to verify that a compile time -// expression is true. For example, you could use it to verify the -// size of a static array: -// -// GTEST_COMPILE_ASSERT_(GTEST_ARRAY_SIZE_(names) == NUM_NAMES, -// names_incorrect_size); -// -// or to make sure a struct is smaller than a certain size: -// -// GTEST_COMPILE_ASSERT_(sizeof(foo) < 128, foo_too_large); -// -// The second argument to the macro is the name of the variable. If -// the expression is false, most compilers will issue a warning/error -// containing the name of the variable. - -#if GTEST_LANG_CXX11 -# define GTEST_COMPILE_ASSERT_(expr, msg) static_assert(expr, #msg) -#else // !GTEST_LANG_CXX11 -template - struct CompileAssert { -}; - -# define GTEST_COMPILE_ASSERT_(expr, msg) \ - typedef ::testing::internal::CompileAssert<(static_cast(expr))> \ - msg[static_cast(expr) ? 1 : -1] GTEST_ATTRIBUTE_UNUSED_ -#endif // !GTEST_LANG_CXX11 - -// Implementation details of GTEST_COMPILE_ASSERT_: -// -// (In C++11, we simply use static_assert instead of the following) -// -// - GTEST_COMPILE_ASSERT_ works by defining an array type that has -1 -// elements (and thus is invalid) when the expression is false. -// -// - The simpler definition -// -// #define GTEST_COMPILE_ASSERT_(expr, msg) typedef char msg[(expr) ? 1 : -1] -// -// does not work, as gcc supports variable-length arrays whose sizes -// are determined at run-time (this is gcc's extension and not part -// of the C++ standard). As a result, gcc fails to reject the -// following code with the simple definition: -// -// int foo; -// GTEST_COMPILE_ASSERT_(foo, msg); // not supposed to compile as foo is -// // not a compile-time constant. -// -// - By using the type CompileAssert<(bool(expr))>, we ensures that -// expr is a compile-time constant. (Template arguments must be -// determined at compile-time.) -// -// - The outter parentheses in CompileAssert<(bool(expr))> are necessary -// to work around a bug in gcc 3.4.4 and 4.0.1. If we had written -// -// CompileAssert -// -// instead, these compilers will refuse to compile -// -// GTEST_COMPILE_ASSERT_(5 > 0, some_message); -// -// (They seem to think the ">" in "5 > 0" marks the end of the -// template argument list.) -// -// - The array size is (bool(expr) ? 1 : -1), instead of simply -// -// ((expr) ? 1 : -1). -// -// This is to avoid running into a bug in MS VC 7.1, which -// causes ((0.0) ? 1 : -1) to incorrectly evaluate to 1. - -// StaticAssertTypeEqHelper is used by StaticAssertTypeEq defined in gtest.h. -// -// This template is declared, but intentionally undefined. -template -struct StaticAssertTypeEqHelper; - -template -struct StaticAssertTypeEqHelper { - enum { value = true }; -}; - -// Evaluates to the number of elements in 'array'. -#define GTEST_ARRAY_SIZE_(array) (sizeof(array) / sizeof(array[0])) - -#if GTEST_HAS_GLOBAL_STRING -typedef ::string string; -#else -typedef ::std::string string; -#endif // GTEST_HAS_GLOBAL_STRING - -#if GTEST_HAS_GLOBAL_WSTRING -typedef ::wstring wstring; -#elif GTEST_HAS_STD_WSTRING -typedef ::std::wstring wstring; -#endif // GTEST_HAS_GLOBAL_WSTRING - -// A helper for suppressing warnings on constant condition. It just -// returns 'condition'. -GTEST_API_ bool IsTrue(bool condition); - -// Defines scoped_ptr. - -// This implementation of scoped_ptr is PARTIAL - it only contains -// enough stuff to satisfy Google Test's need. -template -class scoped_ptr { - public: - typedef T element_type; - - explicit scoped_ptr(T* p = NULL) : ptr_(p) {} - ~scoped_ptr() { reset(); } - - T& operator*() const { return *ptr_; } - T* operator->() const { return ptr_; } - T* get() const { return ptr_; } - - T* release() { - T* const ptr = ptr_; - ptr_ = NULL; - return ptr; - } - - void reset(T* p = NULL) { - if (p != ptr_) { - if (IsTrue(sizeof(T) > 0)) { // Makes sure T is a complete type. - delete ptr_; - } - ptr_ = p; - } - } - - friend void swap(scoped_ptr& a, scoped_ptr& b) { - using std::swap; - swap(a.ptr_, b.ptr_); - } - - private: - T* ptr_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(scoped_ptr); -}; - -// Defines RE. - -// A simple C++ wrapper for . It uses the POSIX Extended -// Regular Expression syntax. -class GTEST_API_ RE { - public: - // A copy constructor is required by the Standard to initialize object - // references from r-values. - RE(const RE& other) { Init(other.pattern()); } - - // Constructs an RE from a string. - RE(const ::std::string& regex) { Init(regex.c_str()); } // NOLINT - -#if GTEST_HAS_GLOBAL_STRING - - RE(const ::string& regex) { Init(regex.c_str()); } // NOLINT - -#endif // GTEST_HAS_GLOBAL_STRING - - RE(const char* regex) { Init(regex); } // NOLINT - ~RE(); - - // Returns the string representation of the regex. - const char* pattern() const { return pattern_; } - - // FullMatch(str, re) returns true iff regular expression re matches - // the entire str. - // PartialMatch(str, re) returns true iff regular expression re - // matches a substring of str (including str itself). - // - // TODO(wan@google.com): make FullMatch() and PartialMatch() work - // when str contains NUL characters. - static bool FullMatch(const ::std::string& str, const RE& re) { - return FullMatch(str.c_str(), re); - } - static bool PartialMatch(const ::std::string& str, const RE& re) { - return PartialMatch(str.c_str(), re); - } - -#if GTEST_HAS_GLOBAL_STRING - - static bool FullMatch(const ::string& str, const RE& re) { - return FullMatch(str.c_str(), re); - } - static bool PartialMatch(const ::string& str, const RE& re) { - return PartialMatch(str.c_str(), re); - } - -#endif // GTEST_HAS_GLOBAL_STRING - - static bool FullMatch(const char* str, const RE& re); - static bool PartialMatch(const char* str, const RE& re); - - private: - void Init(const char* regex); - - // We use a const char* instead of an std::string, as Google Test used to be - // used where std::string is not available. TODO(wan@google.com): change to - // std::string. - const char* pattern_; - bool is_valid_; - -#if GTEST_USES_POSIX_RE - - regex_t full_regex_; // For FullMatch(). - regex_t partial_regex_; // For PartialMatch(). - -#else // GTEST_USES_SIMPLE_RE - - const char* full_pattern_; // For FullMatch(); - -#endif - - GTEST_DISALLOW_ASSIGN_(RE); -}; - -// Formats a source file path and a line number as they would appear -// in an error message from the compiler used to compile this code. -GTEST_API_ ::std::string FormatFileLocation(const char* file, int line); - -// Formats a file location for compiler-independent XML output. -// Although this function is not platform dependent, we put it next to -// FormatFileLocation in order to contrast the two functions. -GTEST_API_ ::std::string FormatCompilerIndependentFileLocation(const char* file, - int line); - -// Defines logging utilities: -// GTEST_LOG_(severity) - logs messages at the specified severity level. The -// message itself is streamed into the macro. -// LogToStderr() - directs all log messages to stderr. -// FlushInfoLog() - flushes informational log messages. - -enum GTestLogSeverity { - GTEST_INFO, - GTEST_WARNING, - GTEST_ERROR, - GTEST_FATAL -}; - -// Formats log entry severity, provides a stream object for streaming the -// log message, and terminates the message with a newline when going out of -// scope. -class GTEST_API_ GTestLog { - public: - GTestLog(GTestLogSeverity severity, const char* file, int line); - - // Flushes the buffers and, if severity is GTEST_FATAL, aborts the program. - ~GTestLog(); - - ::std::ostream& GetStream() { return ::std::cerr; } - - private: - const GTestLogSeverity severity_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(GTestLog); -}; - -#if !defined(GTEST_LOG_) - -# define GTEST_LOG_(severity) \ - ::testing::internal::GTestLog(::testing::internal::GTEST_##severity, \ - __FILE__, __LINE__).GetStream() - -inline void LogToStderr() {} -inline void FlushInfoLog() { fflush(NULL); } - -#endif // !defined(GTEST_LOG_) - -#if !defined(GTEST_CHECK_) -// INTERNAL IMPLEMENTATION - DO NOT USE. -// -// GTEST_CHECK_ is an all-mode assert. It aborts the program if the condition -// is not satisfied. -// Synopsys: -// GTEST_CHECK_(boolean_condition); -// or -// GTEST_CHECK_(boolean_condition) << "Additional message"; -// -// This checks the condition and if the condition is not satisfied -// it prints message about the condition violation, including the -// condition itself, plus additional message streamed into it, if any, -// and then it aborts the program. It aborts the program irrespective of -// whether it is built in the debug mode or not. -# define GTEST_CHECK_(condition) \ - GTEST_AMBIGUOUS_ELSE_BLOCKER_ \ - if (::testing::internal::IsTrue(condition)) \ - ; \ - else \ - GTEST_LOG_(FATAL) << "Condition " #condition " failed. " -#endif // !defined(GTEST_CHECK_) - -// An all-mode assert to verify that the given POSIX-style function -// call returns 0 (indicating success). Known limitation: this -// doesn't expand to a balanced 'if' statement, so enclose the macro -// in {} if you need to use it as the only statement in an 'if' -// branch. -#define GTEST_CHECK_POSIX_SUCCESS_(posix_call) \ - if (const int gtest_error = (posix_call)) \ - GTEST_LOG_(FATAL) << #posix_call << "failed with error " \ - << gtest_error - -#if GTEST_HAS_STD_MOVE_ -using std::move; -#else // GTEST_HAS_STD_MOVE_ -template -const T& move(const T& t) { - return t; -} -#endif // GTEST_HAS_STD_MOVE_ - -// INTERNAL IMPLEMENTATION - DO NOT USE IN USER CODE. -// -// Use ImplicitCast_ as a safe version of static_cast for upcasting in -// the type hierarchy (e.g. casting a Foo* to a SuperclassOfFoo* or a -// const Foo*). When you use ImplicitCast_, the compiler checks that -// the cast is safe. Such explicit ImplicitCast_s are necessary in -// surprisingly many situations where C++ demands an exact type match -// instead of an argument type convertable to a target type. -// -// The syntax for using ImplicitCast_ is the same as for static_cast: -// -// ImplicitCast_(expr) -// -// ImplicitCast_ would have been part of the C++ standard library, -// but the proposal was submitted too late. It will probably make -// its way into the language in the future. -// -// This relatively ugly name is intentional. It prevents clashes with -// similar functions users may have (e.g., implicit_cast). The internal -// namespace alone is not enough because the function can be found by ADL. -template -inline To ImplicitCast_(To x) { return x; } - -// When you upcast (that is, cast a pointer from type Foo to type -// SuperclassOfFoo), it's fine to use ImplicitCast_<>, since upcasts -// always succeed. When you downcast (that is, cast a pointer from -// type Foo to type SubclassOfFoo), static_cast<> isn't safe, because -// how do you know the pointer is really of type SubclassOfFoo? It -// could be a bare Foo, or of type DifferentSubclassOfFoo. Thus, -// when you downcast, you should use this macro. In debug mode, we -// use dynamic_cast<> to double-check the downcast is legal (we die -// if it's not). In normal mode, we do the efficient static_cast<> -// instead. Thus, it's important to test in debug mode to make sure -// the cast is legal! -// This is the only place in the code we should use dynamic_cast<>. -// In particular, you SHOULDN'T be using dynamic_cast<> in order to -// do RTTI (eg code like this: -// if (dynamic_cast(foo)) HandleASubclass1Object(foo); -// if (dynamic_cast(foo)) HandleASubclass2Object(foo); -// You should design the code some other way not to need this. -// -// This relatively ugly name is intentional. It prevents clashes with -// similar functions users may have (e.g., down_cast). The internal -// namespace alone is not enough because the function can be found by ADL. -template // use like this: DownCast_(foo); -inline To DownCast_(From* f) { // so we only accept pointers - // Ensures that To is a sub-type of From *. This test is here only - // for compile-time type checking, and has no overhead in an - // optimized build at run-time, as it will be optimized away - // completely. - GTEST_INTENTIONAL_CONST_COND_PUSH_() - if (false) { - GTEST_INTENTIONAL_CONST_COND_POP_() - const To to = NULL; - ::testing::internal::ImplicitCast_(to); - } - -#if GTEST_HAS_RTTI - // RTTI: debug mode only! - GTEST_CHECK_(f == NULL || dynamic_cast(f) != NULL); -#endif - return static_cast(f); -} - -// Downcasts the pointer of type Base to Derived. -// Derived must be a subclass of Base. The parameter MUST -// point to a class of type Derived, not any subclass of it. -// When RTTI is available, the function performs a runtime -// check to enforce this. -template -Derived* CheckedDowncastToActualType(Base* base) { -#if GTEST_HAS_RTTI - GTEST_CHECK_(typeid(*base) == typeid(Derived)); -#endif - -#if GTEST_HAS_DOWNCAST_ - return ::down_cast(base); -#elif GTEST_HAS_RTTI - return dynamic_cast(base); // NOLINT -#else - return static_cast(base); // Poor man's downcast. -#endif -} - -#if GTEST_HAS_STREAM_REDIRECTION - -// Defines the stderr capturer: -// CaptureStdout - starts capturing stdout. -// GetCapturedStdout - stops capturing stdout and returns the captured string. -// CaptureStderr - starts capturing stderr. -// GetCapturedStderr - stops capturing stderr and returns the captured string. -// -GTEST_API_ void CaptureStdout(); -GTEST_API_ std::string GetCapturedStdout(); -GTEST_API_ void CaptureStderr(); -GTEST_API_ std::string GetCapturedStderr(); - -#endif // GTEST_HAS_STREAM_REDIRECTION - -// Returns a path to temporary directory. -GTEST_API_ std::string TempDir(); - -// Returns the size (in bytes) of a file. -GTEST_API_ size_t GetFileSize(FILE* file); - -// Reads the entire content of a file as a string. -GTEST_API_ std::string ReadEntireFile(FILE* file); - -// All command line arguments. -GTEST_API_ const ::std::vector& GetArgvs(); - -#if GTEST_HAS_DEATH_TEST - -const ::std::vector& GetInjectableArgvs(); -void SetInjectableArgvs(const ::std::vector* - new_argvs); - - -#endif // GTEST_HAS_DEATH_TEST - -// Defines synchronization primitives. -#if GTEST_IS_THREADSAFE -# if GTEST_HAS_PTHREAD -// Sleeps for (roughly) n milliseconds. This function is only for testing -// Google Test's own constructs. Don't use it in user tests, either -// directly or indirectly. -inline void SleepMilliseconds(int n) { - const timespec time = { - 0, // 0 seconds. - n * 1000L * 1000L, // And n ms. - }; - nanosleep(&time, NULL); -} -# endif // GTEST_HAS_PTHREAD - -# if GTEST_HAS_NOTIFICATION_ -// Notification has already been imported into the namespace. -// Nothing to do here. - -# elif GTEST_HAS_PTHREAD -// Allows a controller thread to pause execution of newly created -// threads until notified. Instances of this class must be created -// and destroyed in the controller thread. -// -// This class is only for testing Google Test's own constructs. Do not -// use it in user tests, either directly or indirectly. -class Notification { - public: - Notification() : notified_(false) { - GTEST_CHECK_POSIX_SUCCESS_(pthread_mutex_init(&mutex_, NULL)); - } - ~Notification() { - pthread_mutex_destroy(&mutex_); - } - - // Notifies all threads created with this notification to start. Must - // be called from the controller thread. - void Notify() { - pthread_mutex_lock(&mutex_); - notified_ = true; - pthread_mutex_unlock(&mutex_); - } - - // Blocks until the controller thread notifies. Must be called from a test - // thread. - void WaitForNotification() { - for (;;) { - pthread_mutex_lock(&mutex_); - const bool notified = notified_; - pthread_mutex_unlock(&mutex_); - if (notified) - break; - SleepMilliseconds(10); - } - } - - private: - pthread_mutex_t mutex_; - bool notified_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(Notification); -}; - -# elif GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT - -GTEST_API_ void SleepMilliseconds(int n); - -// Provides leak-safe Windows kernel handle ownership. -// Used in death tests and in threading support. -class GTEST_API_ AutoHandle { - public: - // Assume that Win32 HANDLE type is equivalent to void*. Doing so allows us to - // avoid including in this header file. Including is - // undesirable because it defines a lot of symbols and macros that tend to - // conflict with client code. This assumption is verified by - // WindowsTypesTest.HANDLEIsVoidStar. - typedef void* Handle; - AutoHandle(); - explicit AutoHandle(Handle handle); - - ~AutoHandle(); - - Handle Get() const; - void Reset(); - void Reset(Handle handle); - - private: - // Returns true iff the handle is a valid handle object that can be closed. - bool IsCloseable() const; - - Handle handle_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(AutoHandle); -}; - -// Allows a controller thread to pause execution of newly created -// threads until notified. Instances of this class must be created -// and destroyed in the controller thread. -// -// This class is only for testing Google Test's own constructs. Do not -// use it in user tests, either directly or indirectly. -class GTEST_API_ Notification { - public: - Notification(); - void Notify(); - void WaitForNotification(); - - private: - AutoHandle event_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(Notification); -}; -# endif // GTEST_HAS_NOTIFICATION_ - -// On MinGW, we can have both GTEST_OS_WINDOWS and GTEST_HAS_PTHREAD -// defined, but we don't want to use MinGW's pthreads implementation, which -// has conformance problems with some versions of the POSIX standard. -# if GTEST_HAS_PTHREAD && !GTEST_OS_WINDOWS_MINGW - -// As a C-function, ThreadFuncWithCLinkage cannot be templated itself. -// Consequently, it cannot select a correct instantiation of ThreadWithParam -// in order to call its Run(). Introducing ThreadWithParamBase as a -// non-templated base class for ThreadWithParam allows us to bypass this -// problem. -class ThreadWithParamBase { - public: - virtual ~ThreadWithParamBase() {} - virtual void Run() = 0; -}; - -// pthread_create() accepts a pointer to a function type with the C linkage. -// According to the Standard (7.5/1), function types with different linkages -// are different even if they are otherwise identical. Some compilers (for -// example, SunStudio) treat them as different types. Since class methods -// cannot be defined with C-linkage we need to define a free C-function to -// pass into pthread_create(). -extern "C" inline void* ThreadFuncWithCLinkage(void* thread) { - static_cast(thread)->Run(); - return NULL; -} - -// Helper class for testing Google Test's multi-threading constructs. -// To use it, write: -// -// void ThreadFunc(int param) { /* Do things with param */ } -// Notification thread_can_start; -// ... -// // The thread_can_start parameter is optional; you can supply NULL. -// ThreadWithParam thread(&ThreadFunc, 5, &thread_can_start); -// thread_can_start.Notify(); -// -// These classes are only for testing Google Test's own constructs. Do -// not use them in user tests, either directly or indirectly. -template -class ThreadWithParam : public ThreadWithParamBase { - public: - typedef void UserThreadFunc(T); - - ThreadWithParam(UserThreadFunc* func, T param, Notification* thread_can_start) - : func_(func), - param_(param), - thread_can_start_(thread_can_start), - finished_(false) { - ThreadWithParamBase* const base = this; - // The thread can be created only after all fields except thread_ - // have been initialized. - GTEST_CHECK_POSIX_SUCCESS_( - pthread_create(&thread_, 0, &ThreadFuncWithCLinkage, base)); - } - ~ThreadWithParam() { Join(); } - - void Join() { - if (!finished_) { - GTEST_CHECK_POSIX_SUCCESS_(pthread_join(thread_, 0)); - finished_ = true; - } - } - - virtual void Run() { - if (thread_can_start_ != NULL) - thread_can_start_->WaitForNotification(); - func_(param_); - } - - private: - UserThreadFunc* const func_; // User-supplied thread function. - const T param_; // User-supplied parameter to the thread function. - // When non-NULL, used to block execution until the controller thread - // notifies. - Notification* const thread_can_start_; - bool finished_; // true iff we know that the thread function has finished. - pthread_t thread_; // The native thread object. - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ThreadWithParam); -}; -# endif // !GTEST_OS_WINDOWS && GTEST_HAS_PTHREAD || - // GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ - -# if GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ -// Mutex and ThreadLocal have already been imported into the namespace. -// Nothing to do here. - -# elif GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT - -// Mutex implements mutex on Windows platforms. It is used in conjunction -// with class MutexLock: -// -// Mutex mutex; -// ... -// MutexLock lock(&mutex); // Acquires the mutex and releases it at the -// // end of the current scope. -// -// A static Mutex *must* be defined or declared using one of the following -// macros: -// GTEST_DEFINE_STATIC_MUTEX_(g_some_mutex); -// GTEST_DECLARE_STATIC_MUTEX_(g_some_mutex); -// -// (A non-static Mutex is defined/declared in the usual way). -class GTEST_API_ Mutex { - public: - enum MutexType { kStatic = 0, kDynamic = 1 }; - // We rely on kStaticMutex being 0 as it is to what the linker initializes - // type_ in static mutexes. critical_section_ will be initialized lazily - // in ThreadSafeLazyInit(). - enum StaticConstructorSelector { kStaticMutex = 0 }; - - // This constructor intentionally does nothing. It relies on type_ being - // statically initialized to 0 (effectively setting it to kStatic) and on - // ThreadSafeLazyInit() to lazily initialize the rest of the members. - explicit Mutex(StaticConstructorSelector /*dummy*/) {} - - Mutex(); - ~Mutex(); - - void Lock(); - - void Unlock(); - - // Does nothing if the current thread holds the mutex. Otherwise, crashes - // with high probability. - void AssertHeld(); - - private: - // Initializes owner_thread_id_ and critical_section_ in static mutexes. - void ThreadSafeLazyInit(); - - // Per http://blogs.msdn.com/b/oldnewthing/archive/2004/02/23/78395.aspx, - // we assume that 0 is an invalid value for thread IDs. - unsigned int owner_thread_id_; - - // For static mutexes, we rely on these members being initialized to zeros - // by the linker. - MutexType type_; - long critical_section_init_phase_; // NOLINT - _RTL_CRITICAL_SECTION* critical_section_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(Mutex); -}; - -# define GTEST_DECLARE_STATIC_MUTEX_(mutex) \ - extern ::testing::internal::Mutex mutex - -# define GTEST_DEFINE_STATIC_MUTEX_(mutex) \ - ::testing::internal::Mutex mutex(::testing::internal::Mutex::kStaticMutex) - -// We cannot name this class MutexLock because the ctor declaration would -// conflict with a macro named MutexLock, which is defined on some -// platforms. That macro is used as a defensive measure to prevent against -// inadvertent misuses of MutexLock like "MutexLock(&mu)" rather than -// "MutexLock l(&mu)". Hence the typedef trick below. -class GTestMutexLock { - public: - explicit GTestMutexLock(Mutex* mutex) - : mutex_(mutex) { mutex_->Lock(); } - - ~GTestMutexLock() { mutex_->Unlock(); } - - private: - Mutex* const mutex_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(GTestMutexLock); -}; - -typedef GTestMutexLock MutexLock; - -// Base class for ValueHolder. Allows a caller to hold and delete a value -// without knowing its type. -class ThreadLocalValueHolderBase { - public: - virtual ~ThreadLocalValueHolderBase() {} -}; - -// Provides a way for a thread to send notifications to a ThreadLocal -// regardless of its parameter type. -class ThreadLocalBase { - public: - // Creates a new ValueHolder object holding a default value passed to - // this ThreadLocal's constructor and returns it. It is the caller's - // responsibility not to call this when the ThreadLocal instance already - // has a value on the current thread. - virtual ThreadLocalValueHolderBase* NewValueForCurrentThread() const = 0; - - protected: - ThreadLocalBase() {} - virtual ~ThreadLocalBase() {} - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(ThreadLocalBase); -}; - -// Maps a thread to a set of ThreadLocals that have values instantiated on that -// thread and notifies them when the thread exits. A ThreadLocal instance is -// expected to persist until all threads it has values on have terminated. -class GTEST_API_ ThreadLocalRegistry { - public: - // Registers thread_local_instance as having value on the current thread. - // Returns a value that can be used to identify the thread from other threads. - static ThreadLocalValueHolderBase* GetValueOnCurrentThread( - const ThreadLocalBase* thread_local_instance); - - // Invoked when a ThreadLocal instance is destroyed. - static void OnThreadLocalDestroyed( - const ThreadLocalBase* thread_local_instance); -}; - -class GTEST_API_ ThreadWithParamBase { - public: - void Join(); - - protected: - class Runnable { - public: - virtual ~Runnable() {} - virtual void Run() = 0; - }; - - ThreadWithParamBase(Runnable *runnable, Notification* thread_can_start); - virtual ~ThreadWithParamBase(); - - private: - AutoHandle thread_; -}; - -// Helper class for testing Google Test's multi-threading constructs. -template -class ThreadWithParam : public ThreadWithParamBase { - public: - typedef void UserThreadFunc(T); - - ThreadWithParam(UserThreadFunc* func, T param, Notification* thread_can_start) - : ThreadWithParamBase(new RunnableImpl(func, param), thread_can_start) { - } - virtual ~ThreadWithParam() {} - - private: - class RunnableImpl : public Runnable { - public: - RunnableImpl(UserThreadFunc* func, T param) - : func_(func), - param_(param) { - } - virtual ~RunnableImpl() {} - virtual void Run() { - func_(param_); - } - - private: - UserThreadFunc* const func_; - const T param_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(RunnableImpl); - }; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ThreadWithParam); -}; - -// Implements thread-local storage on Windows systems. -// -// // Thread 1 -// ThreadLocal tl(100); // 100 is the default value for each thread. -// -// // Thread 2 -// tl.set(150); // Changes the value for thread 2 only. -// EXPECT_EQ(150, tl.get()); -// -// // Thread 1 -// EXPECT_EQ(100, tl.get()); // In thread 1, tl has the original value. -// tl.set(200); -// EXPECT_EQ(200, tl.get()); -// -// The template type argument T must have a public copy constructor. -// In addition, the default ThreadLocal constructor requires T to have -// a public default constructor. -// -// The users of a TheadLocal instance have to make sure that all but one -// threads (including the main one) using that instance have exited before -// destroying it. Otherwise, the per-thread objects managed for them by the -// ThreadLocal instance are not guaranteed to be destroyed on all platforms. -// -// Google Test only uses global ThreadLocal objects. That means they -// will die after main() has returned. Therefore, no per-thread -// object managed by Google Test will be leaked as long as all threads -// using Google Test have exited when main() returns. -template -class ThreadLocal : public ThreadLocalBase { - public: - ThreadLocal() : default_factory_(new DefaultValueHolderFactory()) {} - explicit ThreadLocal(const T& value) - : default_factory_(new InstanceValueHolderFactory(value)) {} - - ~ThreadLocal() { ThreadLocalRegistry::OnThreadLocalDestroyed(this); } - - T* pointer() { return GetOrCreateValue(); } - const T* pointer() const { return GetOrCreateValue(); } - const T& get() const { return *pointer(); } - void set(const T& value) { *pointer() = value; } - - private: - // Holds a value of T. Can be deleted via its base class without the caller - // knowing the type of T. - class ValueHolder : public ThreadLocalValueHolderBase { - public: - ValueHolder() : value_() {} - explicit ValueHolder(const T& value) : value_(value) {} - - T* pointer() { return &value_; } - - private: - T value_; - GTEST_DISALLOW_COPY_AND_ASSIGN_(ValueHolder); - }; - - - T* GetOrCreateValue() const { - return static_cast( - ThreadLocalRegistry::GetValueOnCurrentThread(this))->pointer(); - } - - virtual ThreadLocalValueHolderBase* NewValueForCurrentThread() const { - return default_factory_->MakeNewHolder(); - } - - class ValueHolderFactory { - public: - ValueHolderFactory() {} - virtual ~ValueHolderFactory() {} - virtual ValueHolder* MakeNewHolder() const = 0; - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(ValueHolderFactory); - }; - - class DefaultValueHolderFactory : public ValueHolderFactory { - public: - DefaultValueHolderFactory() {} - virtual ValueHolder* MakeNewHolder() const { return new ValueHolder(); } - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(DefaultValueHolderFactory); - }; - - class InstanceValueHolderFactory : public ValueHolderFactory { - public: - explicit InstanceValueHolderFactory(const T& value) : value_(value) {} - virtual ValueHolder* MakeNewHolder() const { - return new ValueHolder(value_); - } - - private: - const T value_; // The value for each thread. - - GTEST_DISALLOW_COPY_AND_ASSIGN_(InstanceValueHolderFactory); - }; - - scoped_ptr default_factory_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ThreadLocal); -}; - -# elif GTEST_HAS_PTHREAD - -// MutexBase and Mutex implement mutex on pthreads-based platforms. -class MutexBase { - public: - // Acquires this mutex. - void Lock() { - GTEST_CHECK_POSIX_SUCCESS_(pthread_mutex_lock(&mutex_)); - owner_ = pthread_self(); - has_owner_ = true; - } - - // Releases this mutex. - void Unlock() { - // Since the lock is being released the owner_ field should no longer be - // considered valid. We don't protect writing to has_owner_ here, as it's - // the caller's responsibility to ensure that the current thread holds the - // mutex when this is called. - has_owner_ = false; - GTEST_CHECK_POSIX_SUCCESS_(pthread_mutex_unlock(&mutex_)); - } - - // Does nothing if the current thread holds the mutex. Otherwise, crashes - // with high probability. - void AssertHeld() const { - GTEST_CHECK_(has_owner_ && pthread_equal(owner_, pthread_self())) - << "The current thread is not holding the mutex @" << this; - } - - // A static mutex may be used before main() is entered. It may even - // be used before the dynamic initialization stage. Therefore we - // must be able to initialize a static mutex object at link time. - // This means MutexBase has to be a POD and its member variables - // have to be public. - public: - pthread_mutex_t mutex_; // The underlying pthread mutex. - // has_owner_ indicates whether the owner_ field below contains a valid thread - // ID and is therefore safe to inspect (e.g., to use in pthread_equal()). All - // accesses to the owner_ field should be protected by a check of this field. - // An alternative might be to memset() owner_ to all zeros, but there's no - // guarantee that a zero'd pthread_t is necessarily invalid or even different - // from pthread_self(). - bool has_owner_; - pthread_t owner_; // The thread holding the mutex. -}; - -// Forward-declares a static mutex. -# define GTEST_DECLARE_STATIC_MUTEX_(mutex) \ - extern ::testing::internal::MutexBase mutex - -// Defines and statically (i.e. at link time) initializes a static mutex. -# define GTEST_DEFINE_STATIC_MUTEX_(mutex) \ - ::testing::internal::MutexBase mutex = { PTHREAD_MUTEX_INITIALIZER, false, pthread_t() } - -// The Mutex class can only be used for mutexes created at runtime. It -// shares its API with MutexBase otherwise. -class Mutex : public MutexBase { - public: - Mutex() { - GTEST_CHECK_POSIX_SUCCESS_(pthread_mutex_init(&mutex_, NULL)); - has_owner_ = false; - } - ~Mutex() { - GTEST_CHECK_POSIX_SUCCESS_(pthread_mutex_destroy(&mutex_)); - } - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(Mutex); -}; - -// We cannot name this class MutexLock because the ctor declaration would -// conflict with a macro named MutexLock, which is defined on some -// platforms. That macro is used as a defensive measure to prevent against -// inadvertent misuses of MutexLock like "MutexLock(&mu)" rather than -// "MutexLock l(&mu)". Hence the typedef trick below. -class GTestMutexLock { - public: - explicit GTestMutexLock(MutexBase* mutex) - : mutex_(mutex) { mutex_->Lock(); } - - ~GTestMutexLock() { mutex_->Unlock(); } - - private: - MutexBase* const mutex_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(GTestMutexLock); -}; - -typedef GTestMutexLock MutexLock; - -// Helpers for ThreadLocal. - -// pthread_key_create() requires DeleteThreadLocalValue() to have -// C-linkage. Therefore it cannot be templatized to access -// ThreadLocal. Hence the need for class -// ThreadLocalValueHolderBase. -class ThreadLocalValueHolderBase { - public: - virtual ~ThreadLocalValueHolderBase() {} -}; - -// Called by pthread to delete thread-local data stored by -// pthread_setspecific(). -extern "C" inline void DeleteThreadLocalValue(void* value_holder) { - delete static_cast(value_holder); -} - -// Implements thread-local storage on pthreads-based systems. -template -class ThreadLocal { - public: - ThreadLocal() - : key_(CreateKey()), default_factory_(new DefaultValueHolderFactory()) {} - explicit ThreadLocal(const T& value) - : key_(CreateKey()), - default_factory_(new InstanceValueHolderFactory(value)) {} - - ~ThreadLocal() { - // Destroys the managed object for the current thread, if any. - DeleteThreadLocalValue(pthread_getspecific(key_)); - - // Releases resources associated with the key. This will *not* - // delete managed objects for other threads. - GTEST_CHECK_POSIX_SUCCESS_(pthread_key_delete(key_)); - } - - T* pointer() { return GetOrCreateValue(); } - const T* pointer() const { return GetOrCreateValue(); } - const T& get() const { return *pointer(); } - void set(const T& value) { *pointer() = value; } - - private: - // Holds a value of type T. - class ValueHolder : public ThreadLocalValueHolderBase { - public: - ValueHolder() : value_() {} - explicit ValueHolder(const T& value) : value_(value) {} - - T* pointer() { return &value_; } - - private: - T value_; - GTEST_DISALLOW_COPY_AND_ASSIGN_(ValueHolder); - }; - - static pthread_key_t CreateKey() { - pthread_key_t key; - // When a thread exits, DeleteThreadLocalValue() will be called on - // the object managed for that thread. - GTEST_CHECK_POSIX_SUCCESS_( - pthread_key_create(&key, &DeleteThreadLocalValue)); - return key; - } - - T* GetOrCreateValue() const { - ThreadLocalValueHolderBase* const holder = - static_cast(pthread_getspecific(key_)); - if (holder != NULL) { - return CheckedDowncastToActualType(holder)->pointer(); - } - - ValueHolder* const new_holder = default_factory_->MakeNewHolder(); - ThreadLocalValueHolderBase* const holder_base = new_holder; - GTEST_CHECK_POSIX_SUCCESS_(pthread_setspecific(key_, holder_base)); - return new_holder->pointer(); - } - - class ValueHolderFactory { - public: - ValueHolderFactory() {} - virtual ~ValueHolderFactory() {} - virtual ValueHolder* MakeNewHolder() const = 0; - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(ValueHolderFactory); - }; - - class DefaultValueHolderFactory : public ValueHolderFactory { - public: - DefaultValueHolderFactory() {} - virtual ValueHolder* MakeNewHolder() const { return new ValueHolder(); } - - private: - GTEST_DISALLOW_COPY_AND_ASSIGN_(DefaultValueHolderFactory); - }; - - class InstanceValueHolderFactory : public ValueHolderFactory { - public: - explicit InstanceValueHolderFactory(const T& value) : value_(value) {} - virtual ValueHolder* MakeNewHolder() const { - return new ValueHolder(value_); - } - - private: - const T value_; // The value for each thread. - - GTEST_DISALLOW_COPY_AND_ASSIGN_(InstanceValueHolderFactory); - }; - - // A key pthreads uses for looking up per-thread values. - const pthread_key_t key_; - scoped_ptr default_factory_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(ThreadLocal); -}; - -# endif // GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ - -#else // GTEST_IS_THREADSAFE - -// A dummy implementation of synchronization primitives (mutex, lock, -// and thread-local variable). Necessary for compiling Google Test where -// mutex is not supported - using Google Test in multiple threads is not -// supported on such platforms. - -class Mutex { - public: - Mutex() {} - void Lock() {} - void Unlock() {} - void AssertHeld() const {} -}; - -# define GTEST_DECLARE_STATIC_MUTEX_(mutex) \ - extern ::testing::internal::Mutex mutex - -# define GTEST_DEFINE_STATIC_MUTEX_(mutex) ::testing::internal::Mutex mutex - -// We cannot name this class MutexLock because the ctor declaration would -// conflict with a macro named MutexLock, which is defined on some -// platforms. That macro is used as a defensive measure to prevent against -// inadvertent misuses of MutexLock like "MutexLock(&mu)" rather than -// "MutexLock l(&mu)". Hence the typedef trick below. -class GTestMutexLock { - public: - explicit GTestMutexLock(Mutex*) {} // NOLINT -}; - -typedef GTestMutexLock MutexLock; - -template -class ThreadLocal { - public: - ThreadLocal() : value_() {} - explicit ThreadLocal(const T& value) : value_(value) {} - T* pointer() { return &value_; } - const T* pointer() const { return &value_; } - const T& get() const { return value_; } - void set(const T& value) { value_ = value; } - private: - T value_; -}; - -#endif // GTEST_IS_THREADSAFE - -// Returns the number of threads running in the process, or 0 to indicate that -// we cannot detect it. -GTEST_API_ size_t GetThreadCount(); - -// Passing non-POD classes through ellipsis (...) crashes the ARM -// compiler and generates a warning in Sun Studio. The Nokia Symbian -// and the IBM XL C/C++ compiler try to instantiate a copy constructor -// for objects passed through ellipsis (...), failing for uncopyable -// objects. We define this to ensure that only POD is passed through -// ellipsis on these systems. -#if defined(__SYMBIAN32__) || defined(__IBMCPP__) || defined(__SUNPRO_CC) -// We lose support for NULL detection where the compiler doesn't like -// passing non-POD classes through ellipsis (...). -# define GTEST_ELLIPSIS_NEEDS_POD_ 1 -#else -# define GTEST_CAN_COMPARE_NULL 1 -#endif - -// The Nokia Symbian and IBM XL C/C++ compilers cannot decide between -// const T& and const T* in a function template. These compilers -// _can_ decide between class template specializations for T and T*, -// so a tr1::type_traits-like is_pointer works. -#if defined(__SYMBIAN32__) || defined(__IBMCPP__) -# define GTEST_NEEDS_IS_POINTER_ 1 -#endif - -template -struct bool_constant { - typedef bool_constant type; - static const bool value = bool_value; -}; -template const bool bool_constant::value; - -typedef bool_constant false_type; -typedef bool_constant true_type; - -template -struct is_pointer : public false_type {}; - -template -struct is_pointer : public true_type {}; - -template -struct IteratorTraits { - typedef typename Iterator::value_type value_type; -}; - -template -struct IteratorTraits { - typedef T value_type; -}; - -template -struct IteratorTraits { - typedef T value_type; -}; - -#if GTEST_OS_WINDOWS -# define GTEST_PATH_SEP_ "\\" -# define GTEST_HAS_ALT_PATH_SEP_ 1 -// The biggest signed integer type the compiler supports. -typedef __int64 BiggestInt; -#else -# define GTEST_PATH_SEP_ "/" -# define GTEST_HAS_ALT_PATH_SEP_ 0 -typedef long long BiggestInt; // NOLINT -#endif // GTEST_OS_WINDOWS - -// Utilities for char. - -// isspace(int ch) and friends accept an unsigned char or EOF. char -// may be signed, depending on the compiler (or compiler flags). -// Therefore we need to cast a char to unsigned char before calling -// isspace(), etc. - -inline bool IsAlpha(char ch) { - return isalpha(static_cast(ch)) != 0; -} -inline bool IsAlNum(char ch) { - return isalnum(static_cast(ch)) != 0; -} -inline bool IsDigit(char ch) { - return isdigit(static_cast(ch)) != 0; -} -inline bool IsLower(char ch) { - return islower(static_cast(ch)) != 0; -} -inline bool IsSpace(char ch) { - return isspace(static_cast(ch)) != 0; -} -inline bool IsUpper(char ch) { - return isupper(static_cast(ch)) != 0; -} -inline bool IsXDigit(char ch) { - return isxdigit(static_cast(ch)) != 0; -} -inline bool IsXDigit(wchar_t ch) { - const unsigned char low_byte = static_cast(ch); - return ch == low_byte && isxdigit(low_byte) != 0; -} - -inline char ToLower(char ch) { - return static_cast(tolower(static_cast(ch))); -} -inline char ToUpper(char ch) { - return static_cast(toupper(static_cast(ch))); -} - -inline std::string StripTrailingSpaces(std::string str) { - std::string::iterator it = str.end(); - while (it != str.begin() && IsSpace(*--it)) - it = str.erase(it); - return str; -} - -// The testing::internal::posix namespace holds wrappers for common -// POSIX functions. These wrappers hide the differences between -// Windows/MSVC and POSIX systems. Since some compilers define these -// standard functions as macros, the wrapper cannot have the same name -// as the wrapped function. - -namespace posix { - -// Functions with a different name on Windows. - -#if GTEST_OS_WINDOWS - -typedef struct _stat StatStruct; - -# ifdef __BORLANDC__ -inline int IsATTY(int fd) { return isatty(fd); } -inline int StrCaseCmp(const char* s1, const char* s2) { - return stricmp(s1, s2); -} -inline char* StrDup(const char* src) { return strdup(src); } -# else // !__BORLANDC__ -# if GTEST_OS_WINDOWS_MOBILE -inline int IsATTY(int /* fd */) { return 0; } -# else -inline int IsATTY(int fd) { return _isatty(fd); } -# endif // GTEST_OS_WINDOWS_MOBILE -inline int StrCaseCmp(const char* s1, const char* s2) { - return _stricmp(s1, s2); -} -inline char* StrDup(const char* src) { return _strdup(src); } -# endif // __BORLANDC__ - -# if GTEST_OS_WINDOWS_MOBILE -inline int FileNo(FILE* file) { return reinterpret_cast(_fileno(file)); } -// Stat(), RmDir(), and IsDir() are not needed on Windows CE at this -// time and thus not defined there. -# else -inline int FileNo(FILE* file) { return _fileno(file); } -inline int Stat(const char* path, StatStruct* buf) { return _stat(path, buf); } -inline int RmDir(const char* dir) { return _rmdir(dir); } -inline bool IsDir(const StatStruct& st) { - return (_S_IFDIR & st.st_mode) != 0; -} -# endif // GTEST_OS_WINDOWS_MOBILE - -#else - -typedef struct stat StatStruct; - -inline int FileNo(FILE* file) { return fileno(file); } -inline int IsATTY(int fd) { return isatty(fd); } -inline int Stat(const char* path, StatStruct* buf) { return stat(path, buf); } -inline int StrCaseCmp(const char* s1, const char* s2) { - return strcasecmp(s1, s2); -} -inline char* StrDup(const char* src) { return strdup(src); } -inline int RmDir(const char* dir) { return rmdir(dir); } -inline bool IsDir(const StatStruct& st) { return S_ISDIR(st.st_mode); } - -#endif // GTEST_OS_WINDOWS - -// Functions deprecated by MSVC 8.0. - -GTEST_DISABLE_MSC_WARNINGS_PUSH_(4996 /* deprecated function */) - -inline const char* StrNCpy(char* dest, const char* src, size_t n) { - return strncpy(dest, src, n); -} - -// ChDir(), FReopen(), FDOpen(), Read(), Write(), Close(), and -// StrError() aren't needed on Windows CE at this time and thus not -// defined there. - -#if !GTEST_OS_WINDOWS_MOBILE && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT -inline int ChDir(const char* dir) { return chdir(dir); } -#endif -inline FILE* FOpen(const char* path, const char* mode) { - return fopen(path, mode); -} -#if !GTEST_OS_WINDOWS_MOBILE -inline FILE *FReopen(const char* path, const char* mode, FILE* stream) { - return freopen(path, mode, stream); -} -inline FILE* FDOpen(int fd, const char* mode) { return fdopen(fd, mode); } -#endif -inline int FClose(FILE* fp) { return fclose(fp); } -#if !GTEST_OS_WINDOWS_MOBILE -inline int Read(int fd, void* buf, unsigned int count) { - return static_cast(read(fd, buf, count)); -} -inline int Write(int fd, const void* buf, unsigned int count) { - return static_cast(write(fd, buf, count)); -} -inline int Close(int fd) { return close(fd); } -inline const char* StrError(int errnum) { return strerror(errnum); } -#endif -inline const char* GetEnv(const char* name) { -#if GTEST_OS_WINDOWS_MOBILE || GTEST_OS_WINDOWS_PHONE | GTEST_OS_WINDOWS_RT - // We are on Windows CE, which has no environment variables. - static_cast(name); // To prevent 'unused argument' warning. - return NULL; -#elif defined(__BORLANDC__) || defined(__SunOS_5_8) || defined(__SunOS_5_9) - // Environment variables which we programmatically clear will be set to the - // empty string rather than unset (NULL). Handle that case. - const char* const env = getenv(name); - return (env != NULL && env[0] != '\0') ? env : NULL; -#else - return getenv(name); -#endif -} - -GTEST_DISABLE_MSC_WARNINGS_POP_() - -#if GTEST_OS_WINDOWS_MOBILE -// Windows CE has no C library. The abort() function is used in -// several places in Google Test. This implementation provides a reasonable -// imitation of standard behaviour. -void Abort(); -#else -inline void Abort() { abort(); } -#endif // GTEST_OS_WINDOWS_MOBILE - -} // namespace posix - -// MSVC "deprecates" snprintf and issues warnings wherever it is used. In -// order to avoid these warnings, we need to use _snprintf or _snprintf_s on -// MSVC-based platforms. We map the GTEST_SNPRINTF_ macro to the appropriate -// function in order to achieve that. We use macro definition here because -// snprintf is a variadic function. -#if _MSC_VER >= 1400 && !GTEST_OS_WINDOWS_MOBILE -// MSVC 2005 and above support variadic macros. -# define GTEST_SNPRINTF_(buffer, size, format, ...) \ - _snprintf_s(buffer, size, size, format, __VA_ARGS__) -#elif defined(_MSC_VER) -// Windows CE does not define _snprintf_s and MSVC prior to 2005 doesn't -// complain about _snprintf. -# define GTEST_SNPRINTF_ _snprintf -#else -# define GTEST_SNPRINTF_ snprintf -#endif - -// The maximum number a BiggestInt can represent. This definition -// works no matter BiggestInt is represented in one's complement or -// two's complement. -// -// We cannot rely on numeric_limits in STL, as __int64 and long long -// are not part of standard C++ and numeric_limits doesn't need to be -// defined for them. -const BiggestInt kMaxBiggestInt = - ~(static_cast(1) << (8*sizeof(BiggestInt) - 1)); - -// This template class serves as a compile-time function from size to -// type. It maps a size in bytes to a primitive type with that -// size. e.g. -// -// TypeWithSize<4>::UInt -// -// is typedef-ed to be unsigned int (unsigned integer made up of 4 -// bytes). -// -// Such functionality should belong to STL, but I cannot find it -// there. -// -// Google Test uses this class in the implementation of floating-point -// comparison. -// -// For now it only handles UInt (unsigned int) as that's all Google Test -// needs. Other types can be easily added in the future if need -// arises. -template -class TypeWithSize { - public: - // This prevents the user from using TypeWithSize with incorrect - // values of N. - typedef void UInt; -}; - -// The specialization for size 4. -template <> -class TypeWithSize<4> { - public: - // unsigned int has size 4 in both gcc and MSVC. - // - // As base/basictypes.h doesn't compile on Windows, we cannot use - // uint32, uint64, and etc here. - typedef int Int; - typedef unsigned int UInt; -}; - -// The specialization for size 8. -template <> -class TypeWithSize<8> { - public: -#if GTEST_OS_WINDOWS - typedef __int64 Int; - typedef unsigned __int64 UInt; -#else - typedef long long Int; // NOLINT - typedef unsigned long long UInt; // NOLINT -#endif // GTEST_OS_WINDOWS -}; - -// Integer types of known sizes. -typedef TypeWithSize<4>::Int Int32; -typedef TypeWithSize<4>::UInt UInt32; -typedef TypeWithSize<8>::Int Int64; -typedef TypeWithSize<8>::UInt UInt64; -typedef TypeWithSize<8>::Int TimeInMillis; // Represents time in milliseconds. - -// Utilities for command line flags and environment variables. - -// Macro for referencing flags. -#if !defined(GTEST_FLAG) -# define GTEST_FLAG(name) FLAGS_gtest_##name -#endif // !defined(GTEST_FLAG) - -#if !defined(GTEST_USE_OWN_FLAGFILE_FLAG_) -# define GTEST_USE_OWN_FLAGFILE_FLAG_ 1 -#endif // !defined(GTEST_USE_OWN_FLAGFILE_FLAG_) - -#if !defined(GTEST_DECLARE_bool_) -# define GTEST_FLAG_SAVER_ ::testing::internal::GTestFlagSaver - -// Macros for declaring flags. -# define GTEST_DECLARE_bool_(name) GTEST_API_ extern bool GTEST_FLAG(name) -# define GTEST_DECLARE_int32_(name) \ - GTEST_API_ extern ::testing::internal::Int32 GTEST_FLAG(name) -#define GTEST_DECLARE_string_(name) \ - GTEST_API_ extern ::std::string GTEST_FLAG(name) - -// Macros for defining flags. -#define GTEST_DEFINE_bool_(name, default_val, doc) \ - GTEST_API_ bool GTEST_FLAG(name) = (default_val) -#define GTEST_DEFINE_int32_(name, default_val, doc) \ - GTEST_API_ ::testing::internal::Int32 GTEST_FLAG(name) = (default_val) -#define GTEST_DEFINE_string_(name, default_val, doc) \ - GTEST_API_ ::std::string GTEST_FLAG(name) = (default_val) - -#endif // !defined(GTEST_DECLARE_bool_) - -// Thread annotations -#if !defined(GTEST_EXCLUSIVE_LOCK_REQUIRED_) -# define GTEST_EXCLUSIVE_LOCK_REQUIRED_(locks) -# define GTEST_LOCK_EXCLUDED_(locks) -#endif // !defined(GTEST_EXCLUSIVE_LOCK_REQUIRED_) - -// Parses 'str' for a 32-bit signed integer. If successful, writes the result -// to *value and returns true; otherwise leaves *value unchanged and returns -// false. -// TODO(chandlerc): Find a better way to refactor flag and environment parsing -// out of both gtest-port.cc and gtest.cc to avoid exporting this utility -// function. -bool ParseInt32(const Message& src_text, const char* str, Int32* value); - -// Parses a bool/Int32/string from the environment variable -// corresponding to the given Google Test flag. -bool BoolFromGTestEnv(const char* flag, bool default_val); -GTEST_API_ Int32 Int32FromGTestEnv(const char* flag, Int32 default_val); -std::string StringFromGTestEnv(const char* flag, const char* default_val); - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_PORT_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-string.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-string.h deleted file mode 100644 index 97f1a7fdd2c..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-string.h +++ /dev/null @@ -1,167 +0,0 @@ -// Copyright 2005, Google Inc. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Authors: wan@google.com (Zhanyong Wan), eefacm@gmail.com (Sean Mcafee) -// -// The Google C++ Testing Framework (Google Test) -// -// This header file declares the String class and functions used internally by -// Google Test. They are subject to change without notice. They should not used -// by code external to Google Test. -// -// This header file is #included by . -// It should not be #included by other files. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_STRING_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_STRING_H_ - -#ifdef __BORLANDC__ -// string.h is not guaranteed to provide strcpy on C++ Builder. -# include -#endif - -#include -#include - -#include "gtest/internal/gtest-port.h" - -namespace testing { -namespace internal { - -// String - an abstract class holding static string utilities. -class GTEST_API_ String { - public: - // Static utility methods - - // Clones a 0-terminated C string, allocating memory using new. The - // caller is responsible for deleting the return value using - // delete[]. Returns the cloned string, or NULL if the input is - // NULL. - // - // This is different from strdup() in string.h, which allocates - // memory using malloc(). - static const char* CloneCString(const char* c_str); - -#if GTEST_OS_WINDOWS_MOBILE - // Windows CE does not have the 'ANSI' versions of Win32 APIs. To be - // able to pass strings to Win32 APIs on CE we need to convert them - // to 'Unicode', UTF-16. - - // Creates a UTF-16 wide string from the given ANSI string, allocating - // memory using new. The caller is responsible for deleting the return - // value using delete[]. Returns the wide string, or NULL if the - // input is NULL. - // - // The wide string is created using the ANSI codepage (CP_ACP) to - // match the behaviour of the ANSI versions of Win32 calls and the - // C runtime. - static LPCWSTR AnsiToUtf16(const char* c_str); - - // Creates an ANSI string from the given wide string, allocating - // memory using new. The caller is responsible for deleting the return - // value using delete[]. Returns the ANSI string, or NULL if the - // input is NULL. - // - // The returned string is created using the ANSI codepage (CP_ACP) to - // match the behaviour of the ANSI versions of Win32 calls and the - // C runtime. - static const char* Utf16ToAnsi(LPCWSTR utf16_str); -#endif - - // Compares two C strings. Returns true iff they have the same content. - // - // Unlike strcmp(), this function can handle NULL argument(s). A - // NULL C string is considered different to any non-NULL C string, - // including the empty string. - static bool CStringEquals(const char* lhs, const char* rhs); - - // Converts a wide C string to a String using the UTF-8 encoding. - // NULL will be converted to "(null)". If an error occurred during - // the conversion, "(failed to convert from wide string)" is - // returned. - static std::string ShowWideCString(const wchar_t* wide_c_str); - - // Compares two wide C strings. Returns true iff they have the same - // content. - // - // Unlike wcscmp(), this function can handle NULL argument(s). A - // NULL C string is considered different to any non-NULL C string, - // including the empty string. - static bool WideCStringEquals(const wchar_t* lhs, const wchar_t* rhs); - - // Compares two C strings, ignoring case. Returns true iff they - // have the same content. - // - // Unlike strcasecmp(), this function can handle NULL argument(s). - // A NULL C string is considered different to any non-NULL C string, - // including the empty string. - static bool CaseInsensitiveCStringEquals(const char* lhs, - const char* rhs); - - // Compares two wide C strings, ignoring case. Returns true iff they - // have the same content. - // - // Unlike wcscasecmp(), this function can handle NULL argument(s). - // A NULL C string is considered different to any non-NULL wide C string, - // including the empty string. - // NB: The implementations on different platforms slightly differ. - // On windows, this method uses _wcsicmp which compares according to LC_CTYPE - // environment variable. On GNU platform this method uses wcscasecmp - // which compares according to LC_CTYPE category of the current locale. - // On MacOS X, it uses towlower, which also uses LC_CTYPE category of the - // current locale. - static bool CaseInsensitiveWideCStringEquals(const wchar_t* lhs, - const wchar_t* rhs); - - // Returns true iff the given string ends with the given suffix, ignoring - // case. Any string is considered to end with an empty suffix. - static bool EndsWithCaseInsensitive( - const std::string& str, const std::string& suffix); - - // Formats an int value as "%02d". - static std::string FormatIntWidth2(int value); // "%02d" for width == 2 - - // Formats an int value as "%X". - static std::string FormatHexInt(int value); - - // Formats a byte as "%02X". - static std::string FormatByte(unsigned char value); - - private: - String(); // Not meant to be instantiated. -}; // class String - -// Gets the content of the stringstream's buffer as an std::string. Each '\0' -// character in the buffer is replaced with "\\0". -GTEST_API_ std::string StringStreamToString(::std::stringstream* stream); - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_STRING_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h deleted file mode 100644 index e9b405340a8..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h +++ /dev/null @@ -1,1020 +0,0 @@ -// This file was GENERATED by command: -// pump.py gtest-tuple.h.pump -// DO NOT EDIT BY HAND!!! - -// Copyright 2009 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -// Implements a subset of TR1 tuple needed by Google Test and Google Mock. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ - -#include // For ::std::pair. - -// The compiler used in Symbian has a bug that prevents us from declaring the -// tuple template as a friend (it complains that tuple is redefined). This -// hack bypasses the bug by declaring the members that should otherwise be -// private as public. -// Sun Studio versions < 12 also have the above bug. -#if defined(__SYMBIAN32__) || (defined(__SUNPRO_CC) && __SUNPRO_CC < 0x590) -# define GTEST_DECLARE_TUPLE_AS_FRIEND_ public: -#else -# define GTEST_DECLARE_TUPLE_AS_FRIEND_ \ - template friend class tuple; \ - private: -#endif - -// Visual Studio 2010, 2012, and 2013 define symbols in std::tr1 that conflict -// with our own definitions. Therefore using our own tuple does not work on -// those compilers. -#if defined(_MSC_VER) && _MSC_VER >= 1600 /* 1600 is Visual Studio 2010 */ -# error "gtest's tuple doesn't compile on Visual Studio 2010 or later. \ -GTEST_USE_OWN_TR1_TUPLE must be set to 0 on those compilers." -#endif - -// GTEST_n_TUPLE_(T) is the type of an n-tuple. -#define GTEST_0_TUPLE_(T) tuple<> -#define GTEST_1_TUPLE_(T) tuple -#define GTEST_2_TUPLE_(T) tuple -#define GTEST_3_TUPLE_(T) tuple -#define GTEST_4_TUPLE_(T) tuple -#define GTEST_5_TUPLE_(T) tuple -#define GTEST_6_TUPLE_(T) tuple -#define GTEST_7_TUPLE_(T) tuple -#define GTEST_8_TUPLE_(T) tuple -#define GTEST_9_TUPLE_(T) tuple -#define GTEST_10_TUPLE_(T) tuple - -// GTEST_n_TYPENAMES_(T) declares a list of n typenames. -#define GTEST_0_TYPENAMES_(T) -#define GTEST_1_TYPENAMES_(T) typename T##0 -#define GTEST_2_TYPENAMES_(T) typename T##0, typename T##1 -#define GTEST_3_TYPENAMES_(T) typename T##0, typename T##1, typename T##2 -#define GTEST_4_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3 -#define GTEST_5_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4 -#define GTEST_6_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4, typename T##5 -#define GTEST_7_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4, typename T##5, typename T##6 -#define GTEST_8_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4, typename T##5, typename T##6, typename T##7 -#define GTEST_9_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4, typename T##5, typename T##6, \ - typename T##7, typename T##8 -#define GTEST_10_TYPENAMES_(T) typename T##0, typename T##1, typename T##2, \ - typename T##3, typename T##4, typename T##5, typename T##6, \ - typename T##7, typename T##8, typename T##9 - -// In theory, defining stuff in the ::std namespace is undefined -// behavior. We can do this as we are playing the role of a standard -// library vendor. -namespace std { -namespace tr1 { - -template -class tuple; - -// Anything in namespace gtest_internal is Google Test's INTERNAL -// IMPLEMENTATION DETAIL and MUST NOT BE USED DIRECTLY in user code. -namespace gtest_internal { - -// ByRef::type is T if T is a reference; otherwise it's const T&. -template -struct ByRef { typedef const T& type; }; // NOLINT -template -struct ByRef { typedef T& type; }; // NOLINT - -// A handy wrapper for ByRef. -#define GTEST_BY_REF_(T) typename ::std::tr1::gtest_internal::ByRef::type - -// AddRef::type is T if T is a reference; otherwise it's T&. This -// is the same as tr1::add_reference::type. -template -struct AddRef { typedef T& type; }; // NOLINT -template -struct AddRef { typedef T& type; }; // NOLINT - -// A handy wrapper for AddRef. -#define GTEST_ADD_REF_(T) typename ::std::tr1::gtest_internal::AddRef::type - -// A helper for implementing get(). -template class Get; - -// A helper for implementing tuple_element. kIndexValid is true -// iff k < the number of fields in tuple type T. -template -struct TupleElement; - -template -struct TupleElement { - typedef T0 type; -}; - -template -struct TupleElement { - typedef T1 type; -}; - -template -struct TupleElement { - typedef T2 type; -}; - -template -struct TupleElement { - typedef T3 type; -}; - -template -struct TupleElement { - typedef T4 type; -}; - -template -struct TupleElement { - typedef T5 type; -}; - -template -struct TupleElement { - typedef T6 type; -}; - -template -struct TupleElement { - typedef T7 type; -}; - -template -struct TupleElement { - typedef T8 type; -}; - -template -struct TupleElement { - typedef T9 type; -}; - -} // namespace gtest_internal - -template <> -class tuple<> { - public: - tuple() {} - tuple(const tuple& /* t */) {} - tuple& operator=(const tuple& /* t */) { return *this; } -}; - -template -class GTEST_1_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0) : f0_(f0) {} - - tuple(const tuple& t) : f0_(t.f0_) {} - - template - tuple(const GTEST_1_TUPLE_(U)& t) : f0_(t.f0_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_1_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_1_TUPLE_(U)& t) { - f0_ = t.f0_; - return *this; - } - - T0 f0_; -}; - -template -class GTEST_2_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1) : f0_(f0), - f1_(f1) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_) {} - - template - tuple(const GTEST_2_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_) {} - template - tuple(const ::std::pair& p) : f0_(p.first), f1_(p.second) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_2_TUPLE_(U)& t) { - return CopyFrom(t); - } - template - tuple& operator=(const ::std::pair& p) { - f0_ = p.first; - f1_ = p.second; - return *this; - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_2_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - return *this; - } - - T0 f0_; - T1 f1_; -}; - -template -class GTEST_3_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2) : f0_(f0), f1_(f1), f2_(f2) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_) {} - - template - tuple(const GTEST_3_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_3_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_3_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; -}; - -template -class GTEST_4_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3) : f0_(f0), f1_(f1), f2_(f2), - f3_(f3) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_) {} - - template - tuple(const GTEST_4_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_4_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_4_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; -}; - -template -class GTEST_5_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, - GTEST_BY_REF_(T4) f4) : f0_(f0), f1_(f1), f2_(f2), f3_(f3), f4_(f4) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_) {} - - template - tuple(const GTEST_5_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_5_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_5_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; -}; - -template -class GTEST_6_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_(), f5_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, GTEST_BY_REF_(T4) f4, - GTEST_BY_REF_(T5) f5) : f0_(f0), f1_(f1), f2_(f2), f3_(f3), f4_(f4), - f5_(f5) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_), f5_(t.f5_) {} - - template - tuple(const GTEST_6_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_), f5_(t.f5_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_6_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_6_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - f5_ = t.f5_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; - T5 f5_; -}; - -template -class GTEST_7_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_(), f5_(), f6_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, GTEST_BY_REF_(T4) f4, - GTEST_BY_REF_(T5) f5, GTEST_BY_REF_(T6) f6) : f0_(f0), f1_(f1), f2_(f2), - f3_(f3), f4_(f4), f5_(f5), f6_(f6) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_), f5_(t.f5_), f6_(t.f6_) {} - - template - tuple(const GTEST_7_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_), f5_(t.f5_), f6_(t.f6_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_7_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_7_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - f5_ = t.f5_; - f6_ = t.f6_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; - T5 f5_; - T6 f6_; -}; - -template -class GTEST_8_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_(), f5_(), f6_(), f7_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, GTEST_BY_REF_(T4) f4, - GTEST_BY_REF_(T5) f5, GTEST_BY_REF_(T6) f6, - GTEST_BY_REF_(T7) f7) : f0_(f0), f1_(f1), f2_(f2), f3_(f3), f4_(f4), - f5_(f5), f6_(f6), f7_(f7) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_) {} - - template - tuple(const GTEST_8_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_8_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_8_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - f5_ = t.f5_; - f6_ = t.f6_; - f7_ = t.f7_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; - T5 f5_; - T6 f6_; - T7 f7_; -}; - -template -class GTEST_9_TUPLE_(T) { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_(), f5_(), f6_(), f7_(), f8_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, GTEST_BY_REF_(T4) f4, - GTEST_BY_REF_(T5) f5, GTEST_BY_REF_(T6) f6, GTEST_BY_REF_(T7) f7, - GTEST_BY_REF_(T8) f8) : f0_(f0), f1_(f1), f2_(f2), f3_(f3), f4_(f4), - f5_(f5), f6_(f6), f7_(f7), f8_(f8) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_), f8_(t.f8_) {} - - template - tuple(const GTEST_9_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_), f8_(t.f8_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_9_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_9_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - f5_ = t.f5_; - f6_ = t.f6_; - f7_ = t.f7_; - f8_ = t.f8_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; - T5 f5_; - T6 f6_; - T7 f7_; - T8 f8_; -}; - -template -class tuple { - public: - template friend class gtest_internal::Get; - - tuple() : f0_(), f1_(), f2_(), f3_(), f4_(), f5_(), f6_(), f7_(), f8_(), - f9_() {} - - explicit tuple(GTEST_BY_REF_(T0) f0, GTEST_BY_REF_(T1) f1, - GTEST_BY_REF_(T2) f2, GTEST_BY_REF_(T3) f3, GTEST_BY_REF_(T4) f4, - GTEST_BY_REF_(T5) f5, GTEST_BY_REF_(T6) f6, GTEST_BY_REF_(T7) f7, - GTEST_BY_REF_(T8) f8, GTEST_BY_REF_(T9) f9) : f0_(f0), f1_(f1), f2_(f2), - f3_(f3), f4_(f4), f5_(f5), f6_(f6), f7_(f7), f8_(f8), f9_(f9) {} - - tuple(const tuple& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), f3_(t.f3_), - f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_), f8_(t.f8_), f9_(t.f9_) {} - - template - tuple(const GTEST_10_TUPLE_(U)& t) : f0_(t.f0_), f1_(t.f1_), f2_(t.f2_), - f3_(t.f3_), f4_(t.f4_), f5_(t.f5_), f6_(t.f6_), f7_(t.f7_), f8_(t.f8_), - f9_(t.f9_) {} - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_10_TUPLE_(U)& t) { - return CopyFrom(t); - } - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_10_TUPLE_(U)& t) { - f0_ = t.f0_; - f1_ = t.f1_; - f2_ = t.f2_; - f3_ = t.f3_; - f4_ = t.f4_; - f5_ = t.f5_; - f6_ = t.f6_; - f7_ = t.f7_; - f8_ = t.f8_; - f9_ = t.f9_; - return *this; - } - - T0 f0_; - T1 f1_; - T2 f2_; - T3 f3_; - T4 f4_; - T5 f5_; - T6 f6_; - T7 f7_; - T8 f8_; - T9 f9_; -}; - -// 6.1.3.2 Tuple creation functions. - -// Known limitations: we don't support passing an -// std::tr1::reference_wrapper to make_tuple(). And we don't -// implement tie(). - -inline tuple<> make_tuple() { return tuple<>(); } - -template -inline GTEST_1_TUPLE_(T) make_tuple(const T0& f0) { - return GTEST_1_TUPLE_(T)(f0); -} - -template -inline GTEST_2_TUPLE_(T) make_tuple(const T0& f0, const T1& f1) { - return GTEST_2_TUPLE_(T)(f0, f1); -} - -template -inline GTEST_3_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2) { - return GTEST_3_TUPLE_(T)(f0, f1, f2); -} - -template -inline GTEST_4_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3) { - return GTEST_4_TUPLE_(T)(f0, f1, f2, f3); -} - -template -inline GTEST_5_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4) { - return GTEST_5_TUPLE_(T)(f0, f1, f2, f3, f4); -} - -template -inline GTEST_6_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4, const T5& f5) { - return GTEST_6_TUPLE_(T)(f0, f1, f2, f3, f4, f5); -} - -template -inline GTEST_7_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4, const T5& f5, const T6& f6) { - return GTEST_7_TUPLE_(T)(f0, f1, f2, f3, f4, f5, f6); -} - -template -inline GTEST_8_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4, const T5& f5, const T6& f6, const T7& f7) { - return GTEST_8_TUPLE_(T)(f0, f1, f2, f3, f4, f5, f6, f7); -} - -template -inline GTEST_9_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4, const T5& f5, const T6& f6, const T7& f7, - const T8& f8) { - return GTEST_9_TUPLE_(T)(f0, f1, f2, f3, f4, f5, f6, f7, f8); -} - -template -inline GTEST_10_TUPLE_(T) make_tuple(const T0& f0, const T1& f1, const T2& f2, - const T3& f3, const T4& f4, const T5& f5, const T6& f6, const T7& f7, - const T8& f8, const T9& f9) { - return GTEST_10_TUPLE_(T)(f0, f1, f2, f3, f4, f5, f6, f7, f8, f9); -} - -// 6.1.3.3 Tuple helper classes. - -template struct tuple_size; - -template -struct tuple_size { - static const int value = 0; -}; - -template -struct tuple_size { - static const int value = 1; -}; - -template -struct tuple_size { - static const int value = 2; -}; - -template -struct tuple_size { - static const int value = 3; -}; - -template -struct tuple_size { - static const int value = 4; -}; - -template -struct tuple_size { - static const int value = 5; -}; - -template -struct tuple_size { - static const int value = 6; -}; - -template -struct tuple_size { - static const int value = 7; -}; - -template -struct tuple_size { - static const int value = 8; -}; - -template -struct tuple_size { - static const int value = 9; -}; - -template -struct tuple_size { - static const int value = 10; -}; - -template -struct tuple_element { - typedef typename gtest_internal::TupleElement< - k < (tuple_size::value), k, Tuple>::type type; -}; - -#define GTEST_TUPLE_ELEMENT_(k, Tuple) typename tuple_element::type - -// 6.1.3.4 Element access. - -namespace gtest_internal { - -template <> -class Get<0> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(0, Tuple)) - Field(Tuple& t) { return t.f0_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(0, Tuple)) - ConstField(const Tuple& t) { return t.f0_; } -}; - -template <> -class Get<1> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(1, Tuple)) - Field(Tuple& t) { return t.f1_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(1, Tuple)) - ConstField(const Tuple& t) { return t.f1_; } -}; - -template <> -class Get<2> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(2, Tuple)) - Field(Tuple& t) { return t.f2_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(2, Tuple)) - ConstField(const Tuple& t) { return t.f2_; } -}; - -template <> -class Get<3> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(3, Tuple)) - Field(Tuple& t) { return t.f3_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(3, Tuple)) - ConstField(const Tuple& t) { return t.f3_; } -}; - -template <> -class Get<4> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(4, Tuple)) - Field(Tuple& t) { return t.f4_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(4, Tuple)) - ConstField(const Tuple& t) { return t.f4_; } -}; - -template <> -class Get<5> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(5, Tuple)) - Field(Tuple& t) { return t.f5_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(5, Tuple)) - ConstField(const Tuple& t) { return t.f5_; } -}; - -template <> -class Get<6> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(6, Tuple)) - Field(Tuple& t) { return t.f6_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(6, Tuple)) - ConstField(const Tuple& t) { return t.f6_; } -}; - -template <> -class Get<7> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(7, Tuple)) - Field(Tuple& t) { return t.f7_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(7, Tuple)) - ConstField(const Tuple& t) { return t.f7_; } -}; - -template <> -class Get<8> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(8, Tuple)) - Field(Tuple& t) { return t.f8_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(8, Tuple)) - ConstField(const Tuple& t) { return t.f8_; } -}; - -template <> -class Get<9> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(9, Tuple)) - Field(Tuple& t) { return t.f9_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(9, Tuple)) - ConstField(const Tuple& t) { return t.f9_; } -}; - -} // namespace gtest_internal - -template -GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(k, GTEST_10_TUPLE_(T))) -get(GTEST_10_TUPLE_(T)& t) { - return gtest_internal::Get::Field(t); -} - -template -GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(k, GTEST_10_TUPLE_(T))) -get(const GTEST_10_TUPLE_(T)& t) { - return gtest_internal::Get::ConstField(t); -} - -// 6.1.3.5 Relational operators - -// We only implement == and !=, as we don't have a need for the rest yet. - -namespace gtest_internal { - -// SameSizeTuplePrefixComparator::Eq(t1, t2) returns true if the -// first k fields of t1 equals the first k fields of t2. -// SameSizeTuplePrefixComparator(k1, k2) would be a compiler error if -// k1 != k2. -template -struct SameSizeTuplePrefixComparator; - -template <> -struct SameSizeTuplePrefixComparator<0, 0> { - template - static bool Eq(const Tuple1& /* t1 */, const Tuple2& /* t2 */) { - return true; - } -}; - -template -struct SameSizeTuplePrefixComparator { - template - static bool Eq(const Tuple1& t1, const Tuple2& t2) { - return SameSizeTuplePrefixComparator::Eq(t1, t2) && - ::std::tr1::get(t1) == ::std::tr1::get(t2); - } -}; - -} // namespace gtest_internal - -template -inline bool operator==(const GTEST_10_TUPLE_(T)& t, - const GTEST_10_TUPLE_(U)& u) { - return gtest_internal::SameSizeTuplePrefixComparator< - tuple_size::value, - tuple_size::value>::Eq(t, u); -} - -template -inline bool operator!=(const GTEST_10_TUPLE_(T)& t, - const GTEST_10_TUPLE_(U)& u) { return !(t == u); } - -// 6.1.4 Pairs. -// Unimplemented. - -} // namespace tr1 -} // namespace std - -#undef GTEST_0_TUPLE_ -#undef GTEST_1_TUPLE_ -#undef GTEST_2_TUPLE_ -#undef GTEST_3_TUPLE_ -#undef GTEST_4_TUPLE_ -#undef GTEST_5_TUPLE_ -#undef GTEST_6_TUPLE_ -#undef GTEST_7_TUPLE_ -#undef GTEST_8_TUPLE_ -#undef GTEST_9_TUPLE_ -#undef GTEST_10_TUPLE_ - -#undef GTEST_0_TYPENAMES_ -#undef GTEST_1_TYPENAMES_ -#undef GTEST_2_TYPENAMES_ -#undef GTEST_3_TYPENAMES_ -#undef GTEST_4_TYPENAMES_ -#undef GTEST_5_TYPENAMES_ -#undef GTEST_6_TYPENAMES_ -#undef GTEST_7_TYPENAMES_ -#undef GTEST_8_TYPENAMES_ -#undef GTEST_9_TYPENAMES_ -#undef GTEST_10_TYPENAMES_ - -#undef GTEST_DECLARE_TUPLE_AS_FRIEND_ -#undef GTEST_BY_REF_ -#undef GTEST_ADD_REF_ -#undef GTEST_TUPLE_ELEMENT_ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h.pump b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h.pump deleted file mode 100644 index 429ddfeecaa..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-tuple.h.pump +++ /dev/null @@ -1,347 +0,0 @@ -$$ -*- mode: c++; -*- -$var n = 10 $$ Maximum number of tuple fields we want to support. -$$ This meta comment fixes auto-indentation in Emacs. }} -// Copyright 2009 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -// Implements a subset of TR1 tuple needed by Google Test and Google Mock. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ - -#include // For ::std::pair. - -// The compiler used in Symbian has a bug that prevents us from declaring the -// tuple template as a friend (it complains that tuple is redefined). This -// hack bypasses the bug by declaring the members that should otherwise be -// private as public. -// Sun Studio versions < 12 also have the above bug. -#if defined(__SYMBIAN32__) || (defined(__SUNPRO_CC) && __SUNPRO_CC < 0x590) -# define GTEST_DECLARE_TUPLE_AS_FRIEND_ public: -#else -# define GTEST_DECLARE_TUPLE_AS_FRIEND_ \ - template friend class tuple; \ - private: -#endif - -// Visual Studio 2010, 2012, and 2013 define symbols in std::tr1 that conflict -// with our own definitions. Therefore using our own tuple does not work on -// those compilers. -#if defined(_MSC_VER) && _MSC_VER >= 1600 /* 1600 is Visual Studio 2010 */ -# error "gtest's tuple doesn't compile on Visual Studio 2010 or later. \ -GTEST_USE_OWN_TR1_TUPLE must be set to 0 on those compilers." -#endif - - -$range i 0..n-1 -$range j 0..n -$range k 1..n -// GTEST_n_TUPLE_(T) is the type of an n-tuple. -#define GTEST_0_TUPLE_(T) tuple<> - -$for k [[ -$range m 0..k-1 -$range m2 k..n-1 -#define GTEST_$(k)_TUPLE_(T) tuple<$for m, [[T##$m]]$for m2 [[, void]]> - -]] - -// GTEST_n_TYPENAMES_(T) declares a list of n typenames. - -$for j [[ -$range m 0..j-1 -#define GTEST_$(j)_TYPENAMES_(T) $for m, [[typename T##$m]] - - -]] - -// In theory, defining stuff in the ::std namespace is undefined -// behavior. We can do this as we are playing the role of a standard -// library vendor. -namespace std { -namespace tr1 { - -template <$for i, [[typename T$i = void]]> -class tuple; - -// Anything in namespace gtest_internal is Google Test's INTERNAL -// IMPLEMENTATION DETAIL and MUST NOT BE USED DIRECTLY in user code. -namespace gtest_internal { - -// ByRef::type is T if T is a reference; otherwise it's const T&. -template -struct ByRef { typedef const T& type; }; // NOLINT -template -struct ByRef { typedef T& type; }; // NOLINT - -// A handy wrapper for ByRef. -#define GTEST_BY_REF_(T) typename ::std::tr1::gtest_internal::ByRef::type - -// AddRef::type is T if T is a reference; otherwise it's T&. This -// is the same as tr1::add_reference::type. -template -struct AddRef { typedef T& type; }; // NOLINT -template -struct AddRef { typedef T& type; }; // NOLINT - -// A handy wrapper for AddRef. -#define GTEST_ADD_REF_(T) typename ::std::tr1::gtest_internal::AddRef::type - -// A helper for implementing get(). -template class Get; - -// A helper for implementing tuple_element. kIndexValid is true -// iff k < the number of fields in tuple type T. -template -struct TupleElement; - - -$for i [[ -template -struct TupleElement { - typedef T$i type; -}; - - -]] -} // namespace gtest_internal - -template <> -class tuple<> { - public: - tuple() {} - tuple(const tuple& /* t */) {} - tuple& operator=(const tuple& /* t */) { return *this; } -}; - - -$for k [[ -$range m 0..k-1 -template -class $if k < n [[GTEST_$(k)_TUPLE_(T)]] $else [[tuple]] { - public: - template friend class gtest_internal::Get; - - tuple() : $for m, [[f$(m)_()]] {} - - explicit tuple($for m, [[GTEST_BY_REF_(T$m) f$m]]) : [[]] -$for m, [[f$(m)_(f$m)]] {} - - tuple(const tuple& t) : $for m, [[f$(m)_(t.f$(m)_)]] {} - - template - tuple(const GTEST_$(k)_TUPLE_(U)& t) : $for m, [[f$(m)_(t.f$(m)_)]] {} - -$if k == 2 [[ - template - tuple(const ::std::pair& p) : f0_(p.first), f1_(p.second) {} - -]] - - tuple& operator=(const tuple& t) { return CopyFrom(t); } - - template - tuple& operator=(const GTEST_$(k)_TUPLE_(U)& t) { - return CopyFrom(t); - } - -$if k == 2 [[ - template - tuple& operator=(const ::std::pair& p) { - f0_ = p.first; - f1_ = p.second; - return *this; - } - -]] - - GTEST_DECLARE_TUPLE_AS_FRIEND_ - - template - tuple& CopyFrom(const GTEST_$(k)_TUPLE_(U)& t) { - -$for m [[ - f$(m)_ = t.f$(m)_; - -]] - return *this; - } - - -$for m [[ - T$m f$(m)_; - -]] -}; - - -]] -// 6.1.3.2 Tuple creation functions. - -// Known limitations: we don't support passing an -// std::tr1::reference_wrapper to make_tuple(). And we don't -// implement tie(). - -inline tuple<> make_tuple() { return tuple<>(); } - -$for k [[ -$range m 0..k-1 - -template -inline GTEST_$(k)_TUPLE_(T) make_tuple($for m, [[const T$m& f$m]]) { - return GTEST_$(k)_TUPLE_(T)($for m, [[f$m]]); -} - -]] - -// 6.1.3.3 Tuple helper classes. - -template struct tuple_size; - - -$for j [[ -template -struct tuple_size { - static const int value = $j; -}; - - -]] -template -struct tuple_element { - typedef typename gtest_internal::TupleElement< - k < (tuple_size::value), k, Tuple>::type type; -}; - -#define GTEST_TUPLE_ELEMENT_(k, Tuple) typename tuple_element::type - -// 6.1.3.4 Element access. - -namespace gtest_internal { - - -$for i [[ -template <> -class Get<$i> { - public: - template - static GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_($i, Tuple)) - Field(Tuple& t) { return t.f$(i)_; } // NOLINT - - template - static GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_($i, Tuple)) - ConstField(const Tuple& t) { return t.f$(i)_; } -}; - - -]] -} // namespace gtest_internal - -template -GTEST_ADD_REF_(GTEST_TUPLE_ELEMENT_(k, GTEST_$(n)_TUPLE_(T))) -get(GTEST_$(n)_TUPLE_(T)& t) { - return gtest_internal::Get::Field(t); -} - -template -GTEST_BY_REF_(GTEST_TUPLE_ELEMENT_(k, GTEST_$(n)_TUPLE_(T))) -get(const GTEST_$(n)_TUPLE_(T)& t) { - return gtest_internal::Get::ConstField(t); -} - -// 6.1.3.5 Relational operators - -// We only implement == and !=, as we don't have a need for the rest yet. - -namespace gtest_internal { - -// SameSizeTuplePrefixComparator::Eq(t1, t2) returns true if the -// first k fields of t1 equals the first k fields of t2. -// SameSizeTuplePrefixComparator(k1, k2) would be a compiler error if -// k1 != k2. -template -struct SameSizeTuplePrefixComparator; - -template <> -struct SameSizeTuplePrefixComparator<0, 0> { - template - static bool Eq(const Tuple1& /* t1 */, const Tuple2& /* t2 */) { - return true; - } -}; - -template -struct SameSizeTuplePrefixComparator { - template - static bool Eq(const Tuple1& t1, const Tuple2& t2) { - return SameSizeTuplePrefixComparator::Eq(t1, t2) && - ::std::tr1::get(t1) == ::std::tr1::get(t2); - } -}; - -} // namespace gtest_internal - -template -inline bool operator==(const GTEST_$(n)_TUPLE_(T)& t, - const GTEST_$(n)_TUPLE_(U)& u) { - return gtest_internal::SameSizeTuplePrefixComparator< - tuple_size::value, - tuple_size::value>::Eq(t, u); -} - -template -inline bool operator!=(const GTEST_$(n)_TUPLE_(T)& t, - const GTEST_$(n)_TUPLE_(U)& u) { return !(t == u); } - -// 6.1.4 Pairs. -// Unimplemented. - -} // namespace tr1 -} // namespace std - - -$for j [[ -#undef GTEST_$(j)_TUPLE_ - -]] - - -$for j [[ -#undef GTEST_$(j)_TYPENAMES_ - -]] - -#undef GTEST_DECLARE_TUPLE_AS_FRIEND_ -#undef GTEST_BY_REF_ -#undef GTEST_ADD_REF_ -#undef GTEST_TUPLE_ELEMENT_ - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TUPLE_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h deleted file mode 100644 index e46f7cfcb48..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h +++ /dev/null @@ -1,3331 +0,0 @@ -// This file was GENERATED by command: -// pump.py gtest-type-util.h.pump -// DO NOT EDIT BY HAND!!! - -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -// Type utilities needed for implementing typed and type-parameterized -// tests. This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -// Currently we support at most 50 types in a list, and at most 50 -// type-parameterized tests in one type-parameterized test case. -// Please contact googletestframework@googlegroups.com if you need -// more. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ - -#include "gtest/internal/gtest-port.h" - -// #ifdef __GNUC__ is too general here. It is possible to use gcc without using -// libstdc++ (which is where cxxabi.h comes from). -# if GTEST_HAS_CXXABI_H_ -# include -# elif defined(__HP_aCC) -# include -# endif // GTEST_HASH_CXXABI_H_ - -namespace testing { -namespace internal { - -// GetTypeName() returns a human-readable name of type T. -// NB: This function is also used in Google Mock, so don't move it inside of -// the typed-test-only section below. -template -std::string GetTypeName() { -# if GTEST_HAS_RTTI - - const char* const name = typeid(T).name(); -# if GTEST_HAS_CXXABI_H_ || defined(__HP_aCC) - int status = 0; - // gcc's implementation of typeid(T).name() mangles the type name, - // so we have to demangle it. -# if GTEST_HAS_CXXABI_H_ - using abi::__cxa_demangle; -# endif // GTEST_HAS_CXXABI_H_ - char* const readable_name = __cxa_demangle(name, 0, 0, &status); - const std::string name_str(status == 0 ? readable_name : name); - free(readable_name); - return name_str; -# else - return name; -# endif // GTEST_HAS_CXXABI_H_ || __HP_aCC - -# else - - return ""; - -# endif // GTEST_HAS_RTTI -} - -#if GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -// AssertyTypeEq::type is defined iff T1 and T2 are the same -// type. This can be used as a compile-time assertion to ensure that -// two types are equal. - -template -struct AssertTypeEq; - -template -struct AssertTypeEq { - typedef bool type; -}; - -// A unique type used as the default value for the arguments of class -// template Types. This allows us to simulate variadic templates -// (e.g. Types, Type, and etc), which C++ doesn't -// support directly. -struct None {}; - -// The following family of struct and struct templates are used to -// represent type lists. In particular, TypesN -// represents a type list with N types (T1, T2, ..., and TN) in it. -// Except for Types0, every struct in the family has two member types: -// Head for the first type in the list, and Tail for the rest of the -// list. - -// The empty type list. -struct Types0 {}; - -// Type lists of length 1, 2, 3, and so on. - -template -struct Types1 { - typedef T1 Head; - typedef Types0 Tail; -}; -template -struct Types2 { - typedef T1 Head; - typedef Types1 Tail; -}; - -template -struct Types3 { - typedef T1 Head; - typedef Types2 Tail; -}; - -template -struct Types4 { - typedef T1 Head; - typedef Types3 Tail; -}; - -template -struct Types5 { - typedef T1 Head; - typedef Types4 Tail; -}; - -template -struct Types6 { - typedef T1 Head; - typedef Types5 Tail; -}; - -template -struct Types7 { - typedef T1 Head; - typedef Types6 Tail; -}; - -template -struct Types8 { - typedef T1 Head; - typedef Types7 Tail; -}; - -template -struct Types9 { - typedef T1 Head; - typedef Types8 Tail; -}; - -template -struct Types10 { - typedef T1 Head; - typedef Types9 Tail; -}; - -template -struct Types11 { - typedef T1 Head; - typedef Types10 Tail; -}; - -template -struct Types12 { - typedef T1 Head; - typedef Types11 Tail; -}; - -template -struct Types13 { - typedef T1 Head; - typedef Types12 Tail; -}; - -template -struct Types14 { - typedef T1 Head; - typedef Types13 Tail; -}; - -template -struct Types15 { - typedef T1 Head; - typedef Types14 Tail; -}; - -template -struct Types16 { - typedef T1 Head; - typedef Types15 Tail; -}; - -template -struct Types17 { - typedef T1 Head; - typedef Types16 Tail; -}; - -template -struct Types18 { - typedef T1 Head; - typedef Types17 Tail; -}; - -template -struct Types19 { - typedef T1 Head; - typedef Types18 Tail; -}; - -template -struct Types20 { - typedef T1 Head; - typedef Types19 Tail; -}; - -template -struct Types21 { - typedef T1 Head; - typedef Types20 Tail; -}; - -template -struct Types22 { - typedef T1 Head; - typedef Types21 Tail; -}; - -template -struct Types23 { - typedef T1 Head; - typedef Types22 Tail; -}; - -template -struct Types24 { - typedef T1 Head; - typedef Types23 Tail; -}; - -template -struct Types25 { - typedef T1 Head; - typedef Types24 Tail; -}; - -template -struct Types26 { - typedef T1 Head; - typedef Types25 Tail; -}; - -template -struct Types27 { - typedef T1 Head; - typedef Types26 Tail; -}; - -template -struct Types28 { - typedef T1 Head; - typedef Types27 Tail; -}; - -template -struct Types29 { - typedef T1 Head; - typedef Types28 Tail; -}; - -template -struct Types30 { - typedef T1 Head; - typedef Types29 Tail; -}; - -template -struct Types31 { - typedef T1 Head; - typedef Types30 Tail; -}; - -template -struct Types32 { - typedef T1 Head; - typedef Types31 Tail; -}; - -template -struct Types33 { - typedef T1 Head; - typedef Types32 Tail; -}; - -template -struct Types34 { - typedef T1 Head; - typedef Types33 Tail; -}; - -template -struct Types35 { - typedef T1 Head; - typedef Types34 Tail; -}; - -template -struct Types36 { - typedef T1 Head; - typedef Types35 Tail; -}; - -template -struct Types37 { - typedef T1 Head; - typedef Types36 Tail; -}; - -template -struct Types38 { - typedef T1 Head; - typedef Types37 Tail; -}; - -template -struct Types39 { - typedef T1 Head; - typedef Types38 Tail; -}; - -template -struct Types40 { - typedef T1 Head; - typedef Types39 Tail; -}; - -template -struct Types41 { - typedef T1 Head; - typedef Types40 Tail; -}; - -template -struct Types42 { - typedef T1 Head; - typedef Types41 Tail; -}; - -template -struct Types43 { - typedef T1 Head; - typedef Types42 Tail; -}; - -template -struct Types44 { - typedef T1 Head; - typedef Types43 Tail; -}; - -template -struct Types45 { - typedef T1 Head; - typedef Types44 Tail; -}; - -template -struct Types46 { - typedef T1 Head; - typedef Types45 Tail; -}; - -template -struct Types47 { - typedef T1 Head; - typedef Types46 Tail; -}; - -template -struct Types48 { - typedef T1 Head; - typedef Types47 Tail; -}; - -template -struct Types49 { - typedef T1 Head; - typedef Types48 Tail; -}; - -template -struct Types50 { - typedef T1 Head; - typedef Types49 Tail; -}; - - -} // namespace internal - -// We don't want to require the users to write TypesN<...> directly, -// as that would require them to count the length. Types<...> is much -// easier to write, but generates horrible messages when there is a -// compiler error, as gcc insists on printing out each template -// argument, even if it has the default value (this means Types -// will appear as Types in the compiler -// errors). -// -// Our solution is to combine the best part of the two approaches: a -// user would write Types, and Google Test will translate -// that to TypesN internally to make error messages -// readable. The translation is done by the 'type' member of the -// Types template. -template -struct Types { - typedef internal::Types50 type; -}; - -template <> -struct Types { - typedef internal::Types0 type; -}; -template -struct Types { - typedef internal::Types1 type; -}; -template -struct Types { - typedef internal::Types2 type; -}; -template -struct Types { - typedef internal::Types3 type; -}; -template -struct Types { - typedef internal::Types4 type; -}; -template -struct Types { - typedef internal::Types5 type; -}; -template -struct Types { - typedef internal::Types6 type; -}; -template -struct Types { - typedef internal::Types7 type; -}; -template -struct Types { - typedef internal::Types8 type; -}; -template -struct Types { - typedef internal::Types9 type; -}; -template -struct Types { - typedef internal::Types10 type; -}; -template -struct Types { - typedef internal::Types11 type; -}; -template -struct Types { - typedef internal::Types12 type; -}; -template -struct Types { - typedef internal::Types13 type; -}; -template -struct Types { - typedef internal::Types14 type; -}; -template -struct Types { - typedef internal::Types15 type; -}; -template -struct Types { - typedef internal::Types16 type; -}; -template -struct Types { - typedef internal::Types17 type; -}; -template -struct Types { - typedef internal::Types18 type; -}; -template -struct Types { - typedef internal::Types19 type; -}; -template -struct Types { - typedef internal::Types20 type; -}; -template -struct Types { - typedef internal::Types21 type; -}; -template -struct Types { - typedef internal::Types22 type; -}; -template -struct Types { - typedef internal::Types23 type; -}; -template -struct Types { - typedef internal::Types24 type; -}; -template -struct Types { - typedef internal::Types25 type; -}; -template -struct Types { - typedef internal::Types26 type; -}; -template -struct Types { - typedef internal::Types27 type; -}; -template -struct Types { - typedef internal::Types28 type; -}; -template -struct Types { - typedef internal::Types29 type; -}; -template -struct Types { - typedef internal::Types30 type; -}; -template -struct Types { - typedef internal::Types31 type; -}; -template -struct Types { - typedef internal::Types32 type; -}; -template -struct Types { - typedef internal::Types33 type; -}; -template -struct Types { - typedef internal::Types34 type; -}; -template -struct Types { - typedef internal::Types35 type; -}; -template -struct Types { - typedef internal::Types36 type; -}; -template -struct Types { - typedef internal::Types37 type; -}; -template -struct Types { - typedef internal::Types38 type; -}; -template -struct Types { - typedef internal::Types39 type; -}; -template -struct Types { - typedef internal::Types40 type; -}; -template -struct Types { - typedef internal::Types41 type; -}; -template -struct Types { - typedef internal::Types42 type; -}; -template -struct Types { - typedef internal::Types43 type; -}; -template -struct Types { - typedef internal::Types44 type; -}; -template -struct Types { - typedef internal::Types45 type; -}; -template -struct Types { - typedef internal::Types46 type; -}; -template -struct Types { - typedef internal::Types47 type; -}; -template -struct Types { - typedef internal::Types48 type; -}; -template -struct Types { - typedef internal::Types49 type; -}; - -namespace internal { - -# define GTEST_TEMPLATE_ template class - -// The template "selector" struct TemplateSel is used to -// represent Tmpl, which must be a class template with one type -// parameter, as a type. TemplateSel::Bind::type is defined -// as the type Tmpl. This allows us to actually instantiate the -// template "selected" by TemplateSel. -// -// This trick is necessary for simulating typedef for class templates, -// which C++ doesn't support directly. -template -struct TemplateSel { - template - struct Bind { - typedef Tmpl type; - }; -}; - -# define GTEST_BIND_(TmplSel, T) \ - TmplSel::template Bind::type - -// A unique struct template used as the default value for the -// arguments of class template Templates. This allows us to simulate -// variadic templates (e.g. Templates, Templates, -// and etc), which C++ doesn't support directly. -template -struct NoneT {}; - -// The following family of struct and struct templates are used to -// represent template lists. In particular, TemplatesN represents a list of N templates (T1, T2, ..., and TN). Except -// for Templates0, every struct in the family has two member types: -// Head for the selector of the first template in the list, and Tail -// for the rest of the list. - -// The empty template list. -struct Templates0 {}; - -// Template lists of length 1, 2, 3, and so on. - -template -struct Templates1 { - typedef TemplateSel Head; - typedef Templates0 Tail; -}; -template -struct Templates2 { - typedef TemplateSel Head; - typedef Templates1 Tail; -}; - -template -struct Templates3 { - typedef TemplateSel Head; - typedef Templates2 Tail; -}; - -template -struct Templates4 { - typedef TemplateSel Head; - typedef Templates3 Tail; -}; - -template -struct Templates5 { - typedef TemplateSel Head; - typedef Templates4 Tail; -}; - -template -struct Templates6 { - typedef TemplateSel Head; - typedef Templates5 Tail; -}; - -template -struct Templates7 { - typedef TemplateSel Head; - typedef Templates6 Tail; -}; - -template -struct Templates8 { - typedef TemplateSel Head; - typedef Templates7 Tail; -}; - -template -struct Templates9 { - typedef TemplateSel Head; - typedef Templates8 Tail; -}; - -template -struct Templates10 { - typedef TemplateSel Head; - typedef Templates9 Tail; -}; - -template -struct Templates11 { - typedef TemplateSel Head; - typedef Templates10 Tail; -}; - -template -struct Templates12 { - typedef TemplateSel Head; - typedef Templates11 Tail; -}; - -template -struct Templates13 { - typedef TemplateSel Head; - typedef Templates12 Tail; -}; - -template -struct Templates14 { - typedef TemplateSel Head; - typedef Templates13 Tail; -}; - -template -struct Templates15 { - typedef TemplateSel Head; - typedef Templates14 Tail; -}; - -template -struct Templates16 { - typedef TemplateSel Head; - typedef Templates15 Tail; -}; - -template -struct Templates17 { - typedef TemplateSel Head; - typedef Templates16 Tail; -}; - -template -struct Templates18 { - typedef TemplateSel Head; - typedef Templates17 Tail; -}; - -template -struct Templates19 { - typedef TemplateSel Head; - typedef Templates18 Tail; -}; - -template -struct Templates20 { - typedef TemplateSel Head; - typedef Templates19 Tail; -}; - -template -struct Templates21 { - typedef TemplateSel Head; - typedef Templates20 Tail; -}; - -template -struct Templates22 { - typedef TemplateSel Head; - typedef Templates21 Tail; -}; - -template -struct Templates23 { - typedef TemplateSel Head; - typedef Templates22 Tail; -}; - -template -struct Templates24 { - typedef TemplateSel Head; - typedef Templates23 Tail; -}; - -template -struct Templates25 { - typedef TemplateSel Head; - typedef Templates24 Tail; -}; - -template -struct Templates26 { - typedef TemplateSel Head; - typedef Templates25 Tail; -}; - -template -struct Templates27 { - typedef TemplateSel Head; - typedef Templates26 Tail; -}; - -template -struct Templates28 { - typedef TemplateSel Head; - typedef Templates27 Tail; -}; - -template -struct Templates29 { - typedef TemplateSel Head; - typedef Templates28 Tail; -}; - -template -struct Templates30 { - typedef TemplateSel Head; - typedef Templates29 Tail; -}; - -template -struct Templates31 { - typedef TemplateSel Head; - typedef Templates30 Tail; -}; - -template -struct Templates32 { - typedef TemplateSel Head; - typedef Templates31 Tail; -}; - -template -struct Templates33 { - typedef TemplateSel Head; - typedef Templates32 Tail; -}; - -template -struct Templates34 { - typedef TemplateSel Head; - typedef Templates33 Tail; -}; - -template -struct Templates35 { - typedef TemplateSel Head; - typedef Templates34 Tail; -}; - -template -struct Templates36 { - typedef TemplateSel Head; - typedef Templates35 Tail; -}; - -template -struct Templates37 { - typedef TemplateSel Head; - typedef Templates36 Tail; -}; - -template -struct Templates38 { - typedef TemplateSel Head; - typedef Templates37 Tail; -}; - -template -struct Templates39 { - typedef TemplateSel Head; - typedef Templates38 Tail; -}; - -template -struct Templates40 { - typedef TemplateSel Head; - typedef Templates39 Tail; -}; - -template -struct Templates41 { - typedef TemplateSel Head; - typedef Templates40 Tail; -}; - -template -struct Templates42 { - typedef TemplateSel Head; - typedef Templates41 Tail; -}; - -template -struct Templates43 { - typedef TemplateSel Head; - typedef Templates42 Tail; -}; - -template -struct Templates44 { - typedef TemplateSel Head; - typedef Templates43 Tail; -}; - -template -struct Templates45 { - typedef TemplateSel Head; - typedef Templates44 Tail; -}; - -template -struct Templates46 { - typedef TemplateSel Head; - typedef Templates45 Tail; -}; - -template -struct Templates47 { - typedef TemplateSel Head; - typedef Templates46 Tail; -}; - -template -struct Templates48 { - typedef TemplateSel Head; - typedef Templates47 Tail; -}; - -template -struct Templates49 { - typedef TemplateSel Head; - typedef Templates48 Tail; -}; - -template -struct Templates50 { - typedef TemplateSel Head; - typedef Templates49 Tail; -}; - - -// We don't want to require the users to write TemplatesN<...> directly, -// as that would require them to count the length. Templates<...> is much -// easier to write, but generates horrible messages when there is a -// compiler error, as gcc insists on printing out each template -// argument, even if it has the default value (this means Templates -// will appear as Templates in the compiler -// errors). -// -// Our solution is to combine the best part of the two approaches: a -// user would write Templates, and Google Test will translate -// that to TemplatesN internally to make error messages -// readable. The translation is done by the 'type' member of the -// Templates template. -template -struct Templates { - typedef Templates50 type; -}; - -template <> -struct Templates { - typedef Templates0 type; -}; -template -struct Templates { - typedef Templates1 type; -}; -template -struct Templates { - typedef Templates2 type; -}; -template -struct Templates { - typedef Templates3 type; -}; -template -struct Templates { - typedef Templates4 type; -}; -template -struct Templates { - typedef Templates5 type; -}; -template -struct Templates { - typedef Templates6 type; -}; -template -struct Templates { - typedef Templates7 type; -}; -template -struct Templates { - typedef Templates8 type; -}; -template -struct Templates { - typedef Templates9 type; -}; -template -struct Templates { - typedef Templates10 type; -}; -template -struct Templates { - typedef Templates11 type; -}; -template -struct Templates { - typedef Templates12 type; -}; -template -struct Templates { - typedef Templates13 type; -}; -template -struct Templates { - typedef Templates14 type; -}; -template -struct Templates { - typedef Templates15 type; -}; -template -struct Templates { - typedef Templates16 type; -}; -template -struct Templates { - typedef Templates17 type; -}; -template -struct Templates { - typedef Templates18 type; -}; -template -struct Templates { - typedef Templates19 type; -}; -template -struct Templates { - typedef Templates20 type; -}; -template -struct Templates { - typedef Templates21 type; -}; -template -struct Templates { - typedef Templates22 type; -}; -template -struct Templates { - typedef Templates23 type; -}; -template -struct Templates { - typedef Templates24 type; -}; -template -struct Templates { - typedef Templates25 type; -}; -template -struct Templates { - typedef Templates26 type; -}; -template -struct Templates { - typedef Templates27 type; -}; -template -struct Templates { - typedef Templates28 type; -}; -template -struct Templates { - typedef Templates29 type; -}; -template -struct Templates { - typedef Templates30 type; -}; -template -struct Templates { - typedef Templates31 type; -}; -template -struct Templates { - typedef Templates32 type; -}; -template -struct Templates { - typedef Templates33 type; -}; -template -struct Templates { - typedef Templates34 type; -}; -template -struct Templates { - typedef Templates35 type; -}; -template -struct Templates { - typedef Templates36 type; -}; -template -struct Templates { - typedef Templates37 type; -}; -template -struct Templates { - typedef Templates38 type; -}; -template -struct Templates { - typedef Templates39 type; -}; -template -struct Templates { - typedef Templates40 type; -}; -template -struct Templates { - typedef Templates41 type; -}; -template -struct Templates { - typedef Templates42 type; -}; -template -struct Templates { - typedef Templates43 type; -}; -template -struct Templates { - typedef Templates44 type; -}; -template -struct Templates { - typedef Templates45 type; -}; -template -struct Templates { - typedef Templates46 type; -}; -template -struct Templates { - typedef Templates47 type; -}; -template -struct Templates { - typedef Templates48 type; -}; -template -struct Templates { - typedef Templates49 type; -}; - -// The TypeList template makes it possible to use either a single type -// or a Types<...> list in TYPED_TEST_CASE() and -// INSTANTIATE_TYPED_TEST_CASE_P(). - -template -struct TypeList { - typedef Types1 type; -}; - -template -struct TypeList > { - typedef typename Types::type type; -}; - -#endif // GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h.pump b/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h.pump deleted file mode 100644 index 251fdf025b2..00000000000 --- a/lib/libcgroup-3.1.0/googletest/googletest/include/gtest/internal/gtest-type-util.h.pump +++ /dev/null @@ -1,297 +0,0 @@ -$$ -*- mode: c++; -*- -$var n = 50 $$ Maximum length of type lists we want to support. -// Copyright 2008 Google Inc. -// All Rights Reserved. -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -// Author: wan@google.com (Zhanyong Wan) - -// Type utilities needed for implementing typed and type-parameterized -// tests. This file is generated by a SCRIPT. DO NOT EDIT BY HAND! -// -// Currently we support at most $n types in a list, and at most $n -// type-parameterized tests in one type-parameterized test case. -// Please contact googletestframework@googlegroups.com if you need -// more. - -#ifndef GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ -#define GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ - -#include "gtest/internal/gtest-port.h" - -// #ifdef __GNUC__ is too general here. It is possible to use gcc without using -// libstdc++ (which is where cxxabi.h comes from). -# if GTEST_HAS_CXXABI_H_ -# include -# elif defined(__HP_aCC) -# include -# endif // GTEST_HASH_CXXABI_H_ - -namespace testing { -namespace internal { - -// GetTypeName() returns a human-readable name of type T. -// NB: This function is also used in Google Mock, so don't move it inside of -// the typed-test-only section below. -template -std::string GetTypeName() { -# if GTEST_HAS_RTTI - - const char* const name = typeid(T).name(); -# if GTEST_HAS_CXXABI_H_ || defined(__HP_aCC) - int status = 0; - // gcc's implementation of typeid(T).name() mangles the type name, - // so we have to demangle it. -# if GTEST_HAS_CXXABI_H_ - using abi::__cxa_demangle; -# endif // GTEST_HAS_CXXABI_H_ - char* const readable_name = __cxa_demangle(name, 0, 0, &status); - const std::string name_str(status == 0 ? readable_name : name); - free(readable_name); - return name_str; -# else - return name; -# endif // GTEST_HAS_CXXABI_H_ || __HP_aCC - -# else - - return ""; - -# endif // GTEST_HAS_RTTI -} - -#if GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -// AssertyTypeEq::type is defined iff T1 and T2 are the same -// type. This can be used as a compile-time assertion to ensure that -// two types are equal. - -template -struct AssertTypeEq; - -template -struct AssertTypeEq { - typedef bool type; -}; - -// A unique type used as the default value for the arguments of class -// template Types. This allows us to simulate variadic templates -// (e.g. Types, Type, and etc), which C++ doesn't -// support directly. -struct None {}; - -// The following family of struct and struct templates are used to -// represent type lists. In particular, TypesN -// represents a type list with N types (T1, T2, ..., and TN) in it. -// Except for Types0, every struct in the family has two member types: -// Head for the first type in the list, and Tail for the rest of the -// list. - -// The empty type list. -struct Types0 {}; - -// Type lists of length 1, 2, 3, and so on. - -template -struct Types1 { - typedef T1 Head; - typedef Types0 Tail; -}; - -$range i 2..n - -$for i [[ -$range j 1..i -$range k 2..i -template <$for j, [[typename T$j]]> -struct Types$i { - typedef T1 Head; - typedef Types$(i-1)<$for k, [[T$k]]> Tail; -}; - - -]] - -} // namespace internal - -// We don't want to require the users to write TypesN<...> directly, -// as that would require them to count the length. Types<...> is much -// easier to write, but generates horrible messages when there is a -// compiler error, as gcc insists on printing out each template -// argument, even if it has the default value (this means Types -// will appear as Types in the compiler -// errors). -// -// Our solution is to combine the best part of the two approaches: a -// user would write Types, and Google Test will translate -// that to TypesN internally to make error messages -// readable. The translation is done by the 'type' member of the -// Types template. - -$range i 1..n -template <$for i, [[typename T$i = internal::None]]> -struct Types { - typedef internal::Types$n<$for i, [[T$i]]> type; -}; - -template <> -struct Types<$for i, [[internal::None]]> { - typedef internal::Types0 type; -}; - -$range i 1..n-1 -$for i [[ -$range j 1..i -$range k i+1..n -template <$for j, [[typename T$j]]> -struct Types<$for j, [[T$j]]$for k[[, internal::None]]> { - typedef internal::Types$i<$for j, [[T$j]]> type; -}; - -]] - -namespace internal { - -# define GTEST_TEMPLATE_ template class - -// The template "selector" struct TemplateSel is used to -// represent Tmpl, which must be a class template with one type -// parameter, as a type. TemplateSel::Bind::type is defined -// as the type Tmpl. This allows us to actually instantiate the -// template "selected" by TemplateSel. -// -// This trick is necessary for simulating typedef for class templates, -// which C++ doesn't support directly. -template -struct TemplateSel { - template - struct Bind { - typedef Tmpl type; - }; -}; - -# define GTEST_BIND_(TmplSel, T) \ - TmplSel::template Bind::type - -// A unique struct template used as the default value for the -// arguments of class template Templates. This allows us to simulate -// variadic templates (e.g. Templates, Templates, -// and etc), which C++ doesn't support directly. -template -struct NoneT {}; - -// The following family of struct and struct templates are used to -// represent template lists. In particular, TemplatesN represents a list of N templates (T1, T2, ..., and TN). Except -// for Templates0, every struct in the family has two member types: -// Head for the selector of the first template in the list, and Tail -// for the rest of the list. - -// The empty template list. -struct Templates0 {}; - -// Template lists of length 1, 2, 3, and so on. - -template -struct Templates1 { - typedef TemplateSel Head; - typedef Templates0 Tail; -}; - -$range i 2..n - -$for i [[ -$range j 1..i -$range k 2..i -template <$for j, [[GTEST_TEMPLATE_ T$j]]> -struct Templates$i { - typedef TemplateSel Head; - typedef Templates$(i-1)<$for k, [[T$k]]> Tail; -}; - - -]] - -// We don't want to require the users to write TemplatesN<...> directly, -// as that would require them to count the length. Templates<...> is much -// easier to write, but generates horrible messages when there is a -// compiler error, as gcc insists on printing out each template -// argument, even if it has the default value (this means Templates -// will appear as Templates in the compiler -// errors). -// -// Our solution is to combine the best part of the two approaches: a -// user would write Templates, and Google Test will translate -// that to TemplatesN internally to make error messages -// readable. The translation is done by the 'type' member of the -// Templates template. - -$range i 1..n -template <$for i, [[GTEST_TEMPLATE_ T$i = NoneT]]> -struct Templates { - typedef Templates$n<$for i, [[T$i]]> type; -}; - -template <> -struct Templates<$for i, [[NoneT]]> { - typedef Templates0 type; -}; - -$range i 1..n-1 -$for i [[ -$range j 1..i -$range k i+1..n -template <$for j, [[GTEST_TEMPLATE_ T$j]]> -struct Templates<$for j, [[T$j]]$for k[[, NoneT]]> { - typedef Templates$i<$for j, [[T$j]]> type; -}; - -]] - -// The TypeList template makes it possible to use either a single type -// or a Types<...> list in TYPED_TEST_CASE() and -// INSTANTIATE_TYPED_TEST_CASE_P(). - -template -struct TypeList { - typedef Types1 type; -}; - - -$range i 1..n -template <$for i, [[typename T$i]]> -struct TypeList > { - typedef typename Types<$for i, [[T$i]]>::type type; -}; - -#endif // GTEST_HAS_TYPED_TEST || GTEST_HAS_TYPED_TEST_P - -} // namespace internal -} // namespace testing - -#endif // GTEST_INCLUDE_GTEST_INTERNAL_GTEST_TYPE_UTIL_H_ diff --git a/lib/libcgroup-3.1.0/googletest/googletest/libgtest.so b/lib/libcgroup-3.1.0/googletest/googletest/libgtest.so deleted file mode 100755 index cd17e16f1a3d2043e60b21c35300ca13d1502a6b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1064536 zcmbT-2{e@P`#=19#*n?S@4GD7v+rZgR%9o8gh&WQDO{zOK*QV;l`?)I~iLeJln;f}kNmG!V?+1)6})R~7L8 zb4oyz5GuHZ2jTwDwYdMe<^LXdi%9=-__q=C%@7~sKev?pxgGhhru+KmUHaSq-tRw; zS3>dU!TzgjhW@Afw z=^&n=&jR@H|Jnb&o)K;*K8uLgJ7ae&FJ?ss2Npi}%yCLRUjA-U0&YS`;R8QQ9N><$ z#AY6*6v2~IbTHAArkxJVqGGQxD8f&_#dKgZo>TBry5JEPVS4!re1w(Va0Dym7x4DLK(SNc?j_U20Yq z#FUTEqtksqf@M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iV!;Uq4z<_m#XPE>Vc&}J!UObe!uo}nUa0VB5eU)hZ7Cb zcLm?7ag3(E{_tV#XNB^Q58WDHS?&+w=Vr!LR1iaxz^irPgTU7O{Qsy{o)y5?;XeA$DSQC9Ri&JrHSnPt{=FLdpRS>=;(2cjhas}V;hdU3 z7h!uDJ5DDfa3H}>gj=d>&}oUZ?d0>$wC!fS z{InX+I~mtb6f>D=m{f2!G`$6?_N~KSf4gm`b0n%f6VWa&e)}VvCkC87JJQJ{4i5BX zz3v)n+a|i`_3#L^hUran&!m&ArF-qX?r6d7!As{Fnyp(V5K_N^#vA5xfb)EBlj64a zw{D#n%;&t^SaJNOtlOW?x_Okp-_0hy)PgAek!@77Vb6(AjO3lT+vQFfmCX^G4zhUZ zxNfpEokjtN<1J1$fw$lVFJFvnz9pSjc5nYpJ39JdQXI4U?1gW=aogQ&f^NEP_Y8Fm zblcrKyXbt3jsK-~cZ|VU*AU&_Le5Sh1f7wg+p2VUWp~}OvtyvI6B;;2BMvy~O+7us z-6Qr$$BzDPxP2$bV-_5;iR!Z@e4a!fkFhJxu`G~QbI#{#YMhlZ=6rC4j@|hDoqxRN z?T!ukP8iKswblV1a#sDE(fLPv=m^h(;;L|AI^#KGpkCh4l;pBG&kZND#qd-vsRfJ;8IJ5YWWc$pNl%6K(;3Fe zBII?)2g--fznAnNiFZk?b9w$`Rty zi^QJB=gK7ZLN7!{-pP>Oop&1ThuEPdiUvOK`6aRRJyy}=XvA=*xneX9tidJqk@1J# j_ekB1h50?a#n7jHLSJ$8deo<)4R7Rw(rbJMK34q$?v1qA diff --git a/lib/libcgroup-3.1.0/include/Makefile.am b/lib/libcgroup-3.1.0/include/Makefile.am deleted file mode 100644 index 23cebaac753..00000000000 --- a/lib/libcgroup-3.1.0/include/Makefile.am +++ /dev/null @@ -1,9 +0,0 @@ -# Using 'nobase_', we what groups.h in /usr/include/libcgroup/ directory -nobase_include_HEADERS = libcgroup.h libcgroup/error.h libcgroup/init.h \ - libcgroup/groups.h libcgroup/tasks.h \ - libcgroup/iterators.h libcgroup/config.h \ - libcgroup/log.h libcgroup/tools.h - -if WITH_SYSTEMD -nobase_include_HEADERS += libcgroup/systemd.h -endif diff --git a/lib/libcgroup-3.1.0/include/Makefile.in b/lib/libcgroup-3.1.0/include/Makefile.in deleted file mode 100644 index ea420bf382f..00000000000 --- a/lib/libcgroup-3.1.0/include/Makefile.in +++ /dev/null @@ -1,607 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -@WITH_SYSTEMD_TRUE@am__append_1 = libcgroup/systemd.h -subdir = include -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__nobase_include_HEADERS_DIST) \ - $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__nobase_include_HEADERS_DIST = libcgroup.h libcgroup/error.h \ - libcgroup/init.h libcgroup/groups.h libcgroup/tasks.h \ - libcgroup/iterators.h libcgroup/config.h libcgroup/log.h \ - libcgroup/tools.h libcgroup/systemd.h -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(includedir)" -HEADERS = $(nobase_include_HEADERS) -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ - -# Using 'nobase_', we what groups.h in /usr/include/libcgroup/ directory -nobase_include_HEADERS = libcgroup.h libcgroup/error.h \ - libcgroup/init.h libcgroup/groups.h libcgroup/tasks.h \ - libcgroup/iterators.h libcgroup/config.h libcgroup/log.h \ - libcgroup/tools.h $(am__append_1) -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign include/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign include/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -install-nobase_includeHEADERS: $(nobase_include_HEADERS) - @$(NORMAL_INSTALL) - @list='$(nobase_include_HEADERS)'; test -n "$(includedir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ - fi; \ - $(am__nobase_list) | while read dir files; do \ - xfiles=; for file in $$files; do \ - if test -f "$$file"; then xfiles="$$xfiles $$file"; \ - else xfiles="$$xfiles $(srcdir)/$$file"; fi; done; \ - test -z "$$xfiles" || { \ - test "x$$dir" = x. || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(includedir)/$$dir'"; \ - $(MKDIR_P) "$(DESTDIR)$(includedir)/$$dir"; }; \ - echo " $(INSTALL_HEADER) $$xfiles '$(DESTDIR)$(includedir)/$$dir'"; \ - $(INSTALL_HEADER) $$xfiles "$(DESTDIR)$(includedir)/$$dir" || exit $$?; }; \ - done - -uninstall-nobase_includeHEADERS: - @$(NORMAL_UNINSTALL) - @list='$(nobase_include_HEADERS)'; test -n "$(includedir)" || list=; \ - $(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \ - dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(HEADERS) -installdirs: - for dir in "$(DESTDIR)$(includedir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: install-nobase_includeHEADERS - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-nobase_includeHEADERS - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ - clean-libtool cscopelist-am ctags ctags-am distclean \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man \ - install-nobase_includeHEADERS install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ - uninstall-am uninstall-nobase_includeHEADERS - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/include/libcgroup.h b/lib/libcgroup-3.1.0/include/libcgroup.h deleted file mode 100644 index eddb356f678..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup.h +++ /dev/null @@ -1,43 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright IBM Corporation. 2007 - * - * Author: Balbir Singh - */ - -#ifndef _LIBCGROUP_H -#define _LIBCGROUP_H - -#define _LIBCGROUP_H_INSIDE - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#undef _LIBCGROUP_H_INSIDE - -/*! \mainpage libcgroup - * - * \section intro_sec Introduction - * - * @c libcgroup is a library that abstracts the control group file system in Linux. - * It comes with various command-line tools and configuration files, see - * their man pages for details. - * - * This documentation provides description of @c libcgroup API. Read following - * sections, preferably in this order: - * -# @ref group_init "Initialization" - * -# @ref group_groups "Control Groups" - * -# @ref group_iterators "Iterators" - * -# @ref group_tasks "Manipulation with tasks" - * -# @ref group_config "Configuration" - * -# @ref group_errors "Error Handling" - */ - -#endif /* _LIBCGROUP_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/config.h b/lib/libcgroup-3.1.0/include/libcgroup/config.h deleted file mode 100644 index 08354d49f4c..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/config.h +++ /dev/null @@ -1,138 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_CONFIG_H -#define _LIBCGROUP_CONFIG_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @defgroup group_config 5. Configuration - * @{ - * - * @name Configuration file - * @{ - * - * @c libcgroup can mount and create control groups and set their parameters as - * specified in a configuration file. - * - * @todo add this description?: These functions are mostly intended - * to be used by internal @c libcgroup tools, however they are fully supported - * and applications can benefit from them. - */ - -/** - * Load configuration file and mount and create control groups described there. - * See cgconfig.conf man page for format of the file. - * @param pathname Name of the configuration file to load. - */ -int cgroup_config_load_config(const char *pathname); - -/** - * Delete all control groups and unmount all hierarchies. - */ -int cgroup_unload_cgroups(void); - -/** - * Delete all cgroups and unmount all mount points defined in specified config - * file. - * - * The groups are either removed recursively or only the empty ones, based - * on given flags. Mount point are always umounted only if they are empty, - * regardless of any flags. - * - * The groups are sorted before they are removed, so the removal of empty ones - * actually works (i.e. subgroups are removed first). - * - * @param pathname Name of the configuration file to unload. - * @param flags Combination of CGFLAG_DELETE_* flags, which indicate what and - * how to delete. - */ -int cgroup_config_unload_config(const char *pathname, int flags); - -/** - * Sets default permissions of groups created by subsequent - * cgroup_config_load_config() calls. If a config file contains a 'default {}' - * section, the default permissions from the config file is then used. - * - * Use cgroup_new_cgroup() to create a dummy group and cgroup_set_uid_gid() and - * cgroup_set_permissions() to set its permissions. Use NO_UID_GID instead of - * GID/UID and NO_PERMS instead of file/directory permissions to let kernel - * decide the default permissions where you don't want specific user and/or - * permissions. Kernel then uses current user/group and permissions from umask - * then. - * - * @param new_default New default permissions from this group are copied to - * libcgroup internal structures. I.e., this group can be freed immediatelly - * after this function returns. - */ -int cgroup_config_set_default(struct cgroup *new_default); - -/** - * Initializes the templates cache and load it from file pathname. - */ -int cgroup_init_templates_cache(char *pathname); - -/** - * Reloads the templates list from file pathname. - */ -int cgroup_reload_cached_templates(char *pathname); - -/** - * Load the templates cache from files. Before calling this function, - * cgroup_templates_cache_set_source_files has to be called first. - * @param file_index index of file which was unable to be parsed - * @return 0 on success, > 0 on error - */ -int cgroup_load_templates_cache_from_files(int *file_index); - -/** - * Setting source files of templates. This function has to be called before - * any call of cgroup_load_templates_cache_from_files. - * @param tmpl_files - */ -struct cgroup_string_list; -void cgroup_templates_cache_set_source_files( - struct cgroup_string_list *tmpl_files); - -/** - * Physically create a new control group in kernel, based on given control - * group template and configuration file. If given template is not set in - * configuration file, then the procedure works create the control group - * using cgroup_create_cgroup() function - * - * Templates are loaded using cgroup_load_templates_cache_from_files - * function, which must be preceded by cgroup_templates_cache_set_source_files - * call. - * - * The flags can alter the behavior of this function: - * CGFLAG_USE_TEMPLATE_CACHE: Use cached templates instead of - * parsing the config file - * - * @param pathname Name of the configuration file with template definitions - * @param cgroup Wanted control group - contains substitute name and wanted - * controllers. - * @param template_name Template name used for cgroup setting - * @param flags Bit flags to change the behavior - */ -int cgroup_config_create_template_group( - struct cgroup *cgroup, char *template_name, - int flags); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /*_LIBCGROUP_CONFIG_H*/ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/error.h b/lib/libcgroup-3.1.0/include/libcgroup/error.h deleted file mode 100644 index 3520a038831..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/error.h +++ /dev/null @@ -1,111 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_ERROR_H -#define _LIBCGROUP_ERROR_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @defgroup group_errors 6. Error handling - * @{ - * - * @name Error handling - * @{ - * Unless states otherwise in documentation of a function, all functions - * return @c int, which is zero (0) when the function succeeds, and positive - * number if the function fails. - * - * The returned integer is one of the ECG* values described below. Value - * #ECGOTHER means that the error was caused by underlying OS and the real - * cause can be found by calling cgroup_get_last_errno(). - */ - -enum { - ECGROUPNOTCOMPILED = 50000, - ECGROUPNOTMOUNTED, /* 50001 */ - ECGROUPNOTEXIST, /* 50002 */ - ECGROUPNOTCREATED, /* 50003 */ - ECGROUPSUBSYSNOTMOUNTED, /* 50004 */ - ECGROUPNOTOWNER, /* 50005 */ - /** Controllers bound to different mount points */ - ECGROUPMULTIMOUNTED, /* 50006 */ - /* This is the stock error. Default error. @todo really? */ - ECGROUPNOTALLOWED, /* 50007 */ - ECGMAXVALUESEXCEEDED, /* 50008 */ - ECGCONTROLLEREXISTS, /* 50009 */ - ECGVALUEEXISTS, /* 50010 */ - ECGINVAL, /* 50011 */ - ECGCONTROLLERCREATEFAILED, /* 50012 */ - ECGFAIL, /* 50013 */ - ECGROUPNOTINITIALIZED, /* 50014 */ - ECGROUPVALUENOTEXIST, /* 50015 */ - /** - * Represents error coming from other libraries like glibc. @c libcgroup - * users need to check cgroup_get_last_errno() upon encountering this - * error. - */ - ECGOTHER, /* 50016 */ - ECGROUPNOTEQUAL, /* 50017 */ - ECGCONTROLLERNOTEQUAL, /* 50018 */ - /** Failed to parse rules configuration file. */ - ECGROUPPARSEFAIL, /* 50019 */ - /** Rules list does not exist. */ - ECGROUPNORULES, /* 50020 */ - ECGMOUNTFAIL, /* 50021 */ - /** - * Not an real error, it just indicates that iterator has come to end - * of sequence and no more items are left. - */ - ECGEOF = 50023, - /** Failed to parse config file (cgconfig.conf). */ - ECGCONFIGPARSEFAIL, /* 50024 */ - ECGNAMESPACEPATHS, /* 50025 */ - ECGNAMESPACECONTROLLER, /* 50026 */ - ECGMOUNTNAMESPACE, /* 50027 */ - ECGROUPUNSUPP, /* 50028 */ - ECGCANTSETVALUE, /* 50029 */ - /** Removing of a group failed because it was not empty. */ - ECGNONEMPTY, /* 50030 */ - /** Failed to convert from cgroup v1 to/from cgroup v2 */ - ECGNOVERSIONCONVERT, /* 50031 */ -}; - -/** - * Legacy definition of ECGRULESPARSEFAIL error code. - */ -#define ECGRULESPARSEFAIL ECGROUPPARSEFAIL - -/** - * Format error code to a human-readable English string. No internationalization - * is currently done. Returned pointer leads to @c libcgroup memory and - * must not be freed nor modified. The memory is rewritten by subsequent - * call to this function. - * @param code Error code for which the corresponding error string is - * returned. When #ECGOTHER is used, text with glibc's description of - * cgroup_get_last_errno() value is returned. - */ -const char *cgroup_strerror(int code); - -/** - * Return last errno, which caused ECGOTHER error. - */ -int cgroup_get_last_errno(void); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_INIT_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/groups.h b/lib/libcgroup-3.1.0/include/libcgroup/groups.h deleted file mode 100644 index 503f499c339..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/groups.h +++ /dev/null @@ -1,706 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_GROUPS_H -#define _LIBCGROUP_GROUPS_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#include -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -enum cg_version_t { - CGROUP_UNK = 0, - CGROUP_V1, - CGROUP_V2, - CGROUP_DISK = 0xFF, -}; - -enum cg_setup_mode_t { - CGROUP_MODE_UNK = 0, - CGROUP_MODE_LEGACY, - CGROUP_MODE_HYBRID, - CGROUP_MODE_UNIFIED, -}; - -/** - * Flags for cgroup_delete_cgroup_ext(). - */ -enum cgroup_delete_flag { - /** - * Ignore errors caused by migration of tasks to parent group. - */ - CGFLAG_DELETE_IGNORE_MIGRATION = 1, - - /** - * Recursively delete all child groups. - */ - CGFLAG_DELETE_RECURSIVE = 2, - - /** - * Delete the cgroup only if it is empty, i.e. it has no subgroups and - * no processes inside. This flag cannot be used with - * CGFLAG_DELETE_RECURSIVE. - */ - CGFLAG_DELETE_EMPTY_ONLY = 4, -}; - -/** - * @defgroup group_groups 2. Group manipulation API - * @{ - * - * @name Basic infrastructure - * @{ - * struct cgroup* is the heart of @c libcgroup API. - * The structure is opaque to applications, all access to the structure is - * through appropriate functions. - * - * The most important information is that one struct cgroup* can - * represent zero, one or more real control groups in kernel. - * The struct cgroup* is identified by name of the group, which must be - * set by cgroup_new_cgroup(). Multiple controllers (aka subsystems) can be - * attached to one struct cgroup* using cgroup_add_controller(). These - * controllers can belong to different hierarchies. - * - * This approach is different to the one in the Linux kernel - a control group - * must be part of exactly one hierarchy there. In @c libcgroup, a group can be - * part of multiple hierarchies, as long as the group name is the same. - * - * @par Example: - * Let there be following control groups: - * @code - * cpu,cpuacct:/ - * cpu,cpuacct:/foo - * cpu,cpuacct:/bar - * freezer:/ - * freezer:/foo - * @endcode - * I.e. there is @c cpu and @c cpuacct controller mounted together in one - * hierarchy, with @c foo and @c bar groups. In addition, @c freezer is - * mounted as separate hierarchy, with only one @c foo group. - * - * @par - * Following code creates struct cgroup* structure, which represents - * one group cpu,cpuacct:/foo: - * @code - * struct cgroup *foo = cgroup_new_cgroup("foo"); - * cgroup_add_controller(foo, "cpu"); - * @endcode - * Now, you can call e.g. cgroup_delete_cgroup() and the group is deleted from - * the hierarchy. You can note that it's enough to add only one controller to - * the group to fully identify a group in cpu,cpuacct hierarchy. - * - * @par - * Following code creates struct cgroup* structure, which represents - * @b two groups, cpu,cpuacct:/foo and freezer:/foo: - * @code - * struct cgroup *foo = cgroup_new_cgroup("foo"); - * cgroup_add_controller(foo, "cpu"); - * cgroup_add_controller(foo, "freezer"); - * @endcode - * Now, if you call e.g. cgroup_delete_cgroup(), the group gets deleted from - * @b both hierarchies. - * - * @todo add some propaganda what's so great on this approach... I personally - * think it is broken and confusing (see TODOs below). - * - * Following functions are provided to create/destroy various libcgroup - * structures. Please note that none of these functions actually create or - * delete a cgroup in kernel! - */ - -/** - * @struct cgroup - * - * Structure describing one or more control groups. The structure is opaque to - * applications. - */ -struct cgroup; - -/** - * @struct cgroup_controller - * Structure describing a controller attached to one struct @c cgroup, including - * parameters of the group and their values. The structure is opaque to - * applications. - * @see groups - */ -struct cgroup_controller; - -/** - * Uninitialized file/directory permissions used for task/control files. - */ -#define NO_PERMS (-1U) - -/** - * Uninitialized UID/GID used for task/control files. - */ -#define NO_UID_GID (-1U) - -/** - * Allocate new cgroup structure. This function itself does not create new - * control group in kernel, only new struct cgroup inside libcgroup! - * - * @param name Path to the group, relative from root group. Use @c "/" or @c "." - * for the root group itself and @c "/foo/bar/baz" or @c "foo/bar/baz" for - * subgroups. - * @todo suggest one preferred way, either "/foo" or "foo". - * @returns Created group or NULL on error. - */ -struct cgroup *cgroup_new_cgroup(const char *name); - -/** - * Attach new controller to cgroup. This function just modifies internal - * libcgroup structure, not the kernel control group. - * - * @param cgroup - * @param name The name of the controller, e.g. "freezer". - * @return Created controller or NULL on error. - */ -struct cgroup_controller *cgroup_add_controller(struct cgroup *cgroup, - const char *name); - -/** - * Attach all mounted controllers to given cgroup. This function just modifies - * internal libcgroup structure, not the kernel control group. - * - * @param cgroup - * @return zero or error number - */ -int cgroup_add_all_controllers(struct cgroup *cgroup); - - -/** - * Return appropriate controller from given group. - * The controller must be added before using cgroup_add_controller() or loaded - * from kernel using cgroup_get_cgroup(). - * @param cgroup - * @param name The name of the controller, e.g. "freezer". - */ -struct cgroup_controller *cgroup_get_controller(struct cgroup *cgroup, - const char *name); - -/** - * Free internal @c cgroup structure. This function frees also all controllers - * attached to the @c cgroup, including all parameters and their values. - * @param cgroup - */ -void cgroup_free(struct cgroup **cgroup); - -/** - * Free internal list of controllers from the group. - * @todo should this function be public??? - * @param cgroup - */ -void cgroup_free_controllers(struct cgroup *cgroup); - -/** - * @} - * @name Group manipulation API - * Using following functions you can create and remove control groups and - * change their parameters. - * @note All access to kernel is through previously mounted cgroup filesystems. - * @c libcgroup does not mount/unmount anything for you. - * @{ - */ - -/** - * Physically create a control group in kernel. The group is created in all - * hierarchies, which cover controllers added by cgroup_add_controller(). - * All parameters set by cgroup_add_value_* functions are written. - * The created groups has owner which was set by cgroup_set_uid_gid() and - * permissions set by cgroup_set_permissions. - * @param cgroup - * @param ignore_ownership When nozero, all errors are ignored when setting - * owner of the group and/or its tasks file. - * @todo what is ignore_ownership good for? - * @retval #ECGROUPNOTEQUAL if not all specified controller parameters - * were successfully set. - */ -int cgroup_create_cgroup(struct cgroup *cgroup, int ignore_ownership); - -/** - * Physically create new control group in kernel, with all parameters and values - * copied from its parent group. The group is created in all hierarchies, where - * the parent group exists. I.e. following code creates subgroup in all - * hierarchies, because all of them have root (=parent) group. - * @code - * struct cgroup *foo = cgroup_new_cgroup("foo"); - * cgroup_create_cgroup_from_parent(foo, 0); - * @endcode - * @todo what is this good for? Why the list of controllers added by - * cgroup_add_controller() is not used, like in cgroup_create_cgroup()? I can't - * crate subgroup of root group in just one hierarchy with this function! - * - * @param cgroup The cgroup to create. Only it's name is used, everything else - * is discarded. - * @param ignore_ownership When nozero, all errors are ignored when setting - * owner of the group and/or its tasks file. - * @todo what is ignore_ownership good for? - * @retval #ECGROUPNOTEQUAL if not all inherited controller parameters - * were successfully set (this is expected). - */ -int cgroup_create_cgroup_from_parent(struct cgroup *cgroup, - int ignore_ownership); - -/** - * Physically modify a control group in kernel. All parameters added by - * cgroup_add_value_ or cgroup_set_value_ are written. - * Currently it's not possible to change and owner of a group. - * - * @param cgroup - */ -int cgroup_modify_cgroup(struct cgroup *cgroup); - -/** - * Physically remove a control group from kernel. The group is removed from - * all hierarchies, which cover controllers added by cgroup_add_controller() - * or cgroup_get_cgroup(). All tasks inside the group are automatically moved - * to parent group. - * - * The group being removed must be empty, i.e. without subgroups. Use - * cgroup_delete_cgroup_ext() for recursive delete. - * - * @param cgroup - * @param ignore_migration When nozero, all errors are ignored when migrating - * tasks from the group to the parent group. - * @todo what is ignore_migration good for? rmdir() will fail if tasks were not moved. - */ -int cgroup_delete_cgroup(struct cgroup *cgroup, int ignore_migration); - -/** - * Physically remove a control group from kernel. - * All tasks are automatically moved to parent group. - * If #CGFLAG_DELETE_IGNORE_MIGRATION flag is used, the errors that occurred - * during the task movement are ignored. - * #CGFLAG_DELETE_RECURSIVE flag specifies that all subgroups should be removed - * too. If root group is being removed with this flag specified, all subgroups - * are removed but the root group itself is left undeleted. - * @see cgroup_delete_flag. - * - * @param cgroup - * @param flags Combination of CGFLAG_DELETE_* flags, which indicate what and - * how to delete. - */ -int cgroup_delete_cgroup_ext(struct cgroup *cgroup, int flags); - -/** - * @} - * @name Other functions - * @{ - * Helper functions to manipulate with control groups. - */ - -/** - * Read all information regarding the group from kernel. - * Based on name of the group, list of controllers and all parameters and their - * values are read from all hierarchies, where a group with given name exists. - * All existing controllers are replaced. I.e. following code will fill @c root - * with controllers from all hierarchies, because the root group is available in - * all of them. - * @code - * struct cgroup *root = cgroup_new_cgroup("/"); - * cgroup_get_cgroup(root); - * @endcode - * - * @todo what is this function good for? Why is not considered only the list of - * controllers attached by cgroup_add_controller()? What owners will return - * cgroup_get_uid_gid() if the group is in multiple hierarchies, each with - * different owner of tasks file? - * - * @param cgroup The cgroup to load. Only it's name is used, everything else - * is replaced. - */ -int cgroup_get_cgroup(struct cgroup *cgroup); - -/** - * Copy all controllers, their parameters and values. Group name, permissions - * and ownerships are not coppied. All existing controllers - * in the source group are discarded. - * - * @param dst Destination group. - * @param src Source group. - */ -int cgroup_copy_cgroup(struct cgroup *dst, struct cgroup *src); - -/** - * Compare names, owners, controllers, parameters and values of two groups. - * - * @param cgroup_a - * @param cgroup_b - * - * @retval 0 if the groups are the same. - * @retval #ECGROUPNOTEQUAL if the groups are not the same. - * @retval #ECGCONTROLLERNOTEQUAL if the only difference are controllers, - * parameters or their values. - */ -int cgroup_compare_cgroup(struct cgroup *cgroup_a, struct cgroup *cgroup_b); - - -/** - * Compare names, parameters and values of two controllers. - * - * @param cgca - * @param cgcb - * - * @retval 0 if the controllers are the same. - * @retval #ECGCONTROLLERNOTEQUAL if the controllers are not equal. - */ -int cgroup_compare_controllers(struct cgroup_controller *cgca, - struct cgroup_controller *cgcb); - -/** - * Set owner of the group control files and the @c tasks file. This function - * modifies only @c libcgroup internal @c cgroup structure, use - * cgroup_create_cgroup() afterwards to create the group with given owners. - * - * @param cgroup - * @param tasks_uid UID of the owner of group's @c tasks file. - * @param tasks_gid GID of the owner of group's @c tasks file. - * @param control_uid UID of the owner of group's control files (i.e. - * parameters). - * @param control_gid GID of the owner of group's control files (i.e. - * parameters). - */ -int cgroup_set_uid_gid(struct cgroup *cgroup, uid_t tasks_uid, gid_t tasks_gid, - uid_t control_uid, gid_t control_gid); - -/** - * Return owners of the group's @c tasks file and control files. - * The data is read from @c libcgroup internal @c cgroup structure, use - * cgroup_set_uid_gid() or cgroup_get_cgroup() to fill it. - */ -int cgroup_get_uid_gid(struct cgroup *cgroup, uid_t *tasks_uid, - gid_t *tasks_gid, uid_t *control_uid, - gid_t *control_gid); - -/** - * Stores given file permissions of the group's control and tasks files - * into the @c cgroup data structure. Use NO_PERMS if permissions shouldn't - * be changed or a value which applicable to chmod(2). Please note that - * the given permissions are masked with the file owner's permissions. - * For example if a control file has permissions 640 and control_fperm is - * 471 the result will be 460. - * @param cgroup - * @param control_dperm Directory permission for the group. - * @param control_fperm File permission for the control files. - * @param task_fperm File permissions for task file. - */ -void cgroup_set_permissions(struct cgroup *cgroup, - mode_t control_dperm, mode_t control_fperm, - mode_t task_fperm); - -/** - * @} - * @name Group parameters - * These are functions can read or modify parameter of a group. - * @note All these functions read/write parameters to @c libcgorup internal - * structures. Use cgroup_get_cgroup() to load parameters from kernel to these - * internal structures and cgroup_modify_cgroup() or cgroup_create_cgroup() to - * write changes to kernel. - * @{ - */ - -/** - * Add parameter and its value to internal @c libcgroup structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - * - */ -int cgroup_add_value_string(struct cgroup_controller *controller, - const char *name, const char *value); - -/** - * Add parameter and its value to internal @c libcgroup structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * Content of the value is copied to internal structures and is not needed - * after return from the function. - * - * @param controller - * @param name The name of the parameter. - * @param value - * - */ -int cgroup_add_value_int64(struct cgroup_controller *controller, - const char *name, int64_t value); - -/** - * Add parameter and its value to internal @c libcgroup structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - * - */ -int cgroup_add_value_uint64(struct cgroup_controller *controller, - const char *name, u_int64_t value); - -/** - * Add parameter and its value to internal @c libcgroup structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - * - */ -int cgroup_add_value_bool(struct cgroup_controller *controller, - const char *name, bool value); - -/** - * Read a parameter value from @c libcgroup internal structures. - * Use @c cgroup_get_cgroup() to fill these structures with data from kernel. - * It's up to the caller to free returned value. - * - * This function works only for 'short' parameters. Use - * cgroup_read_stats_begin(), cgroup_read_stats_next() and - * cgroup_read_stats_end() to read @c stats parameter, which can be longer - * than libcgroup's internal buffers. - * @todo rephrase, it's too vague... How big is the buffer actually? - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_get_value_string(struct cgroup_controller *controller, - const char *name, char **value); -/** - * Read a parameter value from @c libcgroup internal structures. - * Use @c cgroup_get_cgroup() to fill these structures with data from kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_get_value_int64(struct cgroup_controller *controller, - const char *name, int64_t *value); - -/** - * Read a parameter value from @c libcgroup internal structures. - * Use @c cgroup_get_cgroup() to fill these structures with data from kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_get_value_uint64(struct cgroup_controller *controller, - const char *name, u_int64_t *value); - -/** - * Read a parameter value from @c libcgroup internal structures. - * Use @c cgroup_get_cgroup() to fill these structures with data from kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_get_value_bool(struct cgroup_controller *controller, - const char *name, bool *value); - -/** - * Set a parameter value in @c libcgroup internal structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_set_value_string(struct cgroup_controller *controller, - const char *name, const char *value); - -/** - * Set a parameter value in @c libcgroup internal structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * Content of the value is copied to internal structures and is not needed - * after return from the function. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_set_value_int64(struct cgroup_controller *controller, - const char *name, int64_t value); -/** - * Set a parameter value in @c libcgroup internal structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_set_value_uint64(struct cgroup_controller *controller, - const char *name, u_int64_t value); - -/** - * Set a parameter value in @c libcgroup internal structures. - * Use cgroup_modify_cgroup() or cgroup_create_cgroup() to write it to kernel. - * - * @param controller - * @param name The name of the parameter. - * @param value - */ -int cgroup_set_value_bool(struct cgroup_controller *controller, - const char *name, bool value); - -/** - * Return the number of variables for the specified controller in @c libcgroup - * internal structures. Use cgroup_get_cgroup() to fill these structures with - * data from kernel. Use this function together with cgroup_get_value_name() - * to list all parameters of a group. - * - * @param controller - * @return Count of the parameters or -1 on error. - */ -int cgroup_get_value_name_count(struct cgroup_controller *controller); - -/** - * Return the name of parameter of controller at given index. - * The index goes from 0 to cgroup_get_value_name_count()-1. - * Use this function to list all parameter of the controller. - * - * @note The returned value is pointer to internal @c libcgroup structure, - * do not free it. - * - * @param controller - * @param index The index of the parameter. - * @return Name of the parameter. - */ -char *cgroup_get_value_name(struct cgroup_controller *controller, int index); - -/** - * Get the list of process in a cgroup. This list is guaranteed to - * be sorted. It is not necessary that it is unique. - * @param name The name of the cgroup - * @param controller The name of the controller - * @param pids The list of pids. Should be uninitialized when passed - * to the API. Should be freed by the caller using free. - * @param size The size of the pids array returned by the API. - */ -int cgroup_get_procs(char *name, char *controller, pid_t **pids, int *size); - -/** - * Change permission of files and directories of given group - * @param cgroup The cgroup which permissions should be changed - * @param dir_mode The permission mode of group directory - * @param dirm_change Denotes whether the directory change should be done - * @param file_mode The permission mode of group files - * @param filem_change Denotes whether the directory change should be done - */ -int cg_chmod_recursive(struct cgroup *cgroup, mode_t dir_mode, - int dirm_change, mode_t file_mode, int filem_change); - -/** - * Get the name of the cgroup from a given cgroup - * @param cgroup The cgroup whose name is needed - */ -char *cgroup_get_cgroup_name(struct cgroup *cgroup); - -/* - * Convert from one cgroup version to another version - * - * @param out_cgroup Destination cgroup - * @param out_version Destination cgroup version - * @param in_cgroup Source cgroup - * @param in_version Source cgroup version, only used if set to v1 or v2 - * - * @return 0 on success - * ECGFAIL conversion failed - * ECGCONTROLLERNOTEQUAL incorrect controller version provided - */ -int cgroup_convert_cgroup(struct cgroup * const out_cgroup, - enum cg_version_t out_version, - const struct cgroup * const in_cgroup, - enum cg_version_t in_version); - -/** - * List the mount paths, that matches the specified version - * - * @param cgrp_version The cgroup type/version - * @param mount_paths Holds the list of mount paths - * @return 0 success and list of mounts paths in mount_paths - * ECGOTHER on failure and mount_paths is NULL. - */ -int cgroup_list_mount_points(const enum cg_version_t cgrp_version, - char ***mount_paths); - -/** - * Get the cgroup version of a controller. Version is set to CGROUP_UNK - * if the version cannot be determined. - * - * @param controller The controller of interest - * @param version The version of the controller - */ -int cgroup_get_controller_version(const char * const controller, - enum cg_version_t * const version); - -/** - * Get the current group setup mode (legacy/unified/hybrid) - * - * @return CGROUP_MODE_UNK on failure and setup mode on success - */ -enum cg_setup_mode_t cgroup_setup_mode(void); - -/** - * Return the number of controllers for the specified cgroup in libcgroup - * internal structures. - * - * @param cgroup - * @return Count of the controllers or -1 on error. - */ -int cgroup_get_controller_count(struct cgroup *cgroup); - -/** - * Return requested controller from given group - * - * @param cgroup - * @param index The index into the cgroup controller list - */ -struct cgroup_controller *cgroup_get_controller_by_index(struct cgroup *cgroup, int index); - -/** - * Given a controller pointer, get the name of the controller - * - * @param controller - * @return controller name string, NULL if there's an error - */ -char *cgroup_get_controller_name(struct cgroup_controller *controller); - -/** - * Return true if cgroup setup mode is cgroup v1 (legacy), else - * returns false. - */ -bool is_cgroup_mode_legacy(void); - -/** - * Return true if cgroup setup mode is cgroup v1/v2 (hybrid), else - * returns false. - */ -bool is_cgroup_mode_hybrid(void); - -/** - * Return true if cgroup setup mode is cgroup v2 (unified), else - * returns false. - */ -bool is_cgroup_mode_unified(void); - -/** - * @} - * @} - */ - - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_GROUPS_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/init.h b/lib/libcgroup-3.1.0/include/libcgroup/init.h deleted file mode 100644 index c61f5781da3..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/init.h +++ /dev/null @@ -1,86 +0,0 @@ -#ifndef _LIBCGROUP_INIT_H -#define _LIBCGROUP_INIT_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -#define CGROUP_VER_MAJOR 3 -#define CGROUP_VER_MINOR 1 -#define CGROUP_VER_RELEASE 0 - -struct cgroup_library_version { - unsigned int major; - unsigned int minor; - unsigned int release; -}; - -/** - * Query the library version information - * - * This function returns a pointer to a populated cgroup_library_version - * struct. The caller does not need to free the structure when finished. - * - */ -const struct cgroup_library_version *cgroup_version(void); - -/** - * @defgroup group_init 1. Initialization - * @{ - * - * @name Initialization - * @{ - * Application must initialize @c libcgroup using cgroup_init() before any - * other @c libcgroup function can be called. @c libcgroup caches information - * about mounted hierarchies (just what's mounted where, not the control groups - * themselves) at this time. There is currently no way to refresh this cache, - * i.e. all subsequent mounts/remounts/unmounts are not reflected in this cache - * and @c libcgroup may produce unexpected results. - * - * In addition, there is no way how to clean the cache on application exit. - * - * @todo this is very bad... There should be at least way how to refresh the - * cache and/or an option to refresh it automatically (does kernel provide - * any indication, when a filesystem is mounted/unmounted?). Dtto the cleanup - * on exit. - */ - -/** - * Initialize libcgroup. Information about mounted hierarchies are examined - * and cached internally (just what's mounted where, not the groups themselves). - * - * If the cgroup logging was not set using cgroup_set_logger() or - * cgroup_set_default_logger() before calling cgroup_init(), the default logger - * is automatically set, logging CGROUP_LOG_ERROR messages. - */ -int cgroup_init(void); - -/** - * Returns path where is mounted given controller. Applications should rely on - * @c libcgroup API and not call this function directly. - * Only the first mount point is returned, use - * cgroup_get_subsys_mount_point_begin(), cgroup_get_subsys_mount_point_next() - * and cgroup_get_subsys_mount_point_end() to get all of them. - * @param controller Name of the controller - * @param mount_point The string where the mount point location is stored. - * Please note, the caller must free the mount_point. - */ -int cgroup_get_subsys_mount_point(const char *controller, char **mount_point); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_INIT_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/init.h.in b/lib/libcgroup-3.1.0/include/libcgroup/init.h.in deleted file mode 100644 index 1e1323deb73..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/init.h.in +++ /dev/null @@ -1,86 +0,0 @@ -#ifndef _LIBCGROUP_INIT_H -#define _LIBCGROUP_INIT_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -#define CGROUP_VER_MAJOR @LIBRARY_VERSION_MAJOR@ -#define CGROUP_VER_MINOR @LIBRARY_VERSION_MINOR@ -#define CGROUP_VER_RELEASE @LIBRARY_VERSION_RELEASE@ - -struct cgroup_library_version { - unsigned int major; - unsigned int minor; - unsigned int release; -}; - -/** - * Query the library version information - * - * This function returns a pointer to a populated cgroup_library_version - * struct. The caller does not need to free the structure when finished. - * - */ -const struct cgroup_library_version *cgroup_version(void); - -/** - * @defgroup group_init 1. Initialization - * @{ - * - * @name Initialization - * @{ - * Application must initialize @c libcgroup using cgroup_init() before any - * other @c libcgroup function can be called. @c libcgroup caches information - * about mounted hierarchies (just what's mounted where, not the control groups - * themselves) at this time. There is currently no way to refresh this cache, - * i.e. all subsequent mounts/remounts/unmounts are not reflected in this cache - * and @c libcgroup may produce unexpected results. - * - * In addition, there is no way how to clean the cache on application exit. - * - * @todo this is very bad... There should be at least way how to refresh the - * cache and/or an option to refresh it automatically (does kernel provide - * any indication, when a filesystem is mounted/unmounted?). Dtto the cleanup - * on exit. - */ - -/** - * Initialize libcgroup. Information about mounted hierarchies are examined - * and cached internally (just what's mounted where, not the groups themselves). - * - * If the cgroup logging was not set using cgroup_set_logger() or - * cgroup_set_default_logger() before calling cgroup_init(), the default logger - * is automatically set, logging CGROUP_LOG_ERROR messages. - */ -int cgroup_init(void); - -/** - * Returns path where is mounted given controller. Applications should rely on - * @c libcgroup API and not call this function directly. - * Only the first mount point is returned, use - * cgroup_get_subsys_mount_point_begin(), cgroup_get_subsys_mount_point_next() - * and cgroup_get_subsys_mount_point_end() to get all of them. - * @param controller Name of the controller - * @param mount_point The string where the mount point location is stored. - * Please note, the caller must free the mount_point. - */ -int cgroup_get_subsys_mount_point(const char *controller, char **mount_point); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_INIT_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/iterators.h b/lib/libcgroup-3.1.0/include/libcgroup/iterators.h deleted file mode 100644 index 0256e090227..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/iterators.h +++ /dev/null @@ -1,435 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_ITERATORS_H -#define _LIBCGROUP_ITERATORS_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#include -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @defgroup group_iterators 3. Iterators - * @{ - * So-called iterators are a code pattern to retrieve various data from - * libcgroup in distinct chunks, for example when an application needs to read - * list of groups in a hierarchy, it uses iterator to get one group at a time. - * Iterator is opaque to the application, the application sees only - * void* handle pointer, which is managed internally by @c libcgroup. - * Each iterator provides at least these functions: - * - int iterator_name_begin(void **handle, my_type *item) - * - Initialize the iterator, store pointer to it into the @c handle. - * - Return the first element in the iterator, let's say it's @c my_type. - * - Return @c 0, if the operation succeeded. - * - Return #ECGEOF, if the operation succeeded, but the iterator is empty. - * The value of @c item is undefined in this case. - * - Return any other error code on error. - * - int iterator_name_next(void **handle, my_type *item) - * - Advance to next element in the iterator and return it. - * - Return @c 0, if the operation succeeded. - * - Return #ECGEOF, if there is no item to advance to, i.e. the iterator - * is already at its end. The value of @c item is undefined in this case. - * - Return any other error code on error. - * - void iterator_name_end(void **handle) - * - Free any data associated with the iterator. This function must be - * called even when iterator_name_begin() fails. - * - * @todo not all iterators follow this pattern, e.g. cgroup_walk_tree_begin() - * can result both in a state that cgroup_walk_tree_end() is not needed - * and will sigsegv and in a state that cgroup_walk_tree_end() is needed - * to free allocated memory. Complete review is needed! - * @par Example of iterator usage: - * @code - * void *handle; // our iterator handle - * my_type item; // the data returned by the iterator - * int ret; - * ret = iterator_name_begin(&handle, &item); - * while (ret == 0) { - * // process the item here - * ret = iterator_name_begin(&handle, &item); - * } - * if (ret != ECGEOF) { - * // process the error here - * } - * iterator_name_end(&handle); - * @endcode - * - * @name Walk through control group filesystem - * @{ - * This iterator returns all subgroups of given control group. It can be used - * to return all groups in given hierarchy, when root control group is provided. - */ - -/** - * Type of the walk. - */ -enum cgroup_walk_type { - /** - * Pre-order directory walk, return a directory first and then its - * subdirectories. - * E.g. directories would be returned in this order: - * @code - * / - * /group - * /group/subgroup1 - * /group/subgroup1/subsubgroup - * /group/subgroup2 - * @endcode - */ - CGROUP_WALK_TYPE_PRE_DIR = 0x1, - /** - * Post-order directory walk, return subdirectories of a directory - * first and then the directory itself. - * E.g. directories would be returned in this order: - * @code - * /group/subgroup1/subsubgroup - * /group/subgroup1 - * /group/subgroup2 - * /group - * / - * @endcode - */ - CGROUP_WALK_TYPE_POST_DIR = 0x2, -}; - -/** - * Type of returned entity. - */ -enum cgroup_file_type { - CGROUP_FILE_TYPE_FILE, /**< File. */ - CGROUP_FILE_TYPE_DIR, /**< Directory. */ - CGROUP_FILE_TYPE_OTHER, /**< Directory. @todo really? */ -}; - -/** - * Information about found directory (= a control group). - */ -struct cgroup_file_info { - /** Type of the entity. */ - enum cgroup_file_type type; - /** Name of the entity. */ - const char *path; - /** Name of its parent. */ - const char *parent; - /** - * Full path to the entity. To get path relative to the root of the - * walk, you must store its @c full_path (or its length) - * and calculate the relative path by yourself. - */ - const char *full_path; - /** - * Depth of the entity, how many directories below the root of - * walk it is. - */ - short depth; -}; - -/** - * Walk through the directory tree for the specified controller. - * The directory representing @c base_path is returned in @c info. - * Use cgroup_walk_tree_set_flags() to specify, in which order should be next - * directories returned. - * @param controller Name of the controller, for which we want to walk - * the directory tree. - * @param base_path Begin walking from this path. Use "/" to walk through - * full hierarchy. - * @param depth The maximum depth to which the function should walk, 0 - * implies all the way down. - * @param handle The handle to be used during iteration. - * @param info The info filled and returned about directory information. - * @param base_level Opaque integer which you must pass to subsequent - * cgroup_walk_tree_next. - * @todo why base_level is not hidden in **handle? - * @return #ECGEOF when there is no node. - */ -int cgroup_walk_tree_begin(const char *controller, const char *base_path, int depth, - void **handle, struct cgroup_file_info *info, - int *base_level); - -/** - * Get the next directory in the walk. - * @param depth The maximum depth to which the function should walk, 0 - * implies all the way down. - * @param handle The handle to be used during iteration. - * @param info The info filled and returned about the next directory. - * @param base_level Value of base_level returned by cgroup_walk_tree_begin(). - * @return #ECGEOF when we are done walking through the nodes. - */ -int cgroup_walk_tree_next(int depth, void **handle, - struct cgroup_file_info *info, int base_level); - -/** - * Release the iterator. - */ -int cgroup_walk_tree_end(void **handle); - -/** - * Set the flags for walk_tree. Currently available flags are in - * #cgroup_walk_type enum. - * @param handle The handle of the iterator. - * @param flags - */ -int cgroup_walk_tree_set_flags(void **handle, int flags); - -/** - * Read the value of the given variable for the specified - * controller and control group. - * The value is read up to newline character or at most max-1 characters, - * whichever comes first (i.e. similar to fgets()). - * @param controller Name of the controller for which stats are requested. - * @param path The path to control group, relative to hierarchy root. - * @param name is variable name. - * @param handle The handle to be used during iteration. - * @param buffer The buffer to read the value into. - * The buffer is always zero-terminated. - * @param max Maximal lenght of the buffer - * @return #ECGEOF when the stats file is empty. - */ - -int cgroup_read_value_begin(const char * const controller, const char *path, - const char * const name, void **handle, - char *buffer, int max); - -/** - * Read the next string from the given variable handle - * which is generated by cgroup_read_stats_begin() function. - * the value is read up to newline character or at most max-1 characters, - * whichever comes first (i.e. similar to fgets()) per - * cgroup_read_stats_next() call - * @param handle The handle to be used during iteration. - * @param data returned the string. - * @param buffer The buffer to read the value into. - * The buffer is always zero-terminated. - * @param max Maximal lenght of the buffer - * @return #ECGEOF when the iterator finishes getting the list of stats. - */ -int cgroup_read_value_next(void **handle, char *buffer, int max); - -/** - * Release the iterator. - */ -int cgroup_read_value_end(void **handle); - -/** - * @} - * - * @name Read group stats - * libcgroup's cgroup_get_value_string() reads only relatively short parametrs - * of a group. Use following functions to read @c stats parameter, which can - * be quite long. - */ - -/** - * Maximum length of a value in stats file. - */ -#define CG_VALUE_MAX 100 -/** - * One item in stats file. - */ -struct cgroup_stat { - char name[FILENAME_MAX]; - char value[CG_VALUE_MAX]; -}; - -/** - * Read the statistics values (= @c stats parameter) for the specified - * controller and control group. One line is returned per - * cgroup_read_stats_begin() and cgroup_read_stats_next() call. - * @param controller Name of the controller for which stats are requested. - * @param path The path to control group, relative to hierarchy root. - * @param handle The handle to be used during iteration. - * @param stat Returned first item in the stats file. - * @return #ECGEOF when the stats file is empty. - */ -int cgroup_read_stats_begin(const char *controller, const char *path, void **handle, - struct cgroup_stat *stat); - -/** - * Read the next stat value. - * @param handle The handle to be used during iteration. - * @param stat Returned next item in the stats file. - * @return #ECGEOF when the iterator finishes getting the list of stats. - */ -int cgroup_read_stats_next(void **handle, struct cgroup_stat *stat); - -/** - * Release the iterator. - */ -int cgroup_read_stats_end(void **handle); - -/** - * @} - * - * @name List all tasks in a group - * Use following functions to read @c tasks file of a group. - * @{ - */ - -/** - * Read the tasks file to get the list of tasks in a cgroup. - * @param cgroup Name of the cgroup. - * @param controller Name of the cgroup subsystem. - * @param handle The handle to be used in the iteration. - * @param pid The pid read from the tasks file. - * @return #ECGEOF when the group does not contain any tasks. - */ -int cgroup_get_task_begin(const char *cgroup, const char *controller, void **handle, - pid_t *pid); - -/** - * Read the next task value. - * @param handle The handle used for iterating. - * @param pid The variable where the value will be stored. - * - * @return #ECGEOF when the iterator finishes getting the list of tasks. - */ -int cgroup_get_task_next(void **handle, pid_t *pid); - -/** - * Release the iterator. - */ -int cgroup_get_task_end(void **handle); - -/** - * @} - * - * @name List mounted controllers - * Use following function to list mounted controllers and to see, how they - * are mounted together in hierarchies. - * Use cgroup_get_all_controller_begin() (see later) to list all controllers, - * including those which are not mounted. - * @{ - */ - -/** - * Information about mounted controller. - */ -struct cgroup_mount_point { - /** Name of the controller. */ - char name[FILENAME_MAX]; - /** Mount point of the controller. */ - char path[FILENAME_MAX]; -}; - -/** - * Read the mount table to give a list where each controller is - * mounted. - * @param handle The handle to be used for iteration. - * @param info The variable where the path to the controller is stored. - * @return #ECGEOF when no controllers are mounted. - */ -int cgroup_get_controller_begin(void **handle, struct cgroup_mount_point *info); - -/** - * Read the next mounted controller. - * While walking through the mount table, the controllers are - * returned in order of their mount points, i.e. controllers mounted together - * in one hierarchy are returned next to each other. - * @param handle The handle to be used for iteration. - * @param info The variable where the path to the controller is stored. - * @return #ECGEOF when all controllers were already returned. - */ -int cgroup_get_controller_next(void **handle, struct cgroup_mount_point *info); - -/** - * Release the iterator. - */ -int cgroup_get_controller_end(void **handle); - -/** - * @} - * - * @name List all controllers - * Use following functions to list all controllers, including those which are - * not mounted. The controllers are returned in the same order as in - * /proc/cgroups file, i.e. mostly random. - */ - -/** - * Detailed information about available controller. - */ -struct controller_data { - /** Controller name. */ - char name[FILENAME_MAX]; - /** - * Hierarchy ID. Controllers with the same hierarchy ID - * are mounted together as one hierarchy. Controllers with - * ID 0 are not currently mounted anywhere. - */ - int hierarchy; - /** Number of groups. */ - int num_cgroups; - /** Enabled flag. */ - int enabled; -}; - -/** - * Read the first of controllers from /proc/cgroups. - * @param handle The handle to be used for iteration. - * @param info The structure which will be filled with controller data. - */ -int cgroup_get_all_controller_begin(void **handle, - struct controller_data *info); -/** - * Read next controllers from /proc/cgroups. - * @param handle The handle to be used for iteration. - * @param info The structure which will be filled with controller data. - */ -int cgroup_get_all_controller_next(void **handle, struct controller_data *info); - -/** - * Release the iterator - */ -int cgroup_get_all_controller_end(void **handle); - -/** - * @} - * - * @name List all mount points of a controller. - * Use following functions to list all mount points of a hierarchy with given - * controller. - */ - -/** - * Read the first mount point of the hierarchy with given controller. - * The first is the same as the mount point returned by - * cgroup_get_subsys_mount_point(). - * @param handle The handle to be used for iteration. - * @param controller The controller name. - * @param path Buffer to fill the path into. The buffer must be at least - * FILENAME_MAX characters long. - */ -int cgroup_get_subsys_mount_point_begin(const char *controller, void **handle, - char *path); - -/** - * Read next mount point of the hierarchy with given controller. - * @param handle The handle to be used for iteration. - * @param path Buffer to fill the path into. The buffer must be at least - * FILENAME_MAX characters long. - */ -int cgroup_get_subsys_mount_point_next(void **handle, char *path); - -/** - * Release the iterator. - */ -int cgroup_get_subsys_mount_point_end(void **handle); - -/** - * @} - * @} - */ - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_ITERATORS_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/log.h b/lib/libcgroup-3.1.0/include/libcgroup/log.h deleted file mode 100644 index b65b8d39aa4..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/log.h +++ /dev/null @@ -1,158 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_LOG_H -#define _LIBCGROUP_LOG_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#endif - -#include - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @defgroup group_log 7. Logging - * @{ - * - * @name Logging - * @{ - * Libcgroup allows applications to register a callback function which - * libcgroup will call when it wants to log something. Each log message - * has associated a log level. As described in previous chapter, most libcgroup - * functions return an error code, which described root cause of the failure - * and log messages might provide further details about these failures and other - * notable events. - * - * @par - * The logging callback can be set at any time, but setting the callback before - * any other libcgroup function (including cgroup_init()) is highly recommended. - * If no logger is set before cgroup_init() is called, default logger is - * automatically set, logging CGROUP_LOG_ERROR messages to stdout. - * - * @par Setting log level - * Some of the functions below set the log level as integer. - * Application can set directly a value of enum #cgroup_log_level or use - * value -1 to set the log level automatically. In this case, libcgroup - * inspects environment variable CGROUP_LOGLEVEL if it is set - * and contains any of these values: ERROR, WARNING, - * INFO, DEBUG or integer number representing value from - * enum #cgroup_log_level. If CGROUP_LOGLEVEL is not set or its value - * is not valid, CGROUP_LOG_ERROR is set as default log level. - * - * @par Example: - * Following short example shows custom libcgroup logger sending all log - * messages to stderr: - * @code - * static void my_logger(void *userdata, int level, const char *fmt, va_list ap) - * { - * vfprintf(stderr, fmt, ap); - * } - * - * int main(int argc, char **argv) - * { - * int ret; - * - * cgroup_set_logger(my_logger, -1, NULL); - * ret = cgroup_init(); - * if (ret) { - * ... - * } - * ... - * @endcode - */ - -/** - * Level of importance of a log message. - */ -enum cgroup_log_level { - /** - * Continue printing the log message, with the previous log level. - * Used to print log messages without the line break. - */ - CGROUP_LOG_CONT = 0, - /** - * Something serious happened and libcgroup failed to perform requested - * operation. - */ - CGROUP_LOG_ERROR, - /** - * Something bad happened but libcgroup recovered from the error. - */ - CGROUP_LOG_WARNING, - /** - * Something interesting happened and the message might be useful to the - * user. - */ - CGROUP_LOG_INFO, - /** - * Debugging messages useful to libcgroup developers. - */ - CGROUP_LOG_DEBUG, -}; - -typedef void (*cgroup_logger_callback)(void *userdata, int level, - const char *fmt, va_list ap); - -/** - * Set libcgroup logging callback. All log messages with equal or lower log - * level will be sent to the application's callback. There can be only - * one callback logger set, the previous callback is replaced with the new one - * by calling this function. - * Use NULL as the logger callback to completely disable libcgroup logging. - * - * @param logger The callback. - * @param loglevel The log level. Use value -1 to automatically discover the - * level from CGROUP_LOGLEVEL environment variable. - * @param userdata Application's data which will be provided back to the - * callback. - */ -extern void cgroup_set_logger(cgroup_logger_callback logger, int loglevel, - void *userdata); - -/** - * Set libcgroup logging to stdout. All messages with the given loglevel - * or below will be sent to standard output. Previous logger set by - * cgroup_set_logger() is replaced. - * - * @param loglevel The log level. Use value -1 to automatically discover the - * level from CGROUP_LOGLEVEL environment variable. - */ -extern void cgroup_set_default_logger(int loglevel); - -/** - * Change current loglevel. - * @param loglevel The log level. Use value -1 to automatically discover the - * level from CGROUP_LOGLEVEL environment variable. - */ -extern void cgroup_set_loglevel(int loglevel); - -/** - * Libcgroup log function. This is for applications which are too lazy to set - * up their own complex logging and miss-use libcgroup for that purpose. - * I.e. this function should be used only by simple command-line tools. - * This logging automatically benefits from CGROUP_LOGLEVEL env. variable. - */ -extern void cgroup_log(int loglevel, const char *fmt, ...); - -/** - * Parse levelstr string for information about desired loglevel. The levelstr - * is usually a value of the CGROUP_LOGLEVEL environment variable. - * @param levelstr String containing desired loglevel. - */ -extern int cgroup_parse_log_level_str(const char *levelstr); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_LOG_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/systemd.h b/lib/libcgroup-3.1.0/include/libcgroup/systemd.h deleted file mode 100644 index ab06128184a..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/systemd.h +++ /dev/null @@ -1,140 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_SYSTEMD_H -#define _LIBCGROUP_SYSTEMD_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -enum cgroup_systemd_mode_t { - CGROUP_SYSTEMD_MODE_FAIL = 0, - CGROUP_SYSTEMD_MODE_REPLACE, - CGROUP_SYSTEMD_MODE_ISOLATE, - CGROUP_SYSTEMD_MODE_IGNORE_DEPS, - CGROUP_SYSTEMD_MODE_IGNORE_REQS, - - CGROUP_SYSTEMD_MODE_CNT, - CGROUP_SYSTEMD_MODE_DFLT = CGROUP_SYSTEMD_MODE_REPLACE -}; - -/** - * Options associated with creating a systemd scope - */ -struct cgroup_systemd_scope_opts { - /** should systemd delegate this cgroup or not. 1 == yes, 0 == no */ - int delegated; - /** systemd behavior when the scope already exists */ - enum cgroup_systemd_mode_t mode; - /** pid to be placed in the cgroup. if 0, libcgroup will create a dummy process */ - pid_t pid; -}; - -/* - * cgroup systemd settings - */ -struct cgroup_systemd_opts { - char slice_name[FILENAME_MAX]; - char scope_name[FILENAME_MAX]; - int setdefault; - pid_t pid; - struct cgroup_systemd_opts *next; -}; - -/** - * Populate the scope options structure with default values - * - * @param opts Scope creation options structure instance. Must already be allocated - * - * @return 0 on success and > 0 on error - */ -int cgroup_set_default_scope_opts(struct cgroup_systemd_scope_opts * const opts); - -/** - * Create a systemd scope under the specified slice - * - * @param scope_name Name of the scope, must end in .scope - * @param slice_name Name of the slice, must end in .slice - * @param opts Scope creation options structure instance - * - * @return 0 on success and > 0 on error - */ -int cgroup_create_scope(const char * const scope_name, const char * const slice_name, - const struct cgroup_systemd_scope_opts * const opts); - -/** - * Create a systemd scope - * - * @param cgroup - * @param ignore_ownership When nonzero, all errors are ignored when setting owner of the group - * owner of the group and/or its tasks file - * @param opts Scope creation options structure instance - * - * @return 0 on success and > 0 on error - * - * @note The cgroup->name field should be of the form "foo.slice/bar.scope" - */ -int cgroup_create_scope2(struct cgroup *cgroup, int ignore_ownership, - const struct cgroup_systemd_scope_opts * const opts); - -/** - * Parse the systemd default cgroup's relative path from - * /var/run/libcgroup/systemd and set it as default delegation cgroup - * path, if available. - * - * The path is relative to cgroup root (default: /sys/fs/cgroup) - * - * @return 1 if a valid default slice/scope is set, 0 in all other cases - */ -int cgroup_set_default_systemd_cgroup(void); - -/** - * Parse the systemd delegation settings from the configuration file - * and allocate a new cgroup_systemd_opts object. - * This function internally calls cgroup_add_systemd_opts() to add the conf and - * value to the newly allocated cgroup_systemd_opts object. - * - * @param conf Name of the systemd delegate setting read from configuration file. - * @param value The value of the conf systemd delegate setting. - * - * @return 1 on success and 0 on error - */ -int cgroup_alloc_systemd_opts(const char * const conf, const char * const value); - -/** - * Parse the systemd delegation settings from the configuration file - * and add the conf and value to the last allocated cgroup_systemd_opts object - * (tail) allocated by cgroup_alloc_systemd_opts() - * - * @param conf Name of the systemd delegate setting read from configuration file. - * @param value The value of the conf systemd delegate setting. - * - * @return 1 on success and 0 on error - */ -int cgroup_add_systemd_opts(const char * const conf, const char * const value); - -/** - * Free the cgroup_systemd_opts objects allocated by cgroup_alloc_systemd_opts() - */ -void cgroup_cleanup_systemd_opts(void); - -/* - * Write the specified slice and scope to the libcgroup systemd run file. This - * slice and scope will then be used as the default cgroup root. Subsequent - * libcgroup commands, cgget, etc., will utilize this slice and scope when - * constructing the libcgroup path - * - * @param slice Slice name, e.g. libcgroup.slice - * @param scope Scope name, e.g. database.scope - */ -int cgroup_write_systemd_default_cgroup(const char * const slice, - const char * const scope); - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_SYSTEMD_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/tasks.h b/lib/libcgroup-3.1.0/include/libcgroup/tasks.h deleted file mode 100644 index 77a85265f4a..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/tasks.h +++ /dev/null @@ -1,214 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -#ifndef _LIBCGROUP_TASKS_H -#define _LIBCGROUP_TASKS_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#include - -#ifndef SWIG -#include -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/** Flags for cgroup_change_cgroup_uid_gid(). */ -enum cgflags { - /** Use cached rules, do not read rules from disk. */ - CGFLAG_USECACHE = 0x01, - /** Use cached templates, do not read templates from disk. */ - CGFLAG_USE_TEMPLATE_CACHE = 0x02, -}; - -/** Flags for cgroup_register_unchanged_process(). */ -enum cgroup_daemon_type { - /** - * The daemon must not touch the given task, i.e. it never moves it - * to any controlgroup. - */ - CGROUP_DAEMON_UNCHANGE_CHILDREN = 0x1, - CGROUP_DAEMON_CANCEL_UNCHANGE_PROCESS = 0x2, -}; - -/** - * @defgroup group_tasks 4. Manipulation with tasks - * @{ - * - * @name Simple task assignment - * @{ - * Applications can use following functions to simply put a task into given - * control group and find a groups where given tasks is. - */ - -/** - * Move current task (=thread) to given control group. - * @param cgroup Destination control group. - */ -int cgroup_attach_task(struct cgroup *cgroup); - -/** - * Move given task (=thread) to given control group. - * @param cgroup Destination control group. - * @param tid The task to move. - */ -int cgroup_attach_task_pid(struct cgroup *cgroup, pid_t tid); - -/** - * Changes the cgroup of a task based on the path provided. In this case, - * the user must already know into which cgroup the task should be placed and - * no rules will be parsed. - * - * @param path Name of the destination group. - * @param pid The task to move. - * @param controllers List of controllers. - * - * @todo should this function be really public? - */ -int cgroup_change_cgroup_path(const char *path, pid_t pid, - const char * const controllers[]); - -/** - * Get the current control group path where the given task is. - * @param pid The task to find. - * @param controller The controller (hierarchy), where to find the task. - * @param current_path The path to control group, where the task has been found. - * The patch is relative to the root of the hierarchy. The caller must - * free this memory. - */ -int cgroup_get_current_controller_path(pid_t pid, const char *controller, - char **current_path); - -/** - * @} - * - * @name Rules - * @{ - * @c libcgroup can move tasks to control groups using simple rules, loaded - * from configuration file. See cgrules.conf man page to see format of the file. - * Following functions can be used to load these rules from a file. - */ - -/** - * Initializes the rules cache and load it from /etc/cgrules.conf. - * @todo add parameter with the filename? - */ -int cgroup_init_rules_cache(void); - -/** - * Reloads the rules list from /etc/cgrules.conf. This function - * is probably NOT thread safe (calls cgroup_parse_rules_config()). - */ -int cgroup_reload_cached_rules(void); - -/** - * Print the cached rules table. This function should be called only after - * first calling cgroup_parse_config(), but it will work with an empty rule - * list. - * @param fp Destination file, where the rules will be printed. - */ -void cgroup_print_rules_config(FILE *fp); - -/** - * @} - * @name Rule based task assignment - * @{ - * @c libcgroup can move tasks to control groups using simple rules, loaded - * from configuration file. See cgrules.conf man page to see format of the file. - * Applications can move tasks to control groups based on these rules using - * following functions. - */ - -/** - * Changes the cgroup of all running PIDs based on the rules in the config - * file. If a rules exists for a PID, then the PID is placed in the correct - * group. - * - * This function may be called after creating new control groups to move - * running PIDs into the newly created control groups. - * @return 0 on success, < 0 on error - */ -int cgroup_change_all_cgroups(void); - -/** - * Changes the cgroup of a program based on the rules in the config file. - * If a rule exists for the given UID, GID or PROCESS NAME, then the given - * PID is placed into the correct group. By default, this function parses - * the configuration file each time it is called. - * - * The flags can alter the behavior of this function: - * CGFLAG_USECACHE: Use cached rules instead of parsing the config file - * CGFLAG_USE_TEMPLATE_CACHE: Use cached templates instead of - * parsing the config file - * - * This function may NOT be thread safe. - * @param uid The UID to match. - * @param gid The GID to match. - * @param procname The PROCESS NAME to match. - * @param pid The PID of the process to move. - * @param flags Bit flags to change the behavior, as defined in enum #cgflags. - * @todo Determine thread-safeness and fix of not safe. - */ -int cgroup_change_cgroup_flags(uid_t uid, gid_t gid, - const char *procname, pid_t pid, int flags); - -/** - * Changes the cgroup of a program based on the rules in the config file. If a - * rule exists for the given UID or GID, then the given PID is placed into the - * correct group. By default, this function parses the configuration file each - * time it is called. - * - * This function may NOT be thread safe. - * @param uid The UID to match. - * @param gid The GID to match. - * @param pid The PID of the process to move. - * @param flags Bit flags to change the behavior, as defined in enum #cgflags. - * @todo Determine thread-safeness and fix if not safe. - */ -int cgroup_change_cgroup_uid_gid_flags(uid_t uid, gid_t gid, - pid_t pid, int flags); - -/** - * Provides backwards-compatibility with older versions of the API. This - * function is deprecated, and cgroup_change_cgroup_uid_gid_flags() should be - * used instead. In fact, this function simply calls the newer one with flags - * set to 0 (none). - * @param uid The UID to match. - * @param gid The GID to match. - * @param pid The PID of the process to move. - */ -int cgroup_change_cgroup_uid_gid(uid_t uid, gid_t gid, pid_t pid); - -/** - * @} - * @name Communication with cgrulesengd daemon - * @{ - * Users can use cgrulesengd daemon to move tasks to groups based on the rules - * automatically when they change their UID, GID or executable name. - * The daemon allows tasks to be 'sticky', i.e. all rules are ignored for these - * tasks and the daemon never moves them. - */ - -/** - * Register the unchanged process to a cgrulesengd daemon. This process - * is never moved to another control group by the daemon. - * If the daemon does not work, this function returns 0 as success. - * @param pid The task id. - * @param flags Bit flags to change the behavior, as defined in - * #cgroup_daemon_type - */ -int cgroup_register_unchanged_process(pid_t pid, int flags); - -/** - * @} - * @} - */ -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_TASKS_H */ diff --git a/lib/libcgroup-3.1.0/include/libcgroup/tools.h b/lib/libcgroup-3.1.0/include/libcgroup/tools.h deleted file mode 100644 index 9fcbb151f7c..00000000000 --- a/lib/libcgroup-3.1.0/include/libcgroup/tools.h +++ /dev/null @@ -1,61 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Libcgroup tools header file - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#ifndef _LIBCGROUP_TOOLS_H -#define _LIBCGROUP_TOOLS_H - -#ifndef _LIBCGROUP_H_INSIDE -#error "Only should be included directly." -#endif - -#ifndef SWIG -#include -#include -#include -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * Read the setting-value pairs in the cgroup sysfs for param cg. - * cgroup_cgxget() will perform the necessary conversions to match - * the "on-disk" format and then convert the data back to the - * requested version. If successful, cg will be populated with - * the setting-value pairs. - * - * @param cg Input/Output cgroup. Must be initialized and freed by the caller - * @param version Cgroup version of cg If set to CGROUP_UNK, the versions - * stored within each controller will be used. Otherwise this - * value will be used to override the cg param's controller - * versions - * @param ignore_unmappable Ignore failures due to settings that cannot be - * converted from one cgroup version to another - */ -int cgroup_cgxget(struct cgroup **cg, - enum cg_version_t version, bool ignore_unmappable); - -/** - * Write the setting-value pairs in *cg to the cgroup sysfs. - * cgroup_cgxset() will perform the necessary conversions to match the - * "on-disk" format prior to writing to the cgroup sysfs. - * - * @param cg cgroup instance that will be written to the cgroup sysfs - * @param version Cgroup version of *cg - * @param ignore_unmappable Ignore failures due to settings that cannot be - * converted from one cgroup version to another - */ -int cgroup_cgxset(const struct cgroup * const cg, - enum cg_version_t version, bool ignore_unmappable); - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _LIBCGROUP_TOOLS_H */ diff --git a/lib/libcgroup-3.1.0/libcgroup.doxyfile b/lib/libcgroup-3.1.0/libcgroup.doxyfile deleted file mode 100644 index bc8b4736191..00000000000 --- a/lib/libcgroup-3.1.0/libcgroup.doxyfile +++ /dev/null @@ -1,1519 +0,0 @@ -# Doxyfile 1.6.1 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project -# -# All text after a hash (#) is considered a comment and will be ignored -# The format is: -# TAG = value [value, ...] -# For lists items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (" ") - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# This tag specifies the encoding used for all characters in the config file -# that follow. The default is UTF-8 which is also the encoding used for all -# text before the first occurrence of this tag. Doxygen uses libiconv (or the -# iconv built into libc) for the transcoding. See -# http://www.gnu.org/software/libiconv for the list of possible encodings. - -DOXYFILE_ENCODING = UTF-8 - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded -# by quotes) that should identify the project. - -PROJECT_NAME = libcgroup - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. -# This could be handy for archiving the generated documentation or -# if some version control system is used. - -PROJECT_NUMBER = - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) -# base path where the generated documentation will be put. -# If a relative path is entered, it will be relative to the location -# where doxygen was started. If left blank the current directory will be used. - -OUTPUT_DIRECTORY = doc/generated - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create -# 4096 sub-directories (in 2 levels) under the output directory of each output -# format and will distribute the generated files over these directories. -# Enabling this option can be useful when feeding doxygen a huge amount of -# source files, where putting all generated files in the same directory would -# otherwise cause performance problems for the file system. - -CREATE_SUBDIRS = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# The default language is English, other supported languages are: -# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, -# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German, -# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English -# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, -# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak, -# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese. - -OUTPUT_LANGUAGE = English - -# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will -# include brief member descriptions after the members that are listed in -# the file and class documentation (similar to JavaDoc). -# Set to NO to disable this. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend -# the brief description of a member or function before the detailed description. -# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator -# that is used to form the text in various listings. Each string -# in this list, if found as the leading text of the brief description, will be -# stripped from the text and the result after processing the whole list, is -# used as the annotated text. Otherwise, the brief description is used as-is. -# If left blank, the following values are used ("$name" is automatically -# replaced with the name of the entity): "The $name class" "The $name widget" -# "The $name file" "is" "provides" "specifies" "contains" -# "represents" "a" "an" "the" - -ABBREVIATE_BRIEF = - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# Doxygen will generate a detailed section even if there is only a brief -# description. - -ALWAYS_DETAILED_SEC = YES - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full -# path before files name in the file list and in the header files. If set -# to NO the shortest path that makes the file name unique will be used. - -FULL_PATH_NAMES = YES - -# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag -# can be used to strip a user-defined part of the path. Stripping is -# only done if one of the specified strings matches the left-hand part of -# the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the -# path to strip. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of -# the path mentioned in the documentation of a class, which tells -# the reader which header file to include in order to use a class. -# If left blank only the name of the header file containing the class -# definition is used. Otherwise one should specify the include paths that -# are normally passed to the compiler using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter -# (but less readable) file names. This can be useful is your file systems -# doesn't support long names like on DOS, Mac, or CD-ROM. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen -# will interpret the first line (until the first dot) of a JavaDoc-style -# comment as the brief description. If set to NO, the JavaDoc -# comments will behave just like regular Qt-style comments -# (thus requiring an explicit @brief command for a brief description.) - -JAVADOC_AUTOBRIEF = YES - -# If the QT_AUTOBRIEF tag is set to YES then Doxygen will -# interpret the first line (until the first dot) of a Qt-style -# comment as the brief description. If set to NO, the comments -# will behave just like regular Qt-style comments (thus requiring -# an explicit \brief command for a brief description.) - -QT_AUTOBRIEF = NO - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen -# treat a multi-line C++ special comment block (i.e. a block of //! or /// -# comments) as a brief description. This used to be the default behaviour. -# The new default is to treat a multi-line C++ comment block as a detailed -# description. Set this tag to YES if you prefer the old behaviour instead. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented -# member inherits the documentation from any documented member that it -# re-implements. - -INHERIT_DOCS = YES - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce -# a new page for each member. If set to NO, the documentation of a member will -# be part of the file/class/namespace that contains it. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. -# Doxygen uses this value to replace tabs by spaces in code fragments. - -TAB_SIZE = 8 - -# This tag can be used to specify a number of aliases that acts -# as commands in the documentation. An alias has the form "name=value". -# For example adding "sideeffect=\par Side Effects:\n" will allow you to -# put the command \sideeffect (or @sideeffect) in the documentation, which -# will result in a user-defined paragraph with heading "Side Effects:". -# You can put \n's in the value part of an alias to insert newlines. - -ALIASES = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C -# sources only. Doxygen will then generate output that is more tailored for C. -# For instance, some of the names that are used will be different. The list -# of all members will be omitted, etc. - -OPTIMIZE_OUTPUT_FOR_C = YES - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java -# sources only. Doxygen will then generate output that is more tailored for -# Java. For instance, namespaces will be presented as packages, qualified -# scopes will look different, etc. - -OPTIMIZE_OUTPUT_JAVA = NO - -# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran -# sources only. Doxygen will then generate output that is more tailored for -# Fortran. - -OPTIMIZE_FOR_FORTRAN = NO - -# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL -# sources. Doxygen will then generate output that is tailored for -# VHDL. - -OPTIMIZE_OUTPUT_VHDL = NO - -# Doxygen selects the parser to use depending on the extension of the files it parses. -# With this tag you can assign which parser to use for a given extension. -# Doxygen has a built-in mapping, but you can override or extend it using this tag. -# The format is ext=language, where ext is a file extension, and language is one of -# the parsers supported by doxygen: IDL, Java, Javascript, C#, C, C++, D, PHP, -# Objective-C, Python, Fortran, VHDL, C, C++. For instance to make doxygen treat -# .inc files as Fortran files (default is PHP), and .f files as C (default is Fortran), -# use: inc=Fortran f=C. Note that for custom extensions you also need to set FILE_PATTERNS otherwise the files are not read by doxygen. - -EXTENSION_MAPPING = - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want -# to include (a tag file for) the STL sources as input, then you should -# set this tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. -# func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. - -BUILTIN_STL_SUPPORT = NO - -# If you use Microsoft's C++/CLI language, you should set this option to YES to -# enable parsing support. - -CPP_CLI_SUPPORT = NO - -# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. -# Doxygen will parse them like normal C++ but will assume all classes use public -# instead of private inheritance when no explicit protection keyword is present. - -SIP_SUPPORT = NO - -# For Microsoft's IDL there are propget and propput attributes to indicate getter -# and setter methods for a property. Setting this option to YES (the default) -# will make doxygen to replace the get and set methods by a property in the -# documentation. This will only work if the methods are indeed getting or -# setting a simple type. If this is not the case, or you want to show the -# methods anyway, you should set this option to NO. - -IDL_PROPERTY_SUPPORT = NO - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES (the default) to allow class member groups of -# the same type (for instance a group of public functions) to be put as a -# subgroup of that type (e.g. under the Public Functions section). Set it to -# NO to prevent subgrouping. Alternatively, this can be done per class using -# the \nosubgrouping command. - -SUBGROUPING = NO - -# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum -# is documented as struct, union, or enum with the name of the typedef. So -# typedef struct TypeS {} TypeT, will appear in the documentation as a struct -# with name TypeT. When disabled the typedef will appear as a member of a file, -# namespace, or class. And the struct will be named TypeS. This can typically -# be useful for C code in case the coding convention dictates that all compound -# types are typedef'ed and only the typedef is referenced, never the tag name. - -TYPEDEF_HIDES_STRUCT = NO - -# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to -# determine which symbols to keep in memory and which to flush to disk. -# When the cache is full, less often used symbols will be written to disk. -# For small to medium size projects (<1000 input files) the default value is -# probably good enough. For larger projects a too small cache size can cause -# doxygen to be busy swapping symbols to and from disk most of the time -# causing a significant performance penality. -# If the system has enough physical memory increasing the cache will improve the -# performance by keeping more symbols in memory. Note that the value works on -# a logarithmic scale so increasing the size by one will rougly double the -# memory usage. The cache size is given by this formula: -# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0, -# corresponding to a cache size of 2^16 = 65536 symbols - -SYMBOL_CACHE_SIZE = 0 - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = YES - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = YES - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = YES - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = NO - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base -# name of the file that contains the anonymous namespace. By default -# anonymous namespace are hidden. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = NO - -# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any -# documentation blocks found inside the body of a function. -# If set to NO (the default) these blocks will be appended to the -# function's detailed documentation block. - -HIDE_IN_BODY_DOCS = NO - -# The INTERNAL_DOCS tag determines if documentation -# that is typed after a \internal command is included. If the tag is set -# to NO (the default) then the documentation will be excluded. -# Set it to YES to include the internal documentation. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate -# file names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. - -CASE_SENSE_NAMES = YES - -# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen -# will show members with their full class and namespace scopes in the -# documentation. If set to YES the scope will be hidden. - -HIDE_SCOPE_NAMES = NO - -# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen -# will put a list of the files that are included by a file in the documentation -# of that file. - -SHOW_INCLUDE_FILES = YES - -# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] -# is inserted in the documentation for inline members. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen -# will sort the (detailed) documentation of file and class members -# alphabetically by member name. If set to NO the members will appear in -# declaration order. - -SORT_MEMBER_DOCS = YES - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the -# brief documentation of file, namespace and class members alphabetically -# by member name. If set to NO (the default) the members will appear in -# declaration order. - -SORT_BRIEF_DOCS = NO - -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the (brief and detailed) documentation of class members so that constructors and destructors are listed first. If set to NO (the default) the constructors will appear in the respective orders defined by SORT_MEMBER_DOCS and SORT_BRIEF_DOCS. This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO. - -SORT_MEMBERS_CTORS_1ST = NO - -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the -# hierarchy of group names into alphabetical order. If set to NO (the default) -# the group names will appear in their defined order. - -SORT_GROUP_NAMES = YES - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be -# sorted by fully-qualified names, including namespaces. If set to -# NO (the default), the class list will be sorted only by class name, -# not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the -# alphabetical list. - -SORT_BY_SCOPE_NAME = NO - -# The GENERATE_TODOLIST tag can be used to enable (YES) or -# disable (NO) the todo list. This list is created by putting \todo -# commands in the documentation. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable (YES) or -# disable (NO) the test list. This list is created by putting \test -# commands in the documentation. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable (YES) or -# disable (NO) the bug list. This list is created by putting \bug -# commands in the documentation. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or -# disable (NO) the deprecated list. This list is created by putting -# \deprecated commands in the documentation. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional -# documentation sections, marked by \if sectionname ... \endif. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines -# the initial value of a variable or define consists of for it to appear in -# the documentation. If the initializer consists of more lines than specified -# here it will be hidden. Use a value of 0 to hide initializers completely. -# The appearance of the initializer of individual variables and defines in the -# documentation can be controlled using \showinitializer or \hideinitializer -# command in the documentation regardless of this setting. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated -# at the bottom of the documentation of classes and structs. If set to YES the -# list will mention the files that were used to generate the documentation. - -SHOW_USED_FILES = YES - -# If the sources in your project are distributed over multiple directories -# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy -# in the documentation. The default is NO. - -SHOW_DIRECTORIES = NO - -# Set the SHOW_FILES tag to NO to disable the generation of the Files page. -# This will remove the Files entry from the Quick Index and from the -# Folder Tree View (if specified). The default is YES. - -SHOW_FILES = YES - -# Set the SHOW_NAMESPACES tag to NO to disable the generation of the -# Namespaces page. -# This will remove the Namespaces entry from the Quick Index -# and from the Folder Tree View (if specified). The default is YES. - -SHOW_NAMESPACES = YES - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from -# the version control system). Doxygen will invoke the program by executing (via -# popen()) the command , where is the value of -# the FILE_VERSION_FILTER tag, and is the name of an input file -# provided by doxygen. Whatever the program writes to standard output -# is used as the file version. See the manual for examples. - -FILE_VERSION_FILTER = - -# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed by -# doxygen. The layout file controls the global structure of the generated output files -# in an output format independent way. The create the layout file that represents -# doxygen's defaults, run doxygen with the -l option. You can optionally specify a -# file name after the option, if omitted DoxygenLayout.xml will be used as the name -# of the layout file. - -LAYOUT_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated -# by doxygen. Possible values are YES and NO. If left blank NO is used. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated by doxygen. Possible values are YES and NO. If left blank -# NO is used. - -WARNINGS = YES - -# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings -# for undocumented members. If EXTRACT_ALL is set to YES then this flag will -# automatically be disabled. - -WARN_IF_UNDOCUMENTED = YES - -# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some -# parameters in a documented function, or documenting parameters that -# don't exist or using markup commands wrongly. - -WARN_IF_DOC_ERROR = YES - -# This WARN_NO_PARAMDOC option can be abled to get warnings for -# functions that are documented, but have no documentation for their parameters -# or return value. If set to NO (the default) doxygen will only warn about -# wrong or incomplete parameter documentation, but not about the absence of -# documentation. - -WARN_NO_PARAMDOC = YES - -# The WARN_FORMAT tag determines the format of the warning messages that -# doxygen can produce. The string should contain the $file, $line, and $text -# tags, which will be replaced by the file and line number from which the -# warning originated and the warning text. Optionally the format may contain -# $version, which will be replaced by the version of the file (if it could -# be obtained via FILE_VERSION_FILTER) - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning -# and error messages should be written. If left blank the output is written -# to stderr. - -WARN_LOGFILE = - -#--------------------------------------------------------------------------- -# configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag can be used to specify the files and/or directories that contain -# documented source files. You may enter file names like "myfile.cpp" or -# directories like "/usr/src/myproject". Separate the files or directories -# with spaces. - -INPUT = include - -# This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is -# also the default input encoding. Doxygen uses libiconv (or the iconv built -# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for -# the list of possible encodings. - -INPUT_ENCODING = UTF-8 - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank the following patterns are tested: -# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx -# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90 - -FILE_PATTERNS = - -# The RECURSIVE tag can be used to turn specify whether or not subdirectories -# should be searched for input files as well. Possible values are YES and NO. -# If left blank NO is used. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. - -EXCLUDE = - -# The EXCLUDE_SYMLINKS tag can be used select whether or not files or -# directories that are symbolic links (a Unix filesystem feature) are excluded -# from the input. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. Note that the wildcards are matched -# against the file with absolute path, so to exclude all test directories -# for example use the pattern */test/* - -EXCLUDE_PATTERNS = - -# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names -# (namespaces, classes, functions, etc.) that should be excluded from the -# output. The symbol name can be a fully qualified name, a word, or if the -# wildcard * is used, a substring. Examples: ANamespace, AClass, -# AClass::ANamespace, ANamespace::*Test - -EXCLUDE_SYMBOLS = - -# The EXAMPLE_PATH tag can be used to specify one or more files or -# directories that contain example code fragments that are included (see -# the \include command). - -EXAMPLE_PATH = - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp -# and *.h) to filter out the source-files in the directories. If left -# blank all files are included. - -EXAMPLE_PATTERNS = - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude -# commands irrespective of the value of the RECURSIVE tag. -# Possible values are YES and NO. If left blank NO is used. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or -# directories that contain image that are included in the documentation (see -# the \image command). - -IMAGE_PATH = - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command , where -# is the value of the INPUT_FILTER tag, and is the name of an -# input file. Doxygen will then use the output that the filter program writes -# to standard output. -# If FILTER_PATTERNS is specified, this tag will be -# ignored. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. -# Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. -# The filters are a list of the form: -# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further -# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER -# is applied to all files. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER) will be used to filter the input files when producing source -# files to browse (i.e. when SOURCE_BROWSER is set to YES). - -FILTER_SOURCE_FILES = NO - -#--------------------------------------------------------------------------- -# configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will -# be generated. Documented entities will be cross-referenced with these sources. -# Note: To get rid of all source code in the generated output, make sure also -# VERBATIM_HEADERS is set to NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body -# of functions and classes directly in the documentation. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct -# doxygen to hide any special comment blocks from generated source code -# fragments. Normal C and C++ comments will always remain visible. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES -# then for each documented function all documented -# functions referencing it will be listed. - -REFERENCED_BY_RELATION = NO - -# If the REFERENCES_RELATION tag is set to YES -# then for each documented function all documented entities -# called/used by that function will be listed. - -REFERENCES_RELATION = NO - -# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) -# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from -# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will -# link to the source code. -# Otherwise they will link to the documentation. - -REFERENCES_LINK_SOURCE = NO - -# If the USE_HTAGS tag is set to YES then the references to source code -# will point to the HTML generated by the htags(1) tool instead of doxygen -# built-in source browser. The htags tool is part of GNU's global source -# tagging system (see http://www.gnu.org/software/global/global.html). You -# will need version 4.8.6 or higher. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen -# will generate a verbatim copy of the header file for each class for -# which an include is specified. Set to NO to disable this. - -VERBATIM_HEADERS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index -# of all compounds will be generated. Enable this if the project -# contains a lot of classes, structs, unions or interfaces. - -ALPHABETICAL_INDEX = NO - -# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then -# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns -# in which this list will be split (can be a number in the range [1..20]) - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all -# classes will be put under the same header in the alphabetical index. -# The IGNORE_PREFIX tag can be used to specify one or more prefixes that -# should be ignored while generating the index headers. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES (the default) Doxygen will -# generate HTML output. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `html' will be used as the default path. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for -# each generated HTML page (for example: .htm,.php,.asp). If it is left blank -# doxygen will generate files with .html extension. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a personal HTML header for -# each generated HTML page. If it is left blank doxygen will generate a -# standard header. - -HTML_HEADER = - -# The HTML_FOOTER tag can be used to specify a personal HTML footer for -# each generated HTML page. If it is left blank doxygen will generate a -# standard footer. - -HTML_FOOTER = - -# If the HTML_TIMESTAMP tag is set to YES then the generated HTML -# documentation will contain the timesstamp. - -HTML_TIMESTAMP = NO - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading -# style sheet that is used by each HTML page. It can be used to -# fine-tune the look of the HTML output. If the tag is left blank doxygen -# will generate a default style sheet. Note that doxygen will try to copy -# the style sheet file to the HTML output directory, so don't put your own -# stylesheet in the HTML output directory as well, or it will be erased! - -HTML_STYLESHEET = - -# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, -# files or namespaces will be aligned in HTML using tables. If set to -# NO a bullet list will be used. - -HTML_ALIGN_MEMBERS = YES - -# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML -# documentation will contain sections that can be hidden and shown after the -# page has loaded. For this to work a browser that supports -# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox -# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari). - -HTML_DYNAMIC_SECTIONS = NO - -# If the GENERATE_DOCSET tag is set to YES, additional index files -# will be generated that can be used as input for Apple's Xcode 3 -# integrated development environment, introduced with OSX 10.5 (Leopard). -# To create a documentation set, doxygen will generate a Makefile in the -# HTML output directory. Running make will produce the docset in that -# directory and running "make install" will install the docset in -# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find -# it at startup. -# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for more information. - -GENERATE_DOCSET = NO - -# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the -# feed. A documentation feed provides an umbrella under which multiple -# documentation sets from a single provider (such as a company or product suite) -# can be grouped. - -DOCSET_FEEDNAME = "Doxygen generated docs" - -# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that -# should uniquely identify the documentation set bundle. This should be a -# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen -# will append .docset to the name. - -DOCSET_BUNDLE_ID = org.doxygen.Project - -# If the GENERATE_HTMLHELP tag is set to YES, additional index files -# will be generated that can be used as input for tools like the -# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) -# of the generated HTML documentation. - -GENERATE_HTMLHELP = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can -# be used to specify the file name of the resulting .chm file. You -# can add a path in front of the file if the result should not be -# written to the html output directory. - -CHM_FILE = - -# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can -# be used to specify the location (absolute path including file name) of -# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run -# the HTML help compiler on the generated index.hhp. - -HHC_LOCATION = - -# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag -# controls if a separate .chi index file is generated (YES) or that -# it should be included in the master .chm file (NO). - -GENERATE_CHI = NO - -# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING -# is used to encode HtmlHelp index (hhk), content (hhc) and project file -# content. - -CHM_INDEX_ENCODING = - -# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag -# controls whether a binary table of contents is generated (YES) or a -# normal table of contents (NO) in the .chm file. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members -# to the contents of the HTML help documentation and to the tree view. - -TOC_EXPAND = NO - -# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and QHP_VIRTUAL_FOLDER -# are set, an additional index file will be generated that can be used as input for -# Qt's qhelpgenerator to generate a Qt Compressed Help (.qch) of the generated -# HTML documentation. - -GENERATE_QHP = NO - -# If the QHG_LOCATION tag is specified, the QCH_FILE tag can -# be used to specify the file name of the resulting .qch file. -# The path specified is relative to the HTML output folder. - -QCH_FILE = - -# The QHP_NAMESPACE tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#namespace - -QHP_NAMESPACE = - -# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating -# Qt Help Project output. For more information please see -# http://doc.trolltech.com/qthelpproject.html#virtual-folders - -QHP_VIRTUAL_FOLDER = doc - -# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to add. -# For more information please see -# http://doc.trolltech.com/qthelpproject.html#custom-filters - -QHP_CUST_FILTER_NAME = - -# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the custom filter to add.For more information please see -# Qt Help Project / Custom Filters. - -QHP_CUST_FILTER_ATTRS = - -# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this project's -# filter section matches. -# Qt Help Project / Filter Attributes. - -QHP_SECT_FILTER_ATTRS = - -# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can -# be used to specify the location of Qt's qhelpgenerator. -# If non-empty doxygen will try to run qhelpgenerator on the generated -# .qhp file. - -QHG_LOCATION = - -# The DISABLE_INDEX tag can be used to turn on/off the condensed index at -# top of each HTML page. The value NO (the default) enables the index and -# the value YES disables it. - -DISABLE_INDEX = NO - -# This tag can be used to set the number of enum values (range [1..20]) -# that doxygen will group on one line in the generated HTML documentation. - -ENUM_VALUES_PER_LINE = 4 - -# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index -# structure should be generated to display hierarchical information. -# If the tag value is set to YES, a side panel will be generated -# containing a tree-like index structure (just like the one that -# is generated for HTML Help). For this to work a browser that supports -# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser). -# Windows users are probably better off using the HTML help feature. - -GENERATE_TREEVIEW = YES - -# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories, -# and Class Hierarchy pages using a tree view instead of an ordered list. - -USE_INLINE_TREES = NO - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be -# used to set the initial width (in pixels) of the frame in which the tree -# is shown. - -TREEVIEW_WIDTH = 250 - -# Use this tag to change the font size of Latex formulas included -# as images in the HTML documentation. The default is 10. Note that -# when you change the font size after a successful doxygen run you need -# to manually remove any form_*.png images from the HTML output directory -# to force them to be regenerated. - -FORMULA_FONTSIZE = 10 - -# When the SEARCHENGINE tag is enable doxygen will generate a search box for the HTML output. The underlying search engine uses javascript -# and DHTML and should work on any modern browser. Note that when using HTML help (GENERATE_HTMLHELP) or Qt help (GENERATE_QHP) -# there is already a search function so this one should typically -# be disabled. - -SEARCHENGINE = NO - -#--------------------------------------------------------------------------- -# configuration options related to the LaTeX output -#--------------------------------------------------------------------------- - -# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will -# generate Latex output. - -GENERATE_LATEX = NO - -# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `latex' will be used as the default path. - -LATEX_OUTPUT = latex - -# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be -# invoked. If left blank `latex' will be used as the default command name. - -LATEX_CMD_NAME = latex - -# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to -# generate index for LaTeX. If left blank `makeindex' will be used as the -# default command name. - -MAKEINDEX_CMD_NAME = makeindex - -# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact -# LaTeX documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_LATEX = YES - -# The PAPER_TYPE tag can be used to set the paper type that is used -# by the printer. Possible values are: a4, a4wide, letter, legal and -# executive. If left blank a4wide will be used. - -PAPER_TYPE = a4wide - -# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX -# packages that should be included in the LaTeX output. - -EXTRA_PACKAGES = - -# The LATEX_HEADER tag can be used to specify a personal LaTeX header for -# the generated latex document. The header should contain everything until -# the first chapter. If it is left blank doxygen will generate a -# standard header. Notice: only use this tag if you know what you are doing! - -LATEX_HEADER = - -# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated -# is prepared for conversion to pdf (using ps2pdf). The pdf file will -# contain links (just like the HTML output) instead of page references -# This makes the output suitable for online browsing using a pdf viewer. - -PDF_HYPERLINKS = YES - -# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of -# plain latex in the generated Makefile. Set this option to YES to get a -# higher quality PDF documentation. - -USE_PDFLATEX = YES - -# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. -# command to the generated LaTeX files. This will instruct LaTeX to keep -# running if errors occur, instead of asking the user for help. -# This option is also used when generating formulas in HTML. - -LATEX_BATCHMODE = NO - -# If LATEX_HIDE_INDICES is set to YES then doxygen will not -# include the index chapters (such as File Index, Compound Index, etc.) -# in the output. - -LATEX_HIDE_INDICES = NO - -# If LATEX_SOURCE_CODE is set to YES then doxygen will include source code with syntax highlighting in the LaTeX output. Note that which sources are shown also depends on other settings such as SOURCE_BROWSER. - -LATEX_SOURCE_CODE = NO - -#--------------------------------------------------------------------------- -# configuration options related to the RTF output -#--------------------------------------------------------------------------- - -# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output -# The RTF output is optimized for Word 97 and may not look very pretty with -# other RTF readers or editors. - -GENERATE_RTF = NO - -# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `rtf' will be used as the default path. - -RTF_OUTPUT = rtf - -# If the COMPACT_RTF tag is set to YES Doxygen generates more compact -# RTF documents. This may be useful for small projects and may help to -# save some trees in general. - -COMPACT_RTF = NO - -# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated -# will contain hyperlink fields. The RTF file will -# contain links (just like the HTML output) instead of page references. -# This makes the output suitable for online browsing using WORD or other -# programs which support those fields. -# Note: wordpad (write) and others do not support links. - -RTF_HYPERLINKS = NO - -# Load stylesheet definitions from file. Syntax is similar to doxygen's -# config file, i.e. a series of assignments. You only have to provide -# replacements, missing definitions are set to their default value. - -RTF_STYLESHEET_FILE = - -# Set optional variables used in the generation of an rtf document. -# Syntax is similar to doxygen's config file. - -RTF_EXTENSIONS_FILE = - -#--------------------------------------------------------------------------- -# configuration options related to the man page output -#--------------------------------------------------------------------------- - -# If the GENERATE_MAN tag is set to YES (the default) Doxygen will -# generate man pages - -GENERATE_MAN = YES - -# The MAN_OUTPUT tag is used to specify where the man pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `man' will be used as the default path. - -MAN_OUTPUT = man - -# The MAN_EXTENSION tag determines the extension that is added to -# the generated man pages (default is the subroutine's section .3) - -MAN_EXTENSION = .3 - -# If the MAN_LINKS tag is set to YES and Doxygen generates man output, -# then it will generate one additional man file for each entity -# documented in the real man page(s). These additional files -# only source the real man page, but without them the man command -# would be unable to find the correct page. The default is NO. - -MAN_LINKS = NO - -#--------------------------------------------------------------------------- -# configuration options related to the XML output -#--------------------------------------------------------------------------- - -# If the GENERATE_XML tag is set to YES Doxygen will -# generate an XML file that captures the structure of -# the code including all documentation. - -GENERATE_XML = NO - -# The XML_OUTPUT tag is used to specify where the XML pages will be put. -# If a relative path is entered the value of OUTPUT_DIRECTORY will be -# put in front of it. If left blank `xml' will be used as the default path. - -XML_OUTPUT = xml - -# The XML_SCHEMA tag can be used to specify an XML schema, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_SCHEMA = - -# The XML_DTD tag can be used to specify an XML DTD, -# which can be used by a validating XML parser to check the -# syntax of the XML files. - -XML_DTD = - -# If the XML_PROGRAMLISTING tag is set to YES Doxygen will -# dump the program listings (including syntax highlighting -# and cross-referencing information) to the XML output. Note that -# enabling this will significantly increase the size of the XML output. - -XML_PROGRAMLISTING = YES - -#--------------------------------------------------------------------------- -# configuration options for the AutoGen Definitions output -#--------------------------------------------------------------------------- - -# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will -# generate an AutoGen Definitions (see autogen.sf.net) file -# that captures the structure of the code including all -# documentation. Note that this feature is still experimental -# and incomplete at the moment. - -GENERATE_AUTOGEN_DEF = NO - -#--------------------------------------------------------------------------- -# configuration options related to the Perl module output -#--------------------------------------------------------------------------- - -# If the GENERATE_PERLMOD tag is set to YES Doxygen will -# generate a Perl module file that captures the structure of -# the code including all documentation. Note that this -# feature is still experimental and incomplete at the -# moment. - -GENERATE_PERLMOD = NO - -# If the PERLMOD_LATEX tag is set to YES Doxygen will generate -# the necessary Makefile rules, Perl scripts and LaTeX code to be able -# to generate PDF and DVI output from the Perl module output. - -PERLMOD_LATEX = NO - -# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be -# nicely formatted so it can be parsed by a human reader. -# This is useful -# if you want to understand what is going on. -# On the other hand, if this -# tag is set to NO the size of the Perl module output will be much smaller -# and Perl will parse it just the same. - -PERLMOD_PRETTY = YES - -# The names of the make variables in the generated doxyrules.make file -# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. -# This is useful so different doxyrules.make files included by the same -# Makefile don't overwrite each other's variables. - -PERLMOD_MAKEVAR_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the preprocessor -#--------------------------------------------------------------------------- - -# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will -# evaluate all C-preprocessor directives found in the sources and include -# files. - -ENABLE_PREPROCESSING = YES - -# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro -# names in the source code. If set to NO (the default) only conditional -# compilation will be performed. Macro expansion can be done in a controlled -# way by setting EXPAND_ONLY_PREDEF to YES. - -MACRO_EXPANSION = NO - -# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES -# then the macro expansion is limited to the macros specified with the -# PREDEFINED and EXPAND_AS_DEFINED tags. - -EXPAND_ONLY_PREDEF = NO - -# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files -# in the INCLUDE_PATH (see below) will be search if a #include is found. - -SEARCH_INCLUDES = YES - -# The INCLUDE_PATH tag can be used to specify one or more directories that -# contain include files that are not input files but should be processed by -# the preprocessor. - -INCLUDE_PATH = - -# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard -# patterns (like *.h and *.hpp) to filter out the header-files in the -# directories. If left blank, the patterns specified with FILE_PATTERNS will -# be used. - -INCLUDE_FILE_PATTERNS = - -# The PREDEFINED tag can be used to specify one or more macro names that -# are defined before the preprocessor is started (similar to the -D option of -# gcc). The argument of the tag is a list of macros of the form: name -# or name=definition (no spaces). If the definition and the = are -# omitted =1 is assumed. To prevent a macro definition from being -# undefined via #undef or recursively expanded use the := operator -# instead of the = operator. - -PREDEFINED = - -# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then -# this tag can be used to specify a list of macro names that should be expanded. -# The macro definition that is found in the sources will be used. -# Use the PREDEFINED tag if you want to use a different macro definition. - -EXPAND_AS_DEFINED = - -# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then -# doxygen's preprocessor will remove all function-like macros that are alone -# on a line, have an all uppercase name, and do not end with a semicolon. Such -# function macros are typically used for boiler-plate code, and will confuse -# the parser if not removed. - -SKIP_FUNCTION_MACROS = YES - -#--------------------------------------------------------------------------- -# Configuration::additions related to external references -#--------------------------------------------------------------------------- - -# The TAGFILES option can be used to specify one or more tagfiles. -# Optionally an initial location of the external documentation -# can be added for each tagfile. The format of a tag file without -# this location is as follows: -# -# TAGFILES = file1 file2 ... -# Adding location for the tag files is done as follows: -# -# TAGFILES = file1=loc1 "file2 = loc2" ... -# where "loc1" and "loc2" can be relative or absolute paths or -# URLs. If a location is present for each tag, the installdox tool -# does not have to be run to correct the links. -# Note that each tag file must have a unique name -# (where the name does NOT include the path) -# If a tag file is not located in the directory in which doxygen -# is run, you must also specify the path to the tagfile here. - -TAGFILES = - -# When a file name is specified after GENERATE_TAGFILE, doxygen will create -# a tag file that is based on the input files it reads. - -GENERATE_TAGFILE = - -# If the ALLEXTERNALS tag is set to YES all external classes will be listed -# in the class index. If set to NO only the inherited external classes -# will be listed. - -ALLEXTERNALS = NO - -# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed -# in the modules index. If set to NO, only the current project's groups will -# be listed. - -EXTERNAL_GROUPS = YES - -# The PERL_PATH should be the absolute path and name of the perl script -# interpreter (i.e. the result of `which perl'). - -PERL_PATH = /usr/bin/perl - -#--------------------------------------------------------------------------- -# Configuration options related to the dot tool -#--------------------------------------------------------------------------- - -# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will -# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base -# or super classes. Setting the tag to NO turns the diagrams off. Note that -# this option is superseded by the HAVE_DOT option below. This is only a -# fallback. It is recommended to install and use dot, since it yields more -# powerful graphs. - -CLASS_DIAGRAMS = NO - -# You can define message sequence charts within doxygen comments using the \msc -# command. Doxygen will then run the mscgen tool (see -# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the -# documentation. The MSCGEN_PATH tag allows you to specify the directory where -# the mscgen tool resides. If left empty the tool is assumed to be found in the -# default search path. - -MSCGEN_PATH = - -# If set to YES, the inheritance and collaboration graphs will hide -# inheritance and usage relations if the target is undocumented -# or is not a class. - -HIDE_UNDOC_RELATIONS = YES - -# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is -# available from the path. This tool is part of Graphviz, a graph visualization -# toolkit from AT&T and Lucent Bell Labs. The other options in this section -# have no effect if this option is set to NO (the default) - -HAVE_DOT = YES - -# By default doxygen will write a font called FreeSans.ttf to the output -# directory and reference it in all dot files that doxygen generates. This -# font does not include all possible unicode characters however, so when you need -# these (or just want a differently looking font) you can specify the font name -# using DOT_FONTNAME. You need to make sure dot is able to find the font, -# which can be done by putting it in a standard location or by setting the -# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory -# containing the font. - -DOT_FONTNAME = FreeSans - -# The DOT_FONTSIZE tag can be used to set the size of the font of dot graphs. -# The default size is 10pt. - -DOT_FONTSIZE = 10 - -# By default doxygen will tell dot to use the output directory to look for the -# FreeSans.ttf font (which doxygen will put there itself). If you specify a -# different font using DOT_FONTNAME you can set the path where dot -# can find it using this tag. - -DOT_FONTPATH = - -# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect inheritance relations. Setting this tag to YES will force the -# the CLASS_DIAGRAMS tag to NO. - -CLASS_GRAPH = YES - -# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for each documented class showing the direct and -# indirect implementation dependencies (inheritance, containment, and -# class references variables) of the class with other documented classes. - -COLLABORATION_GRAPH = YES - -# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen -# will generate a graph for groups, showing the direct groups dependencies - -GROUP_GRAPHS = NO - -# If the UML_LOOK tag is set to YES doxygen will generate inheritance and -# collaboration diagrams in a style similar to the OMG's Unified Modeling -# Language. - -UML_LOOK = YES - -# If set to YES, the inheritance and collaboration graphs will show the -# relations between templates and their instances. - -TEMPLATE_RELATIONS = YES - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT -# tags are set to YES then doxygen will generate a graph for each documented -# file showing the direct and indirect include dependencies of the file with -# other documented files. - -INCLUDE_GRAPH = NO - -# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and -# HAVE_DOT tags are set to YES then doxygen will generate a graph for each -# documented header file showing the documented files that directly or -# indirectly include this file. - -INCLUDED_BY_GRAPH = NO - -# If the CALL_GRAPH and HAVE_DOT options are set to YES then -# doxygen will generate a call dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable call graphs -# for selected functions only using the \callgraph command. - -CALL_GRAPH = NO - -# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then -# doxygen will generate a caller dependency graph for every global function -# or class method. Note that enabling this option will significantly increase -# the time of a run. So in most cases it will be better to enable caller -# graphs for selected functions only using the \callergraph command. - -CALLER_GRAPH = NO - -# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen -# will graphical hierarchy of all classes instead of a textual one. - -GRAPHICAL_HIERARCHY = NO - -# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES -# then doxygen will show the dependencies a directory has on other directories -# in a graphical way. The dependency relations are determined by the #include -# relations between the files in the directories. - -DIRECTORY_GRAPH = NO - -# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images -# generated by dot. Possible values are png, jpg, or gif -# If left blank png will be used. - -DOT_IMAGE_FORMAT = png - -# The tag DOT_PATH can be used to specify the path where the dot tool can be -# found. If left blank, it is assumed the dot tool can be found in the path. - -DOT_PATH = - -# The DOTFILE_DIRS tag can be used to specify one or more directories that -# contain dot files that are included in the documentation (see the -# \dotfile command). - -DOTFILE_DIRS = - -# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of -# nodes that will be shown in the graph. If the number of nodes in a graph -# becomes larger than this value, doxygen will truncate the graph, which is -# visualized by representing a node as a red box. Note that doxygen if the -# number of direct children of the root node in a graph is already larger than -# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note -# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. - -DOT_GRAPH_MAX_NODES = 50 - -# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the -# graphs generated by dot. A depth value of 3 means that only nodes reachable -# from the root by following a path via at most 3 edges will be shown. Nodes -# that lay further from the root node will be omitted. Note that setting this -# option to 1 or 2 may greatly reduce the computation time needed for large -# code bases. Also note that the size of a graph can be further restricted by -# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. - -MAX_DOT_GRAPH_DEPTH = 0 - -# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent -# background. This is disabled by default, because dot on Windows does not -# seem to support this out of the box. Warning: Depending on the platform used, -# enabling this option may lead to badly anti-aliased labels on the edges of -# a graph (i.e. they become hard to read). - -DOT_TRANSPARENT = YES - -# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output -# files in one run (i.e. multiple -o and -T options on the command line). This -# makes dot run faster, but since only newer versions of dot (>1.8.10) -# support this, this feature is disabled by default. - -DOT_MULTI_TARGETS = YES - -# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will -# generate a legend page explaining the meaning of the various boxes and -# arrows in the dot generated graphs. - -GENERATE_LEGEND = YES - -# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will -# remove the intermediate dot files that are used to generate -# the various graphs. - -DOT_CLEANUP = YES diff --git a/lib/libcgroup-3.1.0/libcgroup.pc.in b/lib/libcgroup-3.1.0/libcgroup.pc.in deleted file mode 100644 index bd925e52e96..00000000000 --- a/lib/libcgroup-3.1.0/libcgroup.pc.in +++ /dev/null @@ -1,10 +0,0 @@ -prefix=@prefix@ -exec_prefix=@exec_prefix@ -libdir=@libdir@ -includedir=@includedir@ - -Name: libcgroup -Description: Control Group Configuration Library -Version: @PACKAGE_VERSION@ -Libs: -L${libdir} -lcgroup -Cflags: -I${includedir} diff --git a/lib/libcgroup-3.1.0/m4/ax_code_coverage.m4 b/lib/libcgroup-3.1.0/m4/ax_code_coverage.m4 deleted file mode 100644 index a257469f7fb..00000000000 --- a/lib/libcgroup-3.1.0/m4/ax_code_coverage.m4 +++ /dev/null @@ -1,264 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_code_coverage.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CODE_COVERAGE() -# -# DESCRIPTION -# -# Defines CODE_COVERAGE_CPPFLAGS, CODE_COVERAGE_CFLAGS, -# CODE_COVERAGE_CXXFLAGS and CODE_COVERAGE_LIBS which should be included -# in the CPPFLAGS, CFLAGS CXXFLAGS and LIBS/LIBADD variables of every -# build target (program or library) which should be built with code -# coverage support. Also defines CODE_COVERAGE_RULES which should be -# substituted in your Makefile; and $enable_code_coverage which can be -# used in subsequent configure output. CODE_COVERAGE_ENABLED is defined -# and substituted, and corresponds to the value of the -# --enable-code-coverage option, which defaults to being disabled. -# -# Test also for gcov program and create GCOV variable that could be -# substituted. -# -# Note that all optimisation flags in CFLAGS must be disabled when code -# coverage is enabled. -# -# Usage example: -# -# configure.ac: -# -# AX_CODE_COVERAGE -# -# Makefile.am: -# -# @CODE_COVERAGE_RULES@ -# my_program_LIBS = ... $(CODE_COVERAGE_LIBS) ... -# my_program_CPPFLAGS = ... $(CODE_COVERAGE_CPPFLAGS) ... -# my_program_CFLAGS = ... $(CODE_COVERAGE_CFLAGS) ... -# my_program_CXXFLAGS = ... $(CODE_COVERAGE_CXXFLAGS) ... -# -# This results in a "check-code-coverage" rule being added to any -# Makefile.am which includes "@CODE_COVERAGE_RULES@" (assuming the module -# has been configured with --enable-code-coverage). Running `make -# check-code-coverage` in that directory will run the module's test suite -# (`make check`) and build a code coverage report detailing the code which -# was touched, then print the URI for the report. -# -# In earlier versions of this macro, CODE_COVERAGE_LDFLAGS was defined -# instead of CODE_COVERAGE_LIBS. They are both still defined, but use of -# CODE_COVERAGE_LIBS is preferred for clarity; CODE_COVERAGE_LDFLAGS is -# deprecated. They have the same value. -# -# This code was derived from Makefile.decl in GLib, originally licenced -# under LGPLv2.1+. -# -# LICENSE -# -# Copyright (c) 2012, 2016 Philip Withnall -# Copyright (c) 2012 Xan Lopez -# Copyright (c) 2012 Christian Persch -# Copyright (c) 2012 Paolo Borelli -# Copyright (c) 2012 Dan Winship -# Copyright (c) 2015 Bastien ROUCARIES -# -# This library is free software; you can redistribute it and/or modify it -# under the terms of the GNU Lesser General Public License as published by -# the Free Software Foundation; either version 2.1 of the License, or (at -# your option) any later version. -# -# This library 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 Lesser -# General Public License for more details. -# -# You should have received a copy of the GNU Lesser General Public License -# along with this program. If not, see . - -#serial 20 - -AC_DEFUN([AX_CODE_COVERAGE],[ - dnl Check for --enable-code-coverage - AC_REQUIRE([AC_PROG_SED]) - - # allow to override gcov location - AC_ARG_WITH([gcov], - [AS_HELP_STRING([--with-gcov[=GCOV]], [use given GCOV for coverage (GCOV=gcov).])], - [_AX_CODE_COVERAGE_GCOV_PROG_WITH=$with_gcov], - [_AX_CODE_COVERAGE_GCOV_PROG_WITH=gcov]) - - AC_MSG_CHECKING([whether to build with code coverage support]) - AC_ARG_ENABLE([code-coverage], - AS_HELP_STRING([--enable-code-coverage], - [Whether to enable code coverage support]),, - enable_code_coverage=no) - - AM_CONDITIONAL([CODE_COVERAGE_ENABLED], [test x$enable_code_coverage = xyes]) - AC_SUBST([CODE_COVERAGE_ENABLED], [$enable_code_coverage]) - AC_MSG_RESULT($enable_code_coverage) - - AS_IF([ test "$enable_code_coverage" = "yes" ], [ - # check for gcov - AC_CHECK_TOOL([GCOV], - [$_AX_CODE_COVERAGE_GCOV_PROG_WITH], - [:]) - AS_IF([test "X$GCOV" = "X:"], - [AC_MSG_ERROR([gcov is needed to do coverage])]) - AC_SUBST([GCOV]) - - dnl Check if gcc is being used - AS_IF([ test "$GCC" = "no" ], [ - AC_MSG_ERROR([not compiling with gcc, which is required for gcov code coverage]) - ]) - - AC_CHECK_PROG([LCOV], [lcov], [lcov]) - AC_CHECK_PROG([GENHTML], [genhtml], [genhtml]) - - AS_IF([ test -z "$LCOV" ], [ - AC_MSG_ERROR([To enable code coverage reporting you must have lcov installed]) - ]) - - AS_IF([ test -z "$GENHTML" ], [ - AC_MSG_ERROR([Could not find genhtml from the lcov package]) - ]) - - dnl Build the code coverage flags - dnl Define CODE_COVERAGE_LDFLAGS for backwards compatibility - CODE_COVERAGE_CPPFLAGS="-DNDEBUG" - CODE_COVERAGE_CFLAGS="-O0 -g -fprofile-arcs -ftest-coverage" - CODE_COVERAGE_CXXFLAGS="-O0 -g -fprofile-arcs -ftest-coverage" - CODE_COVERAGE_LIBS="-lgcov" - CODE_COVERAGE_LDFLAGS="$CODE_COVERAGE_LIBS" - - AC_SUBST([CODE_COVERAGE_CPPFLAGS]) - AC_SUBST([CODE_COVERAGE_CFLAGS]) - AC_SUBST([CODE_COVERAGE_CXXFLAGS]) - AC_SUBST([CODE_COVERAGE_LIBS]) - AC_SUBST([CODE_COVERAGE_LDFLAGS]) - - [CODE_COVERAGE_RULES_CHECK=' - -$(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) -k check - $(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) code-coverage-capture -'] - [CODE_COVERAGE_RULES_CAPTURE=' - $(code_coverage_v_lcov_cap)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --capture --output-file "$(CODE_COVERAGE_OUTPUT_FILE).tmp" --test-name "$(call code_coverage_sanitize,$(PACKAGE_NAME)-$(PACKAGE_VERSION))" --no-checksum --compat-libtool $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_OPTIONS) - $(code_coverage_v_lcov_ign)$(LCOV) $(code_coverage_quiet) $(addprefix --directory ,$(CODE_COVERAGE_DIRECTORY)) --remove "$(CODE_COVERAGE_OUTPUT_FILE).tmp" "/tmp/*" $(CODE_COVERAGE_IGNORE_PATTERN) --output-file "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_LCOV_SHOPTS) $(CODE_COVERAGE_LCOV_RMOPTS) - -@rm -f $(CODE_COVERAGE_OUTPUT_FILE).tmp - $(code_coverage_v_genhtml)LANG=C $(GENHTML) $(code_coverage_quiet) $(addprefix --prefix ,$(CODE_COVERAGE_DIRECTORY)) --output-directory "$(CODE_COVERAGE_OUTPUT_DIRECTORY)" --title "$(PACKAGE_NAME)-$(PACKAGE_VERSION) Code Coverage" --legend --show-details "$(CODE_COVERAGE_OUTPUT_FILE)" $(CODE_COVERAGE_GENHTML_OPTIONS) - @echo "file://$(abs_builddir)/$(CODE_COVERAGE_OUTPUT_DIRECTORY)/index.html" -'] - [CODE_COVERAGE_RULES_CLEAN=' -clean: code-coverage-clean -distclean: code-coverage-clean -code-coverage-clean: - -$(LCOV) --directory $(top_builddir) -z - -rm -rf $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_FILE).tmp $(CODE_COVERAGE_OUTPUT_DIRECTORY) - -find . \( -name "*.gcda" -o -name "*.gcno" -o -name "*.gcov" \) -delete -'] - ], [ - [CODE_COVERAGE_RULES_CHECK=' - @echo "Need to reconfigure with --enable-code-coverage" -'] - CODE_COVERAGE_RULES_CAPTURE="$CODE_COVERAGE_RULES_CHECK" - CODE_COVERAGE_RULES_CLEAN='' - ]) - -[CODE_COVERAGE_RULES=' -# Code coverage -# -# Optional: -# - CODE_COVERAGE_DIRECTORY: Top-level directory for code coverage reporting. -# Multiple directories may be specified, separated by whitespace. -# (Default: $(top_builddir)) -# - CODE_COVERAGE_OUTPUT_FILE: Filename and path for the .info file generated -# by lcov for code coverage. (Default: -# $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info) -# - CODE_COVERAGE_OUTPUT_DIRECTORY: Directory for generated code coverage -# reports to be created. (Default: -# $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage) -# - CODE_COVERAGE_BRANCH_COVERAGE: Set to 1 to enforce branch coverage, -# set to 0 to disable it and leave empty to stay with the default. -# (Default: empty) -# - CODE_COVERAGE_LCOV_SHOPTS_DEFAULT: Extra options shared between both lcov -# instances. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE) -# - CODE_COVERAGE_LCOV_SHOPTS: Extra options to shared between both lcov -# instances. (Default: $CODE_COVERAGE_LCOV_SHOPTS_DEFAULT) -# - CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH: --gcov-tool pathtogcov -# - CODE_COVERAGE_LCOV_OPTIONS_DEFAULT: Extra options to pass to the -# collecting lcov instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH) -# - CODE_COVERAGE_LCOV_OPTIONS: Extra options to pass to the collecting lcov -# instance. (Default: $CODE_COVERAGE_LCOV_OPTIONS_DEFAULT) -# - CODE_COVERAGE_LCOV_RMOPTS_DEFAULT: Extra options to pass to the filtering -# lcov instance. (Default: empty) -# - CODE_COVERAGE_LCOV_RMOPTS: Extra options to pass to the filtering lcov -# instance. (Default: $CODE_COVERAGE_LCOV_RMOPTS_DEFAULT) -# - CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT: Extra options to pass to the -# genhtml instance. (Default: based on $CODE_COVERAGE_BRANCH_COVERAGE) -# - CODE_COVERAGE_GENHTML_OPTIONS: Extra options to pass to the genhtml -# instance. (Default: $CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT) -# - CODE_COVERAGE_IGNORE_PATTERN: Extra glob pattern of files to ignore -# -# The generated report will be titled using the $(PACKAGE_NAME) and -# $(PACKAGE_VERSION). In order to add the current git hash to the title, -# use the git-version-gen script, available online. - -# Optional variables -CODE_COVERAGE_DIRECTORY ?= $(top_builddir) -CODE_COVERAGE_OUTPUT_FILE ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage.info -CODE_COVERAGE_OUTPUT_DIRECTORY ?= $(PACKAGE_NAME)-$(PACKAGE_VERSION)-coverage -CODE_COVERAGE_BRANCH_COVERAGE ?= -CODE_COVERAGE_LCOV_SHOPTS_DEFAULT ?= $(if $(CODE_COVERAGE_BRANCH_COVERAGE),\ ---rc lcov_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE)) -CODE_COVERAGE_LCOV_SHOPTS ?= $(CODE_COVERAGE_LCOV_SHOPTS_DEFAULT) -CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH ?= --gcov-tool "$(GCOV)" -CODE_COVERAGE_LCOV_OPTIONS_DEFAULT ?= $(CODE_COVERAGE_LCOV_OPTIONS_GCOVPATH) -CODE_COVERAGE_LCOV_OPTIONS ?= $(CODE_COVERAGE_LCOV_OPTIONS_DEFAULT) -CODE_COVERAGE_LCOV_RMOPTS_DEFAULT ?= -CODE_COVERAGE_LCOV_RMOPTS ?= $(CODE_COVERAGE_LCOV_RMOPTS_DEFAULT) -CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT ?=\ -$(if $(CODE_COVERAGE_BRANCH_COVERAGE),\ ---rc genhtml_branch_coverage=$(CODE_COVERAGE_BRANCH_COVERAGE)) -CODE_COVERAGE_GENHTML_OPTIONS ?= $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULTS) -CODE_COVERAGE_IGNORE_PATTERN ?= - -code_coverage_v_lcov_cap = $(code_coverage_v_lcov_cap_$(V)) -code_coverage_v_lcov_cap_ = $(code_coverage_v_lcov_cap_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_lcov_cap_0 = @echo " LCOV --capture"\ - $(CODE_COVERAGE_OUTPUT_FILE); -code_coverage_v_lcov_ign = $(code_coverage_v_lcov_ign_$(V)) -code_coverage_v_lcov_ign_ = $(code_coverage_v_lcov_ign_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_lcov_ign_0 = @echo " LCOV --remove /tmp/*"\ - $(CODE_COVERAGE_IGNORE_PATTERN); -code_coverage_v_genhtml = $(code_coverage_v_genhtml_$(V)) -code_coverage_v_genhtml_ = $(code_coverage_v_genhtml_$(AM_DEFAULT_VERBOSITY)) -code_coverage_v_genhtml_0 = @echo " GEN " $(CODE_COVERAGE_OUTPUT_DIRECTORY); -code_coverage_quiet = $(code_coverage_quiet_$(V)) -code_coverage_quiet_ = $(code_coverage_quiet_$(AM_DEFAULT_VERBOSITY)) -code_coverage_quiet_0 = --quiet - -# sanitizes the test-name: replaces with underscores: dashes and dots -code_coverage_sanitize = $(subst -,_,$(subst .,_,$(1))) - -# Use recursive makes in order to ignore errors during check -check-code-coverage:'"$CODE_COVERAGE_RULES_CHECK"' - -# Capture code coverage data -code-coverage-capture: code-coverage-capture-hook'"$CODE_COVERAGE_RULES_CAPTURE"' - -# Hook rule executed before code-coverage-capture, overridable by the user -code-coverage-capture-hook: - -'"$CODE_COVERAGE_RULES_CLEAN"' - -GITIGNOREFILES ?= -GITIGNOREFILES += $(CODE_COVERAGE_OUTPUT_FILE) $(CODE_COVERAGE_OUTPUT_DIRECTORY) - -A''M_DISTCHECK_CONFIGURE_FLAGS ?= -A''M_DISTCHECK_CONFIGURE_FLAGS += --disable-code-coverage - -.PHONY: check-code-coverage code-coverage-capture code-coverage-capture-hook code-coverage-clean -'] - - AC_SUBST([CODE_COVERAGE_RULES]) - m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([CODE_COVERAGE_RULES])]) -]) diff --git a/lib/libcgroup-3.1.0/m4/libtool.m4 b/lib/libcgroup-3.1.0/m4/libtool.m4 deleted file mode 100644 index e3adedad630..00000000000 --- a/lib/libcgroup-3.1.0/m4/libtool.m4 +++ /dev/null @@ -1,8403 +0,0 @@ -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- -# -# Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -m4_define([_LT_COPYING], [dnl -# Copyright (C) 2014 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool 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 of the License, or -# (at your option) any later version. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program or library that is built -# using GNU Libtool, you may include this file under the same -# distribution terms that you use for the rest of that program. -# -# GNU Libtool 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, see . -]) - -# serial 59 LT_INIT - - -# LT_PREREQ(VERSION) -# ------------------ -# Complain and exit if this libtool version is less that VERSION. -m4_defun([LT_PREREQ], -[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, - [m4_default([$3], - [m4_fatal([Libtool version $1 or higher is required], - 63)])], - [$2])]) - - -# _LT_CHECK_BUILDDIR -# ------------------ -# Complain if the absolute build directory name contains unusual characters -m4_defun([_LT_CHECK_BUILDDIR], -[case `pwd` in - *\ * | *\ *) - AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; -esac -]) - - -# LT_INIT([OPTIONS]) -# ------------------ -AC_DEFUN([LT_INIT], -[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK -AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl -AC_BEFORE([$0], [LT_LANG])dnl -AC_BEFORE([$0], [LT_OUTPUT])dnl -AC_BEFORE([$0], [LTDL_INIT])dnl -m4_require([_LT_CHECK_BUILDDIR])dnl - -dnl Autoconf doesn't catch unexpanded LT_ macros by default: -m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl -m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl -dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 -dnl unless we require an AC_DEFUNed macro: -AC_REQUIRE([LTOPTIONS_VERSION])dnl -AC_REQUIRE([LTSUGAR_VERSION])dnl -AC_REQUIRE([LTVERSION_VERSION])dnl -AC_REQUIRE([LTOBSOLETE_VERSION])dnl -m4_require([_LT_PROG_LTMAIN])dnl - -_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) - -dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS=$ltmain - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -_LT_SETUP - -# Only expand once: -m4_define([LT_INIT]) -])# LT_INIT - -# Old names: -AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) -AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PROG_LIBTOOL], []) -dnl AC_DEFUN([AM_PROG_LIBTOOL], []) - - -# _LT_PREPARE_CC_BASENAME -# ----------------------- -m4_defun([_LT_PREPARE_CC_BASENAME], [ -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -func_cc_basename () -{ - for cc_temp in @S|@*""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac - done - func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` -} -])# _LT_PREPARE_CC_BASENAME - - -# _LT_CC_BASENAME(CC) -# ------------------- -# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, -# but that macro is also expanded into generated libtool script, which -# arranges for $SED and $ECHO to be set by different means. -m4_defun([_LT_CC_BASENAME], -[m4_require([_LT_PREPARE_CC_BASENAME])dnl -AC_REQUIRE([_LT_DECL_SED])dnl -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl -func_cc_basename $1 -cc_basename=$func_cc_basename_result -]) - - -# _LT_FILEUTILS_DEFAULTS -# ---------------------- -# It is okay to use these file commands and assume they have been set -# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. -m4_defun([_LT_FILEUTILS_DEFAULTS], -[: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} -])# _LT_FILEUTILS_DEFAULTS - - -# _LT_SETUP -# --------- -m4_defun([_LT_SETUP], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl - -_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl -dnl -_LT_DECL([], [host_alias], [0], [The host system])dnl -_LT_DECL([], [host], [0])dnl -_LT_DECL([], [host_os], [0])dnl -dnl -_LT_DECL([], [build_alias], [0], [The build system])dnl -_LT_DECL([], [build], [0])dnl -_LT_DECL([], [build_os], [0])dnl -dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -dnl -AC_REQUIRE([AC_PROG_LN_S])dnl -test -z "$LN_S" && LN_S="ln -s" -_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl -dnl -AC_REQUIRE([LT_CMD_MAX_LEN])dnl -_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl -_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl -dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl -m4_require([_LT_CMD_RELOAD])dnl -m4_require([_LT_DECL_FILECMD])dnl -m4_require([_LT_CHECK_MAGIC_METHOD])dnl -m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl -m4_require([_LT_CMD_OLD_ARCHIVE])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_WITH_SYSROOT])dnl -m4_require([_LT_CMD_TRUNCATE])dnl - -_LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options that allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST -fi -]) -if test -n "${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST -fi - -_LT_CHECK_OBJDIR - -m4_require([_LT_TAG_COMPILER])dnl - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test set != "${COLLECT_NAMES+set}"; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a '.a' archive for static linking (except MSVC and -# ICC, which need '.lib'). -libext=a - -with_gnu_ld=$lt_cv_prog_gnu_ld - -old_CC=$CC -old_CFLAGS=$CFLAGS - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - _LT_PATH_MAGIC - fi - ;; -esac - -# Use C for the default configuration in the libtool script -LT_SUPPORTED_TAG([CC]) -_LT_LANG_C_CONFIG -_LT_LANG_DEFAULT_CONFIG -_LT_CONFIG_COMMANDS -])# _LT_SETUP - - -# _LT_PREPARE_SED_QUOTE_VARS -# -------------------------- -# Define a few sed substitution that help us do robust quoting. -m4_defun([_LT_PREPARE_SED_QUOTE_VARS], -[# Backslashify metacharacters that are still active within -# double-quoted strings. -sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([["`\\]]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' -]) - -# _LT_PROG_LTMAIN -# --------------- -# Note that this code is called both from 'configure', and 'config.status' -# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# 'config.status' has no value for ac_aux_dir unless we are using Automake, -# so we pass a copy along to make sure it has a sensible value anyway. -m4_defun([_LT_PROG_LTMAIN], -[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl -_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain=$ac_aux_dir/ltmain.sh -])# _LT_PROG_LTMAIN - - -## ------------------------------------- ## -## Accumulate code for creating libtool. ## -## ------------------------------------- ## - -# So that we can recreate a full libtool script including additional -# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the 'libtool' -# label. - - -# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) -# ---------------------------------------- -# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL_INIT], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_INIT], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_INIT]) - - -# _LT_CONFIG_LIBTOOL([COMMANDS]) -# ------------------------------ -# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) - - -# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) -# ----------------------------------------------------- -m4_defun([_LT_CONFIG_SAVE_COMMANDS], -[_LT_CONFIG_LIBTOOL([$1]) -_LT_CONFIG_LIBTOOL_INIT([$2]) -]) - - -# _LT_FORMAT_COMMENT([COMMENT]) -# ----------------------------- -# Add leading comment marks to the start of each line, and a trailing -# full-stop to the whole comment if one is not present already. -m4_define([_LT_FORMAT_COMMENT], -[m4_ifval([$1], [ -m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], - [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) -)]) - - - -## ------------------------ ## -## FIXME: Eliminate VARNAME ## -## ------------------------ ## - - -# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) -# ------------------------------------------------------------------- -# CONFIGNAME is the name given to the value in the libtool script. -# VARNAME is the (base) name used in the configure script. -# VALUE may be 0, 1 or 2 for a computed quote escaped value based on -# VARNAME. Any other value will be used directly. -m4_define([_LT_DECL], -[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], - [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], - [m4_ifval([$1], [$1], [$2])]) - lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) - m4_ifval([$4], - [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) - lt_dict_add_subkey([lt_decl_dict], [$2], - [tagged?], [m4_ifval([$5], [yes], [no])])]) -]) - - -# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) -# -------------------------------------------------------- -m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) - - -# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_tag_varnames], -[_lt_decl_filter([tagged?], [yes], $@)]) - - -# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) -# --------------------------------------------------------- -m4_define([_lt_decl_filter], -[m4_case([$#], - [0], [m4_fatal([$0: too few arguments: $#])], - [1], [m4_fatal([$0: too few arguments: $#: $1])], - [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], - [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], - [lt_dict_filter([lt_decl_dict], $@)])[]dnl -]) - - -# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) -# -------------------------------------------------- -m4_define([lt_decl_quote_varnames], -[_lt_decl_filter([value], [1], $@)]) - - -# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_dquote_varnames], -[_lt_decl_filter([value], [2], $@)]) - - -# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_varnames_tagged], -[m4_assert([$# <= 2])dnl -_$0(m4_quote(m4_default([$1], [[, ]])), - m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), - m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) -m4_define([_lt_decl_varnames_tagged], -[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) - - -# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_all_varnames], -[_$0(m4_quote(m4_default([$1], [[, ]])), - m4_if([$2], [], - m4_quote(lt_decl_varnames), - m4_quote(m4_shift($@))))[]dnl -]) -m4_define([_lt_decl_all_varnames], -[lt_join($@, lt_decl_varnames_tagged([$1], - lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl -]) - - -# _LT_CONFIG_STATUS_DECLARE([VARNAME]) -# ------------------------------------ -# Quote a variable value, and forward it to 'config.status' so that its -# declaration there will have the same value as in 'configure'. VARNAME -# must have a single quote delimited value for this to work. -m4_define([_LT_CONFIG_STATUS_DECLARE], -[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) - - -# _LT_CONFIG_STATUS_DECLARATIONS -# ------------------------------ -# We delimit libtool config variables with single quotes, so when -# we write them to config.status, we have to be sure to quote all -# embedded single quotes properly. In configure, this macro expands -# each variable declared with _LT_DECL (and _LT_TAGDECL) into: -# -# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`' -m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], -[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), - [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAGS -# ---------------- -# Output comment and list of tags supported by the script -m4_defun([_LT_LIBTOOL_TAGS], -[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags='_LT_TAGS'dnl -]) - - -# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) -# ----------------------------------- -# Extract the dictionary values for VARNAME (optionally with TAG) and -# expand to a commented shell variable setting: -# -# # Some comment about what VAR is for. -# visible_name=$lt_internal_name -m4_define([_LT_LIBTOOL_DECLARE], -[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], - [description])))[]dnl -m4_pushdef([_libtool_name], - m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl -m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), - [0], [_libtool_name=[$]$1], - [1], [_libtool_name=$lt_[]$1], - [2], [_libtool_name=$lt_[]$1], - [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl -m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl -]) - - -# _LT_LIBTOOL_CONFIG_VARS -# ----------------------- -# Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' -# script. Tagged libtool config variables (even for the LIBTOOL CONFIG -# section) are produced by _LT_LIBTOOL_TAG_VARS. -m4_defun([_LT_LIBTOOL_CONFIG_VARS], -[m4_foreach([_lt_var], - m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAG_VARS(TAG) -# ------------------------- -m4_define([_LT_LIBTOOL_TAG_VARS], -[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) - - -# _LT_TAGVAR(VARNAME, [TAGNAME]) -# ------------------------------ -m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) - - -# _LT_CONFIG_COMMANDS -# ------------------- -# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of -# variables for single and double quote escaping we saved from calls -# to _LT_DECL, we can put quote escaped variables declarations -# into 'config.status', and then the shell code to quote escape them in -# for loops in 'config.status'. Finally, any additional code accumulated -# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. -m4_defun([_LT_CONFIG_COMMANDS], -[AC_PROVIDE_IFELSE([LT_OUTPUT], - dnl If the libtool generation code has been placed in $CONFIG_LT, - dnl instead of duplicating it all over again into config.status, - dnl then we will have config.status run $CONFIG_LT later, so it - dnl needs to know what name is stored there: - [AC_CONFIG_COMMANDS([libtool], - [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], - dnl If the libtool generation code is destined for config.status, - dnl expand the accumulated commands and init code now: - [AC_CONFIG_COMMANDS([libtool], - [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) -])#_LT_CONFIG_COMMANDS - - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], -[ - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -_LT_CONFIG_STATUS_DECLARATIONS -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# A function that is used when there is no print builtin or printf. -func_fallback_echo () -{ - eval 'cat <<_LTECHO_EOF -\$[]1 -_LTECHO_EOF' -} - -# Quote evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_quote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_dquote_varnames); do - case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -_LT_OUTPUT_LIBTOOL_INIT -]) - -# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) -# ------------------------------------ -# Generate a child script FILE with all initialization necessary to -# reuse the environment learned by the parent script, and make the -# file executable. If COMMENT is supplied, it is inserted after the -# '#!' sequence but before initialization text begins. After this -# macro, additional text can be appended to FILE to form the body of -# the child script. The macro ends with non-zero status if the -# file could not be fully written (such as if the disk is full). -m4_ifdef([AS_INIT_GENERATED], -[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], -[m4_defun([_LT_GENERATED_FILE_INIT], -[m4_require([AS_PREPARE])]dnl -[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl -[lt_write_fail=0 -cat >$1 <<_ASEOF || lt_write_fail=1 -#! $SHELL -# Generated by $as_me. -$2 -SHELL=\${CONFIG_SHELL-$SHELL} -export SHELL -_ASEOF -cat >>$1 <<\_ASEOF || lt_write_fail=1 -AS_SHELL_SANITIZE -_AS_PREPARE -exec AS_MESSAGE_FD>&1 -_ASEOF -test 0 = "$lt_write_fail" && chmod +x $1[]dnl -m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT - -# LT_OUTPUT -# --------- -# This macro allows early generation of the libtool script (before -# AC_OUTPUT is called), incase it is used in configure for compilation -# tests. -AC_DEFUN([LT_OUTPUT], -[: ${CONFIG_LT=./config.lt} -AC_MSG_NOTICE([creating $CONFIG_LT]) -_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], -[# Run this file to recreate a libtool stub with the current configuration.]) - -cat >>"$CONFIG_LT" <<\_LTEOF -lt_cl_silent=false -exec AS_MESSAGE_LOG_FD>>config.log -{ - echo - AS_BOX([Running $as_me.]) -} >&AS_MESSAGE_LOG_FD - -lt_cl_help="\ -'$as_me' creates a local libtool stub from the current configuration, -for use in further configure time tests before the real libtool is -generated. - -Usage: $[0] [[OPTIONS]] - - -h, --help print this help, then exit - -V, --version print version number, then exit - -q, --quiet do not print progress messages - -d, --debug don't remove temporary files - -Report bugs to ." - -lt_cl_version="\ -m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl -m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) -configured by $[0], generated by m4_PACKAGE_STRING. - -Copyright (C) 2011 Free Software Foundation, Inc. -This config.lt script is free software; the Free Software Foundation -gives unlimited permision to copy, distribute and modify it." - -while test 0 != $[#] -do - case $[1] in - --version | --v* | -V ) - echo "$lt_cl_version"; exit 0 ;; - --help | --h* | -h ) - echo "$lt_cl_help"; exit 0 ;; - --debug | --d* | -d ) - debug=: ;; - --quiet | --q* | --silent | --s* | -q ) - lt_cl_silent=: ;; - - -*) AC_MSG_ERROR([unrecognized option: $[1] -Try '$[0] --help' for more information.]) ;; - - *) AC_MSG_ERROR([unrecognized argument: $[1] -Try '$[0] --help' for more information.]) ;; - esac - shift -done - -if $lt_cl_silent; then - exec AS_MESSAGE_FD>/dev/null -fi -_LTEOF - -cat >>"$CONFIG_LT" <<_LTEOF -_LT_OUTPUT_LIBTOOL_COMMANDS_INIT -_LTEOF - -cat >>"$CONFIG_LT" <<\_LTEOF -AC_MSG_NOTICE([creating $ofile]) -_LT_OUTPUT_LIBTOOL_COMMANDS -AS_EXIT(0) -_LTEOF -chmod +x "$CONFIG_LT" - -# configure is writing to config.log, but config.lt does its own redirection, -# appending to config.log, which fails on DOS, as config.log is still kept -# open by configure. Here we exec the FD to /dev/null, effectively closing -# config.log, so it can be properly (re)opened and appended to by config.lt. -lt_cl_success=: -test yes = "$silent" && - lt_config_lt_args="$lt_config_lt_args --quiet" -exec AS_MESSAGE_LOG_FD>/dev/null -$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false -exec AS_MESSAGE_LOG_FD>>config.log -$lt_cl_success || AS_EXIT(1) -])# LT_OUTPUT - - -# _LT_CONFIG(TAG) -# --------------- -# If TAG is the built-in tag, create an initial libtool script with a -# default configuration from the untagged config vars. Otherwise add code -# to config.status for appending the configuration named by TAG from the -# matching tagged config vars. -m4_defun([_LT_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_CONFIG_SAVE_COMMANDS([ - m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl - m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options that allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}"; then - setopt NO_GLOB_SUBST - fi - - cfgfile=${ofile}T - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL -# Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. - -# Provide generalized library-building support services. -# Written by Gordon Matzigkeit, 1996 - -_LT_COPYING -_LT_LIBTOOL_TAGS - -# Configured defaults for sys_lib_dlsearch_path munging. -: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} - -# ### BEGIN LIBTOOL CONFIG -_LT_LIBTOOL_CONFIG_VARS -_LT_LIBTOOL_TAG_VARS -# ### END LIBTOOL CONFIG - -_LT_EOF - - cat <<'_LT_EOF' >> "$cfgfile" - -# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE - -_LT_PREPARE_MUNGE_PATH_LIST -_LT_PREPARE_CC_BASENAME - -# ### END FUNCTIONS SHARED WITH CONFIGURE - -_LT_EOF - - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test set != "${COLLECT_NAMES+set}"; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; - esac - - _LT_PROG_LTMAIN - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - $SED '$q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -], -[cat <<_LT_EOF >> "$ofile" - -dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded -dnl in a comment (ie after a #). -# ### BEGIN LIBTOOL TAG CONFIG: $1 -_LT_LIBTOOL_TAG_VARS(_LT_TAG) -# ### END LIBTOOL TAG CONFIG: $1 -_LT_EOF -])dnl /m4_if -], -[m4_if([$1], [], [ - PACKAGE='$PACKAGE' - VERSION='$VERSION' - RM='$RM' - ofile='$ofile'], []) -])dnl /_LT_CONFIG_SAVE_COMMANDS -])# _LT_CONFIG - - -# LT_SUPPORTED_TAG(TAG) -# --------------------- -# Trace this macro to discover what tags are supported by the libtool -# --tag option, using: -# autoconf --trace 'LT_SUPPORTED_TAG:$1' -AC_DEFUN([LT_SUPPORTED_TAG], []) - - -# C support is built-in for now -m4_define([_LT_LANG_C_enabled], []) -m4_define([_LT_TAGS], []) - - -# LT_LANG(LANG) -# ------------- -# Enable libtool support for the given language if not already enabled. -AC_DEFUN([LT_LANG], -[AC_BEFORE([$0], [LT_OUTPUT])dnl -m4_case([$1], - [C], [_LT_LANG(C)], - [C++], [_LT_LANG(CXX)], - [Go], [_LT_LANG(GO)], - [Java], [_LT_LANG(GCJ)], - [Fortran 77], [_LT_LANG(F77)], - [Fortran], [_LT_LANG(FC)], - [Windows Resource], [_LT_LANG(RC)], - [m4_ifdef([_LT_LANG_]$1[_CONFIG], - [_LT_LANG($1)], - [m4_fatal([$0: unsupported language: "$1"])])])dnl -])# LT_LANG - - -# _LT_LANG(LANGNAME) -# ------------------ -m4_defun([_LT_LANG], -[m4_ifdef([_LT_LANG_]$1[_enabled], [], - [LT_SUPPORTED_TAG([$1])dnl - m4_append([_LT_TAGS], [$1 ])dnl - m4_define([_LT_LANG_]$1[_enabled], [])dnl - _LT_LANG_$1_CONFIG($1)])dnl -])# _LT_LANG - - -m4_ifndef([AC_PROG_GO], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_GO. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ -m4_defun([AC_PROG_GO], -[AC_LANG_PUSH(Go)dnl -AC_ARG_VAR([GOC], [Go compiler command])dnl -AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl -_AC_ARG_VAR_LDFLAGS()dnl -AC_CHECK_TOOL(GOC, gccgo) -if test -z "$GOC"; then - if test -n "$ac_tool_prefix"; then - AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) - fi -fi -if test -z "$GOC"; then - AC_CHECK_PROG(GOC, gccgo, gccgo, false) -fi -])#m4_defun -])#m4_ifndef - - -# _LT_LANG_DEFAULT_CONFIG -# ----------------------- -m4_defun([_LT_LANG_DEFAULT_CONFIG], -[AC_PROVIDE_IFELSE([AC_PROG_CXX], - [LT_LANG(CXX)], - [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) - -AC_PROVIDE_IFELSE([AC_PROG_F77], - [LT_LANG(F77)], - [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) - -AC_PROVIDE_IFELSE([AC_PROG_FC], - [LT_LANG(FC)], - [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) - -dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal -dnl pulling things in needlessly. -AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([LT_PROG_GCJ], - [LT_LANG(GCJ)], - [m4_ifdef([AC_PROG_GCJ], - [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([A][M_PROG_GCJ], - [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([LT_PROG_GCJ], - [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) - -AC_PROVIDE_IFELSE([AC_PROG_GO], - [LT_LANG(GO)], - [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) - -AC_PROVIDE_IFELSE([LT_PROG_RC], - [LT_LANG(RC)], - [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) -])# _LT_LANG_DEFAULT_CONFIG - -# Obsolete macros: -AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) -AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) -AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) -AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) -AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_CXX], []) -dnl AC_DEFUN([AC_LIBTOOL_F77], []) -dnl AC_DEFUN([AC_LIBTOOL_FC], []) -dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) -dnl AC_DEFUN([AC_LIBTOOL_RC], []) - - -# _LT_TAG_COMPILER -# ---------------- -m4_defun([_LT_TAG_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl -_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl -_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl -_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_TAG_COMPILER - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -m4_defun([_LT_COMPILER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -m4_defun([_LT_LINKER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* -])# _LT_LINKER_BOILERPLATE - -# _LT_REQUIRED_DARWIN_CHECKS -# ------------------------- -m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ - case $host_os in - rhapsody* | darwin*) - AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) - AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) - AC_CHECK_TOOL([LIPO], [lipo], [:]) - AC_CHECK_TOOL([OTOOL], [otool], [:]) - AC_CHECK_TOOL([OTOOL64], [otool64], [:]) - _LT_DECL([], [DSYMUTIL], [1], - [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) - _LT_DECL([], [NMEDIT], [1], - [Tool to change global to local symbols on Mac OS X]) - _LT_DECL([], [LIPO], [1], - [Tool to manipulate fat objects and archives on Mac OS X]) - _LT_DECL([], [OTOOL], [1], - [ldd/readelf like tool for Mach-O binaries on Mac OS X]) - _LT_DECL([], [OTOOL64], [1], - [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) - - AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], - [lt_cv_apple_cc_single_mod=no - if test -z "$LT_MULTI_MODULE"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - # If there is a non-empty error log, and "single_module" - # appears in it, assume the flag caused a linker warning - if test -s conftest.err && $GREP single_module conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - # Otherwise, if the output was created with a 0 exit code from - # the compiler, it worked. - elif test -f libconftest.dylib && test 0 = "$_lt_result"; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi]) - - AC_CACHE_CHECK([for -exported_symbols_list linker flag], - [lt_cv_ld_exported_symbols_list], - [lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [lt_cv_ld_exported_symbols_list=yes], - [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS=$save_LDFLAGS - ]) - - AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], - [lt_cv_ld_force_load=no - cat > conftest.c << _LT_EOF -int forced_loaded() { return 2;} -_LT_EOF - echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD - echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD - $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD - cat > conftest.c << _LT_EOF -int main() { return 0;} -_LT_EOF - echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err - _lt_result=$? - if test -s conftest.err && $GREP force_load conftest.err; then - cat conftest.err >&AS_MESSAGE_LOG_FD - elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then - lt_cv_ld_force_load=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -f conftest.err libconftest.a conftest conftest.c - rm -rf conftest.dSYM - ]) - case $host_os in - rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - darwin*) - case $MACOSX_DEPLOYMENT_TARGET,$host in - 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - *) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test yes = "$lt_cv_apple_cc_single_mod"; then - _lt_dar_single_mod='$single_module' - fi - if test yes = "$lt_cv_ld_exported_symbols_list"; then - _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' - fi - if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac -]) - - -# _LT_DARWIN_LINKER_FEATURES([TAG]) -# --------------------------------- -# Checks for linker and compiler features on darwin -m4_defun([_LT_DARWIN_LINKER_FEATURES], -[ - m4_require([_LT_REQUIRED_DARWIN_CHECKS]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_automatic, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - if test yes = "$lt_cv_ld_force_load"; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' - m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], - [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='' - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined - case $cc_basename in - ifort*|nagfor*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test yes = "$_lt_dar_can_shared"; then - output_verbose_link_cmd=func_echo_all - _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" - m4_if([$1], [CXX], -[ if test yes != "$lt_cv_apple_cc_single_mod"; then - _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" - fi -],[]) - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi -]) - -# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) -# ---------------------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -# Store the results from the different compilers for each TAGNAME. -# Allow to override them for all tags through lt_cv_aix_libpath. -m4_defun([_LT_SYS_MODULE_PATH_AIX], -[m4_require([_LT_DECL_SED])dnl -if test set = "${lt_cv_aix_libpath+set}"; then - aix_libpath=$lt_cv_aix_libpath -else - AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], - [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ - lt_aix_libpath_sed='[ - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\([^ ]*\) *$/\1/ - p - } - }]' - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - # Check for a 64-bit object if we didn't find anything. - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` - fi],[]) - if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib - fi - ]) - aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) -fi -])# _LT_SYS_MODULE_PATH_AIX - - -# _LT_SHELL_INIT(ARG) -# ------------------- -m4_define([_LT_SHELL_INIT], -[m4_divert_text([M4SH-INIT], [$1 -])])# _LT_SHELL_INIT - - - -# _LT_PROG_ECHO_BACKSLASH -# ----------------------- -# Find how we can fake an echo command that does not interpret backslash. -# In particular, with Autoconf 2.60 or later we add some code to the start -# of the generated configure script that will find a shell with a builtin -# printf (that we can use as an echo command). -m4_defun([_LT_PROG_ECHO_BACKSLASH], -[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO -ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - -AC_MSG_CHECKING([how to print strings]) -# Test print first, because it will be a builtin if present. -if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ - test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='print -r --' -elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then - ECHO='printf %s\n' -else - # Use this function as a fallback that always works. - func_fallback_echo () - { - eval 'cat <<_LTECHO_EOF -$[]1 -_LTECHO_EOF' - } - ECHO='func_fallback_echo' -fi - -# func_echo_all arg... -# Invoke $ECHO with all args, space-separated. -func_echo_all () -{ - $ECHO "$*" -} - -case $ECHO in - printf*) AC_MSG_RESULT([printf]) ;; - print*) AC_MSG_RESULT([print -r]) ;; - *) AC_MSG_RESULT([cat]) ;; -esac - -m4_ifdef([_AS_DETECT_SUGGESTED], -[_AS_DETECT_SUGGESTED([ - test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( - ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO - ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO - PATH=/empty FPATH=/empty; export PATH FPATH - test "X`printf %s $ECHO`" = "X$ECHO" \ - || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) - -_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) -_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) -])# _LT_PROG_ECHO_BACKSLASH - - -# _LT_WITH_SYSROOT -# ---------------- -AC_DEFUN([_LT_WITH_SYSROOT], -[m4_require([_LT_DECL_SED])dnl -AC_MSG_CHECKING([for sysroot]) -AC_ARG_WITH([sysroot], -[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], - [Search for dependent libraries within DIR (or the compiler's sysroot - if not specified).])], -[], [with_sysroot=no]) - -dnl lt_sysroot will always be passed unquoted. We quote it here -dnl in case the user passed a directory name. -lt_sysroot= -case $with_sysroot in #( - yes) - if test yes = "$GCC"; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` - fi - ;; #( - /*) - lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` - ;; #( - no|'') - ;; #( - *) - AC_MSG_RESULT([$with_sysroot]) - AC_MSG_ERROR([The sysroot must be an absolute path.]) - ;; -esac - - AC_MSG_RESULT([${lt_sysroot:-no}]) -_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl -[dependent libraries, and where our libraries should be installed.])]) - -# _LT_ENABLE_LOCK -# --------------- -m4_defun([_LT_ENABLE_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test no = "$enable_libtool_lock" || enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out what ABI is being produced by ac_compile, and set mode - # options accordingly. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `$FILECMD conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE=32 - ;; - *ELF-64*) - HPUX_IA64_MODE=64 - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test yes = "$lt_cv_prog_gnu_ld"; then - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -mips64*-*linux*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - emul=elf - case `$FILECMD conftest.$ac_objext` in - *32-bit*) - emul="${emul}32" - ;; - *64-bit*) - emul="${emul}64" - ;; - esac - case `$FILECMD conftest.$ac_objext` in - *MSB*) - emul="${emul}btsmip" - ;; - *LSB*) - emul="${emul}ltsmip" - ;; - esac - case `$FILECMD conftest.$ac_objext` in - *N32*) - emul="${emul}n32" - ;; - esac - LD="${LD-ld} -m $emul" - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. Note that the listed cases only cover the - # situations where additional linker options are needed (such as when - # doing 32-bit compilation for a host where ld defaults to 64-bit, or - # vice versa); the common cases where no linker options are needed do - # not appear in the list. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `$FILECMD conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - case `$FILECMD conftest.o` in - *x86-64*) - LD="${LD-ld} -m elf32_x86_64" - ;; - *) - LD="${LD-ld} -m elf_i386" - ;; - esac - ;; - powerpc64le-*linux*) - LD="${LD-ld} -m elf32lppclinux" - ;; - powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - powerpcle-*linux*) - LD="${LD-ld} -m elf64lppc" - ;; - powerpc-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS=$CFLAGS - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test yes != "$lt_cv_cc_needs_belf"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS=$SAVE_CFLAGS - fi - ;; -*-*solaris*) - # Find out what ABI is being produced by ac_compile, and set linker - # options accordingly. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `$FILECMD conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) - case $host in - i?86-*-solaris*|x86_64-*-solaris*) - LD="${LD-ld} -m elf_x86_64" - ;; - sparc*-*-solaris*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - # GNU ld 2.21 introduced _sol2 emulations. Use them if available. - if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD=${LD-ld}_sol2 - fi - ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks=$enable_libtool_lock -])# _LT_ENABLE_LOCK - - -# _LT_PROG_AR -# ----------- -m4_defun([_LT_PROG_AR], -[AC_CHECK_TOOLS(AR, [ar], false) -: ${AR=ar} -_LT_DECL([], [AR], [1], [The archiver]) - -# Use ARFLAGS variable as AR's operation code to sync the variable naming with -# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have -# higher priority because thats what people were doing historically (setting -# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS -# variable obsoleted/removed. - -test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} -lt_ar_flags=$AR_FLAGS -_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) - -# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override -# by AR_FLAGS because that was never working and AR_FLAGS is about to die. -_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], - [Flags to create an archive]) - -AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], - [lt_cv_ar_at_file=no - AC_COMPILE_IFELSE([AC_LANG_PROGRAM], - [echo conftest.$ac_objext > conftest.lst - lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' - AC_TRY_EVAL([lt_ar_try]) - if test 0 -eq "$ac_status"; then - # Ensure the archiver fails upon bogus file names. - rm -f conftest.$ac_objext libconftest.a - AC_TRY_EVAL([lt_ar_try]) - if test 0 -ne "$ac_status"; then - lt_cv_ar_at_file=@ - fi - fi - rm -f conftest.* libconftest.a - ]) - ]) - -if test no = "$lt_cv_ar_at_file"; then - archiver_list_spec= -else - archiver_list_spec=$lt_cv_ar_at_file -fi -_LT_DECL([], [archiver_list_spec], [1], - [How to feed a file listing to the archiver]) -])# _LT_PROG_AR - - -# _LT_CMD_OLD_ARCHIVE -# ------------------- -m4_defun([_LT_CMD_OLD_ARCHIVE], -[_LT_PROG_AR - -AC_CHECK_TOOL(STRIP, strip, :) -test -z "$STRIP" && STRIP=: -_LT_DECL([], [STRIP], [1], [A symbol stripping program]) - -AC_CHECK_TOOL(RANLIB, ranlib, :) -test -z "$RANLIB" && RANLIB=: -_LT_DECL([], [RANLIB], [1], - [Commands used to install an old-style archive]) - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - bitrig* | openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" -fi - -case $host_os in - darwin*) - lock_old_archive_extraction=yes ;; - *) - lock_old_archive_extraction=no ;; -esac -_LT_DECL([], [old_postinstall_cmds], [2]) -_LT_DECL([], [old_postuninstall_cmds], [2]) -_LT_TAGDECL([], [old_archive_cmds], [2], - [Commands used to build an old-style archive]) -_LT_DECL([], [lock_old_archive_extraction], [0], - [Whether to use a lock for old archive extraction]) -])# _LT_CMD_OLD_ARCHIVE - - -# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([_LT_COMPILER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $RM conftest* -]) - -if test yes = "[$]$2"; then - m4_if([$5], , :, [$5]) -else - m4_if([$6], , :, [$6]) -fi -])# _LT_COMPILER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) - - -# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------- -# Check whether the given linker option works -AC_DEFUN([_LT_LINKER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS $3" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $RM -r conftest* - LDFLAGS=$save_LDFLAGS -]) - -if test yes = "[$]$2"; then - m4_if([$4], , :, [$4]) -else - m4_if([$5], , :, [$5]) -fi -])# _LT_LINKER_OPTION - -# Old name: -AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) - - -# LT_CMD_MAX_LEN -#--------------- -AC_DEFUN([LT_CMD_MAX_LEN], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring=ABCD - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - mint*) - # On MiNT this can take a long time and run out of memory. - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - os2*) - # The test takes a long time on OS/2. - lt_cv_sys_max_cmd_len=8192 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len" && \ - test undefined != "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test X`env echo "$teststring$teststring" 2>/dev/null` \ - = "X$teststring$teststring"; } >/dev/null 2>&1 && - test 17 != "$i" # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac -]) -if test -n "$lt_cv_sys_max_cmd_len"; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -max_cmd_len=$lt_cv_sys_max_cmd_len -_LT_DECL([], [max_cmd_len], [0], - [What is the maximum length of a command?]) -])# LT_CMD_MAX_LEN - -# Old name: -AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) - - -# _LT_HEADER_DLFCN -# ---------------- -m4_defun([_LT_HEADER_DLFCN], -[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl -])# _LT_HEADER_DLFCN - - -# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ---------------------------------------------------------------- -m4_defun([_LT_TRY_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test yes = "$cross_compiling"; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -[#line $LINENO "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -/* When -fvisibility=hidden is used, assume the code has been annotated - correspondingly for the symbols needed. */ -#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); -#endif - -int fnord () { return 42; } -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else - { - if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - else puts (dlerror ()); - } - /* dlclose (self); */ - } - else - puts (dlerror ()); - - return status; -}] -_LT_EOF - if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_dlunknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_TRY_DLOPEN_SELF - - -# LT_SYS_DLOPEN_SELF -# ------------------ -AC_DEFUN([LT_SYS_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test yes != "$enable_dlopen"; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen=load_add_on - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen=LoadLibrary - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen=dlopen - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ - lt_cv_dlopen=dyld - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - tpf*) - # Don't try to run any link tests for TPF. We know it's impossible - # because TPF is a cross-compiler, and we know how we open DSOs. - lt_cv_dlopen=dlopen - lt_cv_dlopen_libs= - lt_cv_dlopen_self=no - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen=shl_load], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen=dlopen], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test no = "$lt_cv_dlopen"; then - enable_dlopen=no - else - enable_dlopen=yes - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS=$CPPFLAGS - test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS=$LDFLAGS - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS=$LIBS - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test yes = "$lt_cv_dlopen_self"; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS=$save_CPPFLAGS - LDFLAGS=$save_LDFLAGS - LIBS=$save_LIBS - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -_LT_DECL([dlopen_support], [enable_dlopen], [0], - [Whether dlopen is supported]) -_LT_DECL([dlopen_self], [enable_dlopen_self], [0], - [Whether dlopen of programs is supported]) -_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], - [Whether dlopen of statically linked programs is supported]) -])# LT_SYS_DLOPEN_SELF - -# Old name: -AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) - - -# _LT_COMPILER_C_O([TAGNAME]) -# --------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler. -# This macro does not hard code the compiler like AC_PROG_CC_C_O. -m4_defun([_LT_COMPILER_C_O], -[m4_require([_LT_DECL_SED])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* -]) -_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], - [Does compiler simultaneously support -c and -o options?]) -])# _LT_COMPILER_C_O - - -# _LT_COMPILER_FILE_LOCKS([TAGNAME]) -# ---------------------------------- -# Check to see if we can do hard links to lock some files if needed -m4_defun([_LT_COMPILER_FILE_LOCKS], -[m4_require([_LT_ENABLE_LOCK])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_COMPILER_C_O([$1]) - -hard_links=nottested -if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test no = "$hard_links"; then - AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) -])# _LT_COMPILER_FILE_LOCKS - - -# _LT_CHECK_OBJDIR -# ---------------- -m4_defun([_LT_CHECK_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -_LT_DECL([], [objdir], [0], - [The name of the directory that contains temporary libtool files])dnl -m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", - [Define to the sub-directory where libtool stores uninstalled libraries.]) -])# _LT_CHECK_OBJDIR - - -# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) -# -------------------------------------- -# Check hardcoding attributes. -m4_defun([_LT_LINKER_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || - test -n "$_LT_TAGVAR(runpath_var, $1)" || - test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then - - # We can hardcode non-existent directories. - if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && - test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then - # Linking always hardcodes the temporary library directory. - _LT_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) - -if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || - test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then - # Fast installation is not supported - enable_fast_install=no -elif test yes = "$shlibpath_overrides_runpath" || - test no = "$enable_shared"; then - # Fast installation is not necessary - enable_fast_install=needless -fi -_LT_TAGDECL([], [hardcode_action], [0], - [How to hardcode a shared library path into an executable]) -])# _LT_LINKER_HARDCODE_LIBPATH - - -# _LT_CMD_STRIPLIB -# ---------------- -m4_defun([_LT_CMD_STRIPLIB], -[m4_require([_LT_DECL_EGREP]) -striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -z "$STRIP"; then - AC_MSG_RESULT([no]) -else - if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - old_striplib="$STRIP --strip-debug" - striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) - else - case $host_os in - darwin*) - # FIXME - insert some real tests, host_os isn't really good enough - striplib="$STRIP -x" - old_striplib="$STRIP -S" - AC_MSG_RESULT([yes]) - ;; - freebsd*) - if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then - old_striplib="$STRIP --strip-debug" - striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac - fi -fi -_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) -_LT_DECL([], [striplib], [1]) -])# _LT_CMD_STRIPLIB - - -# _LT_PREPARE_MUNGE_PATH_LIST -# --------------------------- -# Make sure func_munge_path_list() is defined correctly. -m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], -[[# func_munge_path_list VARIABLE PATH -# ----------------------------------- -# VARIABLE is name of variable containing _space_ separated list of -# directories to be munged by the contents of PATH, which is string -# having a format: -# "DIR[:DIR]:" -# string "DIR[ DIR]" will be prepended to VARIABLE -# ":DIR[:DIR]" -# string "DIR[ DIR]" will be appended to VARIABLE -# "DIRP[:DIRP]::[DIRA:]DIRA" -# string "DIRP[ DIRP]" will be prepended to VARIABLE and string -# "DIRA[ DIRA]" will be appended to VARIABLE -# "DIR[:DIR]" -# VARIABLE will be replaced by "DIR[ DIR]" -func_munge_path_list () -{ - case x@S|@2 in - x) - ;; - *:) - eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" - ;; - x:*) - eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" - ;; - *::*) - eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" - eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" - ;; - *) - eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" - ;; - esac -} -]])# _LT_PREPARE_PATH_LIST - - -# _LT_SYS_DYNAMIC_LINKER([TAG]) -# ----------------------------- -# PORTME Fill in your ld.so characteristics -m4_defun([_LT_SYS_DYNAMIC_LINKER], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_OBJDUMP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl -AC_MSG_CHECKING([dynamic linker characteristics]) -m4_if([$1], - [], [ -if test yes = "$GCC"; then - case $host_os in - darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; - *) lt_awk_arg='/^libraries:/' ;; - esac - case $host_os in - mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; - *) lt_sed_strip_eq='s|=/|/|g' ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` - case $lt_search_path_spec in - *\;*) - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` - ;; - *) - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` - ;; - esac - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary... - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - # ...but if some path component already ends with the multilib dir we assume - # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). - case "$lt_multi_os_dir; $lt_search_path_spec " in - "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) - lt_multi_os_dir= - ;; - esac - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" - elif test -n "$lt_multi_os_dir"; then - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS = " "; FS = "/|\n";} { - lt_foo = ""; - lt_count = 0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo = "/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[[lt_foo]]++; } - if (lt_freq[[lt_foo]] == 1) { print lt_foo; } -}'` - # AWK program above erroneously prepends '/' to C:/dos/paths - # for these hosts. - case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; - esac - sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=.so -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -AC_ARG_VAR([LT_SYS_LIBRARY_PATH], -[User-defined run-time library search path.]) - -case $host_os in -aix3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='$libname$release$shared_ext$major' - ;; - -aix[[4-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test ia64 = "$host_cpu"; then - # AIX 5 supports IA64 - library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line '#! .'. This would cause the generated library to - # depend on '.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # Using Import Files as archive members, it is possible to support - # filename-based versioning of shared library archives on AIX. While - # this would work for both with and without runtime linking, it will - # prevent static linking of such archives. So we do filename-based - # shared library versioning with .so extension only, which is used - # when both runtime linking and shared linking is enabled. - # Unfortunately, runtime linking may impact performance, so we do - # not want this to be the default eventually. Also, we use the - # versioned .so libs for executables only if there is the -brtl - # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. - # To allow for filename-based versioning support, we need to create - # libNAME.so.V as an archive file, containing: - # *) an Import File, referring to the versioned filename of the - # archive as well as the shared archive member, telling the - # bitwidth (32 or 64) of that shared object, and providing the - # list of exported symbols of that shared object, eventually - # decorated with the 'weak' keyword - # *) the shared object with the F_LOADONLY flag set, to really avoid - # it being seen by the linker. - # At run time we better use the real file rather than another symlink, - # but for link time we create the symlink libNAME.so -> libNAME.so.V - - case $with_aix_soname,$aix_use_runtimelinking in - # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - aix,yes) # traditional libtool - dynamic_linker='AIX unversionable lib.so' - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - aix,no) # traditional AIX only - dynamic_linker='AIX lib.a[(]lib.so.V[)]' - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - ;; - svr4,*) # full svr4 only - dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,yes) # both, prefer svr4 - dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" - library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' - # unpreferred sharedlib libNAME.a needs extra handling - postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' - postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' - # We do not specify a path in Import Files, so LIBPATH fires. - shlibpath_overrides_runpath=yes - ;; - *,no) # both, prefer aix - dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" - library_names_spec='$libname$release.a $libname.a' - soname_spec='$libname$release$shared_ext$major' - # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling - postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' - postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' - ;; - esac - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - esac - ;; - -beos*) - library_names_spec='$libname$shared_ext' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - - case $GCC,$cc_basename in - yes,*) - # gcc - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' - ;; - esac - dynamic_linker='Win32 ld.exe' - ;; - - *,cl* | *,icl*) - # Native MSVC or ICC - libname_spec='$name' - soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' - library_names_spec='$libname.dll.lib' - - case $build_os in - mingw*) - sys_lib_search_path_spec= - lt_save_ifs=$IFS - IFS=';' - for lt_path in $LIB - do - IFS=$lt_save_ifs - # Let DOS variable expansion print the short 8.3 style file name. - lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` - sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" - done - IFS=$lt_save_ifs - # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` - ;; - cygwin*) - # Convert to unix form, then to dos form, then back to unix form - # but this time dos style (no spaces!) so that the unix form looks - # like /cygdrive/c/PROGRA~1:/cygdr... - sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` - sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` - sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - ;; - *) - sys_lib_search_path_spec=$LIB - if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # FIXME: find the short name or the path components, as spaces are - # common. (e.g. "Program Files" -> "PROGRA~1") - ;; - esac - - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes - dynamic_linker='Win32 link.exe' - ;; - - *) - # Assume MSVC and ICC wrapper - library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' - dynamic_linker='Win32 ld.exe' - ;; - esac - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' - soname_spec='$libname$release$major$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd* | dragonfly* | midnightbsd*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[23]].*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2.*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ - freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -haiku*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - dynamic_linker="$host_os runtime_loader" - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=no - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - if test 32 = "$HPUX_IA64_MODE"; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - sys_lib_dlsearch_path_spec=/usr/lib/hpux32 - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - sys_lib_dlsearch_path_spec=/usr/lib/hpux64 - fi - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555, ... - postinstall_cmds='chmod 555 $lib' - # or fails outright, so override atomically: - install_override_mode=555 - ;; - -interix[[3-9]]*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test yes = "$lt_cv_prog_gnu_ld"; then - version_type=linux # correct to gnu/linux during the next big refactor - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" - sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -linux*android*) - version_type=none # Android doesn't support versioned libraries. - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext' - soname_spec='$libname$release$shared_ext' - finish_cmds= - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - dynamic_linker='Android linker' - # Don't embed -rpath directories since the linker doesn't support them. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - - # Some binutils ld are patched to set DT_RUNPATH - AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], - [lt_cv_shlibpath_overrides_runpath=no - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ - LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], - [lt_cv_shlibpath_overrides_runpath=yes])]) - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - ]) - shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - - # Ideally, we could use ldconfig to report *all* directores which are - # searched for libraries, however this is still not possible. Aside from not - # being certain /sbin/ldconfig is available, command - # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, - # even though it is searched at run-time. Try to do the best guess by - # appending ld.so.conf contents (and includes) to the search path. - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; - -openbsd* | bitrig*) - version_type=sunos - sys_lib_dlsearch_path_spec=/usr/lib - need_lib_prefix=no - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - need_version=no - else - need_version=yes - fi - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -os2*) - libname_spec='$name' - version_type=windows - shrext_cmds=.dll - need_version=no - need_lib_prefix=no - # OS/2 can only load a DLL with a base name of 8 characters or less. - soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; - v=$($ECHO $release$versuffix | tr -d .-); - n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); - $ECHO $n$v`$shared_ext' - library_names_spec='${libname}_dll.$libext' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=BEGINLIBPATH - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='$libname$release$shared_ext$major' - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - -rdos*) - dynamic_linker=no - ;; - -solaris*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test yes = "$with_gnu_ld"; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec; then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' - soname_spec='$libname$shared_ext.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=sco - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test yes = "$with_gnu_ld"; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test no = "$dynamic_linker" && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test yes = "$GCC"; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then - sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec -fi - -if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then - sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec -fi - -# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... -configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec - -# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code -func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" - -# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool -configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH - -_LT_DECL([], [variables_saved_for_relink], [1], - [Variables whose values should be saved in libtool wrapper scripts and - restored at link time]) -_LT_DECL([], [need_lib_prefix], [0], - [Do we need the "lib" prefix for modules?]) -_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) -_LT_DECL([], [version_type], [0], [Library versioning type]) -_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) -_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) -_LT_DECL([], [shlibpath_overrides_runpath], [0], - [Is shlibpath searched before the hard-coded library search path?]) -_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) -_LT_DECL([], [library_names_spec], [1], - [[List of archive names. First name is the real one, the rest are links. - The last name is the one that the linker finds with -lNAME]]) -_LT_DECL([], [soname_spec], [1], - [[The coded name of the library, if different from the real name]]) -_LT_DECL([], [install_override_mode], [1], - [Permission mode override for installation of shared libraries]) -_LT_DECL([], [postinstall_cmds], [2], - [Command to use after installation of a shared archive]) -_LT_DECL([], [postuninstall_cmds], [2], - [Command to use after uninstallation of a shared archive]) -_LT_DECL([], [finish_cmds], [2], - [Commands used to finish a libtool library installation in a directory]) -_LT_DECL([], [finish_eval], [1], - [[As "finish_cmds", except a single script fragment to be evaled but - not shown]]) -_LT_DECL([], [hardcode_into_libs], [0], - [Whether we should hardcode library paths into libraries]) -_LT_DECL([], [sys_lib_search_path_spec], [2], - [Compile-time system search path for libraries]) -_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], - [Detected run-time system search path for libraries]) -_LT_DECL([], [configure_time_lt_sys_library_path], [2], - [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) -])# _LT_SYS_DYNAMIC_LINKER - - -# _LT_PATH_TOOL_PREFIX(TOOL) -# -------------------------- -# find a file program that can recognize shared library -AC_DEFUN([_LT_PATH_TOOL_PREFIX], -[m4_require([_LT_DECL_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD=$MAGIC_CMD - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="m4_if([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$1"; then - lt_cv_path_MAGIC_CMD=$ac_dir/"$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD=$lt_cv_path_MAGIC_CMD - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS=$lt_save_ifs - MAGIC_CMD=$lt_save_MAGIC_CMD - ;; -esac]) -MAGIC_CMD=$lt_cv_path_MAGIC_CMD -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -_LT_DECL([], [MAGIC_CMD], [0], - [Used to examine libraries when file_magic_cmd begins with "file"])dnl -])# _LT_PATH_TOOL_PREFIX - -# Old name: -AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) - - -# _LT_PATH_MAGIC -# -------------- -# find a file program that can recognize a shared library -m4_defun([_LT_PATH_MAGIC], -[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# _LT_PATH_MAGIC - - -# LT_PATH_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([LT_PATH_LD], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PROG_ECHO_BACKSLASH])dnl - -AC_ARG_WITH([gnu-ld], - [AS_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test no = "$withval" || with_gnu_ld=yes], - [with_gnu_ld=no])dnl - -ac_prog=ld -if test yes = "$GCC"; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return, which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD=$ac_prog - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test yes = "$with_gnu_ld"; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD=$ac_dir/$ac_prog - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &1 conftest.i -cat conftest.i conftest.i >conftest2.i -: ${lt_DD:=$DD} -AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], -[if "$ac_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then - cmp -s conftest.i conftest.out \ - && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: -fi]) -rm -f conftest.i conftest2.i conftest.out]) -])# _LT_PATH_DD - - -# _LT_CMD_TRUNCATE -# ---------------- -# find command to truncate a binary pipe -m4_defun([_LT_CMD_TRUNCATE], -[m4_require([_LT_PATH_DD]) -AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], -[printf 0123456789abcdef0123456789abcdef >conftest.i -cat conftest.i conftest.i >conftest2.i -lt_cv_truncate_bin= -if "$ac_cv_path_lt_DD" bs=32 count=1 conftest.out 2>/dev/null; then - cmp -s conftest.i conftest.out \ - && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" -fi -rm -f conftest.i conftest2.i conftest.out -test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) -_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], - [Command to truncate a binary pipe]) -])# _LT_CMD_TRUNCATE - - -# _LT_CHECK_MAGIC_METHOD -# ---------------------- -# how to check for library dependencies -# -- PORTME fill in with the dynamic library characteristics -m4_defun([_LT_CHECK_MAGIC_METHOD], -[m4_require([_LT_DECL_EGREP]) -m4_require([_LT_DECL_OBJDUMP]) -AC_CACHE_CHECK([how to recognize dependent libraries], -lt_cv_deplibs_check_method, -[lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# 'unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# that responds to the $file_magic_cmd with a given extended regex. -# If you have 'file' or equivalent on your system and you're not sure -# whether 'pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[[4-9]]*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[[45]]*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='$FILECMD -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - if ( file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; - -cegcc*) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | dragonfly* | midnightbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=$FILECMD - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -haiku*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=$FILECMD - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -interix[[3-9]]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=$FILECMD - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd* | bitrig*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -os2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) - -file_magic_glob= -want_nocaseglob=no -if test "$build" = "$host"; then - case $host_os in - mingw* | pw32*) - if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then - want_nocaseglob=yes - else - file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` - fi - ;; - esac -fi - -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - -_LT_DECL([], [deplibs_check_method], [1], - [Method to check whether dependent libraries are shared objects]) -_LT_DECL([], [file_magic_cmd], [1], - [Command to use when deplibs_check_method = "file_magic"]) -_LT_DECL([], [file_magic_glob], [1], - [How to find potential files when deplibs_check_method = "file_magic"]) -_LT_DECL([], [want_nocaseglob], [1], - [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) -])# _LT_CHECK_MAGIC_METHOD - - -# LT_PATH_NM -# ---------- -# find the pathname to a BSD- or MS-compatible name lister -AC_DEFUN([LT_PATH_NM], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM=$NM -else - lt_nm_to_check=${ac_tool_prefix}nm - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS=$lt_save_ifs - test -z "$ac_dir" && ac_dir=. - tmp_nm=$ac_dir/$lt_tmp_nm - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the 'sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty - case $build_os in - mingw*) lt_bad_file=conftest.nm/nofile ;; - *) lt_bad_file=/dev/null ;; - esac - case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in - *$lt_bad_file* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break 2 - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break 2 - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS=$lt_save_ifs - done - : ${lt_cv_path_NM=no} -fi]) -if test no != "$lt_cv_path_NM"; then - NM=$lt_cv_path_NM -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$DUMPBIN"; then : - # Let the user override the test. - else - AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in - *COFF*) - DUMPBIN="$DUMPBIN -symbols -headers" - ;; - *) - DUMPBIN=: - ;; - esac - fi - AC_SUBST([DUMPBIN]) - if test : != "$DUMPBIN"; then - NM=$DUMPBIN - fi -fi -test -z "$NM" && NM=nm -AC_SUBST([NM]) -_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl - -AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], - [lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) - cat conftest.out >&AS_MESSAGE_LOG_FD - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" - fi - rm -f conftest*]) -])# LT_PATH_NM - -# Old names: -AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) -AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_PROG_NM], []) -dnl AC_DEFUN([AC_PROG_NM], []) - -# _LT_CHECK_SHAREDLIB_FROM_LINKLIB -# -------------------------------- -# how to determine the name of the shared library -# associated with a specific link library. -# -- PORTME fill in with the dynamic library characteristics -m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], -[m4_require([_LT_DECL_EGREP]) -m4_require([_LT_DECL_OBJDUMP]) -m4_require([_LT_DECL_DLLTOOL]) -AC_CACHE_CHECK([how to associate runtime and link libraries], -lt_cv_sharedlib_from_linklib_cmd, -[lt_cv_sharedlib_from_linklib_cmd='unknown' - -case $host_os in -cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh; - # decide which one to use based on capabilities of $DLLTOOL - case `$DLLTOOL --help 2>&1` in - *--identify-strict*) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib - ;; - *) - lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback - ;; - esac - ;; -*) - # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd=$ECHO - ;; -esac -]) -sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd -test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO - -_LT_DECL([], [sharedlib_from_linklib_cmd], [1], - [Command to associate shared and link libraries]) -])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB - - -# _LT_PATH_MANIFEST_TOOL -# ---------------------- -# locate the manifest tool -m4_defun([_LT_PATH_MANIFEST_TOOL], -[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) -test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], - [lt_cv_path_mainfest_tool=no - echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD - $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out - cat conftest.err >&AS_MESSAGE_LOG_FD - if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes - fi - rm -f conftest*]) -if test yes != "$lt_cv_path_mainfest_tool"; then - MANIFEST_TOOL=: -fi -_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl -])# _LT_PATH_MANIFEST_TOOL - - -# _LT_DLL_DEF_P([FILE]) -# --------------------- -# True iff FILE is a Windows DLL '.def' file. -# Keep in sync with func_dll_def_p in the libtool script -AC_DEFUN([_LT_DLL_DEF_P], -[dnl - test DEF = "`$SED -n dnl - -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace - -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments - -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl - -e q dnl Only consider the first "real" line - $1`" dnl -])# _LT_DLL_DEF_P - - -# LT_LIB_M -# -------- -# check for math library -AC_DEFUN([LT_LIB_M], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM=-lm) - ;; -esac -AC_SUBST([LIBM]) -])# LT_LIB_M - -# Old name: -AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_CHECK_LIBM], []) - - -# _LT_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------- -m4_defun([_LT_COMPILER_NO_RTTI], -[m4_require([_LT_TAG_COMPILER])dnl - -_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test yes = "$GCC"; then - case $cc_basename in - nvcc*) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; - *) - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; - esac - - _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], - [Compiler flag to turn off builtin functions]) -])# _LT_COMPILER_NO_RTTI - - -# _LT_CMD_GLOBAL_SYMBOLS -# ---------------------- -m4_defun([_LT_CMD_GLOBAL_SYMBOLS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([LT_PATH_NM])dnl -AC_REQUIRE([LT_PATH_LD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_TAG_COMPILER])dnl - -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) - if test ia64 = "$host_cpu"; then - symcode='[[ABCDEGRST]]' - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris*) - symcode='[[BDRT]]' - ;; -sco3.2v5*) - symcode='[[DT]]' - ;; -sysv4.2uw2*) - symcode='[[DT]]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[[ABDT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Gets list of data symbols to import. - lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" - # Adjust the below global symbol transforms to fixup imported variables. - lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" - lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" - lt_c_name_lib_hook="\ - -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ - -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" -else - # Disable hooks by default. - lt_cv_sys_global_symbol_to_import= - lt_cdecl_hook= - lt_c_name_hook= - lt_c_name_lib_hook= -fi - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ -$lt_cdecl_hook\ -" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ -$lt_c_name_hook\ -" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" - -# Transform an extracted symbol line into symbol name with lib prefix and -# symbol address. -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ -$lt_c_name_lib_hook\ -" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ -" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ -" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function, - # D for any global variable and I for any imported variable. - # Also find C++ and __fastcall symbols from MSVC++ or ICC, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK ['"\ -" {last_section=section; section=\$ 3};"\ -" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ -" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ -" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ -" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ -" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx]" - else - lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE -/* DATA imports from DLLs on WIN32 can't be const, because runtime - relocations are performed -- see ld's documentation on pseudo-relocs. */ -# define LT@&t@_DLSYM_CONST -#elif defined __osf__ -/* This system does not cope well with relocations in const data. */ -# define LT@&t@_DLSYM_CONST -#else -# define LT@&t@_DLSYM_CONST const -#endif - -#ifdef __cplusplus -extern "C" { -#endif - -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' - - cat <<_LT_EOF >> conftest.$ac_ext - -/* The mapping between symbol names and symbols. */ -LT@&t@_DLSYM_CONST struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[[]] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_globsym_save_LIBS=$LIBS - lt_globsym_save_CFLAGS=$CFLAGS - LIBS=conftstm.$ac_objext - CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then - pipe_works=yes - fi - LIBS=$lt_globsym_save_LIBS - CFLAGS=$lt_globsym_save_CFLAGS - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test yes = "$pipe_works"; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi - -# Response file support. -if test "$lt_cv_nm_interface" = "MS dumpbin"; then - nm_file_list_spec='@' -elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then - nm_file_list_spec='@' -fi - -_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], - [Take the output of nm and produce a listing of raw symbols and C names]) -_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], - [Transform the output of nm in a proper C declaration]) -_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], - [Transform the output of nm into a list of symbols to manually relocate]) -_LT_DECL([global_symbol_to_c_name_address], - [lt_cv_sys_global_symbol_to_c_name_address], [1], - [Transform the output of nm in a C name address pair]) -_LT_DECL([global_symbol_to_c_name_address_lib_prefix], - [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], - [Transform the output of nm in a C name address pair when lib prefix is needed]) -_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], - [The name lister interface]) -_LT_DECL([], [nm_file_list_spec], [1], - [Specify filename containing input files for $NM]) -]) # _LT_CMD_GLOBAL_SYMBOLS - - -# _LT_COMPILER_PIC([TAGNAME]) -# --------------------------- -m4_defun([_LT_COMPILER_PIC], -[m4_require([_LT_TAG_COMPILER])dnl -_LT_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_TAGVAR(lt_prog_compiler_static, $1)= - -m4_if([$1], [CXX], [ - # C++ specific cases for pic, static, wl, etc. - if test yes = "$GXX"; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the '-m68020' flag to GCC prevents building anything better, - # like '-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - case $host_os in - os2*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' - ;; - esac - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix[[4-9]]*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly* | midnightbsd*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' - if test ia64 != "$host_cpu"; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64, which still supported -KPIC. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) - # IBM XL 8.0, 9.0 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test yes = "$GCC"; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the '-m68020' flag to GCC prevents building anything better, - # like '-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; - - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - case $host_os in - os2*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' - ;; - esac - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - haiku*) - # PIC is the default for Haiku. - # The "-static" flag exists, but is broken. - _LT_TAGVAR(lt_prog_compiler_static, $1)= - ;; - - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - - case $cc_basename in - nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' - if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" - fi - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test ia64 = "$host_cpu"; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - case $cc_basename in - nagfor*) - # NAG Fortran compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - case $host_os in - os2*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' - ;; - esac - ;; - - hpux9* | hpux10* | hpux11*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - # old Intel for x86_64, which still supported -KPIC. - ecc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' - _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' - ;; - nagfor*) - # NAG Fortran compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - tcc*) - # Fabrice Bellard et al's Tiny C Compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xl* | bgxl* | bgf* | mpixl*) - # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='' - ;; - *Sun\ F* | *Sun*Fortran*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - *Sun\ C*) - # Sun C 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - *Intel*\ [[CF]]*Compiler*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - *Portland\ Group*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - esac - ;; - - newsos6) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - - osf3* | osf4* | osf5*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - rdos*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - solaris*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - unicos*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -case $host_os in - # For platforms that do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" - ;; -esac - -AC_CACHE_CHECK([for $compiler option to produce PIC], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) -_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], - [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], - [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], - [Additional compiler flags for building library objects]) - -_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], - [How to pass a linker flag through the compiler]) -# -# Check to make sure the static flag actually works. -# -wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" -_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], - _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), - $lt_tmp_static_flag, - [], - [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) -_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], - [Compiler flag to prevent dynamic linking]) -])# _LT_COMPILER_PIC - - -# _LT_LINKER_SHLIBS([TAGNAME]) -# ---------------------------- -# See if the linker supports building shared libraries. -m4_defun([_LT_LINKER_SHLIBS], -[AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -m4_if([$1], [CXX], [ - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - case $host_os in - aix[[4-9]]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to GNU nm, but means don't demangle to AIX nm. - # Without the "-l" option, or with the "-B" option, AIX nm treats - # weak defined symbols like other global defined symbols, whereas - # GNU nm marks them as "W". - # While the 'weak' keyword is ignored in the Export File, we need - # it in the Import File for the 'aix-soname' feature, so we have - # to replace the "-B" option with "-P" for AIX nm. - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' - else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds - ;; - cygwin* | mingw* | cegcc*) - case $cc_basename in - cl* | icl*) - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - ;; - *) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - ;; - esac - ;; - *) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -], [ - runpath_var= - _LT_TAGVAR(allow_undefined_flag, $1)= - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(archive_cmds, $1)= - _LT_TAGVAR(archive_expsym_cmds, $1)= - _LT_TAGVAR(compiler_needs_object, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(hardcode_automatic, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(hardcode_libdir_separator, $1)= - _LT_TAGVAR(hardcode_minus_L, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_TAGVAR(inherit_rpath, $1)=no - _LT_TAGVAR(link_all_deplibs, $1)=unknown - _LT_TAGVAR(module_cmds, $1)= - _LT_TAGVAR(module_expsym_cmds, $1)= - _LT_TAGVAR(old_archive_from_new_cmds, $1)= - _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_TAGVAR(thread_safe_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ' (' and ')$', so one must not match beginning or - # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', - # as well as any symbol that contains 'd'. - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. -dnl Note also adjust exclude_expsyms for C++ above. - extract_expsyms_cmds= - - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++ or Intel C++ Compiler. - if test yes != "$GCC"; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) - with_gnu_ld=yes - ;; - openbsd* | bitrig*) - with_gnu_ld=no - ;; - esac - - _LT_TAGVAR(ld_shlibs, $1)=yes - - # On some targets, GNU ld is compatible enough with the native linker - # that we're better off using the native interface for both. - lt_use_gnu_ld_interface=no - if test yes = "$with_gnu_ld"; then - case $host_os in - aix*) - # The AIX port of GNU ld has always aspired to compatibility - # with the native linker. However, as the warning in the GNU ld - # block says, versions before 2.19.5* couldn't really create working - # shared libraries, regardless of the interface used. - case `$LD -v 2>&1` in - *\ \(GNU\ Binutils\)\ 2.19.5*) ;; - *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; - *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - ;; - *) - lt_use_gnu_ld_interface=yes - ;; - esac - fi - - if test yes = "$lt_use_gnu_ld_interface"; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='$wl' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in - *GNU\ gold*) supports_anon_versioning=yes ;; - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[[3-9]]*) - # On AIX/PPC, the GNU linker is very broken - if test ia64 != "$host_cpu"; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.19, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to install binutils -*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. -*** You will then need to restart the configuration process. - -_LT_EOF - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file, use it as - # is; otherwise, prepend EXPORTS... - _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - shrext_cmds=.dll - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) - tmp_diet=no - if test linux-dietlibc = "$host_os"; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test no = "$tmp_diet" - then - tmp_addflag=' $pic_flag' - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95* | pgfortran*) - # Portland Group f77 and f90 compilers - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - _LT_TAGVAR(whole_archive_flag_spec, $1)= - tmp_sharedflag='--shared' ;; - nagfor*) # NAGFOR 5.3 - tmp_sharedflag='-Wl,-shared' ;; - xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - _LT_TAGVAR(compiler_needs_object, $1)=yes - ;; - esac - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) # Sun C 5.9 - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - _LT_TAGVAR(compiler_needs_object, $1)=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - - if test yes = "$supports_anon_versioning"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' - fi - - case $cc_basename in - tcc*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' - ;; - xlf* | bgf* | bgxlf* | mpixlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test yes = "$supports_anon_versioning"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - sunos4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then - runpath_var= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix[[4-9]]*) - if test ia64 = "$host_cpu"; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag= - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to GNU nm, but means don't demangle to AIX nm. - # Without the "-l" option, or with the "-B" option, AIX nm treats - # weak defined symbols like other global defined symbols, whereas - # GNU nm marks them as "W". - # While the 'weak' keyword is ignored in the Export File, we need - # it in the Import File for the 'aix-soname' feature, so we have - # to replace the "-B" option with "-P" for AIX nm. - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' - else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # have runtime linking enabled, and use it for executables. - # For shared libraries, we enable/disable runtime linking - # depending on the kind of the shared library created - - # when "with_aix_soname,aix_use_runtimelinking" is: - # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables - # "aix,yes" lib.so shared, rtl:yes, for executables - # lib.a static archive - # "both,no" lib.so.V(shr.o) shared, rtl:yes - # lib.a(lib.so.V) shared, rtl:no, for executables - # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a(lib.so.V) shared, rtl:no - # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a static archive - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then - aix_use_runtimelinking=yes - break - fi - done - if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then - # With aix-soname=svr4, we create the lib.so.V shared archives only, - # so we don't have lib.a shared libs to link our executables. - # We have to force runtime linking in this case. - aix_use_runtimelinking=yes - LDFLAGS="$LDFLAGS -Wl,-brtl" - fi - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='$wl-f,' - case $with_aix_soname,$aix_use_runtimelinking in - aix,*) ;; # traditional, no import file - svr4,* | *,yes) # use import file - # The Import File defines what to hardcode. - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - ;; - esac - - if test yes = "$GCC"; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`$CC -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test yes = "$aix_use_runtimelinking"; then - shared_flag="$shared_flag "'$wl-G' - fi - # Need to ensure runtime linking is disabled for the traditional - # shared library, or the linker may eventually find shared libraries - # /with/ Import File - we do not want to mix them. - shared_flag_aix='-shared' - shared_flag_svr4='-shared $wl-G' - else - # not using gcc - if test ia64 = "$host_cpu"; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test yes = "$aix_use_runtimelinking"; then - shared_flag='$wl-G' - else - shared_flag='$wl-bM:SRE' - fi - shared_flag_aix='$wl-bM:SRE' - shared_flag_svr4='$wl-G' - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag - else - if test ia64 = "$host_cpu"; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' - if test yes = "$with_gnu_ld"; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' - # -brtl affects multiple linker settings, -berok does not and is overridden later - compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' - if test svr4 != "$with_aix_soname"; then - # This is similar to how AIX traditionally builds its shared libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' - fi - if test aix != "$with_aix_soname"; then - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' - else - # used by -dlpreopen to get the symbols - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' - fi - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - ;; - - bsdi[[45]]*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++ or Intel C++ Compiler. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - case $cc_basename in - cl* | icl*) - # Native MSVC or ICC - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then - cp "$export_symbols" "$output_objdir/$soname.def"; - echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; - else - $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile=$lt_outputfile.exe - lt_tool_outputfile=$lt_tool_outputfile.exe - ;; - esac~ - if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # Assume MSVC and ICC wrapper - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - esac - ;; - - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2.*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly* | midnightbsd*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test yes = "$GCC"; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - else - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - ;; - - hpux10*) - if test yes,no = "$GCC,$with_gnu_ld"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test no = "$with_gnu_ld"; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - fi - ;; - - hpux11*) - if test yes,no = "$GCC,$with_gnu_ld"; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - m4_if($1, [], [ - # Older versions of the 11.00 compiler do not understand -b yet - # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - _LT_LINKER_OPTION([if $CC understands -b], - _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], - [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) - ;; - esac - fi - if test no = "$with_gnu_ld"; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test yes = "$GCC"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - # This should be the same for all languages, so no per-tag cache variable. - AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], - [lt_cv_irix_exported_symbol], - [save_LDFLAGS=$LDFLAGS - LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" - AC_LINK_IFELSE( - [AC_LANG_SOURCE( - [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], - [C++], [[int foo (void) { return 0; }]], - [Fortran 77], [[ - subroutine foo - end]], - [Fortran], [[ - subroutine foo - end]])])], - [lt_cv_irix_exported_symbol=yes], - [lt_cv_irix_exported_symbol=no]) - LDFLAGS=$save_LDFLAGS]) - if test yes = "$lt_cv_irix_exported_symbol"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' - fi - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - linux*) - case $cc_basename in - tcc*) - # Fabrice Bellard et al's Tiny C Compiler - _LT_TAGVAR(ld_shlibs, $1)=yes - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *nto* | *qnx*) - ;; - - openbsd* | bitrig*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - fi - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - shrext_cmds=.dll - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - ;; - - osf3*) - if test yes = "$GCC"; then - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test yes = "$GCC"; then - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' - - # Both c and cxx compiler support -rpath directly - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - solaris*) - _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test yes = "$GCC"; then - wlarc='$wl' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='$wl' - _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands '-z linker_flag'. GCC discards it without '$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test yes = "$GCC"; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - fi - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test sequent = "$host_vendor"; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_TAGVAR(ld_shlibs, $1)=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - if test yes = "$GCC"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We CANNOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' - runpath_var='LD_RUN_PATH' - - if test yes = "$GCC"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - uts4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - if test sni = "$host_vendor"; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' - ;; - esac - fi - fi -]) -AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no - -_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld - -_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl -_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl -_LT_DECL([], [extract_expsyms_cmds], [2], - [The commands to extract the exported symbol list from a shared archive]) - -# -# Do we need to explicitly link libc? -# -case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - - if test yes,yes = "$GCC,$enable_shared"; then - case $_LT_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_CACHE_CHECK([whether -lc should be explicitly linked in], - [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), - [$RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) - pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) - _LT_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) - then - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no - else - lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - ]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) - ;; - esac - fi - ;; -esac - -_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], - [Whether or not to add -lc for building shared libraries]) -_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], - [enable_shared_with_static_runtimes], [0], - [Whether or not to disallow shared libs when runtime libs are static]) -_LT_TAGDECL([], [export_dynamic_flag_spec], [1], - [Compiler flag to allow reflexive dlopens]) -_LT_TAGDECL([], [whole_archive_flag_spec], [1], - [Compiler flag to generate shared objects directly from archives]) -_LT_TAGDECL([], [compiler_needs_object], [1], - [Whether the compiler copes with passing no objects directly]) -_LT_TAGDECL([], [old_archive_from_new_cmds], [2], - [Create an old-style archive from a shared archive]) -_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], - [Create a temporary old-style archive to link instead of a shared archive]) -_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) -_LT_TAGDECL([], [archive_expsym_cmds], [2]) -_LT_TAGDECL([], [module_cmds], [2], - [Commands used to build a loadable module if different from building - a shared archive.]) -_LT_TAGDECL([], [module_expsym_cmds], [2]) -_LT_TAGDECL([], [with_gnu_ld], [1], - [Whether we are building with GNU ld or not]) -_LT_TAGDECL([], [allow_undefined_flag], [1], - [Flag that allows shared libraries with undefined symbols to be built]) -_LT_TAGDECL([], [no_undefined_flag], [1], - [Flag that enforces no undefined symbols]) -_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], - [Flag to hardcode $libdir into a binary during linking. - This must work even if $libdir does not exist]) -_LT_TAGDECL([], [hardcode_libdir_separator], [1], - [Whether we need a single "-rpath" flag with a separated argument]) -_LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes - DIR into the resulting binary]) -_LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes - DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting $shlibpath_var if the - library is relocated]) -_LT_TAGDECL([], [hardcode_minus_L], [0], - [Set to "yes" if using the -LDIR flag during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_shlibpath_var], [0], - [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_automatic], [0], - [Set to "yes" if building a shared library automatically hardcodes DIR - into the library and all subsequent libraries and executables linked - against it]) -_LT_TAGDECL([], [inherit_rpath], [0], - [Set to yes if linker adds runtime paths of dependent libraries - to runtime path list]) -_LT_TAGDECL([], [link_all_deplibs], [0], - [Whether libtool must link a program against all its dependency libraries]) -_LT_TAGDECL([], [always_export_symbols], [0], - [Set to "yes" if exported symbols are required]) -_LT_TAGDECL([], [export_symbols_cmds], [2], - [The commands to list exported symbols]) -_LT_TAGDECL([], [exclude_expsyms], [1], - [Symbols that should not be listed in the preloaded symbols]) -_LT_TAGDECL([], [include_expsyms], [1], - [Symbols that must always be exported]) -_LT_TAGDECL([], [prelink_cmds], [2], - [Commands necessary for linking programs (against libraries) with templates]) -_LT_TAGDECL([], [postlink_cmds], [2], - [Commands necessary for finishing linking programs]) -_LT_TAGDECL([], [file_list_spec], [1], - [Specify filename containing input files]) -dnl FIXME: Not yet implemented -dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], -dnl [Compiler flag to generate thread safe objects]) -])# _LT_LINKER_SHLIBS - - -# _LT_LANG_C_CONFIG([TAG]) -# ------------------------ -# Ensure that the configuration variables for a C compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_C_CONFIG], -[m4_require([_LT_DECL_EGREP])dnl -lt_save_CC=$CC -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - -_LT_TAG_COMPILER -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - LT_SYS_DLOPEN_SELF - _LT_CMD_STRIPLIB - - # Report what library types will actually be built - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test no = "$can_build_shared" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test yes = "$enable_shared" && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - - aix[[4-9]]*) - if test ia64 != "$host_cpu"; then - case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in - yes,aix,yes) ;; # shared object as lib.so file only - yes,svr4,*) ;; # shared object as lib.so archive member only - yes,*) enable_static=no ;; # shared object in lib.a archive as well - esac - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test yes = "$enable_shared" || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_CONFIG($1) -fi -AC_LANG_POP -CC=$lt_save_CC -])# _LT_LANG_C_CONFIG - - -# _LT_LANG_CXX_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a C++ compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_CXX_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_PATH_MANIFEST_TOOL])dnl -if test -n "$CXX" && ( test no != "$CXX" && - ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || - (test g++ != "$CXX"))); then - AC_PROG_CXXCPP -else - _lt_caught_CXX_error=yes -fi - -AC_LANG_PUSH(C++) -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(compiler_needs_object, $1)=no -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test yes != "$_lt_caught_CXX_error"; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_CFLAGS=$CFLAGS - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - CFLAGS=$CXXFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test yes = "$GXX"; then - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - else - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - fi - - if test yes = "$GXX"; then - # Set up default GNU C++ configuration - - LT_PATH_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test yes = "$with_gnu_ld"; then - _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='$wl' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) - _LT_TAGVAR(ld_shlibs, $1)=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aix[[4-9]]*) - if test ia64 = "$host_cpu"; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag= - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # have runtime linking enabled, and use it for executables. - # For shared libraries, we enable/disable runtime linking - # depending on the kind of the shared library created - - # when "with_aix_soname,aix_use_runtimelinking" is: - # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables - # "aix,yes" lib.so shared, rtl:yes, for executables - # lib.a static archive - # "both,no" lib.so.V(shr.o) shared, rtl:yes - # lib.a(lib.so.V) shared, rtl:no, for executables - # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a(lib.so.V) shared, rtl:no - # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables - # lib.a static archive - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then - # With aix-soname=svr4, we create the lib.so.V shared archives only, - # so we don't have lib.a shared libs to link our executables. - # We have to force runtime linking in this case. - aix_use_runtimelinking=yes - LDFLAGS="$LDFLAGS -Wl,-brtl" - fi - ;; - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='$wl-f,' - case $with_aix_soname,$aix_use_runtimelinking in - aix,*) ;; # no import file - svr4,* | *,yes) # use import file - # The Import File defines what to hardcode. - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - ;; - esac - - if test yes = "$GXX"; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`$CC -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test yes = "$aix_use_runtimelinking"; then - shared_flag=$shared_flag' $wl-G' - fi - # Need to ensure runtime linking is disabled for the traditional - # shared library, or the linker may eventually find shared libraries - # /with/ Import File - we do not want to mix them. - shared_flag_aix='-shared' - shared_flag_svr4='-shared $wl-G' - else - # not using gcc - if test ia64 = "$host_cpu"; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test yes = "$aix_use_runtimelinking"; then - shared_flag='$wl-G' - else - shared_flag='$wl-bM:SRE' - fi - shared_flag_aix='$wl-bM:SRE' - shared_flag_svr4='$wl-G' - fi - fi - - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - # The "-G" linker flag allows undefined symbols. - _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' - # Determine the default libpath from the value encoded in an empty - # executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag - else - if test ia64 = "$host_cpu"; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' - if test yes = "$with_gnu_ld"; then - # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' - else - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' - # -brtl affects multiple linker settings, -berok does not and is overridden later - compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' - if test svr4 != "$with_aix_soname"; then - # This is similar to how AIX traditionally builds its shared - # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' - fi - if test aix != "$with_aix_soname"; then - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' - else - # used by -dlpreopen to get the symbols - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' - fi - _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' - fi - fi - ;; - - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - case $GXX,$cc_basename in - ,cl* | no,cl* | ,icl* | no,icl*) - # Native MSVC or ICC - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=.dll - # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then - cp "$export_symbols" "$output_objdir/$soname.def"; - echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; - else - $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' - # The linker will not automatically build a static lib if we build a DLL. - # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - # Don't use ranlib - _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' - _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile=$lt_outputfile.exe - lt_tool_outputfile=$lt_tool_outputfile.exe - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' - ;; - *) - # g++ - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file, use it as - # is; otherwise, prepend EXPORTS... - _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - shrext_cmds=.dll - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ - $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ - $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ - $ECHO EXPORTS >> $output_objdir/$libname.def~ - prefix_cmds="$SED"~ - if test EXPORTS = "`$SED 1q $export_symbols`"; then - prefix_cmds="$prefix_cmds -e 1d"; - fi~ - prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ - cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ - $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ - emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='@' - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - freebsd2.*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - freebsd-elf*) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - - freebsd* | dragonfly* | midnightbsd*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - - hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes = "$GXX"; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - hpux10*|hpux11*) - if test no = "$with_gnu_ld"; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes = "$GXX"; then - if test no = "$with_gnu_ld"; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test yes = "$GXX"; then - if test no = "$with_gnu_ld"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' - fi - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - ;; - - linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) - _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' - _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' - _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 6 and above use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' - ;; - xl* | mpixl* | bgxl*) - # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - if test yes = "$supports_anon_versioning"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | $SED 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' - _LT_TAGVAR(compiler_needs_object, $1)=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - esac - ;; - - lynxos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - m88k*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - - *nto* | *qnx*) - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; - - openbsd* | bitrig*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' - fi - output_verbose_link_cmd=func_echo_all - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - case $host in - osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - ;; - *) - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ - $RM $lib.exp' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - ;; - *) - if test yes,no = "$GXX,$with_gnu_ld"; then - _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' - case $host in - osf3*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - solaris*) - case $cc_basename in - CC* | sunCC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands '-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='func_echo_all' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test yes,no = "$GXX,$with_gnu_ld"; then - _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - else - # g++ 2.7 appears to require '-G' NOT '-shared' on this - # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' - fi - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We CANNOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ - '"$_LT_TAGVAR(old_archive_cmds, $1)" - _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ - '"$_LT_TAGVAR(reload_cmds, $1)" - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - - AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no - - _LT_TAGVAR(GCC, $1)=$GXX - _LT_TAGVAR(LD, $1)=$LD - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test yes != "$_lt_caught_CXX_error" - -AC_LANG_POP -])# _LT_LANG_CXX_CONFIG - - -# _LT_FUNC_STRIPNAME_CNF -# ---------------------- -# func_stripname_cnf prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# -# This function is identical to the (non-XSI) version of func_stripname, -# except this one can be used by m4 code that may be executed by configure, -# rather than the libtool script. -m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl -AC_REQUIRE([_LT_DECL_SED]) -AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) -func_stripname_cnf () -{ - case @S|@2 in - .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; - *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; - esac -} # func_stripname_cnf -])# _LT_FUNC_STRIPNAME_CNF - - -# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) -# --------------------------------- -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -m4_defun([_LT_SYS_HIDDEN_LIBDEPS], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl -# Dependencies to place before and after the object being linked: -_LT_TAGVAR(predep_objects, $1)= -_LT_TAGVAR(postdep_objects, $1)= -_LT_TAGVAR(predeps, $1)= -_LT_TAGVAR(postdeps, $1)= -_LT_TAGVAR(compiler_lib_search_path, $1)= - -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF -int a; -void foo (void) { a = 0; } -_LT_EOF -], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -_LT_EOF -], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer*4 a - a=0 - return - end -_LT_EOF -], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer a - a=0 - return - end -_LT_EOF -], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF -public class foo { - private int a; - public void bar (void) { - a = 0; - } -}; -_LT_EOF -], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF -package foo -func foo() { -} -_LT_EOF -]) - -_lt_libdeps_save_CFLAGS=$CFLAGS -case "$CC $CFLAGS " in #( -*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; -*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; -*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; -esac - -dnl Parse the compiler output and extract the necessary -dnl objects, libraries and library flags. -if AC_TRY_EVAL(ac_compile); then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - for p in `eval "$output_verbose_link_cmd"`; do - case $prev$p in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test x-L = "$p" || - test x-R = "$p"; then - prev=$p - continue - fi - - # Expand the sysroot to ease extracting the directories later. - if test -z "$prev"; then - case $p in - -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; - -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; - -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; - esac - fi - case $p in - =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; - esac - if test no = "$pre_test_object_deps_done"; then - case $prev in - -L | -R) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p - else - _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$_LT_TAGVAR(postdeps, $1)"; then - _LT_TAGVAR(postdeps, $1)=$prev$p - else - _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" - fi - fi - prev= - ;; - - *.lto.$objext) ;; # Ignore GCC LTO objects - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test no = "$pre_test_object_deps_done"; then - if test -z "$_LT_TAGVAR(predep_objects, $1)"; then - _LT_TAGVAR(predep_objects, $1)=$p - else - _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" - fi - else - if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then - _LT_TAGVAR(postdep_objects, $1)=$p - else - _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling $1 test program" -fi - -$RM -f confest.$objext -CFLAGS=$_lt_libdeps_save_CFLAGS - -# PORTME: override above test on systems where it is broken -m4_if([$1], [CXX], -[case $host_os in -interix[[3-9]]*) - # Interix 3.5 installs completely hosed .la files for C++, so rather than - # hack all around it, let's just trust "g++" to DTRT. - _LT_TAGVAR(predep_objects,$1)= - _LT_TAGVAR(postdep_objects,$1)= - _LT_TAGVAR(postdeps,$1)= - ;; -esac -]) - -case " $_LT_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; -esac - _LT_TAGVAR(compiler_lib_search_dirs, $1)= -if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` -fi -_LT_TAGDECL([], [compiler_lib_search_dirs], [1], - [The directories searched by this compiler when creating a shared library]) -_LT_TAGDECL([], [predep_objects], [1], - [Dependencies to place before and after the objects being linked to - create a shared library]) -_LT_TAGDECL([], [postdep_objects], [1]) -_LT_TAGDECL([], [predeps], [1]) -_LT_TAGDECL([], [postdeps], [1]) -_LT_TAGDECL([], [compiler_lib_search_path], [1], - [The library search path used internally by the compiler when linking - a shared library]) -])# _LT_SYS_HIDDEN_LIBDEPS - - -# _LT_LANG_F77_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a Fortran 77 compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_F77_CONFIG], -[AC_LANG_PUSH(Fortran 77) -if test -z "$F77" || test no = "$F77"; then - _lt_disable_F77=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the F77 compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test yes != "$_lt_disable_F77"; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${F77-"f77"} - CFLAGS=$FFLAGS - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - GCC=$G77 - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test no = "$can_build_shared" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test yes = "$enable_shared" && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test ia64 != "$host_cpu"; then - case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in - yes,aix,yes) ;; # shared object as lib.so file only - yes,svr4,*) ;; # shared object as lib.so archive member only - yes,*) enable_static=no ;; # shared object in lib.a archive as well - esac - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test yes = "$enable_shared" || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)=$G77 - _LT_TAGVAR(LD, $1)=$LD - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS -fi # test yes != "$_lt_disable_F77" - -AC_LANG_POP -])# _LT_LANG_F77_CONFIG - - -# _LT_LANG_FC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for a Fortran compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_FC_CONFIG], -[AC_LANG_PUSH(Fortran) - -if test -z "$FC" || test no = "$FC"; then - _lt_disable_FC=yes -fi - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for fc test sources. -ac_ext=${ac_fc_srcext-f} - -# Object file extension for compiled fc test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the FC compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test yes != "$_lt_disable_FC"; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_GCC=$GCC - lt_save_CFLAGS=$CFLAGS - CC=${FC-"f95"} - CFLAGS=$FCFLAGS - compiler=$CC - GCC=$ac_cv_fc_compiler_gnu - - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test no = "$can_build_shared" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test yes = "$enable_shared" && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test ia64 != "$host_cpu"; then - case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in - yes,aix,yes) ;; # shared object as lib.so file only - yes,svr4,*) ;; # shared object as lib.so archive member only - yes,*) enable_static=no ;; # shared object in lib.a archive as well - esac - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test yes = "$enable_shared" || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu - _LT_TAGVAR(LD, $1)=$LD - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC=$lt_save_CC - CFLAGS=$lt_save_CFLAGS -fi # test yes != "$_lt_disable_FC" - -AC_LANG_POP -])# _LT_LANG_FC_CONFIG - - -# _LT_LANG_GCJ_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Java Compiler compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_GCJ_CONFIG], -[AC_REQUIRE([LT_PROG_GCJ])dnl -AC_LANG_SAVE - -# Source file extension for Java test sources. -ac_ext=java - -# Object file extension for compiled Java test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}" - -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GCJ-"gcj"} -CFLAGS=$GCJFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)=$LD -_LT_CC_BASENAME([$compiler]) - -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GCJ_CONFIG - - -# _LT_LANG_GO_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Go compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_GO_CONFIG], -[AC_REQUIRE([LT_PROG_GO])dnl -AC_LANG_SAVE - -# Source file extension for Go test sources. -ac_ext=go - -# Object file extension for compiled Go test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="package main; func main() { }" - -# Code to be used in simple link tests -lt_simple_link_test_code='package main; func main() { }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC=yes -CC=${GOC-"gccgo"} -CFLAGS=$GOFLAGS -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)=$LD -_LT_CC_BASENAME([$compiler]) - -# Go did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(reload_flag, $1)=$reload_flag -_LT_TAGVAR(reload_cmds, $1)=$reload_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) -fi - -AC_LANG_RESTORE - -GCC=$lt_save_GCC -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_GO_CONFIG - - -# _LT_LANG_RC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for the Windows resource compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to 'libtool'. -m4_defun([_LT_LANG_RC_CONFIG], -[AC_REQUIRE([LT_PROG_RC])dnl -AC_LANG_SAVE - -# Source file extension for RC test sources. -ac_ext=rc - -# Object file extension for compiled RC test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' - -# Code to be used in simple link tests -lt_simple_link_test_code=$lt_simple_compile_test_code - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_CFLAGS=$CFLAGS -lt_save_GCC=$GCC -GCC= -CC=${RC-"windres"} -CFLAGS= -compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) -_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -if test -n "$compiler"; then - : - _LT_CONFIG($1) -fi - -GCC=$lt_save_GCC -AC_LANG_RESTORE -CC=$lt_save_CC -CFLAGS=$lt_save_CFLAGS -])# _LT_LANG_RC_CONFIG - - -# LT_PROG_GCJ -# ----------- -AC_DEFUN([LT_PROG_GCJ], -[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], - [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], - [AC_CHECK_TOOL(GCJ, gcj,) - test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS)])])[]dnl -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_GCJ], []) - - -# LT_PROG_GO -# ---------- -AC_DEFUN([LT_PROG_GO], -[AC_CHECK_TOOL(GOC, gccgo,) -]) - - -# LT_PROG_RC -# ---------- -AC_DEFUN([LT_PROG_RC], -[AC_CHECK_TOOL(RC, windres,) -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_RC], []) - - -# _LT_DECL_EGREP -# -------------- -# If we don't have a new enough Autoconf to choose the best grep -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_EGREP], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_REQUIRE([AC_PROG_FGREP])dnl -test -z "$GREP" && GREP=grep -_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) -_LT_DECL([], [EGREP], [1], [An ERE matcher]) -_LT_DECL([], [FGREP], [1], [A literal string matcher]) -dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too -AC_SUBST([GREP]) -]) - - -# _LT_DECL_OBJDUMP -# -------------- -# If we don't have a new enough Autoconf to choose the best objdump -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_OBJDUMP], -[AC_CHECK_TOOL(OBJDUMP, objdump, false) -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) -AC_SUBST([OBJDUMP]) -]) - -# _LT_DECL_DLLTOOL -# ---------------- -# Ensure DLLTOOL variable is set. -m4_defun([_LT_DECL_DLLTOOL], -[AC_CHECK_TOOL(DLLTOOL, dlltool, false) -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) -AC_SUBST([DLLTOOL]) -]) - -# _LT_DECL_FILECMD -# ---------------- -# Check for a file(cmd) program that can be used to detect file type and magic -m4_defun([_LT_DECL_FILECMD], -[AC_CHECK_TOOL([FILECMD], [file], [:]) -_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) -])# _LD_DECL_FILECMD - -# _LT_DECL_SED -# ------------ -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -m4_defun([_LT_DECL_SED], -[AC_PROG_SED -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" -_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) -_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], - [Sed that helps us avoid accidentally triggering echo(1) options like -n]) -])# _LT_DECL_SED - -m4_ifndef([AC_PROG_SED], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ - -m4_defun([AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f "$lt_ac_sed" && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test 10 -lt "$lt_ac_count" && break - lt_ac_count=`expr $lt_ac_count + 1` - if test "$lt_ac_count" -gt "$lt_ac_max"; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -])#AC_PROG_SED -])#m4_ifndef - -# Old name: -AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_SED], []) - - -# _LT_CHECK_SHELL_FEATURES -# ------------------------ -# Find out whether the shell is Bourne or XSI compatible, -# or has some other useful features. -m4_defun([_LT_CHECK_SHELL_FEATURES], -[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi -_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac -_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl -_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl -])# _LT_CHECK_SHELL_FEATURES - - -# _LT_PATH_CONVERSION_FUNCTIONS -# ----------------------------- -# Determine what file name conversion functions should be used by -# func_to_host_file (and, implicitly, by func_to_host_path). These are needed -# for certain cross-compile configurations and native mingw. -m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_MSG_CHECKING([how to convert $build file names to $host format]) -AC_CACHE_VAL(lt_cv_to_host_file_cmd, -[case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 - ;; - esac - ;; - *-*-cygwin* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin - ;; - *-*-cygwin* ) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; - * ) # otherwise, assume *nix - lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin - ;; - esac - ;; - * ) # unhandled hosts (and "normal" native builds) - lt_cv_to_host_file_cmd=func_convert_file_noop - ;; -esac -]) -to_host_file_cmd=$lt_cv_to_host_file_cmd -AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) -_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], - [0], [convert $build file names to $host format])dnl - -AC_MSG_CHECKING([how to convert $build file names to toolchain format]) -AC_CACHE_VAL(lt_cv_to_tool_file_cmd, -[#assume ordinary cross tools, or native build. -lt_cv_to_tool_file_cmd=func_convert_file_noop -case $host in - *-*-mingw* ) - case $build in - *-*-mingw* ) # actually msys - lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 - ;; - esac - ;; -esac -]) -to_tool_file_cmd=$lt_cv_to_tool_file_cmd -AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) -_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], - [0], [convert $build files to toolchain format])dnl -])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/lib/libcgroup-3.1.0/m4/ltoptions.m4 b/lib/libcgroup-3.1.0/m4/ltoptions.m4 deleted file mode 100644 index b0b5e9c2126..00000000000 --- a/lib/libcgroup-3.1.0/m4/ltoptions.m4 +++ /dev/null @@ -1,437 +0,0 @@ -# Helper functions for option handling. -*- Autoconf -*- -# -# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free -# Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 8 ltoptions.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) - - -# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) -# ------------------------------------------ -m4_define([_LT_MANGLE_OPTION], -[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) - - -# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) -# --------------------------------------- -# Set option OPTION-NAME for macro MACRO-NAME, and if there is a -# matching handler defined, dispatch to it. Other OPTION-NAMEs are -# saved as a flag. -m4_define([_LT_SET_OPTION], -[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl -m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), - _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option '$2'])])[]dnl -]) - - -# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) -# ------------------------------------------------------------ -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -m4_define([_LT_IF_OPTION], -[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) - - -# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) -# ------------------------------------------------------- -# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME -# are set. -m4_define([_LT_UNLESS_OPTIONS], -[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), - [m4_define([$0_found])])])[]dnl -m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 -])[]dnl -]) - - -# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) -# ---------------------------------------- -# OPTION-LIST is a space-separated list of Libtool options associated -# with MACRO-NAME. If any OPTION has a matching handler declared with -# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about -# the unknown option and exit. -m4_defun([_LT_SET_OPTIONS], -[# Set options -m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [_LT_SET_OPTION([$1], _LT_Option)]) - -m4_if([$1],[LT_INIT],[ - dnl - dnl Simply set some default values (i.e off) if boolean options were not - dnl specified: - _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no - ]) - _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no - ]) - dnl - dnl If no reference was made to various pairs of opposing options, then - dnl we run the default mode handler for the pair. For example, if neither - dnl 'shared' nor 'disable-shared' was passed, we enable building of shared - dnl archives by default: - _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) - _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) - _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], - [_LT_WITH_AIX_SONAME([aix])]) - ]) -])# _LT_SET_OPTIONS - - -## --------------------------------- ## -## Macros to handle LT_INIT options. ## -## --------------------------------- ## - -# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) -# ----------------------------------------- -m4_define([_LT_MANGLE_DEFUN], -[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) - - -# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) -# ----------------------------------------------- -m4_define([LT_OPTION_DEFINE], -[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl -])# LT_OPTION_DEFINE - - -# dlopen -# ------ -LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes -]) - -AU_DEFUN([AC_LIBTOOL_DLOPEN], -[_LT_SET_OPTION([LT_INIT], [dlopen]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the 'dlopen' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) - - -# win32-dll -# --------- -# Declare package support for building win32 dll's. -LT_OPTION_DEFINE([LT_INIT], [win32-dll], -[enable_win32_dll=yes - -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; -esac - -test -z "$AS" && AS=as -_LT_DECL([], [AS], [1], [Assembler program])dnl - -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl - -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl -])# win32-dll - -AU_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -_LT_SET_OPTION([LT_INIT], [win32-dll]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the 'win32-dll' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) - - -# _LT_ENABLE_SHARED([DEFAULT]) -# ---------------------------- -# implement the --enable-shared flag, and supports the 'shared' and -# 'disable-shared' LT_INIT options. -# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. -m4_define([_LT_ENABLE_SHARED], -[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS=$lt_save_ifs - ;; - esac], - [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) - - _LT_DECL([build_libtool_libs], [enable_shared], [0], - [Whether or not to build shared libraries]) -])# _LT_ENABLE_SHARED - -LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) -]) - -AC_DEFUN([AC_DISABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], [disable-shared]) -]) - -AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_SHARED], []) -dnl AC_DEFUN([AM_DISABLE_SHARED], []) - - - -# _LT_ENABLE_STATIC([DEFAULT]) -# ---------------------------- -# implement the --enable-static flag, and support the 'static' and -# 'disable-static' LT_INIT options. -# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. -m4_define([_LT_ENABLE_STATIC], -[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([static], - [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS=$lt_save_ifs - ;; - esac], - [enable_static=]_LT_ENABLE_STATIC_DEFAULT) - - _LT_DECL([build_old_libs], [enable_static], [0], - [Whether or not to build static libraries]) -])# _LT_ENABLE_STATIC - -LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) - -# Old names: -AC_DEFUN([AC_ENABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) -]) - -AC_DEFUN([AC_DISABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], [disable-static]) -]) - -AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_STATIC], []) -dnl AC_DEFUN([AM_DISABLE_STATIC], []) - - - -# _LT_ENABLE_FAST_INSTALL([DEFAULT]) -# ---------------------------------- -# implement the --enable-fast-install flag, and support the 'fast-install' -# and 'disable-fast-install' LT_INIT options. -# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. -m4_define([_LT_ENABLE_FAST_INSTALL], -[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([fast-install], - [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for pkg in $enableval; do - IFS=$lt_save_ifs - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS=$lt_save_ifs - ;; - esac], - [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) - -_LT_DECL([fast_install], [enable_fast_install], [0], - [Whether or not to optimize for fast installation])dnl -])# _LT_ENABLE_FAST_INSTALL - -LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) - -# Old names: -AU_DEFUN([AC_ENABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the 'fast-install' option into LT_INIT's first parameter.]) -]) - -AU_DEFUN([AC_DISABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the 'disable-fast-install' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) -dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) - - -# _LT_WITH_AIX_SONAME([DEFAULT]) -# ---------------------------------- -# implement the --with-aix-soname flag, and support the `aix-soname=aix' -# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT -# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. -m4_define([_LT_WITH_AIX_SONAME], -[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl -shared_archive_member_spec= -case $host,$enable_shared in -power*-*-aix[[5-9]]*,yes) - AC_MSG_CHECKING([which variant of shared library versioning to provide]) - AC_ARG_WITH([aix-soname], - [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], - [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], - [case $withval in - aix|svr4|both) - ;; - *) - AC_MSG_ERROR([Unknown argument to --with-aix-soname]) - ;; - esac - lt_cv_with_aix_soname=$with_aix_soname], - [AC_CACHE_VAL([lt_cv_with_aix_soname], - [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) - with_aix_soname=$lt_cv_with_aix_soname]) - AC_MSG_RESULT([$with_aix_soname]) - if test aix != "$with_aix_soname"; then - # For the AIX way of multilib, we name the shared archive member - # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', - # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. - # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, - # the AIX toolchain works better with OBJECT_MODE set (default 32). - if test 64 = "${OBJECT_MODE-32}"; then - shared_archive_member_spec=shr_64 - else - shared_archive_member_spec=shr - fi - fi - ;; -*) - with_aix_soname=aix - ;; -esac - -_LT_DECL([], [shared_archive_member_spec], [0], - [Shared archive member basename, for filename based shared library versioning on AIX])dnl -])# _LT_WITH_AIX_SONAME - -LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) -LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) -LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) - - -# _LT_WITH_PIC([MODE]) -# -------------------- -# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' -# LT_INIT options. -# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. -m4_define([_LT_WITH_PIC], -[AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for lt_pkg in $withval; do - IFS=$lt_save_ifs - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS=$lt_save_ifs - ;; - esac], - [pic_mode=m4_default([$1], [default])]) - -_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl -])# _LT_WITH_PIC - -LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) - -# Old name: -AU_DEFUN([AC_LIBTOOL_PICMODE], -[_LT_SET_OPTION([LT_INIT], [pic-only]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the 'pic-only' option into LT_INIT's first parameter.]) -]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) - -## ----------------- ## -## LTDL_INIT Options ## -## ----------------- ## - -m4_define([_LTDL_MODE], []) -LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], - [m4_define([_LTDL_MODE], [nonrecursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [recursive], - [m4_define([_LTDL_MODE], [recursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [subproject], - [m4_define([_LTDL_MODE], [subproject])]) - -m4_define([_LTDL_TYPE], []) -LT_OPTION_DEFINE([LTDL_INIT], [installable], - [m4_define([_LTDL_TYPE], [installable])]) -LT_OPTION_DEFINE([LTDL_INIT], [convenience], - [m4_define([_LTDL_TYPE], [convenience])]) diff --git a/lib/libcgroup-3.1.0/m4/ltsugar.m4 b/lib/libcgroup-3.1.0/m4/ltsugar.m4 deleted file mode 100644 index 902508bd93a..00000000000 --- a/lib/libcgroup-3.1.0/m4/ltsugar.m4 +++ /dev/null @@ -1,124 +0,0 @@ -# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- -# -# Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software -# Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 6 ltsugar.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) - - -# lt_join(SEP, ARG1, [ARG2...]) -# ----------------------------- -# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their -# associated separator. -# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier -# versions in m4sugar had bugs. -m4_define([lt_join], -[m4_if([$#], [1], [], - [$#], [2], [[$2]], - [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) -m4_define([_lt_join], -[m4_if([$#$2], [2], [], - [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) - - -# lt_car(LIST) -# lt_cdr(LIST) -# ------------ -# Manipulate m4 lists. -# These macros are necessary as long as will still need to support -# Autoconf-2.59, which quotes differently. -m4_define([lt_car], [[$1]]) -m4_define([lt_cdr], -[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], - [$#], 1, [], - [m4_dquote(m4_shift($@))])]) -m4_define([lt_unquote], $1) - - -# lt_append(MACRO-NAME, STRING, [SEPARATOR]) -# ------------------------------------------ -# Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. -# Note that neither SEPARATOR nor STRING are expanded; they are appended -# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). -# No SEPARATOR is output if MACRO-NAME was previously undefined (different -# than defined and empty). -# -# This macro is needed until we can rely on Autoconf 2.62, since earlier -# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. -m4_define([lt_append], -[m4_define([$1], - m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) - - - -# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) -# ---------------------------------------------------------- -# Produce a SEP delimited list of all paired combinations of elements of -# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list -# has the form PREFIXmINFIXSUFFIXn. -# Needed until we can rely on m4_combine added in Autoconf 2.62. -m4_define([lt_combine], -[m4_if(m4_eval([$# > 3]), [1], - [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl -[[m4_foreach([_Lt_prefix], [$2], - [m4_foreach([_Lt_suffix], - ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, - [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) - - -# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) -# ----------------------------------------------------------------------- -# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited -# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. -m4_define([lt_if_append_uniq], -[m4_ifdef([$1], - [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], - [lt_append([$1], [$2], [$3])$4], - [$5])], - [lt_append([$1], [$2], [$3])$4])]) - - -# lt_dict_add(DICT, KEY, VALUE) -# ----------------------------- -m4_define([lt_dict_add], -[m4_define([$1($2)], [$3])]) - - -# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) -# -------------------------------------------- -m4_define([lt_dict_add_subkey], -[m4_define([$1($2:$3)], [$4])]) - - -# lt_dict_fetch(DICT, KEY, [SUBKEY]) -# ---------------------------------- -m4_define([lt_dict_fetch], -[m4_ifval([$3], - m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), - m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) - - -# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) -# ----------------------------------------------------------------- -m4_define([lt_if_dict_fetch], -[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], - [$5], - [$6])]) - - -# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) -# -------------------------------------------------------------- -m4_define([lt_dict_filter], -[m4_if([$5], [], [], - [lt_join(m4_quote(m4_default([$4], [[, ]])), - lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), - [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl -]) diff --git a/lib/libcgroup-3.1.0/m4/ltversion.m4 b/lib/libcgroup-3.1.0/m4/ltversion.m4 deleted file mode 100644 index b155d0aceca..00000000000 --- a/lib/libcgroup-3.1.0/m4/ltversion.m4 +++ /dev/null @@ -1,24 +0,0 @@ -# ltversion.m4 -- version numbers -*- Autoconf -*- -# -# Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, -# Inc. -# Written by Scott James Remnant, 2004 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# @configure_input@ - -# serial 4245 ltversion.m4 -# This file is part of GNU Libtool - -m4_define([LT_PACKAGE_VERSION], [2.4.7]) -m4_define([LT_PACKAGE_REVISION], [2.4.7]) - -AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.7' -macro_revision='2.4.7' -_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) -_LT_DECL(, macro_revision, 0) -]) diff --git a/lib/libcgroup-3.1.0/m4/lt~obsolete.m4 b/lib/libcgroup-3.1.0/m4/lt~obsolete.m4 deleted file mode 100644 index 0f7a8759da8..00000000000 --- a/lib/libcgroup-3.1.0/m4/lt~obsolete.m4 +++ /dev/null @@ -1,99 +0,0 @@ -# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- -# -# Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free -# Software Foundation, Inc. -# Written by Scott James Remnant, 2004. -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 5 lt~obsolete.m4 - -# These exist entirely to fool aclocal when bootstrapping libtool. -# -# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), -# which have later been changed to m4_define as they aren't part of the -# exported API, or moved to Autoconf or Automake where they belong. -# -# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN -# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us -# using a macro with the same name in our local m4/libtool.m4 it'll -# pull the old libtool.m4 in (it doesn't see our shiny new m4_define -# and doesn't know about Autoconf macros at all.) -# -# So we provide this file, which has a silly filename so it's always -# included after everything else. This provides aclocal with the -# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything -# because those macros already exist, or will be overwritten later. -# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. -# -# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. -# Yes, that means every name once taken will need to remain here until -# we give up compatibility with versions before 1.7, at which point -# we need to keep only those names which we still refer to. - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) - -m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) -m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) -m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) -m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) -m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) -m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) -m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) -m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) -m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) -m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) -m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) -m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) -m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) -m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) -m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) -m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) -m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) -m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) -m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) -m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) -m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) -m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) -m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) -m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) -m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) -m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) -m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) -m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) -m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) -m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) -m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) -m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) -m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) -m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) -m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) -m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) -m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) -m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) -m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) -m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) -m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) -m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) -m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) -m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) -m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) -m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) -m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) -m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) -m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) -m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/lib/libcgroup-3.1.0/myconfigure b/lib/libcgroup-3.1.0/myconfigure deleted file mode 100755 index e84d8f60961..00000000000 --- a/lib/libcgroup-3.1.0/myconfigure +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh - -SCRIPT_DIR="$(dirname "$(readlink -f "$0")")" -cd "$SCRIPT_DIR" - -# libpam dependency for cgroup is unnecessary for our purposes. -./configure --disable-pam diff --git a/lib/libcgroup-3.1.0/samples/Makefile.am b/lib/libcgroup-3.1.0/samples/Makefile.am deleted file mode 100644 index d8374f6cc4d..00000000000 --- a/lib/libcgroup-3.1.0/samples/Makefile.am +++ /dev/null @@ -1,2 +0,0 @@ -DIST_SUBDIRS = config c python cmdline -SUBDIRS = $(DIST_SUBDIRS) diff --git a/lib/libcgroup-3.1.0/samples/Makefile.in b/lib/libcgroup-3.1.0/samples/Makefile.in deleted file mode 100644 index 23d01b25cb0..00000000000 --- a/lib/libcgroup-3.1.0/samples/Makefile.in +++ /dev/null @@ -1,653 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = samples -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir distdir-am -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -DIST_SUBDIRS = config c python cmdline -SUBDIRS = $(DIST_SUBDIRS) -all: all-recursive - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign samples/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign samples/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-recursive -all-am: Makefile -installdirs: installdirs-recursive -installdirs-am: -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-recursive - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: - -.MAKE: $(am__recursive_targets) install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - installdirs-am maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/samples/c/Makefile.am b/lib/libcgroup-3.1.0/samples/c/Makefile.am deleted file mode 100644 index 32b3e8b1cb3..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/Makefile.am +++ /dev/null @@ -1,33 +0,0 @@ -AM_CPPFLAGS = -I$(top_srcdir)/include -LDADD = $(top_builddir)/src/.libs/libcgroup.la - -if WITH_SAMPLES - -noinst_PROGRAMS = setuid walk_test read_stats walk_task get_controller \ - get_mount_point proctest get_all_controller \ - get_variable_names test_named_hierarchy \ - get_procs wrapper_test logger empty_cgroup_v2 \ - get_setup_mode - -if WITH_SYSTEMD -noinst_PROGRAMS += create_systemd_scope -endif - -setuid_SOURCES=setuid.c -walk_test_SOURCES=walk_test.c -read_stats_SOURCES=read_stats.c -walk_task_SOURCES=walk_task.c -get_controller_SOURCES=get_controller.c -get_mount_point_SOURCES=get_mount_point.c -proctest_SOURCES=proctest.c -get_all_controller_SOURCES=get_all_controller.c -get_variable_names_SOURCES=get_variable_names.c -test_named_hierarchy_SOURCES=test_named_hierarchy.c -get_procs_SOURCES=get_procs.c -wrapper_test_SOURCES=wrapper_test.c -logger_SOURCES=logger.c -empty_cgroup_v2_SOURCES=empty_cgroup_v2.c -get_setup_mode_SOURCES=get_setup_mode.c -create_systemd_scope_SOURCES=create_systemd_scope.c - -endif diff --git a/lib/libcgroup-3.1.0/samples/c/Makefile.in b/lib/libcgroup-3.1.0/samples/c/Makefile.in deleted file mode 100644 index 72c047fbad6..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/Makefile.in +++ /dev/null @@ -1,880 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -@WITH_SAMPLES_TRUE@noinst_PROGRAMS = setuid$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ walk_test$(EXEEXT) read_stats$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ walk_task$(EXEEXT) get_controller$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ get_mount_point$(EXEEXT) proctest$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ get_all_controller$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ get_variable_names$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ test_named_hierarchy$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ get_procs$(EXEEXT) wrapper_test$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ logger$(EXEEXT) empty_cgroup_v2$(EXEEXT) \ -@WITH_SAMPLES_TRUE@ get_setup_mode$(EXEEXT) $(am__EXEEXT_1) -@WITH_SAMPLES_TRUE@@WITH_SYSTEMD_TRUE@am__append_1 = create_systemd_scope -subdir = samples/c -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -@WITH_SAMPLES_TRUE@@WITH_SYSTEMD_TRUE@am__EXEEXT_1 = create_systemd_scope$(EXEEXT) -PROGRAMS = $(noinst_PROGRAMS) -am__create_systemd_scope_SOURCES_DIST = create_systemd_scope.c -@WITH_SAMPLES_TRUE@am_create_systemd_scope_OBJECTS = \ -@WITH_SAMPLES_TRUE@ create_systemd_scope.$(OBJEXT) -create_systemd_scope_OBJECTS = $(am_create_systemd_scope_OBJECTS) -create_systemd_scope_LDADD = $(LDADD) -create_systemd_scope_DEPENDENCIES = \ - $(top_builddir)/src/.libs/libcgroup.la -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -am__empty_cgroup_v2_SOURCES_DIST = empty_cgroup_v2.c -@WITH_SAMPLES_TRUE@am_empty_cgroup_v2_OBJECTS = \ -@WITH_SAMPLES_TRUE@ empty_cgroup_v2.$(OBJEXT) -empty_cgroup_v2_OBJECTS = $(am_empty_cgroup_v2_OBJECTS) -empty_cgroup_v2_LDADD = $(LDADD) -empty_cgroup_v2_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__get_all_controller_SOURCES_DIST = get_all_controller.c -@WITH_SAMPLES_TRUE@am_get_all_controller_OBJECTS = \ -@WITH_SAMPLES_TRUE@ get_all_controller.$(OBJEXT) -get_all_controller_OBJECTS = $(am_get_all_controller_OBJECTS) -get_all_controller_LDADD = $(LDADD) -get_all_controller_DEPENDENCIES = \ - $(top_builddir)/src/.libs/libcgroup.la -am__get_controller_SOURCES_DIST = get_controller.c -@WITH_SAMPLES_TRUE@am_get_controller_OBJECTS = \ -@WITH_SAMPLES_TRUE@ get_controller.$(OBJEXT) -get_controller_OBJECTS = $(am_get_controller_OBJECTS) -get_controller_LDADD = $(LDADD) -get_controller_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__get_mount_point_SOURCES_DIST = get_mount_point.c -@WITH_SAMPLES_TRUE@am_get_mount_point_OBJECTS = \ -@WITH_SAMPLES_TRUE@ get_mount_point.$(OBJEXT) -get_mount_point_OBJECTS = $(am_get_mount_point_OBJECTS) -get_mount_point_LDADD = $(LDADD) -get_mount_point_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__get_procs_SOURCES_DIST = get_procs.c -@WITH_SAMPLES_TRUE@am_get_procs_OBJECTS = get_procs.$(OBJEXT) -get_procs_OBJECTS = $(am_get_procs_OBJECTS) -get_procs_LDADD = $(LDADD) -get_procs_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__get_setup_mode_SOURCES_DIST = get_setup_mode.c -@WITH_SAMPLES_TRUE@am_get_setup_mode_OBJECTS = \ -@WITH_SAMPLES_TRUE@ get_setup_mode.$(OBJEXT) -get_setup_mode_OBJECTS = $(am_get_setup_mode_OBJECTS) -get_setup_mode_LDADD = $(LDADD) -get_setup_mode_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__get_variable_names_SOURCES_DIST = get_variable_names.c -@WITH_SAMPLES_TRUE@am_get_variable_names_OBJECTS = \ -@WITH_SAMPLES_TRUE@ get_variable_names.$(OBJEXT) -get_variable_names_OBJECTS = $(am_get_variable_names_OBJECTS) -get_variable_names_LDADD = $(LDADD) -get_variable_names_DEPENDENCIES = \ - $(top_builddir)/src/.libs/libcgroup.la -am__logger_SOURCES_DIST = logger.c -@WITH_SAMPLES_TRUE@am_logger_OBJECTS = logger.$(OBJEXT) -logger_OBJECTS = $(am_logger_OBJECTS) -logger_LDADD = $(LDADD) -logger_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__proctest_SOURCES_DIST = proctest.c -@WITH_SAMPLES_TRUE@am_proctest_OBJECTS = proctest.$(OBJEXT) -proctest_OBJECTS = $(am_proctest_OBJECTS) -proctest_LDADD = $(LDADD) -proctest_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__read_stats_SOURCES_DIST = read_stats.c -@WITH_SAMPLES_TRUE@am_read_stats_OBJECTS = read_stats.$(OBJEXT) -read_stats_OBJECTS = $(am_read_stats_OBJECTS) -read_stats_LDADD = $(LDADD) -read_stats_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__setuid_SOURCES_DIST = setuid.c -@WITH_SAMPLES_TRUE@am_setuid_OBJECTS = setuid.$(OBJEXT) -setuid_OBJECTS = $(am_setuid_OBJECTS) -setuid_LDADD = $(LDADD) -setuid_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__test_named_hierarchy_SOURCES_DIST = test_named_hierarchy.c -@WITH_SAMPLES_TRUE@am_test_named_hierarchy_OBJECTS = \ -@WITH_SAMPLES_TRUE@ test_named_hierarchy.$(OBJEXT) -test_named_hierarchy_OBJECTS = $(am_test_named_hierarchy_OBJECTS) -test_named_hierarchy_LDADD = $(LDADD) -test_named_hierarchy_DEPENDENCIES = \ - $(top_builddir)/src/.libs/libcgroup.la -am__walk_task_SOURCES_DIST = walk_task.c -@WITH_SAMPLES_TRUE@am_walk_task_OBJECTS = walk_task.$(OBJEXT) -walk_task_OBJECTS = $(am_walk_task_OBJECTS) -walk_task_LDADD = $(LDADD) -walk_task_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__walk_test_SOURCES_DIST = walk_test.c -@WITH_SAMPLES_TRUE@am_walk_test_OBJECTS = walk_test.$(OBJEXT) -walk_test_OBJECTS = $(am_walk_test_OBJECTS) -walk_test_LDADD = $(LDADD) -walk_test_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -am__wrapper_test_SOURCES_DIST = wrapper_test.c -@WITH_SAMPLES_TRUE@am_wrapper_test_OBJECTS = wrapper_test.$(OBJEXT) -wrapper_test_OBJECTS = $(am_wrapper_test_OBJECTS) -wrapper_test_LDADD = $(LDADD) -wrapper_test_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroup.la -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/create_systemd_scope.Po \ - ./$(DEPDIR)/empty_cgroup_v2.Po \ - ./$(DEPDIR)/get_all_controller.Po \ - ./$(DEPDIR)/get_controller.Po ./$(DEPDIR)/get_mount_point.Po \ - ./$(DEPDIR)/get_procs.Po ./$(DEPDIR)/get_setup_mode.Po \ - ./$(DEPDIR)/get_variable_names.Po ./$(DEPDIR)/logger.Po \ - ./$(DEPDIR)/proctest.Po ./$(DEPDIR)/read_stats.Po \ - ./$(DEPDIR)/setuid.Po ./$(DEPDIR)/test_named_hierarchy.Po \ - ./$(DEPDIR)/walk_task.Po ./$(DEPDIR)/walk_test.Po \ - ./$(DEPDIR)/wrapper_test.Po -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(create_systemd_scope_SOURCES) $(empty_cgroup_v2_SOURCES) \ - $(get_all_controller_SOURCES) $(get_controller_SOURCES) \ - $(get_mount_point_SOURCES) $(get_procs_SOURCES) \ - $(get_setup_mode_SOURCES) $(get_variable_names_SOURCES) \ - $(logger_SOURCES) $(proctest_SOURCES) $(read_stats_SOURCES) \ - $(setuid_SOURCES) $(test_named_hierarchy_SOURCES) \ - $(walk_task_SOURCES) $(walk_test_SOURCES) \ - $(wrapper_test_SOURCES) -DIST_SOURCES = $(am__create_systemd_scope_SOURCES_DIST) \ - $(am__empty_cgroup_v2_SOURCES_DIST) \ - $(am__get_all_controller_SOURCES_DIST) \ - $(am__get_controller_SOURCES_DIST) \ - $(am__get_mount_point_SOURCES_DIST) \ - $(am__get_procs_SOURCES_DIST) \ - $(am__get_setup_mode_SOURCES_DIST) \ - $(am__get_variable_names_SOURCES_DIST) \ - $(am__logger_SOURCES_DIST) $(am__proctest_SOURCES_DIST) \ - $(am__read_stats_SOURCES_DIST) $(am__setuid_SOURCES_DIST) \ - $(am__test_named_hierarchy_SOURCES_DIST) \ - $(am__walk_task_SOURCES_DIST) $(am__walk_test_SOURCES_DIST) \ - $(am__wrapper_test_SOURCES_DIST) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AM_CPPFLAGS = -I$(top_srcdir)/include -LDADD = $(top_builddir)/src/.libs/libcgroup.la -@WITH_SAMPLES_TRUE@setuid_SOURCES = setuid.c -@WITH_SAMPLES_TRUE@walk_test_SOURCES = walk_test.c -@WITH_SAMPLES_TRUE@read_stats_SOURCES = read_stats.c -@WITH_SAMPLES_TRUE@walk_task_SOURCES = walk_task.c -@WITH_SAMPLES_TRUE@get_controller_SOURCES = get_controller.c -@WITH_SAMPLES_TRUE@get_mount_point_SOURCES = get_mount_point.c -@WITH_SAMPLES_TRUE@proctest_SOURCES = proctest.c -@WITH_SAMPLES_TRUE@get_all_controller_SOURCES = get_all_controller.c -@WITH_SAMPLES_TRUE@get_variable_names_SOURCES = get_variable_names.c -@WITH_SAMPLES_TRUE@test_named_hierarchy_SOURCES = test_named_hierarchy.c -@WITH_SAMPLES_TRUE@get_procs_SOURCES = get_procs.c -@WITH_SAMPLES_TRUE@wrapper_test_SOURCES = wrapper_test.c -@WITH_SAMPLES_TRUE@logger_SOURCES = logger.c -@WITH_SAMPLES_TRUE@empty_cgroup_v2_SOURCES = empty_cgroup_v2.c -@WITH_SAMPLES_TRUE@get_setup_mode_SOURCES = get_setup_mode.c -@WITH_SAMPLES_TRUE@create_systemd_scope_SOURCES = create_systemd_scope.c -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign samples/c/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign samples/c/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -clean-noinstPROGRAMS: - @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list - -create_systemd_scope$(EXEEXT): $(create_systemd_scope_OBJECTS) $(create_systemd_scope_DEPENDENCIES) $(EXTRA_create_systemd_scope_DEPENDENCIES) - @rm -f create_systemd_scope$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(create_systemd_scope_OBJECTS) $(create_systemd_scope_LDADD) $(LIBS) - -empty_cgroup_v2$(EXEEXT): $(empty_cgroup_v2_OBJECTS) $(empty_cgroup_v2_DEPENDENCIES) $(EXTRA_empty_cgroup_v2_DEPENDENCIES) - @rm -f empty_cgroup_v2$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(empty_cgroup_v2_OBJECTS) $(empty_cgroup_v2_LDADD) $(LIBS) - -get_all_controller$(EXEEXT): $(get_all_controller_OBJECTS) $(get_all_controller_DEPENDENCIES) $(EXTRA_get_all_controller_DEPENDENCIES) - @rm -f get_all_controller$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_all_controller_OBJECTS) $(get_all_controller_LDADD) $(LIBS) - -get_controller$(EXEEXT): $(get_controller_OBJECTS) $(get_controller_DEPENDENCIES) $(EXTRA_get_controller_DEPENDENCIES) - @rm -f get_controller$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_controller_OBJECTS) $(get_controller_LDADD) $(LIBS) - -get_mount_point$(EXEEXT): $(get_mount_point_OBJECTS) $(get_mount_point_DEPENDENCIES) $(EXTRA_get_mount_point_DEPENDENCIES) - @rm -f get_mount_point$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_mount_point_OBJECTS) $(get_mount_point_LDADD) $(LIBS) - -get_procs$(EXEEXT): $(get_procs_OBJECTS) $(get_procs_DEPENDENCIES) $(EXTRA_get_procs_DEPENDENCIES) - @rm -f get_procs$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_procs_OBJECTS) $(get_procs_LDADD) $(LIBS) - -get_setup_mode$(EXEEXT): $(get_setup_mode_OBJECTS) $(get_setup_mode_DEPENDENCIES) $(EXTRA_get_setup_mode_DEPENDENCIES) - @rm -f get_setup_mode$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_setup_mode_OBJECTS) $(get_setup_mode_LDADD) $(LIBS) - -get_variable_names$(EXEEXT): $(get_variable_names_OBJECTS) $(get_variable_names_DEPENDENCIES) $(EXTRA_get_variable_names_DEPENDENCIES) - @rm -f get_variable_names$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(get_variable_names_OBJECTS) $(get_variable_names_LDADD) $(LIBS) - -logger$(EXEEXT): $(logger_OBJECTS) $(logger_DEPENDENCIES) $(EXTRA_logger_DEPENDENCIES) - @rm -f logger$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(logger_OBJECTS) $(logger_LDADD) $(LIBS) - -proctest$(EXEEXT): $(proctest_OBJECTS) $(proctest_DEPENDENCIES) $(EXTRA_proctest_DEPENDENCIES) - @rm -f proctest$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(proctest_OBJECTS) $(proctest_LDADD) $(LIBS) - -read_stats$(EXEEXT): $(read_stats_OBJECTS) $(read_stats_DEPENDENCIES) $(EXTRA_read_stats_DEPENDENCIES) - @rm -f read_stats$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(read_stats_OBJECTS) $(read_stats_LDADD) $(LIBS) - -setuid$(EXEEXT): $(setuid_OBJECTS) $(setuid_DEPENDENCIES) $(EXTRA_setuid_DEPENDENCIES) - @rm -f setuid$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(setuid_OBJECTS) $(setuid_LDADD) $(LIBS) - -test_named_hierarchy$(EXEEXT): $(test_named_hierarchy_OBJECTS) $(test_named_hierarchy_DEPENDENCIES) $(EXTRA_test_named_hierarchy_DEPENDENCIES) - @rm -f test_named_hierarchy$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(test_named_hierarchy_OBJECTS) $(test_named_hierarchy_LDADD) $(LIBS) - -walk_task$(EXEEXT): $(walk_task_OBJECTS) $(walk_task_DEPENDENCIES) $(EXTRA_walk_task_DEPENDENCIES) - @rm -f walk_task$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(walk_task_OBJECTS) $(walk_task_LDADD) $(LIBS) - -walk_test$(EXEEXT): $(walk_test_OBJECTS) $(walk_test_DEPENDENCIES) $(EXTRA_walk_test_DEPENDENCIES) - @rm -f walk_test$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(walk_test_OBJECTS) $(walk_test_LDADD) $(LIBS) - -wrapper_test$(EXEEXT): $(wrapper_test_OBJECTS) $(wrapper_test_DEPENDENCIES) $(EXTRA_wrapper_test_DEPENDENCIES) - @rm -f wrapper_test$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(wrapper_test_OBJECTS) $(wrapper_test_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/create_systemd_scope.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/empty_cgroup_v2.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_all_controller.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_controller.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_mount_point.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_procs.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_setup_mode.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/get_variable_names.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/logger.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/proctest.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/read_stats.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setuid.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_named_hierarchy.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/walk_task.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/walk_test.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wrapper_test.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(PROGRAMS) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \ - mostlyclean-am - -distclean: distclean-am - -rm -f ./$(DEPDIR)/create_systemd_scope.Po - -rm -f ./$(DEPDIR)/empty_cgroup_v2.Po - -rm -f ./$(DEPDIR)/get_all_controller.Po - -rm -f ./$(DEPDIR)/get_controller.Po - -rm -f ./$(DEPDIR)/get_mount_point.Po - -rm -f ./$(DEPDIR)/get_procs.Po - -rm -f ./$(DEPDIR)/get_setup_mode.Po - -rm -f ./$(DEPDIR)/get_variable_names.Po - -rm -f ./$(DEPDIR)/logger.Po - -rm -f ./$(DEPDIR)/proctest.Po - -rm -f ./$(DEPDIR)/read_stats.Po - -rm -f ./$(DEPDIR)/setuid.Po - -rm -f ./$(DEPDIR)/test_named_hierarchy.Po - -rm -f ./$(DEPDIR)/walk_task.Po - -rm -f ./$(DEPDIR)/walk_test.Po - -rm -f ./$(DEPDIR)/wrapper_test.Po - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/create_systemd_scope.Po - -rm -f ./$(DEPDIR)/empty_cgroup_v2.Po - -rm -f ./$(DEPDIR)/get_all_controller.Po - -rm -f ./$(DEPDIR)/get_controller.Po - -rm -f ./$(DEPDIR)/get_mount_point.Po - -rm -f ./$(DEPDIR)/get_procs.Po - -rm -f ./$(DEPDIR)/get_setup_mode.Po - -rm -f ./$(DEPDIR)/get_variable_names.Po - -rm -f ./$(DEPDIR)/logger.Po - -rm -f ./$(DEPDIR)/proctest.Po - -rm -f ./$(DEPDIR)/read_stats.Po - -rm -f ./$(DEPDIR)/setuid.Po - -rm -f ./$(DEPDIR)/test_named_hierarchy.Po - -rm -f ./$(DEPDIR)/walk_task.Po - -rm -f ./$(DEPDIR)/walk_test.Po - -rm -f ./$(DEPDIR)/wrapper_test.Po - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-generic clean-libtool clean-noinstPROGRAMS cscopelist-am \ - ctags ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/samples/c/create_systemd_scope.c b/lib/libcgroup-3.1.0/samples/c/create_systemd_scope.c deleted file mode 100644 index cb9ab7d4227..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/create_systemd_scope.c +++ /dev/null @@ -1,613 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Sample program that shows how to use libcgroup to create a systemd scope - * - * This program is designed to meet the requirements outlined in the systemd - * cmdline example [1] via the libcgroup C APIs. - * - * [1] https://github.com/libcgroup/libcgroup/blob/main/samples/cmdline/systemd-with-idle-process.md - * - * Copyright (c) 2023 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -/* - * To compile and link this program: - * (From the root of the libcgroup source code directory) - * $ ./bootstrap - * $ ./configure --sysconfdir=/etc --localstatedir=/var \ - * --enable-opaque-hierarchy="name=systemd" --enable-systemd \ - * --enable-python --enable-samples - * $ make - * - * Add the libcgroup idle thread to your PATH. (Some distros restrict the - * modification of the $PATH environment variable when invoking sudo, so you - * will need to manually copy the executable to your path.) - * $ sudo cp src/libcgroup_systemd_idle_thread /a/path/in/your/sudo/path - * - * To run this program: - * $ # Note that there are more options. Run `create_systemd_scope -h` for more info - * $ sudo LD_LIBRARY_PATH=src/.libs ./samples/c/create_systemd_scope \ - * --slice --scope - */ - -/* - */ - -#include -#include -#include -#include -#include -#include -#include - -#define TMP_CGNAME "tmp" -#define HIGH_CGNAME "high-priority" -#define MED_CGNAME "medium-priority" -#define LOW_CGNAME "low-priority" - -struct example_opts { - char slice[FILENAME_MAX]; - char scope[FILENAME_MAX]; - - struct cgroup_systemd_scope_opts systemd_opts; - - bool debug; -}; - -static const struct option long_opts[] = { - {"delegated", no_argument, NULL, 'd'}, - {"help", no_argument, NULL, 'h'}, - {"pid", required_argument, NULL, 'p'}, - {"scope", required_argument, NULL, 's'}, - {"slice", required_argument, NULL, 't'}, - {"verbose", no_argument, NULL, 'v'}, - {NULL, 0, NULL, 0} -}; - -static void usage(const char * const program_name) -{ - printf("Usage: %s -s -t [-p ]\n", program_name); - printf("Create a systemd scope using the libcgroup C APIs\n"); - printf(" -d, --delegated Instruct systemd to create a delegated scope\n"); - printf(" -p, --pid PID to be placed in the scope, if not provided,\n"); - printf(" libcgroup will place a default idle PID in the scope\n"); - printf(" -s, --scope Scope name, must end in .scope\n"); - printf(" -t, --slice Slice name, must end in .slice\n"); - printf(" -v, --verbose Enable libcgroup debug messages\n"); -} - -static int parse_opts(int argc, char *argv[], struct example_opts * const opts) -{ - int c; - - while ((c = getopt_long(argc, argv, "hs:t:p:dv", long_opts, NULL)) > 0) { - switch (c) { - case 'd': - opts->systemd_opts.delegated = true; - break; - case 'h': - usage(argv[0]); - exit(0); - case 'p': - opts->systemd_opts.pid = atoi(optarg); - if (opts->systemd_opts.pid <= 1) { - usage(argv[0]); - exit(1); - } - break; - case 's': - strncpy(opts->scope, optarg, FILENAME_MAX - 1); - break; - case 't': - strncpy(opts->slice, optarg, FILENAME_MAX - 1); - break; - case 'v': - opts->debug = true; - break; - default: - usage(argv[0]); - exit(1); - break; - } - } - - return 0; -} - -static int create_scope(const struct example_opts * const opts) -{ - int ret; - - printf("\n----------------------------------------------------------------\n"); - printf("Creating systemd scope, %s/%s,\n", opts->slice, opts->scope); - if (opts->systemd_opts.pid > 1) - printf("and placing PID, %d, in the scope\n", opts->systemd_opts.pid); - else - printf("and libcgroup will place an idle process in the scope\n"); - printf("----------------------------------------------------------------\n\n"); - - ret = cgroup_create_scope(opts->scope, opts->slice, &opts->systemd_opts); - if (ret == ECGINVAL) { - printf("An invalid parameter was passed into cgroup_create_scope()\n" - "Check your scope name, slice name, and systemd options carefully\n"); - goto error; - } else if (ret == ECGOTHER) { - printf("Libcgroup typically returns ECGOTHER when a system call fails.\n" - "These failures could be caused by being out of memory, lack of\n" - "permissions, etc. Enabling libcgroup debug messages may help\n" - "root cause the issue; pass in '-v' to this program\n"); - printf("The failing system call returned an errno of %d\n", - cgroup_get_last_errno()); - goto error; - } else if (ret > 0) { - printf("An unspecified error occurred - likely in the formation or\n" - "sending/receiving of the message to systemd to create the scope.\n" - "Ensure that this application has the requisite permissions and\n" - "capabilities to create a scope. Enabling libcgroup debug\n" - "messages may help root cause the failing instruction; pass in\n" - "'-v' to this program\n"); - printf("Libcgroup returned %d\n", ret); - goto error; - } - - /* - * Counterintuitively, this function returns 1 on success - */ - ret = cgroup_write_systemd_default_cgroup(opts->slice, opts->scope); - if (ret != 1) { - printf("Failed to set the libcgroup default scope/slice: %d: %s\n", - ret, cgroup_strerror(ret)); - ret = ECGFAIL; - goto error; - } - - /* - * cgroup_set_default_systemd_cgroup() will return 1 if a default slice/scope are - * set, and will return 0 otherwise. Ensure that a default slice/scope are set. - * This is critical because subsequent code in this example is assuming a default, - * and if the default is not set, then calls will be operating on the root cgroup. - */ - ret = cgroup_set_default_systemd_cgroup(); - if (ret != 1) { - printf("The default slice/scope are not properly set\n"); - ret = ECGFAIL; - goto error; - } - - ret = 0; - -error: - return ret; -} - -static int create_tmp_cgroup(const struct example_opts * const opts) -{ - struct cgroup *cg; - int ret = 0; - - cg = cgroup_new_cgroup(TMP_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - goto error; - } - - ret = cgroup_create_cgroup(cg, 1); - if (ret) { - printf("Failed to write the cgroup to /sys/fs/cgroup: %d: %s\n", - ret, cgroup_strerror(ret)); - goto error; - } - -error: - if (cg) - cgroup_free(&cg); - - return ret; -} - -static int move_pids_to_tmp_cgroup(const struct example_opts * const opts) -{ - struct cgroup *cg = NULL; - int ret, pid_cnt, i; - pid_t *pids = NULL; - int saved_ret = 0; - - /* - * Since we told libcgroup that our slice and scope are the default, we can - * operate with that as our "root" directory. If we hadn't set them as the - * default, then we would have had to build up the relative path - - * /. - */ - ret = cgroup_get_procs("/", NULL, &pids, &pid_cnt); - if (ret) { - printf("Failed to get the pids in %s: %d: %s\n", opts->scope, - ret, cgroup_strerror(ret)); - goto error; - } - - cg = cgroup_new_cgroup(TMP_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - goto error; - } - - for (i = 0; i < pid_cnt; i++) { - ret = cgroup_attach_task_pid(cg, pids[i]); - if (ret) { - printf("Failed to attach pid %d to %s\n", pids[i], TMP_CGNAME); - /* - * Instead of failing, let's save off the return code and continue - * moving processes to the new cgroup. Perhaps the failing PID was - * killed between when we read cgroup.procs and when we tried to - * move it - */ - saved_ret = ret; - } - } - -error: - if (pids) - free(pids); - - if (cg) - cgroup_free(&cg); - - if (ret == 0 && saved_ret) - ret = saved_ret; - - return ret; -} - -static int create_high_priority_cgroup(const struct example_opts * const opts) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg; - int ret = 0; - - cg = cgroup_new_cgroup(HIGH_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - ret = ECGFAIL; - goto error; - } - - ctrl = cgroup_add_controller(cg, "cpu"); - if (!ctrl) { - printf("Failed to add the cpu controller to the %s cgroup struct\n", - HIGH_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "cpu.weight", "600"); - if (ret) { - printf("Failed to set %s's cpu.weight: %d: %s\n", HIGH_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ctrl = cgroup_add_controller(cg, "memory"); - if (!ctrl) { - printf("Failed to add the memory controller to the %s cgroup struct\n", - HIGH_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "memory.low", "1G"); - if (ret) { - printf("Failed to set %s's memory.low: %d: %s\n", HIGH_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ret = cgroup_create_cgroup(cg, 0); - if (ret) { - printf("Failed to write the %s cgroup to /sys/fs/cgroup: %d: %s\n", - HIGH_CGNAME, ret, cgroup_strerror(ret)); - goto error; - } - -error: - if (cg) - cgroup_free(&cg); - - return ret; -} - -static int create_medium_priority_cgroup(const struct example_opts * const opts) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg; - int ret = 0; - - cg = cgroup_new_cgroup(MED_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - ret = ECGFAIL; - goto error; - } - - ctrl = cgroup_add_controller(cg, "cpu"); - if (!ctrl) { - printf("Failed to add the cpu controller to the %s cgroup struct\n", - MED_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "cpu.weight", "300"); - if (ret) { - printf("Failed to set %s's cpu.weight: %d: %s\n", MED_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ctrl = cgroup_add_controller(cg, "memory"); - if (!ctrl) { - printf("Failed to add the memory controller to the %s cgroup struct\n", - MED_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "memory.high", "3G"); - if (ret) { - printf("Failed to set %s's memory.high: %d: %s\n", MED_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ret = cgroup_create_cgroup(cg, 0); - if (ret) { - printf("Failed to write the %s cgroup to /sys/fs/cgroup: %d: %s\n", - MED_CGNAME, ret, cgroup_strerror(ret)); - goto error; - } - -error: - if (cg) - cgroup_free(&cg); - - return ret; -} - -static int create_low_priority_cgroup(const struct example_opts * const opts) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg; - int ret = 0; - - cg = cgroup_new_cgroup(LOW_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - ret = ECGFAIL; - goto error; - } - - ctrl = cgroup_add_controller(cg, "cpu"); - if (!ctrl) { - printf("Failed to add the cpu controller to the %s cgroup struct\n", - LOW_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "cpu.weight", "100"); - if (ret) { - printf("Failed to set %s's cpu.weight: %d: %s\n", LOW_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ctrl = cgroup_add_controller(cg, "memory"); - if (!ctrl) { - printf("Failed to add the memory controller to the %s cgroup struct\n", - LOW_CGNAME); - ret = ECGFAIL; - goto error; - } - - ret = cgroup_set_value_string(ctrl, "memory.max", "2G"); - if (ret) { - printf("Failed to set %s's memory.high: %d: %s\n", LOW_CGNAME, ret, - cgroup_strerror(ret)); - goto error; - } - - ret = cgroup_create_cgroup(cg, 0); - if (ret) { - printf("Failed to write the %s cgroup to /sys/fs/cgroup: %d: %s\n", - LOW_CGNAME, ret, cgroup_strerror(ret)); - goto error; - } - -error: - if (cg) - cgroup_free(&cg); - - return ret; -} - -static int create_process(pid_t * const pid, const char * const cgname) -{ - int ret = 0; - - *pid = fork(); - if (*pid < 0) { - printf("Failed to create the process: %d\n", errno); - ret = ECGFAIL; - goto error; - } else if (*pid == 0) { - /* - * This is the child process. Move it to the requested cgroup - */ - ret = cgroup_change_cgroup_path(cgname, getpid(), NULL); - if (ret) - exit(0); - - while (true) - sleep(10); - } - -error: - if (ret) - *pid = -1; - - return ret; -} - -static int delete_tmp_cgroup(void) -{ - struct cgroup *cg = NULL; - int ret, pid_cnt, i; - int saved_errno = 0; - pid_t *pids = NULL; - - ret = cgroup_get_procs(TMP_CGNAME, NULL, &pids, &pid_cnt); - if (ret) { - printf("Failed to get the pids in %s: %d: %s\n", TMP_CGNAME, - ret, cgroup_strerror(ret)); - goto error; - } - - for (i = 0; i < pid_cnt; i++) { - ret = kill(pids[i], SIGTERM); - if (ret < 0) { - saved_errno = errno; - printf("Kill failed: %d\n", errno); - /* - * Do not bail out here as there may be other PIDS to process - */ - } - } - - cg = cgroup_new_cgroup(TMP_CGNAME); - if (!cg) { - printf("Failed to allocate the cgroup struct. Are we out of memory?\n"); - goto error; - } - - ret = cgroup_delete_cgroup(cg, 1); - if (ret) - printf("Failed to delete the %s cgroup: %d: %s\n", TMP_CGNAME, ret, - cgroup_strerror(ret)); - -error: - if (pids) - free(pids); - - if (cg) - cgroup_free(&cg); - - if (ret == 0 && saved_errno) - ret = ECGFAIL; - - return ret; -} - -static void wait_for_child(pid_t pid) -{ - int wstatus; - - (void)waitpid(pid, &wstatus, 0); - - if (WIFEXITED(wstatus)) - printf("pid %d exited with status %d\n", pid, WEXITSTATUS(wstatus)); - else if (WIFSIGNALED(wstatus)) - printf("pid %d exited due to signal %d\n", pid, WTERMSIG(wstatus)); -} - -int main(int argc, char *argv[]) -{ - pid_t high_pid, med_pid, low_pid; - struct example_opts opts = {0}; - int ret = 0; - - if (argc < 3) { - usage(argv[0]); - exit(1); - } - - ret = cgroup_set_default_scope_opts(&opts.systemd_opts); - if (ret) { - printf("Failed to set the default systemd options: %d\n", ret); - goto error; - } - - ret = parse_opts(argc, argv, &opts); - if (ret) { - printf("Failed to parse the command line options: %d\n", ret); - goto error; - } - - if (opts.debug) - cgroup_set_default_logger(CGROUP_LOG_DEBUG); - - ret = cgroup_init(); - if (ret) - goto error; - - ret = create_scope(&opts); - if (ret) - goto error; - - ret = create_tmp_cgroup(&opts); - if (ret) - goto error; - - ret = move_pids_to_tmp_cgroup(&opts); - if (ret) - goto error; - - ret = create_high_priority_cgroup(&opts); - if (ret) - goto error; - - ret = create_medium_priority_cgroup(&opts); - if (ret) - goto error; - - ret = create_low_priority_cgroup(&opts); - if (ret) - goto error; - - ret = create_process(&high_pid, HIGH_CGNAME); - if (ret) - goto error; - - ret = create_process(&med_pid, MED_CGNAME); - if (ret) - goto error; - - ret = create_process(&low_pid, LOW_CGNAME); - if (ret) - goto error; - - ret = delete_tmp_cgroup(); - if (ret) - goto error; - - printf("\n----------------------------------------------------------------\n"); - printf("Cgroup setup completed successfully\n"); - printf("\t* The scope %s was placed under slice %s\n", opts.scope, opts.slice); - printf("\t* Libcgroup initially placed an idle process in the scope,\n" - "\t but it has been removed by this program\n"); - printf("\t* PID %d has been placed in the %s cgroup\n", high_pid, HIGH_CGNAME); - printf("\t* PID %d has been placed in the %s cgroup\n", med_pid, MED_CGNAME); - printf("\t* PID %d has been placed in the %s cgroup\n", low_pid, LOW_CGNAME); - printf("\nThis program will wait for the aforementioned child processes to\n" - "exit before exiting itself. Systemd will automatically delete the\n" - "scope when there are no longer any processes running within the.\n" - "scope. Systemd will not automatically delete the slice.\n"); - printf("----------------------------------------------------------------\n\n"); - - wait_for_child(high_pid); - wait_for_child(med_pid); - wait_for_child(low_pid); - -error: - return ret; -} diff --git a/lib/libcgroup-3.1.0/samples/c/empty_cgroup_v2.c b/lib/libcgroup-3.1.0/samples/c/empty_cgroup_v2.c deleted file mode 100644 index a6dcf688576..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/empty_cgroup_v2.c +++ /dev/null @@ -1,40 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Simple program to add empty cgroup v2 - * - * Copyright (c) 2022 Oracle and/or its affiliates. - * Author: Kamalesh babulal - */ - -#include - -#include -#include - -#define CGRP_NAME "empty_cgrp" - -int main(int argc, char **argv) -{ - struct cgroup *cgroup = NULL; - int ret = 0; - - ret = cgroup_init(); - if (ret) { - fprintf(stderr, "cgroup_init failed\n"); - exit(1); - } - - cgroup = cgroup_new_cgroup(CGRP_NAME); - if (!cgroup) { - fprintf(stderr, "Failed to allocate cgroup %s\n", CGRP_NAME); - exit(1); - } - - ret = cgroup_create_cgroup(cgroup, 0); - if (ret) - fprintf(stderr, "Failed to create cgroup %s\n", CGRP_NAME); - - cgroup_free(&cgroup); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_all_controller.c b/lib/libcgroup-3.1.0/samples/c/get_all_controller.c deleted file mode 100644 index 8695fb552fc..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_all_controller.c +++ /dev/null @@ -1,36 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include - -int main(void) -{ - struct controller_data info; - void *handle; - int error; - - error = cgroup_init(); - - if (error) { - printf("cgroup_init failed with %s\n", cgroup_strerror(error)); - exit(1); - } - - error = cgroup_get_all_controller_begin(&handle, &info); - - while (error != ECGEOF) { - printf("Controller %10s %5d %5d %5d\n", info.name, - info.hierarchy, info.num_cgroups, info.enabled); - error = cgroup_get_all_controller_next(&handle, &info); - if (error && error != ECGEOF) { - printf("cgroup_get_controller_next failed with %s\n", - cgroup_strerror(error)); - exit(1); - } - } - - error = cgroup_get_all_controller_end(&handle); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_controller.c b/lib/libcgroup-3.1.0/samples/c/get_controller.c deleted file mode 100644 index 6115bc97194..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_controller.c +++ /dev/null @@ -1,34 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include - -int main(void) -{ - struct cgroup_mount_point info; - void *handle; - int error; - - error = cgroup_init(); - if (error) { - printf("cgroup_init failed with %s\n", cgroup_strerror(error)); - exit(1); - } - - error = cgroup_get_controller_begin(&handle, &info); - while (error != ECGEOF) { - printf("Controller %s is mounted at %s\n", - info.name, info.path); - error = cgroup_get_controller_next(&handle, &info); - if (error && error != ECGEOF) { - printf("cgroup_get_controller_next failed with %s", - cgroup_strerror(error)); - exit(1); - } - } - - error = cgroup_get_controller_end(&handle); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_mount_point.c b/lib/libcgroup-3.1.0/samples/c/get_mount_point.c deleted file mode 100644 index 788500744df..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_mount_point.c +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include -#include -#include - -int main(void) -{ - char *mount_point; - char string[100]; - int ret; - - strcpy(string, "cpu"); - - ret = cgroup_init(); - if (ret) { - printf("cgroup_init failed with %s\n", cgroup_strerror(ret)); - exit(3); - } - - ret = cgroup_get_subsys_mount_point(string, &mount_point); - if (ret) { - printf("get_mount_point failed with %s\n", - cgroup_strerror(ret)); - exit(3); - } - - printf("The mount point is %s\n", mount_point); - free(mount_point); - - strcpy(string, "obviouslynonexistsubsys"); - - ret = cgroup_get_subsys_mount_point(string, &mount_point); - if (!ret) { - printf("get_mount_point failed as it got a "); - printf("non existent subsys\n"); - exit(3); - } - - if (ret == ECGROUPNOTEXIST) { - printf("get_mount_point worked as expected\n"); - return 0; - } - - printf("get_mount_point failed with %s\n", cgroup_strerror(ret)); - - return 3; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_procs.c b/lib/libcgroup-3.1.0/samples/c/get_procs.c deleted file mode 100644 index 30f7b0ae0e1..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_procs.c +++ /dev/null @@ -1,37 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include - -/* - * Assumes the cgroup is already mounted at /cgroup/memory/a - * Assumes some processes are already in the cgroup - * Assumes it is the memory controller is mounted in at that point - */ -int main(void) -{ - pid_t *pids; - int size; - int ret; - int i; - - ret = cgroup_init(); - if (ret) { - printf("FAIL: cgroup_init failed with %s\n", - cgroup_strerror(ret)); - exit(3); - } - - ret = cgroup_get_procs("a", "memory", &pids, &size); - if (ret) { - printf("FAIL: cgroup_get_procs failed with %s\n", - cgroup_strerror(ret)); - exit(3); - } - - for (i = 0; i < size; i++) - printf("%u\n", pids[i]); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_setup_mode.c b/lib/libcgroup-3.1.0/samples/c/get_setup_mode.c deleted file mode 100644 index e983f4fe71e..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_setup_mode.c +++ /dev/null @@ -1,44 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/* - * Copyright (c) 2023 Oracle and/or its affiliates - * - * Author: Kamalesh Babulal - * - * Description: This file contains the sample code to demonstrate usage of - * cgroup_setup_mode() API. - */ - -#include -#include - -#include - -int main(void) -{ - enum cg_setup_mode_t setup_mode; - int ret; - - ret = cgroup_init(); - if (ret) { - printf("cgroup_init failed with %s\n", cgroup_strerror(ret)); - exit(1); - } - - setup_mode = cgroup_setup_mode(); - switch(setup_mode) { - case CGROUP_MODE_LEGACY: - printf("cgroup mode: Legacy\n"); - break; - case CGROUP_MODE_HYBRID: - printf("cgroup mode: Hybrid\n"); - break; - case CGROUP_MODE_UNIFIED: - printf("cgroup mode: Unified\n"); - break; - default: - printf("cgroup mode: Unknown\n"); - break; - } - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/get_variable_names.c b/lib/libcgroup-3.1.0/samples/c/get_variable_names.c deleted file mode 100644 index da4e5d12235..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/get_variable_names.c +++ /dev/null @@ -1,61 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include "../src/libcgroup-internal.h" -#include - -#include -#include -#include - -int main(int argc, char *argv[]) -{ - struct cgroup_controller *group_controller = NULL; - struct cgroup *group = NULL; - char group_name[] = "/"; - char *name; - int count; - int ret; - int i, j; - - if (argc < 2) { - printf("no list of groups provided\n"); - return -1; - } - - ret = cgroup_init(); - if (ret) { - printf("cgroup_init failed with %s\n", cgroup_strerror(ret)); - exit(1); - } - - group = cgroup_new_cgroup(group_name); - if (group == NULL) { - printf("cannot create group '%s'\n", group_name); - return -1; - } - - ret = cgroup_get_cgroup(group); - if (ret != 0) { - printf("cannot read group '%s': %s\n", - group_name, cgroup_strerror(ret)); - } - - for (i = 1; i < argc; i++) { - - group_controller = cgroup_get_controller(group, argv[i]); - if (group_controller == NULL) { - printf("cannot find controller '%s' in group '%s'\n", - argv[i], group_name); - ret = -1; - continue; - } - - count = cgroup_get_value_name_count(group_controller); - for (j = 0; j < count; j++) { - name = cgroup_get_value_name(group_controller, j); - if (name != NULL) - printf("%s\n", name); - } - } - - return ret; -} diff --git a/lib/libcgroup-3.1.0/samples/c/logger.c b/lib/libcgroup-3.1.0/samples/c/logger.c deleted file mode 100644 index cdadf647966..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/logger.c +++ /dev/null @@ -1,47 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/* - * Copyright Red Hat Inc., 2012 - * - * Author: Jan Safranek - * - * Description: This file contains the test code for libcgroup logging. - */ - -#include "config.h" -#include "libcgroup.h" -#include "../src/libcgroup-internal.h" - -#include -#include - -static void mylogger(void *userdata, int loglevel, const char *fmt, va_list ap) -{ - printf("custom: "); - vprintf(fmt, ap); -} - -int main(int argc, char **argv) -{ - int loglevel = -1; - int custom = 0; - int i; - - for (i = 1; i < argc; i++) { - if (strcmp("custom", argv[i]) == 0) - custom = 1; - else - loglevel = atoi(argv[i]); - } - - if (custom) - cgroup_set_logger(mylogger, loglevel, NULL); - else - cgroup_set_default_logger(loglevel); - - cgroup_dbg("DEBUG message\n"); - cgroup_info("INFO message\n"); - cgroup_warn("WARNING message\n"); - cgroup_err("ERROR message\n"); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/proctest.c b/lib/libcgroup-3.1.0/samples/c/proctest.c deleted file mode 100644 index 8f8007f8a09..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/proctest.c +++ /dev/null @@ -1,48 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/* - * Copyright NEC Soft Ltd. 2009 - * - * Author: Ken'ichi Ohmichi - */ - -#include "../src/libcgroup-internal.h" - -#include -#include - -int main(int argc, char *argv[]) -{ - char *procname; - pid_t pid; - uid_t uid; - gid_t gid; - int ret; - int i; - - if (argc < 2) { - printf("Specify process-id.\n"); - return 1; - } - - printf(" Pid | Process name | Uid | Gid\n"); - printf("-------+----------------------------------+-------+-------\n"); - - for (i = 1; i < argc; i++) { - pid = atoi(argv[i]); - - ret = cgroup_get_uid_gid_from_procfs(pid, &uid, &gid); - if (ret) { - printf("%6d | ret = %d\n", pid, ret); - continue; - } - ret = cgroup_get_procname_from_procfs(pid, &procname); - if (ret) { - printf("%6d | ret = %d\n", pid, ret); - continue; - } - printf("%6d | %32s | %5d | %5d\n", pid, procname, uid, gid); - free(procname); - } - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/read_stats.c b/lib/libcgroup-3.1.0/samples/c/read_stats.c deleted file mode 100644 index 92974d1e3d6..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/read_stats.c +++ /dev/null @@ -1,86 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include -#include -#include - -#include - -int read_stats(char *path, char *controller) -{ - struct cgroup_stat stat; - void *handle; - int ret; - - ret = cgroup_read_stats_begin(controller, path, &handle, &stat); - if (ret != 0) { - fprintf(stderr, "stats read failed\n"); - return -1; - } - - printf("Stats for %s:\n", path); - printf("%s: %s", stat.name, stat.value); - - while ((ret = cgroup_read_stats_next(&handle, &stat)) != - ECGEOF) { - printf("%s: %s", stat.name, stat.value); - } - - cgroup_read_stats_end(&handle); - printf("\n"); - return 0; -} - -int main(int argc, char *argv[]) -{ - struct cgroup_file_info info; - char cgroup_path[FILENAME_MAX]; - char *controller; - int root_len; - void *handle; - int lvl; - int ret; - - if (argc < 2) { - fprintf(stderr, "Usage %s: \n", - argv[0]); - exit(EXIT_FAILURE); - } - - controller = argv[1]; - - ret = cgroup_init(); - if (ret != 0) { - fprintf(stderr, "init failed\n"); - exit(EXIT_FAILURE); - } - - ret = cgroup_walk_tree_begin(controller, "/", 0, &handle, &info, &lvl); - - if (ret != 0) { - fprintf(stderr, "Walk failed\n"); - exit(EXIT_FAILURE); - } - - root_len = strlen(info.full_path) - 1; - strncpy(cgroup_path, info.path, FILENAME_MAX - 1); - ret = read_stats(cgroup_path, controller); - if (ret < 0) - exit(EXIT_FAILURE); - - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) != - ECGEOF) { - if (info.type != CGROUP_FILE_TYPE_DIR) - continue; - strncpy(cgroup_path, info.full_path + root_len, FILENAME_MAX - 1); - strcat(cgroup_path, "/"); - ret = read_stats(cgroup_path, controller); - if (ret < 0) - exit(EXIT_FAILURE); - } - cgroup_walk_tree_end(&handle); - - return EXIT_SUCCESS; -} diff --git a/lib/libcgroup-3.1.0/samples/c/setuid.c b/lib/libcgroup-3.1.0/samples/c/setuid.c deleted file mode 100644 index a51fdb34584..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/setuid.c +++ /dev/null @@ -1,74 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/* - * Copyright Red Hat Inc. 2008 - * - * Author: Steve Olivieri - */ - -#include -#include -#include -#include -#include -#include -#include - -#include - -/* - * This is just a simple program for changing a UID or a GID. Comment out - * whichever block you don't want to use. - */ -int main(int argc, char *argv[]) -{ - /* User data */ - struct passwd *pwd; - - /* UID of user */ - uid_t uid; - - /* Return codes */ - int ret = 0; - - if (argc < 2) { - printf("Usage: %s \n", argv[0]); - goto finished; - } - - pwd = getpwnam(argv[1]); - if (!pwd) { - fprintf(stderr, "getpwnam() failed: %s\n", - strerror(errno)); - ret = -errno; - goto finished; - } - - uid = pwd->pw_uid; - fprintf(stdout, "Setting UID to %s (%d).\n", pwd->pw_name, uid); - ret = setuid(uid); - if (ret != 0) { - fprintf(stderr, "Call to setuid() failed with error: %s\n", - strerror(errno)); - ret = -errno; - goto finished; - } - -// while(1) { -// grp = getgrnam("root"); -// gid = grp->gr_gid; -// fprintf(stdout, "Setting GID to %s (%d).\n", -// grp->gr_name, gid); -// if ((ret = setgid(gid))) { -// fprintf(stderr, "Call to setgid() failed with error:" -// " %s\n", strerror(errno)); -// ret = -errno; -// goto finished; -// } -// } - - while (1) - usleep(3000000); - -finished: - return ret; -} diff --git a/lib/libcgroup-3.1.0/samples/c/test_named_hierarchy.c b/lib/libcgroup-3.1.0/samples/c/test_named_hierarchy.c deleted file mode 100644 index c0bf7eeba46..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/test_named_hierarchy.c +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include -#include - -/* - * Assumes cgroup is mounted at /cgroup using - * mount -t cgroup -o none,name=test none /cgroup - */ -int main(void) -{ - struct cgroup_controller *cgc; - struct cgroup *cgroup; - int ret; - - ret = cgroup_init(); - if (ret) { - printf("FAIL: cgroup_init failed with %s\n", - cgroup_strerror(ret)); - exit(3); - } - - cgroup = cgroup_new_cgroup("test"); - if (!cgroup) { - printf("FAIL: cgroup_new_cgroup failed\n"); - exit(3); - } - - cgc = cgroup_add_controller(cgroup, "name=test"); - if (!cgc) { - printf("FAIL: cgroup_add_controller failed\n"); - exit(3); - } - - ret = cgroup_create_cgroup(cgroup, 1); - if (ret) { - printf("FAIL: cgroup_create_cgroup failed with %s\n", - cgroup_strerror(ret)); - exit(3); - } - - if (access("/cgroup/test", F_OK)) - printf("PASS\n"); - else - printf("Failed to create cgroup\n"); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/walk_task.c b/lib/libcgroup-3.1.0/samples/c/walk_task.c deleted file mode 100644 index 1a9f59d8820..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/walk_task.c +++ /dev/null @@ -1,51 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include -#include -#include - -int main(int argc, char *argv[]) -{ - char *group = NULL; - void *handle; - int ret, i; - - if (argc < 2) { - printf("No list of groups provided\n"); - return -1; - } - - ret = cgroup_init(); - if (ret) { - printf("cgroup_init failed with %s\n", cgroup_strerror(ret)); - return -1; - } - - for (i = 1; i < argc; i++) { - pid_t pid; - - group = strdup(argv[i]); - printf("Printing the details of groups %s\n", group); - - ret = cgroup_get_task_begin(group, "cpu", &handle, &pid); - while (!ret) { - printf("Pid is %u\n", pid); - ret = cgroup_get_task_next(&handle, &pid); - if (ret && ret != ECGEOF) { - printf("cgroup_get_task_next failed with %s\n", - cgroup_strerror(ret)); - if (ret == ECGOTHER) - printf("failure with %s\n", - strerror(errno)); - return -1; - } - } - free(group); - group = NULL; - ret = cgroup_get_task_end(&handle); - } - - return 0; -} diff --git a/lib/libcgroup-3.1.0/samples/c/walk_test.c b/lib/libcgroup-3.1.0/samples/c/walk_test.c deleted file mode 100644 index 20c7641b5ff..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/walk_test.c +++ /dev/null @@ -1,126 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include - -#include -#include -#include -#include - -#include - -void visit_node(struct cgroup_file_info *info, char *root) -{ - if (info->type == CGROUP_FILE_TYPE_DIR) { - printf("path %s, parent %s, relative %s, full %s\n", - info->path, info->parent, - info->full_path + strlen(root) - 1, - info->full_path); - } -} - -int main(int argc, char *argv[]) -{ - struct cgroup_file_info info; - char root[FILENAME_MAX]; - char *controller; - void *handle; - int lvl, i; - int ret; - - if (argc < 2) { - fprintf(stderr, "Usage %s: \n", - argv[0]); - exit(EXIT_FAILURE); - } - - controller = argv[1]; - - ret = cgroup_init(); - if (ret != 0) { - fprintf(stderr, "Init failed\n"); - exit(EXIT_FAILURE); - } - - ret = cgroup_walk_tree_begin(controller, "/", 0, &handle, &info, &lvl); - - if (ret != 0) { - fprintf(stderr, "Walk failed\n"); - exit(EXIT_FAILURE); - } - - strcpy(root, info.full_path); - printf("Begin pre-order walk\n"); - printf("root is %s\n", root); - visit_node(&info, root); - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) != - ECGEOF) { - visit_node(&info, root); - } - cgroup_walk_tree_end(&handle); - - printf("pre-order walk finished\n"); - ret = cgroup_walk_tree_begin(controller, "/", 0, &handle, &info, &lvl); - - if (ret != 0) { - fprintf(stderr, "Walk failed\n"); - exit(EXIT_FAILURE); - } - - ret = cgroup_walk_tree_set_flags(&handle, CGROUP_WALK_TYPE_POST_DIR); - - if (ret) { - fprintf(stderr, "Walk failed with %s\n", cgroup_strerror(ret)); - exit(EXIT_FAILURE); - } - - strcpy(root, info.full_path); - printf("Begin post-order walk\n"); - printf("root is %s\n", root); - visit_node(&info, root); - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) != - ECGEOF) { - visit_node(&info, root); - } - cgroup_walk_tree_end(&handle); - printf("post order walk finished\n"); - - ret = cgroup_walk_tree_begin(controller, "/a", 2, &handle, &info, &lvl); - - if (ret != 0) { - fprintf(stderr, "Walk failed\n"); - exit(EXIT_FAILURE); - } - strcpy(root, info.full_path); - printf("root is %s\n", root); - visit_node(&info, root); - while ((ret = cgroup_walk_tree_next(2, &handle, &info, lvl)) != - ECGEOF) { - visit_node(&info, root); - } - cgroup_walk_tree_end(&handle); - - /* - * Walk only the first five nodes - */ - i = 0; - printf("Walking the first 5 nodes\n"); - ret = cgroup_walk_tree_begin(controller, "/", 0, &handle, &info, &lvl); - - if (ret != 0) { - fprintf(stderr, "Walk failed\n"); - exit(EXIT_FAILURE); - } - strcpy(root, info.full_path); - printf("root is %s\n", root); - visit_node(&info, root); - i++; - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) != - ECGEOF) { - visit_node(&info, root); - if (++i >= 5) - break; - } - cgroup_walk_tree_end(&handle); - - return EXIT_SUCCESS; -} diff --git a/lib/libcgroup-3.1.0/samples/c/wrapper_test.c b/lib/libcgroup-3.1.0/samples/c/wrapper_test.c deleted file mode 100644 index c1f88371bf7..00000000000 --- a/lib/libcgroup-3.1.0/samples/c/wrapper_test.c +++ /dev/null @@ -1,46 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include "../src/libcgroup-internal.h" -#include - -#include -#include - -int main(void) -{ - struct cgroup *cgroup; - struct cgroup_controller *cgc; - int fail = 0; - - cgroup = cgroup_new_cgroup("test"); - cgc = cgroup_add_controller(cgroup, "cpu"); - - cgroup_add_value_int64(cgc, "cpu.shares", 2048); - cgroup_add_value_uint64(cgc, "cpu.something", 1000); - cgroup_add_value_bool(cgc, "cpu.bool", 1); - - if (!strcmp(cgroup->controller[0]->values[0]->name, "cpu.shares")) { - if (strcmp(cgroup->controller[0]->values[0]->value, "2048")) { - printf("FAIL for add_value_int\n"); - fail = 1; - } - } - - if (!strcmp(cgroup->controller[0]->values[1]->name, "cpu.something")) { - if (strcmp(cgroup->controller[0]->values[1]->value, "1000")) { - printf("FAIL for add_value_uint\n"); - fail = 1; - } - } - - if (!strcmp(cgroup->controller[0]->values[2]->name, "cpu.bool")) { - if (strcmp(cgroup->controller[0]->values[2]->value, "1")) { - printf("FAIL for add_value_bool\n"); - fail = 1; - } - } - - if (!fail) - printf("PASS!\n"); - - return fail; -} diff --git a/lib/libcgroup-3.1.0/samples/cmdline/Makefile.am b/lib/libcgroup-3.1.0/samples/cmdline/Makefile.am deleted file mode 100644 index dd0ca5e930b..00000000000 --- a/lib/libcgroup-3.1.0/samples/cmdline/Makefile.am +++ /dev/null @@ -1,13 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup cmdline samples Makefile.am -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -if WITH_SAMPLES - -EXTRA_DIST = systemd-with-idle-process.md - -endif diff --git a/lib/libcgroup-3.1.0/samples/cmdline/Makefile.in b/lib/libcgroup-3.1.0/samples/cmdline/Makefile.in deleted file mode 100644 index ff919868173..00000000000 --- a/lib/libcgroup-3.1.0/samples/cmdline/Makefile.in +++ /dev/null @@ -1,483 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup cmdline samples Makefile.am -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = samples/cmdline -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -@WITH_SAMPLES_TRUE@EXTRA_DIST = systemd-with-idle-process.md -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign samples/cmdline/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign samples/cmdline/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/samples/config/Makefile.am b/lib/libcgroup-3.1.0/samples/config/Makefile.am deleted file mode 100644 index a52cef736e0..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/Makefile.am +++ /dev/null @@ -1,9 +0,0 @@ -EXTRA_DIST = cgconfig.conf \ - cgconfig.sysconfig \ - cgred.conf \ - cgrules.conf \ - cgsnapshot_denylist.conf \ - cgsnapshot_allowlist.conf \ - invalid_namespace_config.conf \ - invalid_namespace_mount_config.conf \ - namespace_config.conf diff --git a/lib/libcgroup-3.1.0/samples/config/Makefile.in b/lib/libcgroup-3.1.0/samples/config/Makefile.in deleted file mode 100644 index 8d1b2d41d02..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/Makefile.in +++ /dev/null @@ -1,484 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = samples/config -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -EXTRA_DIST = cgconfig.conf \ - cgconfig.sysconfig \ - cgred.conf \ - cgrules.conf \ - cgsnapshot_denylist.conf \ - cgsnapshot_allowlist.conf \ - invalid_namespace_config.conf \ - invalid_namespace_mount_config.conf \ - namespace_config.conf - -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign samples/config/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign samples/config/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/samples/config/cgconfig.conf b/lib/libcgroup-3.1.0/samples/config/cgconfig.conf deleted file mode 100644 index de29594fd74..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgconfig.conf +++ /dev/null @@ -1,42 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Copyright IBM Corporation. 2007 -# -# Authors: Balbir Singh -# -#group daemons/www { -# perm { -# task { -# uid = root; -# gid = webmaster; -# } -# admin { -# uid = root; -# gid = root; -# } -# } -# cpu { -# cpu.shares = 1000; -# } -#} -# -#group daemons/ftp { -# perm { -# task { -# uid = root; -# gid = ftpmaster; -# } -# admin { -# uid = root; -# gid = root; -# } -# } -# cpu { -# cpu.shares = 500; -# } -#} -# -#mount { -# cpu = /mnt/cgroups/cpu; -# cpuacct = /mnt/cgroups/cpuacct; -#} diff --git a/lib/libcgroup-3.1.0/samples/config/cgconfig.sysconfig b/lib/libcgroup-3.1.0/samples/config/cgconfig.sysconfig deleted file mode 100644 index 5a61bf6e987..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgconfig.sysconfig +++ /dev/null @@ -1,12 +0,0 @@ -# Service cgconfig can create a default group in all mounted hierarchies and -# move all processes there on boot. If no default rule is specified in -# /etc/cgrules.conf, the default group is named '/sysdefault'. -# This automatically created group(s) can be useful e.g. when using 'cpu' -# controller to limit cpu.shares of this default group and allowing some more -# important group take most of the CPU. -# -# By default, create these groups: -CREATE_DEFAULT=yes - -# Uncomment following line to disable creation of the default group on startup: -# CREATE_DEFAULT=no diff --git a/lib/libcgroup-3.1.0/samples/config/cgred.conf b/lib/libcgroup-3.1.0/samples/config/cgred.conf deleted file mode 100644 index edd0dc763d9..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgred.conf +++ /dev/null @@ -1,27 +0,0 @@ -# /etc/sysconfig/cgred.conf - CGroup Rules Engine Daemon configuration file -# -# The four options listed below (CONFIG_FILE, LOG_FILE, NODAEMON, LOG) are -# the only valid ones. Defining anything else in this file will cause the -# CGroup Rules Engine program to fail. So, don't do it. - -# The pathname to the configuration file for CGroup Rules Engine -CONFIG_FILE="/etc/cgrules.conf" - -# Uncomment the following line to log to specified file instead of syslog -#LOG_FILE="/var/log/cgrulesengd.log" - -# Uncomment the second line to run CGroup Rules Engine in non-daemon mode -NODAEMON="" -#NODAEMON="--nodaemon" - -# Set owner of cgred socket. 'cgexec' tool should have write access there -# (either using suid and/or sgid permissions or Linux capabilities). -SOCKET_USER="" -SOCKET_GROUP="cgred" - -# Uncomment the second line to disable logging for CGroup Rules Engine -# Uncomment the third line to enable more verbose logging. -LOG="" -#LOG="--nolog" -#LOG="-v" - diff --git a/lib/libcgroup-3.1.0/samples/config/cgrules.conf b/lib/libcgroup-3.1.0/samples/config/cgrules.conf deleted file mode 100644 index 86300b3d850..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgrules.conf +++ /dev/null @@ -1,10 +0,0 @@ -# /etc/cgrules.conf -#The format of this file is described in cgrules.conf(5) -#manual page. -# -# Example: -# -#@student cpu,memory usergroup/student/ -#peter cpu test1/ -#% memory test2/ -# End of file diff --git a/lib/libcgroup-3.1.0/samples/config/cgsnapshot_allowlist.conf b/lib/libcgroup-3.1.0/samples/config/cgsnapshot_allowlist.conf deleted file mode 100644 index 2c9ab23831b..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgsnapshot_allowlist.conf +++ /dev/null @@ -1,48 +0,0 @@ -#cgsnapshot tool configuration file - -#memory -memory.memsw.failcnt -memory.memsw.limit_in_bytes -memory.memsw.max_usage_in_bytes -memory.swappiness -memory.use_hierarchy -memory.failcnt -memory.soft_limit_in_bytes -memory.limit_in_bytes -memory.max_usage_in_bytes -memory.move_charge_at_immigrate - -#cpu -cpu.rt_runtime_us -cpu.rt_period_us - -#cpuacct -cpuacct.usage - -#devices -devices.deny -devices.allow -devices.list - -#cpuset -cpuset.memory_spread_slab -cpuset.memory_spread_page -cpuset.memory_migrate -cpuset.sched_relax_domain_level -cpuset.sched_load_balance -cpuset.mem_hardwall -cpuset.mem_exclusive -cpuset.cpu_exclusive -cpuset.mems -cpuset.cpus - -#ns - -#freezer -freezer.state - -#net_cls -net_cls.classid - -#blkio -blkio.weight \ No newline at end of file diff --git a/lib/libcgroup-3.1.0/samples/config/cgsnapshot_denylist.conf b/lib/libcgroup-3.1.0/samples/config/cgsnapshot_denylist.conf deleted file mode 100644 index 3d63373e78e..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/cgsnapshot_denylist.conf +++ /dev/null @@ -1,20 +0,0 @@ -#cgsnapshot tool configuration file - -#memory -memory.oom_control - -#cpu - -#cpuacct - -#devices - -#cpuset - -#ns - -#freezer - -#net_cls - -#blkio \ No newline at end of file diff --git a/lib/libcgroup-3.1.0/samples/config/invalid_namespace_config.conf b/lib/libcgroup-3.1.0/samples/config/invalid_namespace_config.conf deleted file mode 100644 index 074e1869cfc..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/invalid_namespace_config.conf +++ /dev/null @@ -1,53 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Copyright IBM Corporation. 2009 -# -# Authors: Dhaval Giani -# -group www { - perm { - task { - uid = root; - gid = webmaster; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 1000; - } - cpuacct { - } -} - -group ftp { - perm { - task { - uid = root; - gid = ftpmaster; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 500; - } - cpuacct { - } -} - -mount { - cpu = /mnt/cgroups; - cpuacct = /mnt/cgroups; -} - -namespace { - cpu = daemons; - #This is invalid since both cpu and cpuacct are mounted at the - #same place but have different namespace - cpuacct = network; -} diff --git a/lib/libcgroup-3.1.0/samples/config/invalid_namespace_mount_config.conf b/lib/libcgroup-3.1.0/samples/config/invalid_namespace_mount_config.conf deleted file mode 100644 index e910672c47b..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/invalid_namespace_mount_config.conf +++ /dev/null @@ -1,59 +0,0 @@ -# -# Copyright IBM Corporation. 2009 -# -# Authors: Dhaval Giani -# This program is free software; you can redistribute it and/or modify it -# under the terms of version 2.1 of the GNU Lesser General Public License -# as published by the Free Software Foundation. -# -# This program is distributed in the hope that it would be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -# -group www { - perm { - task { - uid = root; - gid = root; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 1000; - } - cpuacct { - } -} - -group ftp { - perm { - task { - uid = root; - gid = root; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 500; - } - cpuacct { - } -} - -#This is invalid because we cannot have mount and namespace in the same -#configuration file. -mount { - cpu = /cgroups/cpu; - cpuacct = /cgroups/cpuacct; -} - -namespace { - cpu = daemons; - cpuacct = daemons; -} diff --git a/lib/libcgroup-3.1.0/samples/config/namespace_config.conf b/lib/libcgroup-3.1.0/samples/config/namespace_config.conf deleted file mode 100644 index bdb5e7f5642..00000000000 --- a/lib/libcgroup-3.1.0/samples/config/namespace_config.conf +++ /dev/null @@ -1,46 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Copyright IBM Corporation. 2009 -# -# Authors: Dhaval Giani -# -group www { - perm { - task { - uid = root; - gid = root; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 1000; - } - cpuacct { - } -} - -group ftp { - perm { - task { - uid = root; - gid = root; - } - admin { - uid = root; - gid = root; - } - } - cpu { - cpu.shares = 500; - } - cpuacct { - } -} - -namespace { - cpu = daemons; - cpuacct = daemons; -} diff --git a/lib/libcgroup-3.1.0/samples/python/Makefile.am b/lib/libcgroup-3.1.0/samples/python/Makefile.am deleted file mode 100644 index 17aaf89b7db..00000000000 --- a/lib/libcgroup-3.1.0/samples/python/Makefile.am +++ /dev/null @@ -1,18 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup python samples Makefile.am -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -if WITH_SAMPLES - -EXTRA_DIST = create_systemd_scope.py - -endif - -clean-local: clean-local-check -.PHONY: clean-local-check -clean-local-check: - -rm -f *.pyc diff --git a/lib/libcgroup-3.1.0/samples/python/Makefile.in b/lib/libcgroup-3.1.0/samples/python/Makefile.in deleted file mode 100644 index 82973de5453..00000000000 --- a/lib/libcgroup-3.1.0/samples/python/Makefile.in +++ /dev/null @@ -1,488 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup python samples Makefile.am -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = samples/python -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -@WITH_SAMPLES_TRUE@EXTRA_DIST = create_systemd_scope.py -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign samples/python/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign samples/python/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-local mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - clean-local cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -clean-local: clean-local-check -.PHONY: clean-local-check -clean-local-check: - -rm -f *.pyc - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/scripts/Makefile.am b/lib/libcgroup-3.1.0/scripts/Makefile.am deleted file mode 100644 index 9d0f19165b4..00000000000 --- a/lib/libcgroup-3.1.0/scripts/Makefile.am +++ /dev/null @@ -1,11 +0,0 @@ -EXTRA_DIST = init.d/cgconfig.in init.d/cgred.in - -if WITH_INITSCRIPT_INSTALL -INITSCRIPTDIR=$(DESTDIR)$(sysconfdir)/rc.d/init.d -install-exec-hook: - $(INSTALL) -d $(INITSCRIPTDIR) - $(INSTALL_SCRIPT) init.d/cgconfig init.d/cgred $(INITSCRIPTDIR) - -uninstall-hook: - rm -f $(INITSCRIPTDIR)/cgconfig $(INITSCRIPTDIR)/cgred -endif diff --git a/lib/libcgroup-3.1.0/scripts/Makefile.in b/lib/libcgroup-3.1.0/scripts/Makefile.in deleted file mode 100644 index e626dc29ad5..00000000000 --- a/lib/libcgroup-3.1.0/scripts/Makefile.in +++ /dev/null @@ -1,486 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = scripts -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -EXTRA_DIST = init.d/cgconfig.in init.d/cgred.in -@WITH_INITSCRIPT_INSTALL_TRUE@INITSCRIPTDIR = $(DESTDIR)$(sysconfdir)/rc.d/init.d -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign scripts/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign scripts/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -@WITH_INITSCRIPT_INSTALL_FALSE@install-exec-hook: -@WITH_INITSCRIPT_INSTALL_FALSE@uninstall-hook: -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-exec-hook -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) uninstall-hook -.MAKE: install-am install-exec-am install-strip uninstall-am - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-exec-hook \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags-am uninstall uninstall-am uninstall-hook - -.PRECIOUS: Makefile - -@WITH_INITSCRIPT_INSTALL_TRUE@install-exec-hook: -@WITH_INITSCRIPT_INSTALL_TRUE@ $(INSTALL) -d $(INITSCRIPTDIR) -@WITH_INITSCRIPT_INSTALL_TRUE@ $(INSTALL_SCRIPT) init.d/cgconfig init.d/cgred $(INITSCRIPTDIR) - -@WITH_INITSCRIPT_INSTALL_TRUE@uninstall-hook: -@WITH_INITSCRIPT_INSTALL_TRUE@ rm -f $(INITSCRIPTDIR)/cgconfig $(INITSCRIPTDIR)/cgred - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/scripts/init.d/cgconfig.in b/lib/libcgroup-3.1.0/scripts/init.d/cgconfig.in deleted file mode 100644 index 527430e042b..00000000000 --- a/lib/libcgroup-3.1.0/scripts/init.d/cgconfig.in +++ /dev/null @@ -1,221 +0,0 @@ -#!/bin/bash -# SPDX-License-Identifier: LGPL-2.1-only -# -# Start/Stop the workload manager -# -# Copyright IBM Corporation. 2008 -# -# Authors: Balbir Singh -# -# cgconfig Control Groups Configuration Startup -# chkconfig: - 5 95 -# description: This script runs the cgconfigparser utility to parse and setup -# the control group filesystem. It uses /etc/cgconfig.conf -# and parses the configuration specified in there. - -### BEGIN INIT INFO -# Provides: cgconfig -# Required-Start: -# Required-Stop: -# Should-Start: ypbind -# Should-Stop: ypbind -# Short-Description: Create and setup control group filesystem(s) -# Description: Create and setup control group filesystem(s) -### END INIT INFO - -# get correct location of binaries from configure -sbindir=@sbindir@ -CGCONFIGPARSER_BIN=$sbindir/cgconfigparser -CONFIG_FILE=/etc/cgconfig.conf -CONFIG_DIR=/etc/cgconfig.d -servicename=cgconfig - - -lockfile=/run/lock/subsys/$servicename -# -# Source LSB routines -# -SYSLIBFILE=/lib/lsb/init-functions -OLDSYSLIBFILE=/etc/init.d/functions -if [[ -x $SYSLIBFILE ]] ; then - # shellcheck disable=SC1090 - source $SYSLIBFILE -elif [[ -x $OLDSYSLIBFILE ]] ; then - # shellcheck disable=SC1090 - source $OLDSYSLIBFILE - log_warning_msg() ( warning "$@" ; printf "\n" 1>&2 ; ) - log_failure_msg() ( failure "$@" ; printf "\n" 1>&2 ; ) - log_success_msg() ( success "$@" ; printf "\n" 1>&2 ; ) -else - log_warning_msg() ( printf "warning:%s\n" "$@" 1>&2 ;) - log_failure_msg() ( printf "failure:%s\n" "$@" 1>&2 ;) - log_success_msg() ( printf "success:%s\n" "$@" 1>&2 ;) -fi - -# read the config -CREATE_DEFAULT=yes -if [ -e /etc/sysconfig/cgconfig ]; then - # shellcheck disable=SC1091 - source /etc/sysconfig/cgconfig -fi - -lockfiledir=$(dirname "$lockfile") - -create_default_groups() { - defaultcgroup= - - if [ -f /etc/cgrules.conf ]; then - # shellcheck disable=SC2034 - read -r user ctrl defaultcgroup <<< \ - "$(grep -m1 '^\*[[:space:]]\+' /etc/cgrules.conf)" - if [[ ( -n "$defaultcgroup" ) && ( "$defaultcgroup" = "*" ) ]]; then - log_warning_msg "/etc/cgrules.conf incorrect" - log_warning_msg "Overriding it" - defaultcgroup= - fi - fi - - if [[ -z "$defaultcgroup" ]] - then - defaultcgroup=sysdefault/ - fi - - # - # Find all mounted subsystems and create comma-separated list - # of controllers. - # - controllers=$(lssubsys 2>/dev/null | tr '\n' ',' | sed s/.$//) - - # - # Create the default group, ignore errors when the default group - # already exists. - # - cgcreate -f 664 -d 775 -g "$controllers":"$defaultcgroup" 2>/dev/null - - # - # special rule for cpusets - # - if echo "$controllers" | grep -q -w cpuset; then - cpus=$(cgget -nv -r cpuset.cpus /) - cgset -r cpuset.cpus="$cpus $defaultcgroup" - mems=$(cgget -nv -r cpuset.mems /) - cgset -r cpuset.mems="$mems $defaultcgroup" - fi - - # - # Classify everything to default cgroup. Ignore errors, some processes - # may exit after ps is run and before cgclassify moves them. - # - cgclassify -g "$controllers:$defaultcgroup $(ps --no-headers -eL o tid)" \ - 2>/dev/null || : -} - -start() { - printf "Starting %s service: " "$servicename" - if [[ -f "$lockfile" ]]; then - log_warning_msg "lock file already exists" - return 0 - fi - - if [[ ! -s "$CONFIG_FILE" ]]; then - log_failure_msg $CONFIG_FILE "is not configured" - return 6 - fi - - - if ! "$CGCONFIGPARSER_BIN" -l "$CONFIG_FILE" -L "$CONFIG_DIR" - then - log_failure_msg "Failed to parse " "$CONFIG_FILE" "or" "$CONFIG_DIR"'/*' - return 1 - fi - - if [ $CREATE_DEFAULT = "yes" ]; then - create_default_groups - fi - - if ! mkdir -p "$lockfiledir" ; then - log_failure_msg "Failed to mkdir $lockfiledir directory" - return 1 - fi - - - if ! touch "$lockfile" ; then - log_failure_msg "Failed to touch $lockfile" - return 1 - fi - log_success_msg "Started $servicename" - return 0 -} - -stop() { - printf "Stopping %s service is not supported!: " "$servicename" - log_failure_msg "Failed to stop $servicename" - return 1 -} - -trapped() { - # - # Do nothing - # - true -} - -usage() { - echo "$0 " - exit 2 -} - -common() { - # - # main script work done here - # - trap "trapped ABRT" ABRT - trap "trapped QUIT" QUIT - trap "trapped TERM" TERM - trap "trapped INT" INT -} - -restart() { - common - stop - start -} - -RETVAL=0 - -case $1 in - 'stop') - common - stop - RETVAL=$? - ;; - 'start') - common - start - RETVAL=$? - ;; - 'restart'|'reload') - restart - RETVAL=$? - ;; - 'condrestart') - if [[ -f "$lockfile" ]]; then - restart - RETVAL=$? - fi - ;; - 'status') - if [ -f "$lockfile" ]; then - echo "Running" - exit 0 - else - echo "Stopped" - exit 3 - fi - ;; - *) - usage - ;; -esac - -exit $RETVAL diff --git a/lib/libcgroup-3.1.0/scripts/init.d/cgred.in b/lib/libcgroup-3.1.0/scripts/init.d/cgred.in deleted file mode 100644 index 3374dafeb5b..00000000000 --- a/lib/libcgroup-3.1.0/scripts/init.d/cgred.in +++ /dev/null @@ -1,170 +0,0 @@ -#!/bin/bash -# SPDX-License-Identifier: LGPL-2.1-only -# -# Start/Stop the CGroups Rules Engine Daemon -# -# Copyright Red Hat Inc. 2008 -# -# Authors: Steve Olivieri -# -# cgred CGroups Rules Engine Daemon -# chkconfig: - 14 86 -# description: This is a daemon for automatically classifying processes \ -# into cgroups based on UID/GID. -# -# processname: cgrulesengd -# pidfile: /var/run/cgred.pid -# -### BEGIN INIT INFO -# Provides: cgrulesengd -# Required-Start: $local_fs $syslog $cgconfig -# Required-Stop: $local_fs $syslog -# Should-Start: -# Should-Stop: -# Short-Description: start and stop the cgroups rules engine daemon -# Description: CGroup Rules Engine is a tool for automatically using \ -# cgroups to classify processes -### END INIT INFO - -sbindir=@sbindir@ -CGRED_BIN=$sbindir/cgrulesengd - -# Sanity checks -[[ -x $CGRED_BIN ]] || exit 1 - -# -# Source LSB routines -# -SYSLIBFILE=/lib/lsb/init-functions -OLDSYSLIBFILE=/etc/init.d/functions -if [[ -x $SYSLIBFILE ]] ; then - # shellcheck disable=SC1090 - source $SYSLIBFILE -elif [[ -x $OLDSYSLIBFILE ]] ; then - # shellcheck disable=SC1090 - source $OLDSYSLIBFILE - log_warning_msg() ( warning "$@" ; printf "\n" 1>&2 ; ) - log_failure_msg() ( failure "$@" ; printf "\n" 1>&2 ; ) - log_success_msg() ( success "$@" ; printf "\n" 1>&2 ; ) -else - log_warning_msg() ( printf "warning:%s\n" "$@" 1>&2 ;) - log_failure_msg() ( printf "failure:%s\n" "$@" 1>&2 ;) - log_success_msg() ( printf "success:%s\n" "$@" 1>&2 ;) -fi - -# Read in configuration options. -if [[ -f "/etc/sysconfig/cgred.conf" ]] ; then - # shellcheck disable=SC1091 - source /etc/sysconfig/cgred.conf - OPTIONS="$NODAEMON $LOG" - if [[ -n "$LOG_FILE" ]]; then - OPTIONS="$OPTIONS --logfile=$LOG_FILE" - fi - if [[ -n "$SOCKET_USER" ]]; then - OPTIONS="$OPTIONS -u $SOCKET_USER" - fi - if [[ -n "$SOCKET_GROUP" ]]; then - OPTIONS="$OPTIONS -g $SOCKET_GROUP" - fi -else - OPTIONS="" -fi - -# For convenience -processname=cgrulesengd -servicename=cgred -lockfile="/var/lock/subsys/$servicename" -pidfile=/var/run/cgred.pid - -start() -{ - echo -n $"Starting CGroup Rules Engine Daemon: " - if [[ -f "$lockfile" ]]; then - log_failure_msg "$servicename is already running with PID $(cat ${pidfile})" - return 0 - fi - num=$(grep "cgroup" /proc/mounts | awk '$3=="cgroup"' | wc -l) - if [[ "$num" -eq 0 ]]; then - echo - log_failure_msg $"Cannot find cgroups, is cgconfig service running?" - return 1 - fi - daemon --check $servicename --pidfile $pidfile $CGRED_BIN $OPTIONS - retval=$? - echo - if [[ $retval -ne 0 ]]; then - return 7 - fi - if ! touch "$lockfile"; then - return 1 - fi - pidof "$processname" > $pidfile - return 0 -} - -stop() -{ - echo -n $"Stopping CGroup Rules Engine Daemon..." - if [[ ! -f $pidfile ]]; then - log_success_msg - return 0 - fi - killproc -p $pidfile -TERM "$processname" - retval=$? - echo - if [[ $retval -ne 0 ]]; then - return 1 - fi - rm -f "$lockfile" "$pidfile" - return 0 -} - -RETVAL=0 - -# See how we are called -case "$1" in - start) - start - RETVAL=$? - ;; - stop) - stop - RETVAL=$? - ;; - status) - status -p $pidfile $servicename - RETVAL=$? - ;; - restart) - stop - start - RETVAL=$? - ;; - condrestart) - if [[ -f "$lockfile" ]]; then - stop - start - RETVAL=$? - fi - ;; - reload|flash) - if [[ -f "$lockfile" ]]; then - echo $"Reloading rules configuration..." - kill -s 12 "$(cat ${pidfile})" - RETVAL=$? - if [[ $RETVAL -eq 0 ]] ; then - log_success_msg "" - else - log_failure_msg "" - fi - else - log_failure_msg "$servicename is not running." - fi - ;; - *) - echo $"Usage: $0 {start|stop|status|restart|condrestart|reload}" - RETVAL=2 - ;; -esac - -exit $RETVAL diff --git a/lib/libcgroup-3.1.0/src/Makefile.am b/lib/libcgroup-3.1.0/src/Makefile.am deleted file mode 100644 index 12c94b37d98..00000000000 --- a/lib/libcgroup-3.1.0/src/Makefile.am +++ /dev/null @@ -1,62 +0,0 @@ -@CODE_COVERAGE_RULES@ - -BUILT_SOURCES = parse.c parse.h - -DIST_SUBDIRS = . daemon pam tools python -SUBDIRS = . daemon pam tools -if ENABLE_PYTHON -SUBDIRS += python -endif -EXTRA_DIST = libcgroup_systemd_idle_thread - -# generate parse.h from parse.y -AM_YFLAGS = -d - -CLEANFILES = lex.c parse.c parse.h - -AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_builddir)/include - -VERSION_NUMBER = $(LIBRARY_VERSION_MAJOR):$(LIBRARY_VERSION_MINOR):$(LIBRARY_VERSION_RELEASE) -TESTING_MAP_FILE = $(top_srcdir)/tests/gunit/libcgroup_unittest.map - -if WITH_SYSTEMD -libcgroup_systemd_idle_thread_SOURCES = libcgroup_systemd_idle_thread.c -bin_PROGRAMS = libcgroup_systemd_idle_thread -endif - -lib_LTLIBRARIES = libcgroup.la -libcgroup_la_SOURCES = parse.h parse.y lex.l api.c config.c libcgroup-internal.h libcgroup.map \ - wrapper.c log.c abstraction-common.c abstraction-common.h \ - abstraction-map.c abstraction-map.h abstraction-cpu.c abstraction-cpuset.c \ - tools/cgxget.c tools/cgxset.c -if WITH_SYSTEMD -libcgroup_la_SOURCES += systemd.c -endif - -libcgroup_la_LIBADD = -lpthread $(CODE_COVERAGE_LIBS) -libcgroup_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) -DSTATIC=static -DLIBCG_LIB -fPIC - -libcgroup_la_LDFLAGS = -Wl,--version-script,$(srcdir)/libcgroup.map \ - -version-number $(VERSION_NUMBER) -if WITH_SYSTEMD -libcgroup_la_LDFLAGS += -lsystemd -libcgroup_la_CFLAGS += -DWITH_SYSTEMD -endif - -noinst_LTLIBRARIES = libcgroupfortesting.la -libcgroupfortesting_la_SOURCES = parse.h parse.y lex.l api.c config.c libcgroup-internal.h \ - libcgroup.map wrapper.c log.c abstraction-common.c \ - abstraction-common.h abstraction-map.c abstraction-map.h \ - abstraction-cpu.c abstraction-cpuset.c -if WITH_SYSTEMD -libcgroupfortesting_la_SOURCES += systemd.c -endif - -libcgroupfortesting_la_LIBADD = -lpthread $(CODE_COVERAGE_LIBS) -libcgroupfortesting_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) -DSTATIC= -DUNIT_TEST - -libcgroupfortesting_la_LDFLAGS = -Wl,--version-script,$(TESTING_MAP_FILE) \ - -version-number $(VERSION_NUMBER) -if WITH_SYSTEMD -libcgroupfortesting_la_LDFLAGS += -lsystemd -endif diff --git a/lib/libcgroup-3.1.0/src/Makefile.in b/lib/libcgroup-3.1.0/src/Makefile.in deleted file mode 100644 index 99199aa5b71..00000000000 --- a/lib/libcgroup-3.1.0/src/Makefile.in +++ /dev/null @@ -1,1281 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -@ENABLE_PYTHON_TRUE@am__append_1 = python -@WITH_SYSTEMD_TRUE@bin_PROGRAMS = \ -@WITH_SYSTEMD_TRUE@ libcgroup_systemd_idle_thread$(EXEEXT) -@WITH_SYSTEMD_TRUE@am__append_2 = systemd.c -@WITH_SYSTEMD_TRUE@am__append_3 = -lsystemd -@WITH_SYSTEMD_TRUE@am__append_4 = -DWITH_SYSTEMD -@WITH_SYSTEMD_TRUE@am__append_5 = systemd.c -@WITH_SYSTEMD_TRUE@am__append_6 = -lsystemd -subdir = src -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)" -PROGRAMS = $(bin_PROGRAMS) -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) -am__DEPENDENCIES_1 = -libcgroup_la_DEPENDENCIES = $(am__DEPENDENCIES_1) -am__libcgroup_la_SOURCES_DIST = parse.h parse.y lex.l api.c config.c \ - libcgroup-internal.h libcgroup.map wrapper.c log.c \ - abstraction-common.c abstraction-common.h abstraction-map.c \ - abstraction-map.h abstraction-cpu.c abstraction-cpuset.c \ - tools/cgxget.c tools/cgxset.c systemd.c -am__dirstamp = $(am__leading_dot)dirstamp -@WITH_SYSTEMD_TRUE@am__objects_1 = libcgroup_la-systemd.lo -am_libcgroup_la_OBJECTS = libcgroup_la-parse.lo libcgroup_la-lex.lo \ - libcgroup_la-api.lo libcgroup_la-config.lo \ - libcgroup_la-wrapper.lo libcgroup_la-log.lo \ - libcgroup_la-abstraction-common.lo \ - libcgroup_la-abstraction-map.lo \ - libcgroup_la-abstraction-cpu.lo \ - libcgroup_la-abstraction-cpuset.lo \ - tools/libcgroup_la-cgxget.lo tools/libcgroup_la-cgxset.lo \ - $(am__objects_1) -libcgroup_la_OBJECTS = $(am_libcgroup_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libcgroup_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(libcgroup_la_CFLAGS) \ - $(CFLAGS) $(libcgroup_la_LDFLAGS) $(LDFLAGS) -o $@ -libcgroupfortesting_la_DEPENDENCIES = $(am__DEPENDENCIES_1) -am__libcgroupfortesting_la_SOURCES_DIST = parse.h parse.y lex.l api.c \ - config.c libcgroup-internal.h libcgroup.map wrapper.c log.c \ - abstraction-common.c abstraction-common.h abstraction-map.c \ - abstraction-map.h abstraction-cpu.c abstraction-cpuset.c \ - systemd.c -@WITH_SYSTEMD_TRUE@am__objects_2 = libcgroupfortesting_la-systemd.lo -am_libcgroupfortesting_la_OBJECTS = libcgroupfortesting_la-parse.lo \ - libcgroupfortesting_la-lex.lo libcgroupfortesting_la-api.lo \ - libcgroupfortesting_la-config.lo \ - libcgroupfortesting_la-wrapper.lo \ - libcgroupfortesting_la-log.lo \ - libcgroupfortesting_la-abstraction-common.lo \ - libcgroupfortesting_la-abstraction-map.lo \ - libcgroupfortesting_la-abstraction-cpu.lo \ - libcgroupfortesting_la-abstraction-cpuset.lo $(am__objects_2) -libcgroupfortesting_la_OBJECTS = $(am_libcgroupfortesting_la_OBJECTS) -libcgroupfortesting_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ - $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ - $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) \ - $(libcgroupfortesting_la_LDFLAGS) $(LDFLAGS) -o $@ -am__libcgroup_systemd_idle_thread_SOURCES_DIST = \ - libcgroup_systemd_idle_thread.c -@WITH_SYSTEMD_TRUE@am_libcgroup_systemd_idle_thread_OBJECTS = \ -@WITH_SYSTEMD_TRUE@ libcgroup_systemd_idle_thread.$(OBJEXT) -libcgroup_systemd_idle_thread_OBJECTS = \ - $(am_libcgroup_systemd_idle_thread_OBJECTS) -libcgroup_systemd_idle_thread_LDADD = $(LDADD) -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/libcgroup_la-abstraction-common.Plo \ - ./$(DEPDIR)/libcgroup_la-abstraction-cpu.Plo \ - ./$(DEPDIR)/libcgroup_la-abstraction-cpuset.Plo \ - ./$(DEPDIR)/libcgroup_la-abstraction-map.Plo \ - ./$(DEPDIR)/libcgroup_la-api.Plo \ - ./$(DEPDIR)/libcgroup_la-config.Plo \ - ./$(DEPDIR)/libcgroup_la-lex.Plo \ - ./$(DEPDIR)/libcgroup_la-log.Plo \ - ./$(DEPDIR)/libcgroup_la-parse.Plo \ - ./$(DEPDIR)/libcgroup_la-systemd.Plo \ - ./$(DEPDIR)/libcgroup_la-wrapper.Plo \ - ./$(DEPDIR)/libcgroup_systemd_idle_thread.Po \ - ./$(DEPDIR)/libcgroupfortesting_la-abstraction-common.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-abstraction-map.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-api.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-config.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-lex.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-log.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-parse.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-systemd.Plo \ - ./$(DEPDIR)/libcgroupfortesting_la-wrapper.Plo \ - tools/$(DEPDIR)/libcgroup_la-cgxget.Plo \ - tools/$(DEPDIR)/libcgroup_la-cgxset.Plo -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -LEXCOMPILE = $(LEX) $(AM_LFLAGS) $(LFLAGS) -LTLEXCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(LEX) $(AM_LFLAGS) $(LFLAGS) -AM_V_LEX = $(am__v_LEX_@AM_V@) -am__v_LEX_ = $(am__v_LEX_@AM_DEFAULT_V@) -am__v_LEX_0 = @echo " LEX " $@; -am__v_LEX_1 = -YLWRAP = $(top_srcdir)/build-aux/ylwrap -am__yacc_c2h = sed -e s/cc$$/hh/ -e s/cpp$$/hpp/ -e s/cxx$$/hxx/ \ - -e s/c++$$/h++/ -e s/c$$/h/ -YACCCOMPILE = $(YACC) $(AM_YFLAGS) $(YFLAGS) -LTYACCCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(YACC) $(AM_YFLAGS) $(YFLAGS) -AM_V_YACC = $(am__v_YACC_@AM_V@) -am__v_YACC_ = $(am__v_YACC_@AM_DEFAULT_V@) -am__v_YACC_0 = @echo " YACC " $@; -am__v_YACC_1 = -SOURCES = $(libcgroup_la_SOURCES) $(libcgroupfortesting_la_SOURCES) \ - $(libcgroup_systemd_idle_thread_SOURCES) -DIST_SOURCES = $(am__libcgroup_la_SOURCES_DIST) \ - $(am__libcgroupfortesting_la_SOURCES_DIST) \ - $(am__libcgroup_systemd_idle_thread_SOURCES_DIST) -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir distdir-am -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp $(top_srcdir)/build-aux/ylwrap \ - lex.c parse.c parse.h -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -BUILT_SOURCES = parse.c parse.h -DIST_SUBDIRS = . daemon pam tools python -SUBDIRS = . daemon pam tools $(am__append_1) -EXTRA_DIST = libcgroup_systemd_idle_thread - -# generate parse.h from parse.y -AM_YFLAGS = -d -CLEANFILES = lex.c parse.c parse.h -AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_builddir)/include -VERSION_NUMBER = $(LIBRARY_VERSION_MAJOR):$(LIBRARY_VERSION_MINOR):$(LIBRARY_VERSION_RELEASE) -TESTING_MAP_FILE = $(top_srcdir)/tests/gunit/libcgroup_unittest.map -@WITH_SYSTEMD_TRUE@libcgroup_systemd_idle_thread_SOURCES = libcgroup_systemd_idle_thread.c -lib_LTLIBRARIES = libcgroup.la -libcgroup_la_SOURCES = parse.h parse.y lex.l api.c config.c \ - libcgroup-internal.h libcgroup.map wrapper.c log.c \ - abstraction-common.c abstraction-common.h abstraction-map.c \ - abstraction-map.h abstraction-cpu.c abstraction-cpuset.c \ - tools/cgxget.c tools/cgxset.c $(am__append_2) -libcgroup_la_LIBADD = -lpthread $(CODE_COVERAGE_LIBS) -libcgroup_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) -DSTATIC=static \ - -DLIBCG_LIB -fPIC $(am__append_4) -libcgroup_la_LDFLAGS = -Wl,--version-script,$(srcdir)/libcgroup.map \ - -version-number $(VERSION_NUMBER) $(am__append_3) -noinst_LTLIBRARIES = libcgroupfortesting.la -libcgroupfortesting_la_SOURCES = parse.h parse.y lex.l api.c config.c \ - libcgroup-internal.h libcgroup.map wrapper.c log.c \ - abstraction-common.c abstraction-common.h abstraction-map.c \ - abstraction-map.h abstraction-cpu.c abstraction-cpuset.c \ - $(am__append_5) -libcgroupfortesting_la_LIBADD = -lpthread $(CODE_COVERAGE_LIBS) -libcgroupfortesting_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) -DSTATIC= -DUNIT_TEST -libcgroupfortesting_la_LDFLAGS = \ - -Wl,--version-script,$(TESTING_MAP_FILE) -version-number \ - $(VERSION_NUMBER) $(am__append_6) -all: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -.SUFFIXES: .c .l .lo .o .obj .y -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ - fi; \ - for p in $$list; do echo "$$p $$p"; done | \ - sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p \ - || test -f $$p1 \ - ; then echo "$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n;h' \ - -e 's|.*|.|' \ - -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ - sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) files[d] = files[d] " " $$1; \ - else { print "f", $$3 "/" $$4, $$1; } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' \ - `; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(bindir)" && rm -f $$files - -clean-binPROGRAMS: - @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } -parse.h: parse.c - @if test ! -f $@; then rm -f parse.c; else :; fi - @if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) parse.c; else :; fi -tools/$(am__dirstamp): - @$(MKDIR_P) tools - @: > tools/$(am__dirstamp) -tools/$(DEPDIR)/$(am__dirstamp): - @$(MKDIR_P) tools/$(DEPDIR) - @: > tools/$(DEPDIR)/$(am__dirstamp) -tools/libcgroup_la-cgxget.lo: tools/$(am__dirstamp) \ - tools/$(DEPDIR)/$(am__dirstamp) -tools/libcgroup_la-cgxset.lo: tools/$(am__dirstamp) \ - tools/$(DEPDIR)/$(am__dirstamp) - -libcgroup.la: $(libcgroup_la_OBJECTS) $(libcgroup_la_DEPENDENCIES) $(EXTRA_libcgroup_la_DEPENDENCIES) - $(AM_V_CCLD)$(libcgroup_la_LINK) -rpath $(libdir) $(libcgroup_la_OBJECTS) $(libcgroup_la_LIBADD) $(LIBS) - -libcgroupfortesting.la: $(libcgroupfortesting_la_OBJECTS) $(libcgroupfortesting_la_DEPENDENCIES) $(EXTRA_libcgroupfortesting_la_DEPENDENCIES) - $(AM_V_CCLD)$(libcgroupfortesting_la_LINK) $(libcgroupfortesting_la_OBJECTS) $(libcgroupfortesting_la_LIBADD) $(LIBS) - -libcgroup_systemd_idle_thread$(EXEEXT): $(libcgroup_systemd_idle_thread_OBJECTS) $(libcgroup_systemd_idle_thread_DEPENDENCIES) $(EXTRA_libcgroup_systemd_idle_thread_DEPENDENCIES) - @rm -f libcgroup_systemd_idle_thread$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(libcgroup_systemd_idle_thread_OBJECTS) $(libcgroup_systemd_idle_thread_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -rm -f tools/*.$(OBJEXT) - -rm -f tools/*.lo - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-abstraction-common.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-abstraction-cpu.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-abstraction-cpuset.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-abstraction-map.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-api.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-config.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-lex.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-log.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-parse.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-systemd.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_la-wrapper.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroup_systemd_idle_thread.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-abstraction-common.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-abstraction-map.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-api.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-config.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-lex.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-log.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-parse.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-systemd.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgroupfortesting_la-wrapper.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@tools/$(DEPDIR)/libcgroup_la-cgxget.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@tools/$(DEPDIR)/libcgroup_la-cgxset.Plo@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -libcgroup_la-parse.lo: parse.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-parse.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-parse.Tpo -c -o libcgroup_la-parse.lo `test -f 'parse.c' || echo '$(srcdir)/'`parse.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-parse.Tpo $(DEPDIR)/libcgroup_la-parse.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='parse.c' object='libcgroup_la-parse.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-parse.lo `test -f 'parse.c' || echo '$(srcdir)/'`parse.c - -libcgroup_la-lex.lo: lex.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-lex.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-lex.Tpo -c -o libcgroup_la-lex.lo `test -f 'lex.c' || echo '$(srcdir)/'`lex.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-lex.Tpo $(DEPDIR)/libcgroup_la-lex.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lex.c' object='libcgroup_la-lex.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-lex.lo `test -f 'lex.c' || echo '$(srcdir)/'`lex.c - -libcgroup_la-api.lo: api.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-api.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-api.Tpo -c -o libcgroup_la-api.lo `test -f 'api.c' || echo '$(srcdir)/'`api.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-api.Tpo $(DEPDIR)/libcgroup_la-api.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='api.c' object='libcgroup_la-api.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-api.lo `test -f 'api.c' || echo '$(srcdir)/'`api.c - -libcgroup_la-config.lo: config.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-config.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-config.Tpo -c -o libcgroup_la-config.lo `test -f 'config.c' || echo '$(srcdir)/'`config.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-config.Tpo $(DEPDIR)/libcgroup_la-config.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='config.c' object='libcgroup_la-config.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-config.lo `test -f 'config.c' || echo '$(srcdir)/'`config.c - -libcgroup_la-wrapper.lo: wrapper.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-wrapper.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-wrapper.Tpo -c -o libcgroup_la-wrapper.lo `test -f 'wrapper.c' || echo '$(srcdir)/'`wrapper.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-wrapper.Tpo $(DEPDIR)/libcgroup_la-wrapper.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='wrapper.c' object='libcgroup_la-wrapper.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-wrapper.lo `test -f 'wrapper.c' || echo '$(srcdir)/'`wrapper.c - -libcgroup_la-log.lo: log.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-log.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-log.Tpo -c -o libcgroup_la-log.lo `test -f 'log.c' || echo '$(srcdir)/'`log.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-log.Tpo $(DEPDIR)/libcgroup_la-log.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='log.c' object='libcgroup_la-log.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-log.lo `test -f 'log.c' || echo '$(srcdir)/'`log.c - -libcgroup_la-abstraction-common.lo: abstraction-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-abstraction-common.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-abstraction-common.Tpo -c -o libcgroup_la-abstraction-common.lo `test -f 'abstraction-common.c' || echo '$(srcdir)/'`abstraction-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-abstraction-common.Tpo $(DEPDIR)/libcgroup_la-abstraction-common.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-common.c' object='libcgroup_la-abstraction-common.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-abstraction-common.lo `test -f 'abstraction-common.c' || echo '$(srcdir)/'`abstraction-common.c - -libcgroup_la-abstraction-map.lo: abstraction-map.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-abstraction-map.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-abstraction-map.Tpo -c -o libcgroup_la-abstraction-map.lo `test -f 'abstraction-map.c' || echo '$(srcdir)/'`abstraction-map.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-abstraction-map.Tpo $(DEPDIR)/libcgroup_la-abstraction-map.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-map.c' object='libcgroup_la-abstraction-map.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-abstraction-map.lo `test -f 'abstraction-map.c' || echo '$(srcdir)/'`abstraction-map.c - -libcgroup_la-abstraction-cpu.lo: abstraction-cpu.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-abstraction-cpu.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-abstraction-cpu.Tpo -c -o libcgroup_la-abstraction-cpu.lo `test -f 'abstraction-cpu.c' || echo '$(srcdir)/'`abstraction-cpu.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-abstraction-cpu.Tpo $(DEPDIR)/libcgroup_la-abstraction-cpu.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-cpu.c' object='libcgroup_la-abstraction-cpu.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-abstraction-cpu.lo `test -f 'abstraction-cpu.c' || echo '$(srcdir)/'`abstraction-cpu.c - -libcgroup_la-abstraction-cpuset.lo: abstraction-cpuset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-abstraction-cpuset.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-abstraction-cpuset.Tpo -c -o libcgroup_la-abstraction-cpuset.lo `test -f 'abstraction-cpuset.c' || echo '$(srcdir)/'`abstraction-cpuset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-abstraction-cpuset.Tpo $(DEPDIR)/libcgroup_la-abstraction-cpuset.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-cpuset.c' object='libcgroup_la-abstraction-cpuset.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-abstraction-cpuset.lo `test -f 'abstraction-cpuset.c' || echo '$(srcdir)/'`abstraction-cpuset.c - -tools/libcgroup_la-cgxget.lo: tools/cgxget.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT tools/libcgroup_la-cgxget.lo -MD -MP -MF tools/$(DEPDIR)/libcgroup_la-cgxget.Tpo -c -o tools/libcgroup_la-cgxget.lo `test -f 'tools/cgxget.c' || echo '$(srcdir)/'`tools/cgxget.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) tools/$(DEPDIR)/libcgroup_la-cgxget.Tpo tools/$(DEPDIR)/libcgroup_la-cgxget.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools/cgxget.c' object='tools/libcgroup_la-cgxget.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o tools/libcgroup_la-cgxget.lo `test -f 'tools/cgxget.c' || echo '$(srcdir)/'`tools/cgxget.c - -tools/libcgroup_la-cgxset.lo: tools/cgxset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT tools/libcgroup_la-cgxset.lo -MD -MP -MF tools/$(DEPDIR)/libcgroup_la-cgxset.Tpo -c -o tools/libcgroup_la-cgxset.lo `test -f 'tools/cgxset.c' || echo '$(srcdir)/'`tools/cgxset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) tools/$(DEPDIR)/libcgroup_la-cgxset.Tpo tools/$(DEPDIR)/libcgroup_la-cgxset.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools/cgxset.c' object='tools/libcgroup_la-cgxset.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o tools/libcgroup_la-cgxset.lo `test -f 'tools/cgxset.c' || echo '$(srcdir)/'`tools/cgxset.c - -libcgroup_la-systemd.lo: systemd.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -MT libcgroup_la-systemd.lo -MD -MP -MF $(DEPDIR)/libcgroup_la-systemd.Tpo -c -o libcgroup_la-systemd.lo `test -f 'systemd.c' || echo '$(srcdir)/'`systemd.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroup_la-systemd.Tpo $(DEPDIR)/libcgroup_la-systemd.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='systemd.c' object='libcgroup_la-systemd.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroup_la_CFLAGS) $(CFLAGS) -c -o libcgroup_la-systemd.lo `test -f 'systemd.c' || echo '$(srcdir)/'`systemd.c - -libcgroupfortesting_la-parse.lo: parse.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-parse.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-parse.Tpo -c -o libcgroupfortesting_la-parse.lo `test -f 'parse.c' || echo '$(srcdir)/'`parse.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-parse.Tpo $(DEPDIR)/libcgroupfortesting_la-parse.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='parse.c' object='libcgroupfortesting_la-parse.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-parse.lo `test -f 'parse.c' || echo '$(srcdir)/'`parse.c - -libcgroupfortesting_la-lex.lo: lex.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-lex.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-lex.Tpo -c -o libcgroupfortesting_la-lex.lo `test -f 'lex.c' || echo '$(srcdir)/'`lex.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-lex.Tpo $(DEPDIR)/libcgroupfortesting_la-lex.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lex.c' object='libcgroupfortesting_la-lex.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-lex.lo `test -f 'lex.c' || echo '$(srcdir)/'`lex.c - -libcgroupfortesting_la-api.lo: api.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-api.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-api.Tpo -c -o libcgroupfortesting_la-api.lo `test -f 'api.c' || echo '$(srcdir)/'`api.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-api.Tpo $(DEPDIR)/libcgroupfortesting_la-api.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='api.c' object='libcgroupfortesting_la-api.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-api.lo `test -f 'api.c' || echo '$(srcdir)/'`api.c - -libcgroupfortesting_la-config.lo: config.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-config.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-config.Tpo -c -o libcgroupfortesting_la-config.lo `test -f 'config.c' || echo '$(srcdir)/'`config.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-config.Tpo $(DEPDIR)/libcgroupfortesting_la-config.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='config.c' object='libcgroupfortesting_la-config.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-config.lo `test -f 'config.c' || echo '$(srcdir)/'`config.c - -libcgroupfortesting_la-wrapper.lo: wrapper.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-wrapper.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-wrapper.Tpo -c -o libcgroupfortesting_la-wrapper.lo `test -f 'wrapper.c' || echo '$(srcdir)/'`wrapper.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-wrapper.Tpo $(DEPDIR)/libcgroupfortesting_la-wrapper.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='wrapper.c' object='libcgroupfortesting_la-wrapper.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-wrapper.lo `test -f 'wrapper.c' || echo '$(srcdir)/'`wrapper.c - -libcgroupfortesting_la-log.lo: log.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-log.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-log.Tpo -c -o libcgroupfortesting_la-log.lo `test -f 'log.c' || echo '$(srcdir)/'`log.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-log.Tpo $(DEPDIR)/libcgroupfortesting_la-log.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='log.c' object='libcgroupfortesting_la-log.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-log.lo `test -f 'log.c' || echo '$(srcdir)/'`log.c - -libcgroupfortesting_la-abstraction-common.lo: abstraction-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-abstraction-common.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-abstraction-common.Tpo -c -o libcgroupfortesting_la-abstraction-common.lo `test -f 'abstraction-common.c' || echo '$(srcdir)/'`abstraction-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-abstraction-common.Tpo $(DEPDIR)/libcgroupfortesting_la-abstraction-common.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-common.c' object='libcgroupfortesting_la-abstraction-common.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-abstraction-common.lo `test -f 'abstraction-common.c' || echo '$(srcdir)/'`abstraction-common.c - -libcgroupfortesting_la-abstraction-map.lo: abstraction-map.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-abstraction-map.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-abstraction-map.Tpo -c -o libcgroupfortesting_la-abstraction-map.lo `test -f 'abstraction-map.c' || echo '$(srcdir)/'`abstraction-map.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-abstraction-map.Tpo $(DEPDIR)/libcgroupfortesting_la-abstraction-map.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-map.c' object='libcgroupfortesting_la-abstraction-map.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-abstraction-map.lo `test -f 'abstraction-map.c' || echo '$(srcdir)/'`abstraction-map.c - -libcgroupfortesting_la-abstraction-cpu.lo: abstraction-cpu.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-abstraction-cpu.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Tpo -c -o libcgroupfortesting_la-abstraction-cpu.lo `test -f 'abstraction-cpu.c' || echo '$(srcdir)/'`abstraction-cpu.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Tpo $(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-cpu.c' object='libcgroupfortesting_la-abstraction-cpu.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-abstraction-cpu.lo `test -f 'abstraction-cpu.c' || echo '$(srcdir)/'`abstraction-cpu.c - -libcgroupfortesting_la-abstraction-cpuset.lo: abstraction-cpuset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-abstraction-cpuset.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Tpo -c -o libcgroupfortesting_la-abstraction-cpuset.lo `test -f 'abstraction-cpuset.c' || echo '$(srcdir)/'`abstraction-cpuset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Tpo $(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='abstraction-cpuset.c' object='libcgroupfortesting_la-abstraction-cpuset.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-abstraction-cpuset.lo `test -f 'abstraction-cpuset.c' || echo '$(srcdir)/'`abstraction-cpuset.c - -libcgroupfortesting_la-systemd.lo: systemd.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -MT libcgroupfortesting_la-systemd.lo -MD -MP -MF $(DEPDIR)/libcgroupfortesting_la-systemd.Tpo -c -o libcgroupfortesting_la-systemd.lo `test -f 'systemd.c' || echo '$(srcdir)/'`systemd.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgroupfortesting_la-systemd.Tpo $(DEPDIR)/libcgroupfortesting_la-systemd.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='systemd.c' object='libcgroupfortesting_la-systemd.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgroupfortesting_la_CFLAGS) $(CFLAGS) -c -o libcgroupfortesting_la-systemd.lo `test -f 'systemd.c' || echo '$(srcdir)/'`systemd.c - -.l.c: - $(AM_V_LEX)$(am__skiplex) $(SHELL) $(YLWRAP) $< $(LEX_OUTPUT_ROOT).c $@ -- $(LEXCOMPILE) - -.y.c: - $(AM_V_YACC)$(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h `echo $@ | $(am__yacc_c2h)` y.output $*.output -- $(YACCCOMPILE) - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -rm -rf tools/.libs tools/_libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) check-recursive -all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) -install-binPROGRAMS: install-libLTLIBRARIES - -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(libdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) install-recursive -install-exec: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -rm -f tools/$(DEPDIR)/$(am__dirstamp) - -rm -f tools/$(am__dirstamp) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -rm -f lex.c - -rm -f parse.c - -rm -f parse.h - -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) -clean: clean-recursive - -clean-am: clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \ - clean-libtool clean-noinstLTLIBRARIES mostlyclean-am - -distclean: distclean-recursive - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-common.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-cpu.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-cpuset.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-map.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-api.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-config.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-lex.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-log.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-parse.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-systemd.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-wrapper.Plo - -rm -f ./$(DEPDIR)/libcgroup_systemd_idle_thread.Po - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-common.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-map.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-api.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-config.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-lex.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-log.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-parse.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-systemd.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-wrapper.Plo - -rm -f tools/$(DEPDIR)/libcgroup_la-cgxget.Plo - -rm -f tools/$(DEPDIR)/libcgroup_la-cgxset.Plo - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: install-binPROGRAMS install-libLTLIBRARIES - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-common.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-cpu.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-cpuset.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-abstraction-map.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-api.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-config.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-lex.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-log.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-parse.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-systemd.Plo - -rm -f ./$(DEPDIR)/libcgroup_la-wrapper.Plo - -rm -f ./$(DEPDIR)/libcgroup_systemd_idle_thread.Po - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-common.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpu.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-cpuset.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-abstraction-map.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-api.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-config.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-lex.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-log.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-parse.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-systemd.Plo - -rm -f ./$(DEPDIR)/libcgroupfortesting_la-wrapper.Plo - -rm -f tools/$(DEPDIR)/libcgroup_la-cgxget.Plo - -rm -f tools/$(DEPDIR)/libcgroup_la-cgxset.Plo - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-binPROGRAMS uninstall-libLTLIBRARIES - -.MAKE: $(am__recursive_targets) all check install install-am \ - install-exec install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--depfiles check check-am clean clean-binPROGRAMS \ - clean-generic clean-libLTLIBRARIES clean-libtool \ - clean-noinstLTLIBRARIES cscopelist-am ctags ctags-am distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-binPROGRAMS install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-libLTLIBRARIES install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-binPROGRAMS uninstall-libLTLIBRARIES - -.PRECIOUS: Makefile - -@CODE_COVERAGE_RULES@ - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/src/abstraction-common.c b/lib/libcgroup-3.1.0/src/abstraction-common.c deleted file mode 100644 index fe0511d1a46..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-common.c +++ /dev/null @@ -1,286 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup abstraction layer - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include "abstraction-common.h" -#include "abstraction-map.h" - -#include -#include - -#include -#include -#include -#include -#include - - -int cgroup_strtol(const char * const in_str, int base, long * const out_value) -{ - char *endptr = NULL; - int ret = 0; - - if (out_value == NULL) { - cgroup_err("Invalid parameter to %s\n", __func__); - ret = ECGINVAL; - goto out; - } - - errno = 0; - *out_value = strtol(in_str, &endptr, base); - - /* taken directly from strtol's man page */ - if ((errno == ERANGE && (*out_value == LONG_MAX || *out_value == LONG_MIN)) || - (errno != 0 && *out_value == 0)) { - cgroup_err("Failed to convert %s from strtol: %s\n", in_str); - ret = ECGFAIL; - goto out; - } - - if (endptr == in_str) { - cgroup_err("No long value found in %s\n", in_str); - ret = ECGFAIL; - goto out; - } - -out: - return ret; -} - -int cgroup_convert_int(struct cgroup_controller * const dst_cgc, const char * const in_value, - const char * const out_setting, void *in_dflt, void *out_dflt) -{ -#define OUT_VALUE_STR_LEN 20 - - long out_dflt_int = (long)out_dflt; - long in_dflt_int = (long)in_dflt; - char *out_value_str = NULL; - long out_value; - int ret; - - if (!in_value) - return ECGINVAL; - - if (strlen(in_value) > 0) { - ret = cgroup_strtol(in_value, 10, &out_value); - if (ret) - goto out; - - /* now scale from the input range to the output range */ - out_value = out_value * out_dflt_int / in_dflt_int; - - out_value_str = calloc(sizeof(char), OUT_VALUE_STR_LEN); - if (!out_value_str) { - ret = ECGOTHER; - goto out; - } - - ret = snprintf(out_value_str, OUT_VALUE_STR_LEN, "%ld", out_value); - if (ret == OUT_VALUE_STR_LEN) { - /* we ran out of room in the string. throw an error */ - cgroup_err("output value too large for string: %d\n", out_value); - ret = ECGFAIL; - goto out; - } - } - - ret = cgroup_add_value_string(dst_cgc, out_setting, out_value_str); - -out: - if (out_value_str) - free(out_value_str); - - return ret; -} - -int cgroup_convert_name_only(struct cgroup_controller * const dst_cgc, const char * const in_value, - const char * const out_setting, void *in_dflt, void *out_dflt) -{ - return cgroup_add_value_string(dst_cgc, out_setting, in_value); -} - -int cgroup_convert_passthrough(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - return cgroup_add_value_string(dst_cgc, out_setting, in_value); -} - -int cgroup_convert_unmappable(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - return ECGNOVERSIONCONVERT; -} - -static int convert_setting(struct cgroup_controller * const out_cgc, - const struct control_value * const in_ctrl_val) -{ - const struct cgroup_abstraction_map *convert_tbl; - int ret = ECGINVAL; - int tbl_sz = 0; - int i; - - switch (out_cgc->version) { - case CGROUP_V1: - convert_tbl = cgroup_v2_to_v1_map; - tbl_sz = cgroup_v2_to_v1_map_sz; - break; - case CGROUP_V2: - convert_tbl = cgroup_v1_to_v2_map; - tbl_sz = cgroup_v1_to_v2_map_sz; - break; - default: - ret = ECGFAIL; - goto out; - } - - for (i = 0; i < tbl_sz; i++) { - /* - * For a few settings, e.g. - * cpu.max <-> cpu.cfs_quota_us/cpu.cfs_period_us, the - * conversion from the N->1 field (cpu.max) back to one of the - * other settings cannot be done without prior knowledge of our - * desired setting (quota or period in this example). - * If prev_name is set, it can guide us back to the correct - * mapping. - */ - if (strcmp(convert_tbl[i].in_setting, in_ctrl_val->name) == 0 && - (in_ctrl_val->prev_name == NULL || - strcmp(in_ctrl_val->prev_name, convert_tbl[i].out_setting) == 0)) { - - ret = convert_tbl[i].cgroup_convert(out_cgc, in_ctrl_val->value, - convert_tbl[i].out_setting, - convert_tbl[i].in_dflt, - convert_tbl[i].out_dflt); - if (ret) - goto out; - } - } - -out: - return ret; -} - -static int convert_controller(struct cgroup_controller ** const out_cgc, - struct cgroup_controller * const in_cgc) -{ - bool unmappable = false; - int ret; - int i; - - - if (in_cgc->version == (*out_cgc)->version) { - ret = cgroup_copy_controller_values(*out_cgc, in_cgc); - /* regardless of success/failure, there's nothing more to do */ - goto out; - } - - if (strcmp(in_cgc->name, "cpu") == 0) { - ret = cgroup_convert_cpu_nto1(*out_cgc, in_cgc); - if (ret) - goto out; - } - - for (i = 0; i < in_cgc->index; i++) { - ret = convert_setting(*out_cgc, in_cgc->values[i]); - if (ret == ECGNOVERSIONCONVERT) { - /* - * Ignore unmappable errors while they happen, as - * there may be mappable settings after that - */ - unmappable = true; - ret = 0; - } else if (ret) { - /* immediately fail on all other errors */ - goto out; - } - } - -out: - if (ret == 0 && unmappable) { - /* The only error received was an unmappable error. Return it. */ - ret = ECGNOVERSIONCONVERT; - - if ((*out_cgc)->index == 0) { - /* - * No settings were successfully converted. Remove this - * controller so that tools like cgxget aren't confused - */ - cgroup_free_controller(*out_cgc); - *out_cgc = NULL; - } - } - - return ret; -} - -int cgroup_convert_cgroup(struct cgroup * const out_cgroup, enum cg_version_t out_version, - const struct cgroup * const in_cgroup, enum cg_version_t in_version) -{ - struct cgroup_controller *cgc; - bool unmappable = false; - int ret = 0; - int i; - - for (i = 0; i < in_cgroup->index; i++) { - cgc = cgroup_add_controller(out_cgroup, in_cgroup->controller[i]->name); - if (cgc == NULL) { - ret = ECGFAIL; - goto out; - } - - /* the user has overridden the version */ - if (in_version == CGROUP_V1 || in_version == CGROUP_V2) - in_cgroup->controller[i]->version = in_version; - - if (strcmp(CGROUP_FILE_PREFIX, cgc->name) == 0) - /* - * libcgroup only supports accessing cgroup.* files - * on cgroup v2 filesystems. - */ - cgc->version = CGROUP_V2; - else - cgc->version = out_version; - - if (cgc->version == CGROUP_UNK || cgc->version == CGROUP_DISK) { - ret = cgroup_get_controller_version(cgc->name, &cgc->version); - if (ret) - goto out; - } - - ret = convert_controller(&cgc, in_cgroup->controller[i]); - if (ret == ECGNOVERSIONCONVERT) { - /* - * Ignore unmappable errors while they happen, as - * there may be mappable settings after that - */ - unmappable = true; - - if (!cgc) - /* - * The converted controller had no settings - * and was removed. It's up to us to manage - * the controller count - */ - out_cgroup->index--; - } else if (ret) { - /* immediately fail on all other errors */ - goto out; - } - } - -out: - if (ret == 0 && unmappable) - /* - * The only error received was an unmappable - * error. Return it. - */ - ret = ECGNOVERSIONCONVERT; - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/abstraction-common.h b/lib/libcgroup-3.1.0/src/abstraction-common.h deleted file mode 100644 index e14b1a69462..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-common.h +++ /dev/null @@ -1,119 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Libcgroup abstraction layer prototypes and structs - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#ifndef __ABSTRACTION_COMMON -#define __ABSTRACTION_COMMON - -#ifdef __cplusplus -extern "C" { -#endif - -#include "config.h" - -#include -#include "libcgroup-internal.h" - -/** - * Convert a string to a long - * - * @param in_str String to be converted - * @param base Integer base - * @param out_value Pointer to hold the output long value - * - * @return 0 on success, - * ECGFAIL if the conversion to long failed, - * ECGINVAL upon an invalid parameter - */ -int cgroup_strtol(const char * const in_str, int base, long * const out_value); - -/** - * Convert an integer setting to another integer setting - * - * @param dst_cgc Destination cgroup controller - * @param in_value Contents of the input setting - * @param out_setting Destination cgroup setting - * @param in_dflt Default value of the input setting (used to scale the value) - * @param out_dflt Default value of the output setting (used to scale the value) - */ -int cgroup_convert_int(struct cgroup_controller * const dst_cgc, const char * const in_value, - const char * const out_setting, void *in_dflt, void *out_dflt); - -/** - * Convert only the name from one setting to another. The contents remain - * the same - * - * @param dst_cgc Destination cgroup controller - * @param in_value Contents of the input setting - * @param out_setting Destination cgroup setting - * @param in_dflt Default value of the input setting (unused) - * @param out_dflt Default value of the output setting (unused) - */ -int cgroup_convert_name_only(struct cgroup_controller * const dst_cgc, const char * const in_value, - const char * const out_setting, void *in_dflt, void *out_dflt); - -/** - * No conversion necessary. The name and the contents are the same - * - * @param dst_cgc Destination cgroup controller - * @param in_value Contents of the input setting - * @param out_setting Destination cgroup setting - * @param in_dflt Default value of the input setting (unused) - * @param out_dflt Default value of the output setting (unused) - */ -int cgroup_convert_passthrough(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -/** - * Convert from an unmapple setting - * - * @param dst_cgc Destination cgroup controller (unused) - * @param in_value Contents of the input setting (unsed) - * @param out_setting Destination cgroup setting (unused) - * @param in_dflt Default value of the input setting (unused) - * @param out_dflt Default value of the output setting (unused) - * @return Always returns ECGNOVERSIONCONVERT - */ -int cgroup_convert_unmappable(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -/* cpu */ -int cgroup_convert_cpu_nto1(struct cgroup_controller * const out_cgc, - struct cgroup_controller * const in_cgc); - -int cgroup_convert_cpu_quota_to_max(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -int cgroup_convert_cpu_period_to_max(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -int cgroup_convert_cpu_max_to_quota(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -int cgroup_convert_cpu_max_to_period(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -/* cpuset */ -int cgroup_convert_cpuset_to_exclusive(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -int cgroup_convert_cpuset_to_partition(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt); - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* __ABSTRACTION_COMMON */ diff --git a/lib/libcgroup-3.1.0/src/abstraction-cpu.c b/lib/libcgroup-3.1.0/src/abstraction-cpu.c deleted file mode 100644 index 5a56bc07fe5..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-cpu.c +++ /dev/null @@ -1,271 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup abstraction layer for the cpu controller - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include "abstraction-common.h" -#include "abstraction-map.h" - -#include -#include - -#include -#include -#include -#include -#include - -#define LL_MAX 8192 - -static const char * const MAX = "max"; -static const char * const CPU_MAX = "cpu.max"; -static const char * const CFS_QUOTA_US = "cpu.cfs_quota_us"; -static const char * const CFS_PERIOD_US = "cpu.cfs_period_us"; - -static int read_setting(const char * const cgroup_name, const char * const controller_name, - const char * const setting_name, char ** const value) -{ - char tmp_line[LL_MAX]; - void *handle; - int ret; - - ret = cgroup_read_value_begin(controller_name, cgroup_name, setting_name, &handle, - tmp_line, LL_MAX); - if (ret == ECGEOF) - goto read_end; - else if (ret != 0) - goto end; - - *value = strdup(tmp_line); - if ((*value) == NULL) - ret = ECGOTHER; - -read_end: - cgroup_read_value_end(&handle); - if (ret == ECGEOF) - ret = 0; -end: - return ret; -} - -static int get_max(struct cgroup_controller * const cgc, char ** const max) -{ - return read_setting(cgc->cgroup->name, "cpu", "cpu.max", max); -} - -static int get_quota_from_max(struct cgroup_controller * const cgc, char ** const quota) -{ - char *token, *max = NULL, *saveptr = NULL; - int ret; - - ret = get_max(cgc, &max); - if (ret) - goto out; - - token = strtok_r(max, " ", &saveptr); - - *quota = strdup(token); - if ((*quota) == NULL) - ret = ECGOTHER; - -out: - if (max) - free(max); - - return ret; -} - -static int get_period_from_max(struct cgroup_controller * const cgc, char ** const period) -{ - char *token, *max = NULL, *saveptr = NULL; - int ret; - - ret = get_max(cgc, &max); - if (ret) - goto out; - - token = strtok_r(max, " ", &saveptr); - token = strtok_r(NULL, " ", &saveptr); - - *period = strdup(token); - if ((*period) == NULL) - ret = ECGOTHER; - -out: - if (max) - free(max); - - return ret; -} - -int cgroup_convert_cpu_quota_to_max(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - char max_line[LL_MAX] = {0}; - char *period = NULL; - int ret; - - if (strlen(in_value) == 0) { - /* There's no value to convert. Populate the setting */ - ret = cgroup_add_value_string(dst_cgc, out_setting, NULL); - if (ret) - goto out; - } else { - ret = get_period_from_max(dst_cgc, &period); - if (ret) - goto out; - - if (strcmp(in_value, "-1") == 0) - snprintf(max_line, LL_MAX, "%s %s", MAX, period); - else - snprintf(max_line, LL_MAX, "%s %s", in_value, period); - - ret = cgroup_add_value_string(dst_cgc, out_setting, max_line); - if (ret) - goto out; - } - - dst_cgc->values[dst_cgc->index - 1]->prev_name = strdup(CFS_QUOTA_US); - -out: - if (period) - free(period); - - return ret; -} - -int cgroup_convert_cpu_period_to_max(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - char max_line[LL_MAX] = {0}; - char *quota = NULL; - int ret; - - if (strlen(in_value) == 0) { - /* There's no value to convert. Populate the setting and return */ - ret = cgroup_add_value_string(dst_cgc, out_setting, NULL); - if (ret) - goto out; - } else { - ret = get_quota_from_max(dst_cgc, "a); - if (ret) - goto out; - - if (strcmp(in_value, "-1") == 0) - snprintf(max_line, LL_MAX, "%s %s", quota, MAX); - else - snprintf(max_line, LL_MAX, "%s %s", quota, in_value); - ret = cgroup_add_value_string(dst_cgc, out_setting, max_line); - if (ret) - goto out; - } - - dst_cgc->values[dst_cgc->index - 1]->prev_name = strdup(CFS_PERIOD_US); - -out: - if (quota) - free(quota); - - return ret; -} - -int cgroup_convert_cpu_max_to_quota(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - char *token, *copy = NULL, *saveptr = NULL; - int ret; - - if (strlen(in_value) == 0) { - /* There's no value to convert. Populate the setting and return */ - return cgroup_add_value_string(dst_cgc, out_setting, NULL); - } - - copy = strdup(in_value); - if (!copy) - return ECGOTHER; - - token = strtok_r(copy, " ", &saveptr); - - if (strcmp(token, MAX) == 0) - ret = cgroup_add_value_string(dst_cgc, out_setting, "-1"); - else - ret = cgroup_add_value_string(dst_cgc, out_setting, token); - - if (copy) - free(copy); - - return ret; -} - -int cgroup_convert_cpu_max_to_period(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - char *token, *copy = NULL, *saveptr = NULL; - int ret; - - if (strlen(in_value) == 0) { - /* There's no value to convert. Populate the setting and return */ - return cgroup_add_value_string(dst_cgc, out_setting, NULL); - } - - copy = strdup(in_value); - if (!copy) - return ECGOTHER; - - token = strtok_r(copy, " ", &saveptr); - token = strtok_r(NULL, " ", &saveptr); - - ret = cgroup_add_value_string(dst_cgc, out_setting, token); - - if (copy) - free(copy); - - return ret; -} - -int cgroup_convert_cpu_nto1(struct cgroup_controller * const out_cgc, - struct cgroup_controller * const in_cgc) -{ - char *cfs_quota = NULL, *cfs_period = NULL; - char max_line[LL_MAX] = {0}; - int i, ret = 0; - - for (i = 0; i < in_cgc->index; i++) { - if (strcmp(in_cgc->values[i]->name, CFS_QUOTA_US) == 0) - cfs_quota = in_cgc->values[i]->value; - else if (strcmp(in_cgc->values[i]->name, CFS_PERIOD_US) == 0) - cfs_period = in_cgc->values[i]->value; - } - - if (cfs_quota && cfs_period) { - if (strcmp(cfs_quota, "-1") == 0) { - snprintf(max_line, LL_MAX, "%s %s", MAX, cfs_period); - max_line[LL_MAX - 1] = '\0'; - } else { - snprintf(max_line, LL_MAX, "%s %s", cfs_quota, cfs_period); - max_line[LL_MAX - 1] = '\0'; - } - - ret = cgroup_add_value_string(out_cgc, CPU_MAX, max_line); - if (ret) - goto out; - - ret = cgroup_remove_value(in_cgc, CFS_QUOTA_US); - if (ret) - goto out; - - ret = cgroup_remove_value(in_cgc, CFS_PERIOD_US); - if (ret) - goto out; - } - -out: - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/abstraction-cpuset.c b/lib/libcgroup-3.1.0/src/abstraction-cpuset.c deleted file mode 100644 index 745847050fd..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-cpuset.c +++ /dev/null @@ -1,50 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup abstraction layer for the cpuset controller - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include "abstraction-common.h" - -#include -#include - -#include -#include -#include -#include -#include - -static const char * const MEMBER = "member"; -static const char * const ROOT = "root"; - -int cgroup_convert_cpuset_to_exclusive(struct cgroup_controller * const dst_cgc, - const char * const in_value, const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - int ret; - - if (strcmp(in_value, ROOT) == 0) - ret = cgroup_add_value_string(dst_cgc, out_setting, "1"); - else - ret = cgroup_add_value_string(dst_cgc, out_setting, "0"); - - return ret; -} - -int cgroup_convert_cpuset_to_partition(struct cgroup_controller * const dst_cgc, - const char * const in_value, - const char * const out_setting, - void *in_dflt, void *out_dflt) -{ - int ret; - - if (strcmp(in_value, "1") == 0) - ret = cgroup_add_value_string(dst_cgc, out_setting, ROOT); - else - ret = cgroup_add_value_string(dst_cgc, out_setting, MEMBER); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/abstraction-map.c b/lib/libcgroup-3.1.0/src/abstraction-map.c deleted file mode 100644 index 1735e364ea7..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-map.c +++ /dev/null @@ -1,62 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup abstraction layer mappings - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include "abstraction-common.h" -#include "abstraction-map.h" - -#include -#include - -#include -#include -#include -#include -#include - -const struct cgroup_abstraction_map cgroup_v1_to_v2_map[] = { - /* cpu controller */ - {cgroup_convert_int, "cpu.shares", (void *)1024, "cpu.weight", (void *)100}, - {cgroup_convert_cpu_quota_to_max, "cpu.cfs_quota_us", NULL, "cpu.max", NULL}, - {cgroup_convert_cpu_period_to_max, "cpu.cfs_period_us", NULL, "cpu.max", NULL}, - {cgroup_convert_unmappable, "cpu.stat", NULL, "cpu.stat", NULL}, - - /* cpuset controller */ - {cgroup_convert_name_only, "cpuset.effective_cpus", NULL, "cpuset.cpus.effective", NULL}, - {cgroup_convert_name_only, "cpuset.effective_mems", NULL, "cpuset.mems.effective", NULL}, - {cgroup_convert_passthrough, "cpuset.cpus", NULL, "cpuset.cpus", NULL}, - {cgroup_convert_passthrough, "cpuset.mems", NULL, "cpuset.mems", NULL}, - {cgroup_convert_cpuset_to_partition, "cpuset.cpu_exclusive", NULL, - "cpuset.cpus.partition", NULL}, - {cgroup_convert_unmappable, "cpuset.mem_exclusive", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.mem_hardwall", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.memory_migrate", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.memory_pressure", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.mem_pressure_enabled", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.memory_spread_page", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.memory_spread_slab", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.sched_load_balance", NULL, NULL, NULL}, - {cgroup_convert_unmappable, "cpuset.sched_relax_domain_level", NULL, NULL, NULL}, -}; -const int cgroup_v1_to_v2_map_sz = sizeof(cgroup_v1_to_v2_map) / sizeof(cgroup_v1_to_v2_map[0]); - -const struct cgroup_abstraction_map cgroup_v2_to_v1_map[] = { - /* cpu controller */ - {cgroup_convert_int, "cpu.weight", (void *)100, "cpu.shares", (void *)1024}, - {cgroup_convert_cpu_max_to_quota, "cpu.max", NULL, "cpu.cfs_quota_us", NULL}, - {cgroup_convert_cpu_max_to_period, "cpu.max", NULL, "cpu.cfs_period_us", NULL}, - {cgroup_convert_unmappable, "cpu.stat", NULL, "cpu.stat", NULL}, - - /* cpuset controller */ - {cgroup_convert_name_only, "cpuset.cpus.effective", NULL, "cpuset.effective_cpus", NULL}, - {cgroup_convert_name_only, "cpuset.mems.effective", NULL, "cpuset.effective_mems", NULL}, - {cgroup_convert_passthrough, "cpuset.cpus", NULL, "cpuset.cpus", NULL}, - {cgroup_convert_passthrough, "cpuset.mems", NULL, "cpuset.mems", NULL}, - {cgroup_convert_cpuset_to_exclusive, "cpuset.cpus.partition", NULL, - "cpuset.cpu_exclusive", NULL}, -}; -const int cgroup_v2_to_v1_map_sz = sizeof(cgroup_v2_to_v1_map) / sizeof(cgroup_v2_to_v1_map[0]); diff --git a/lib/libcgroup-3.1.0/src/abstraction-map.h b/lib/libcgroup-3.1.0/src/abstraction-map.h deleted file mode 100644 index fd2409a2204..00000000000 --- a/lib/libcgroup-3.1.0/src/abstraction-map.h +++ /dev/null @@ -1,39 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Libcgroup abstraction layer mappings - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#ifndef __ABSTRACTION_MAP -#define __ABSTRACTION_MAP - -#ifdef __cplusplus -extern "C" { -#endif - -struct cgroup_abstraction_map { - /* - * if the conversion isn't a one-to-one mapping or the mathematical - * conversion is unique, create a custom conversion function. - */ - int (*cgroup_convert)(struct cgroup_controller * const dst_cgc, const char * const in_value, - const char * const out_setting, void *in_dflt, void *out_dflt); - char *in_setting; - void *in_dflt; - char *out_setting; - void *out_dflt; -}; - -extern const struct cgroup_abstraction_map cgroup_v1_to_v2_map[]; -extern const int cgroup_v1_to_v2_map_sz; - -extern const struct cgroup_abstraction_map cgroup_v2_to_v1_map[]; -extern const int cgroup_v2_to_v1_map_sz; - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* __ABSTRACTION_MAP */ diff --git a/lib/libcgroup-3.1.0/src/api.c b/lib/libcgroup-3.1.0/src/api.c deleted file mode 100644 index f2991a40cbb..00000000000 --- a/lib/libcgroup-3.1.0/src/api.c +++ /dev/null @@ -1,6538 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright IBM Corporation. 2007 - * - * Author: Dhaval Giani - * Author: Balbir Singh - * - * TODOs: - * 1. Add more APIs for the control groups. - * 2. Handle the configuration related APIs. - * - * Code initiated and designed by Dhaval Giani. All faults are most likely - * his mistake. - * - * Bharata B Rao is willing is take blame - * for mistakes in APIs for reading statistics. - */ - -#ifndef _GNU_SOURCE -#define _GNU_SOURCE -#endif - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include - -#include - -const struct cgroup_library_version library_version = { - .major = CGROUP_VER_MAJOR, - .minor = CGROUP_VER_MINOR, - .release = CGROUP_VER_RELEASE, -}; - -/* - * The errno which happend the last time (have to be thread specific) - */ -__thread int last_errno; - -#define MAXLEN 256 - -/* the value have to be thread specific */ -static __thread char errtext[MAXLEN]; - -/* Task command name length */ -#define TASK_COMM_LEN 16 - -/* Check if cgroup_init has been called or not. */ -static int cgroup_initialized; - -/* List of configuration rules */ -static struct cgroup_rule_list rl; - -/* Temporary list of configuration rules (for non-cache apps) */ -static struct cgroup_rule_list trl; - -/* Lock for the list of rules (rl) */ -static pthread_rwlock_t rl_lock = PTHREAD_RWLOCK_INITIALIZER; - -/* Cgroup v2 mount path. Null if v2 isn't mounted */ -char cg_cgroup_v2_mount_path[FILENAME_MAX]; - -/* Namespace */ -__thread char *cg_namespace_table[CG_CONTROLLER_MAX]; - -pthread_rwlock_t cg_mount_table_lock = PTHREAD_RWLOCK_INITIALIZER; -struct cg_mount_table_s cg_mount_table[CG_CONTROLLER_MAX]; - -/* Cgroup v2 mount paths, with empty controllers */ -struct cg_mount_point *cg_cgroup_v2_empty_mount_paths; - -#ifdef WITH_SYSTEMD -/* Default systemd path name. Length: .slice/.scope */ -char systemd_default_cgroup[FILENAME_MAX * 2 + 1]; -#endif - -const char * const cgroup_strerror_codes[] = { - "Cgroup is not compiled in", - "Cgroup is not mounted", - "Cgroup does not exist", - "Cgroup has not been created", - "Cgroup one of the needed subsystems is not mounted", - "Cgroup, request came in from non owner", - "Cgroup controllers are bound to different mount points", - "Cgroup, operation not allowed", - "Cgroup value set exceeds maximum", - "Cgroup controller already exists", - "Cgroup value already exists", - "Cgroup invalid operation", - "Cgroup, creation of controller failed", - "Cgroup operation failed", - "Cgroup not initialized", - "Cgroup, requested group parameter does not exist", - "Cgroup generic error", - "Cgroup values are not equal", - "Cgroup controllers are different", - "Cgroup parsing failed", - "Cgroup, rules file does not exist", - "Cgroup mounting failed", - "", /* 50022 is reserved for future errors */ - "End of File or iterator", - "Failed to parse config file", - "Have multiple paths for the same namespace", - "Controller in namespace does not exist", - "Either mount or namespace keyword has to be specified in the configuration file", - "This kernel does not support this feature", - "Value setting does not succeed", - "Failed to remove a non-empty group", - "Failed to convert from cgroup v1 to/from cgroup v2", -}; - -static const char * const cgroup_ignored_tasks_files[] = { "tasks", NULL }; - -#ifndef UNIT_TEST -static int cg_get_cgroups_from_proc_cgroups(pid_t pid, char *cgroup_list[], - char *controller_list[], int list_len); - -static int cgroupv2_get_subtree_control(const char *path, const char *ctrl_name, - bool * const enabled); -#endif - -static int cg_chown(const char *filename, uid_t owner, gid_t group) -{ - if (owner == NO_UID_GID) - owner = getuid(); - if (group == NO_UID_GID) - group = getgid(); - - return chown(filename, owner, group); -} -static int cg_chown_file(FTS *fts, FTSENT *ent, uid_t owner, gid_t group) -{ - const char *filename = fts->fts_path; - int ret = 0; - - cgroup_dbg("chown: seeing file %s\n", filename); - switch (ent->fts_info) { - case FTS_ERR: - errno = ent->fts_errno; - break; - case FTS_D: - case FTS_DC: - case FTS_NSOK: - case FTS_NS: - case FTS_DNR: - case FTS_DP: - case FTS_F: - case FTS_DEFAULT: - ret = cg_chown(filename, owner, group); - break; - } - if (ret < 0) { - cgroup_warn("cannot change owner of file %s: %s\n", filename, strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - } - return ret; -} - -/* TODO: Need to decide a better place to put this function. */ -static int cg_chown_recursive(char **path, uid_t owner, gid_t group) -{ - int ret = 0; - FTS *fts; - - cgroup_dbg("chown: path is %s\n", *path); - fts = fts_open(path, FTS_PHYSICAL | FTS_NOCHDIR | FTS_NOSTAT, NULL); - if (fts == NULL) { - cgroup_warn("cannot open directory %s: %s\n", path, strerror(errno)); - last_errno = errno; - return ECGOTHER; - } - - while (1) { - FTSENT *ent; - - ent = fts_read(fts); - if (!ent) { - cgroup_warn("fts_read failed\n"); - break; - } - ret = cg_chown_file(fts, ent, owner, group); - } - fts_close(fts); - - return ret; -} - -int cg_chmod_path(const char *path, mode_t mode, int owner_is_umask) -{ - mode_t mask = -1U; - struct stat buf; - int fd; - - fd = open(path, O_RDONLY); - if (fd == -1) - goto fail; - - if (owner_is_umask) { - mode_t umask, gmask, omask; - /* - * Use owner permissions as an umask for group and others - * permissions because we trust kernel to initialize owner - * permissions to something useful. Keep SUID and SGID bits. - */ - if (fstat(fd, &buf) == -1) - goto fail; - - /* 0700 == S_IRWXU */ - umask = 0700 & buf.st_mode; - gmask = umask >> 3; - omask = gmask >> 3; - - mask = umask|gmask|omask|S_ISUID|S_ISGID|S_ISVTX; - } - - if (fchmod(fd, mode & mask)) - goto fail; - - close(fd); - - return 0; - -fail: - cgroup_warn("cannot change permissions of file %s: %s\n", path, strerror(errno)); - last_errno = errno; - - if (fd > -1) - close(fd); - - return ECGOTHER; -} - -int cg_chmod_file(FTS *fts, FTSENT *ent, mode_t dir_mode, int dirm_change, mode_t file_mode, - int filem_change, int owner_is_umask) -{ - const char *filename = fts->fts_path; - int ret = 0; - - cgroup_dbg("chmod: seeing file %s\n", filename); - - switch (ent->fts_info) { - case FTS_ERR: - errno = ent->fts_errno; - break; - case FTS_D: - case FTS_DC: - case FTS_DNR: - case FTS_DP: - if (dirm_change) - ret = cg_chmod_path(filename, dir_mode, owner_is_umask); - break; - case FTS_F: - case FTS_NSOK: - case FTS_NS: - case FTS_DEFAULT: - if (filem_change) - ret = cg_chmod_path(filename, file_mode, owner_is_umask); - break; - } - - return ret; -} - -/** - * Changes permissions of all directories and control files (i.e. all files - * except files named in ignore_list. The list must be terminated with NULL. - */ -static int cg_chmod_recursive_controller(char *path, mode_t dir_mode, int dirm_change, - mode_t file_mode, int filem_change, int owner_is_umask, - const char * const *ignore_list) -{ - int final_ret = 0; - char *fts_path[2]; - int i, ignored; - int ret = 0; - FTS *fts; - - fts_path[0] = path; - fts_path[1] = NULL; - cgroup_dbg("chmod: path is %s\n", path); - - fts = fts_open(fts_path, FTS_PHYSICAL | FTS_NOCHDIR | FTS_NOSTAT, NULL); - if (fts == NULL) { - cgroup_warn("cannot open directory %s: %s\n", fts_path, strerror(errno)); - last_errno = errno; - return ECGOTHER; - } - - while (1) { - FTSENT *ent; - - ent = fts_read(fts); - if (!ent) { - if (errno != 0) { - cgroup_dbg("fts_read failed\n"); - last_errno = errno; - final_ret = ECGOTHER; - } - break; - } - - ignored = 0; - if (ignore_list != NULL) - for (i = 0; ignore_list[i] != NULL; i++) - if (!strcmp(ignore_list[i], ent->fts_name)) { - ignored = 1; - break; - } - if (ignored) - continue; - - ret = cg_chmod_file(fts, ent, dir_mode, dirm_change, file_mode, filem_change, - owner_is_umask); - if (ret) { - cgroup_warn("cannot change file mode %s: %s\n", fts_path, strerror(errno)); - last_errno = errno; - final_ret = ECGOTHER; - } - } - fts_close(fts); - - return final_ret; -} - -int cg_chmod_recursive(struct cgroup *cgroup, mode_t dir_mode, int dirm_change, mode_t file_mode, - int filem_change) -{ - int final_ret = 0; - char *path; - int i, ret; - - path = malloc(FILENAME_MAX); - if (!path) { - last_errno = errno; - return ECGOTHER; - } - for (i = 0; i < cgroup->index; i++) { - if (!cg_build_path(cgroup->name, path, cgroup->controller[i]->name)) { - final_ret = ECGFAIL; - break; - } - - ret = cg_chmod_recursive_controller(path, dir_mode, dirm_change, file_mode, - filem_change, 0, NULL); - if (ret) - final_ret = ret; - } - free(path); - - return final_ret; -} - -void cgroup_set_permissions(struct cgroup *cgroup, mode_t control_dperm, mode_t control_fperm, - mode_t task_fperm) -{ - if (!cgroup) { - /* ECGROUPNOTALLOWED */ - cgroup_err("Cgroup, operation not allowed\n"); - return; - } - - cgroup->control_dperm = control_dperm; - cgroup->control_fperm = control_fperm; - cgroup->task_fperm = task_fperm; -} - -static char *cgroup_basename(const char *path) -{ - char *tmp_string; - char *base; - - tmp_string = strdup(path); - - if (!tmp_string) - return NULL; - - base = strdup(basename(tmp_string)); - - free(tmp_string); - - return base; -} - -int cgroup_test_subsys_mounted(const char *name) -{ - int i; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - if (strncmp(cg_mount_table[i].name, name, sizeof(cg_mount_table[i].name)) == 0) { - pthread_rwlock_unlock(&cg_mount_table_lock); - return 1; - } - - /* - * The user has likely requested a file like cgroup.type or - * cgroup.procs. Allow this request as long as there's a - * cgroup v2 controller mounted. - */ - if (strncmp(name, CGROUP_FILE_PREFIX, strlen(CGROUP_FILE_PREFIX)) == 0 && - cg_mount_table[i].version == CGROUP_V2) { - pthread_rwlock_unlock(&cg_mount_table_lock); - return 1; - } - } - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return 0; -} - -/** - * Free a single cgroup_rule struct. - * @param r The rule to free from memory - */ -static void cgroup_free_rule(struct cgroup_rule *r) -{ - /* Loop variable */ - int i = 0; - - /* Make sure our rule is not NULL, first. */ - if (!r) { - cgroup_warn("attempted to free NULL rule\n"); - return; - } - if (r->procname) { - free(r->procname); - r->procname = NULL; - } - /* We must free any used controller strings, too. */ - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (r->controllers[i]) - free(r->controllers[i]); - } - - free(r); -} - -/** - * Free a list of cgroup_rule structs. If rl is the main list of rules, the - * lock must be taken for writing before calling this function! - * @param rl Pointer to the list of rules to free from memory - */ -static void cgroup_free_rule_list(struct cgroup_rule_list *cg_rl) -{ - /* Temporary pointer */ - struct cgroup_rule *tmp = NULL; - - /* Make sure we're not freeing NULL memory! */ - if (!(cg_rl->head)) { - cgroup_warn("attempted to free NULL list\n"); - return; - } - - while (cg_rl->head) { - tmp = cg_rl->head; - cg_rl->head = tmp->next; - cgroup_free_rule(tmp); - } - - /* Don't leave wild pointers around! */ - cg_rl->head = NULL; - cg_rl->tail = NULL; -} - -static char *cg_skip_unused_charactors_in_rule(char *rule) -{ - char *itr; - - /* We ignore anything after a # sign as comments. */ - itr = strchr(rule, '#'); - if (itr) - *itr = '\0'; - - /* We also need to remove the newline character. */ - itr = strchr(rule, '\n'); - if (itr) - *itr = '\0'; - - /* Now, skip any leading tabs and spaces. */ - itr = rule; - while (itr && isblank(*itr)) - itr++; - - /* If there's nothing left, we can ignore this line. */ - if (!strlen(itr)) - return NULL; - - return itr; -} - -/** - * Parse the options field in the rule from the cgrules configuration file - * - * @param options Comma-separated string of options - * @param rule The rule that will contain the parsed options - * @return 0 on success, -EINVAL if the options are invalid - * TODO: Make this function thread safe! - */ -STATIC int cgroup_parse_rules_options(char *options, struct cgroup_rule * const rule) -{ - char *stok_buff = NULL; - size_t cmp_len; - int ret = 0; - - stok_buff = strtok(options, ","); - if (!stok_buff) { - cgroup_err("failed to parse options: %s\n", options); - return -EINVAL; - } - - do { - cmp_len = min(strlen(stok_buff), strlen(CGRULE_OPTION_IGNORE)); - if (strlen(stok_buff) == strlen(CGRULE_OPTION_IGNORE) && - strncmp(stok_buff, CGRULE_OPTION_IGNORE, cmp_len) == 0) { - rule->is_ignore = true; - continue; - } - - /* - * "ignore" is the only currently supported option. - * Raise an error if we get here. - */ - cgroup_err("Unsupported option: %s\n", stok_buff); - ret = -EINVAL; - break; - } while ((stok_buff = strtok(NULL, ","))); - - return ret; -} -/** - * Parse the configuration file that maps UID/GIDs to cgroups. If ever the - * configuration file is modified, applications should call this function to - * load the new configuration rules. - * - * The function caller is responsible for calling free() on each rule in the - * list. - * - * The cache parameter alters the behavior of this function. If true, this - * function will read the entire configuration file and store the results in - * rl (global rules list). If false, this function will only parse until it - * finds a rule matching the given UID or GID. It will store this rule in - * trl, as well as any children rules (rules that begin with a %) that it has. - * - * This function is NOT thread safe! - * @param filename configuration file to parse - * @param cache True to cache rules, else false - * @param muid If cache is false, the UID to match against - * @param mgid If cache is false, the GID to match against - * @return 0 on success, -1 if no cache and match found, > 0 on error. - * TODO: Make this function thread safe! - * - */ -static int cgroup_parse_rules_file(char *filename, bool cache, uid_t muid, gid_t mgid, - const char *mprocname) -{ - /* File descriptor for the configuration file */ - FILE *fp = NULL; - - /* Buffer to store the line we're working on */ - char buff[CGROUP_RULE_MAXLINE] = { '\0' }; - - /* Iterator for the line we're working on */ - char *itr = NULL; - - /* Pointer to process name in a line of the configuration file */ - char *procname = NULL; - - /* Pointer to the list that we're using */ - struct cgroup_rule_list *lst = NULL; - - /* Rule to add to the list */ - struct cgroup_rule *newrule = NULL; - - /* Structure to get GID from group name */ - struct group *grp; - - /* Structure to get UID from user name */ - struct passwd *pwd; - - /* Temporary storage for a configuration rule */ - char key[CGROUP_RULE_MAXKEY] = { '\0' }; - char user[LOGIN_NAME_MAX] = { '\0' }; - char controllers[CG_CONTROLLER_MAX] = { '\0' }; - char destination[FILENAME_MAX] = { '\0' }; - char options[CG_OPTIONS_MAX] = { '\0' }; - uid_t uid = CGRULE_INVALID; - gid_t gid = CGRULE_INVALID; - bool has_options = false; - size_t len_username; - int len_procname; - - /* The current line number */ - unsigned int linenum = 0; - - /* Did we skip the previous line? */ - bool skipped = false; - - /* Have we found a matching rule (non-cache mode)? */ - bool matched = false; - - /* Return codes */ - int ret = 0; - - /* Temporary buffer for strtok() */ - char *stok_buff = NULL; - - /* Loop variable. */ - int i = 0; - - /* Determine which list we're using. */ - if (cache) - lst = &rl; - else - lst = &trl; - - /* Open the configuration file. */ - fp = fopen(filename, "re"); - if (!fp) { - cgroup_warn("failed to open configuration file %s: %s\n", filename, - strerror(errno)); - - /* originally ret = 0, but this is parse fail, not success */ - ret = ECGRULESPARSEFAIL; - goto finish; - } - - /* Now, parse the configuration file one line at a time. */ - cgroup_dbg("Parsing configuration file %s.\n", filename); - while (fgets(buff, sizeof(buff), fp) != NULL) { - linenum++; - - itr = cg_skip_unused_charactors_in_rule(buff); - if (!itr) - continue; - - /* - * If we skipped the last rule and this rule is a continuation - * of it (begins with %), then we should skip this rule too. - */ - if (skipped && *itr == '%') { - cgroup_warn("skipped child of invalid rule, line %d.\n", linenum); - continue; - } - - /* clear the buffer. */ - grp = NULL; - pwd = NULL; - - /* - * If there is something left, it should be a rule. Otherwise, - * there's an error in the configuration file. - */ - skipped = false; - i = sscanf(itr, "%s%s%s%s", key, controllers, destination, options); - if (i < 3) { - cgroup_err("failed to parse configuration file on line %d\n", linenum); - goto parsefail; - } else if (i == 3) { - has_options = false; - } else if (i == 4) { - has_options = true; - } - - procname = strchr(key, ':'); - if (procname) { - /* : */ - procname++; /* skip ':' */ - len_username = procname - key - 1; - len_procname = strlen(procname); - if (len_procname < 0) { - cgroup_err("failed to parse configuration file on line %d\n", - linenum); - goto parsefail; - } - } else { - len_username = strlen(key); - len_procname = 0; - } - len_username = min(len_username, sizeof(user) - 1); - memset(user, '\0', sizeof(user)); - strncpy(user, key, len_username); - user[sizeof(user) - 1] = '\0'; - - /* - * Next, check the user/group. If it's a % sign, then we are - * continuing another rule and UID/GID should not be reset. - * If it's a @, we're dealing with a GID rule. If it's a *, - * then we do not need to do a lookup because the rule always - * applies (it's a wildcard). If we're using non-cache mode - * and we've found a matching rule, we only continue to parse - * if we're looking at a child rule. - */ - if ((!cache) && matched && (strncmp(user, "%", 1) != 0)) { - /* If we make it here, we finished (non-cache). */ - cgroup_dbg("Parsing of configuration file complete.\n\n"); - ret = -1; - goto close; - } - if (strncmp(user, "@", 1) == 0) { - /* New GID rule. */ - itr = &(user[1]); - grp = getgrnam(itr); - if (grp) { - uid = CGRULE_INVALID; - gid = grp->gr_gid; - } else { - cgroup_warn("Entry for %s not found. Skipping rule on line %d.\n", - itr, linenum); - skipped = true; - continue; - } - } else if (strncmp(user, "*", 1) == 0) { - /* Special wildcard rule. */ - uid = CGRULE_WILD; - gid = CGRULE_WILD; - } else if (*itr != '%') { - /* New UID rule. */ - pwd = getpwnam(user); - if (pwd) { - uid = pwd->pw_uid; - gid = CGRULE_INVALID; - } else { - cgroup_warn("Entry for %s not found. Skipping rule on line %d.\n", - user, linenum); - skipped = true; - continue; - } - } /* Else, we're continuing another rule (UID/GID are okay). */ - - /* - * If we are not caching rules, then we need to check for a - * match before doing anything else. We consider four cases: - * 1. The UID matches - * 2. The GID matches - * 3. The UID is a member of the GID, or - * 4. We're looking at the wildcard rule, which always matches. - * If none of these are true, we simply continue to the next - * line in the file. - */ - if (grp && muid != CGRULE_INVALID) { - pwd = getpwuid(muid); - if (!pwd) - continue; - - for (i = 0; grp->gr_mem[i]; i++) { - if (!(strcmp(pwd->pw_name, grp->gr_mem[i]))) - matched = true; - } - } - - if (uid == muid || gid == mgid || uid == CGRULE_WILD) - matched = true; - - if (!cache) { - if (!matched) - continue; - if (len_procname) { - char *mproc_base; - /* - * If there is a rule based on process name, - * it should be matched with mprocname. - */ - if (!mprocname) { - uid = CGRULE_INVALID; - gid = CGRULE_INVALID; - matched = false; - continue; - } - - mproc_base = cgroup_basename(mprocname); - if (strcmp(mprocname, procname) && strcmp(mproc_base, procname)) { - uid = CGRULE_INVALID; - gid = CGRULE_INVALID; - matched = false; - free(mproc_base); - continue; - } - free(mproc_base); - } - } - - /* - * Now, we're either caching rules or we found a match. - * Either way, copy everything into a new rule and push it - * into the list. - */ - newrule = calloc(1, sizeof(struct cgroup_rule)); - if (!newrule) { - cgroup_err("out of memory? Error was: %s\n", strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - goto close; - } - - newrule->uid = uid; - newrule->gid = gid; - newrule->is_ignore = false; - - len_username = min(len_username, sizeof(newrule->username) - 1); - strncpy(newrule->username, user, len_username); - newrule->username[sizeof(newrule->username) - 1] = '\0'; - - if (len_procname) { - newrule->procname = strdup(procname); - if (!newrule->procname) { - cgroup_err("strdup failed to allocate memory %s\n", - strerror(errno)); - free(newrule); - last_errno = errno; - ret = ECGOTHER; - goto close; - } - } else { - newrule->procname = NULL; - } - strncpy(newrule->destination, destination, sizeof(newrule->destination) - 1); - newrule->destination[sizeof(newrule->destination) - 1] = '\0'; - - if (has_options) { - ret = cgroup_parse_rules_options(options, newrule); - if (ret < 0) - goto destroyrule; - } - - newrule->next = NULL; - - /* Parse the controller list, and add that to newrule too. */ - stok_buff = strtok(controllers, ","); - if (!stok_buff) { - cgroup_err("failed to parse controllers on line %d\n", linenum); - goto destroyrule; - } - - i = 0; - do { - if (i >= MAX_MNT_ELEMENTS) { - cgroup_err("too many controllers listed on line %d\n", linenum); - goto destroyrule; - } - - newrule->controllers[i] = - strndup(stok_buff, strlen(stok_buff) + 1); - if (!(newrule->controllers[i])) { - cgroup_err("out of memory? Error was: %s\n", strerror(errno)); - goto destroyrule; - } - i++; - } while ((stok_buff = strtok(NULL, ","))); - - /* Now, push the rule. */ - if (lst->head == NULL) { - lst->head = newrule; - lst->tail = newrule; - } else { - lst->tail->next = newrule; - lst->tail = newrule; - } - - cgroup_dbg("Added rule %s (UID: %d, GID: %d) -> %s for controllers:", - lst->tail->username, lst->tail->uid, lst->tail->gid, - lst->tail->destination); - - for (i = 0; lst->tail->controllers[i]; i++) - cgroup_dbg(" %s", lst->tail->controllers[i]); - cgroup_dbg("\n"); - } - - /* If we make it here, there were no errors. */ - cgroup_dbg("Parsing of configuration file complete.\n\n"); - ret = (matched && !cache) ? -1 : 0; - goto close; - -destroyrule: - cgroup_free_rule(newrule); - -parsefail: - ret = ECGRULESPARSEFAIL; - -close: - fclose(fp); -finish: - return ret; -} - -/** - * Parse CGRULES_CONF_FILE and all files in CGRULES_CONF_FILE_DIR. - * If CGRULES_CONF_FILE_DIR does not exists or can not be read, parse only - * CGRULES_CONF_FILE. This way we keep the back compatibility. - * - * Original description of this function moved to cgroup_parse_rules_file. - * Also cloned and all occurences of file changed to files. - * - * Parse the configuration files that maps UID/GIDs to cgroups. If ever the - * configuration files are modified, applications should call this function to - * load the new configuration rules. The function caller is responsible for - * calling free() on each rule in the list. - * - * The cache parameter alters the behavior of this function. If true, this - * function will read the entire content of all configuration files and store - * the results in rl (global rules list). If false, this function will only - * parse until it finds a file and a rule matching the given UID or GID. - * The remaining files are skipped. It will store this rule in trl, as well as - * any children rules (rules that begin with a %) that it has. - * - * Files can be read in an random order so the first match must not be - * dependent on it. Thus construct the rules the way not to break this - * assumption. - * - * This function is NOT thread safe! - * @param cache True to cache rules, else false - * @param muid If cache is false, the UID to match against - * @param mgid If cache is false, the GID to match against - * @return 0 on success, -1 if no cache and match found, > 0 on error. - * TODO: Make this function thread safe! - */ -static int cgroup_parse_rules(bool cache, uid_t muid, gid_t mgid, const char *mprocname) -{ - /* Pointer to the list that we're using */ - struct cgroup_rule_list *lst = NULL; - - /* Directory variables */ - const char *dirname = CGRULES_CONF_DIR; - struct dirent *item; - char *tmp; - int sret; - DIR *d; - - int ret; - - /* Determine which list we're using. */ - if (cache) - lst = &rl; - else - lst = &trl; - - /* If our list already exists, clean it. */ - if (lst->head) - cgroup_free_rule_list(lst); - - pthread_rwlock_wrlock(&rl_lock); - - /* Parse CGRULES_CONF_FILE configuration file (back compatibility). */ - ret = cgroup_parse_rules_file(CGRULES_CONF_FILE, cache, muid, mgid, mprocname); - - /* - * if match (ret = -1), stop parsing other files, - * just return or ret > 0 => error - */ - if (ret != 0) { - pthread_rwlock_unlock(&rl_lock); - return ret; - } - - /* Continue parsing */ - d = opendir(dirname); - if (!d) { - cgroup_warn("Failed to open directory %s: %s\n", dirname, strerror(errno)); - - /* - * Cannot read directory. However, CGRULES_CONF_FILE is - * succesfully parsed. Thus return as a success for back - * compatibility. - */ - pthread_rwlock_unlock(&rl_lock); - - return 0; - } - - /* Read all files from CGRULES_CONF_FILE_DIR */ - do { - item = readdir(d); - if (item && (item->d_type == DT_REG || item->d_type == DT_LNK)) { - - sret = asprintf(&tmp, "%s/%s", dirname, item->d_name); - if (sret < 0) { - cgroup_err("Out of memory\n"); - - /* - * Cannot read directory. - * However, CGRULES_CONF_FILE is succesfully - * parsed. Thus return as a success for back - * compatibility. - */ - ret = 0; - goto unlock_list; - } - - cgroup_dbg("Parsing cgrules file: %s\n", tmp); - ret = cgroup_parse_rules_file(tmp, cache, muid, mgid, mprocname); - - free(tmp); - - /* Match with cache disabled? */ - if (ret != 0) - goto unlock_list; - } - if (!item && errno) { - cgroup_warn("cannot read %s: %s\n", dirname, strerror(errno)); - /* - * Cannot read an item. - * But continue for back compatibility as a success. - */ - ret = 0; - goto unlock_list; - } - } while (item != NULL); - -unlock_list: - closedir(d); - pthread_rwlock_unlock(&rl_lock); - - return ret; -} - -int cg_add_duplicate_mount(struct cg_mount_table_s *item, const char *path) -{ - struct cg_mount_point *mount, *it; - - mount = malloc(sizeof(struct cg_mount_point)); - if (!mount) { - last_errno = errno; - return ECGOTHER; - } - mount->next = NULL; - - strncpy(mount->path, path, sizeof(mount->path)); - mount->path[sizeof(mount->path)-1] = '\0'; - - /* - * Add the mount point to the end of the list. Assuming the list is - * short, no optimization is done. - */ - it = &item->mount; - while (it->next) - it = it->next; - - it->next = mount; - - return 0; -} - -/* - * Tries to find if any controller in cg_mount_table have already mounted on - * the mount_path and if mounted sets the matching controller idx share_mnt - * flag and Return 1 or 0 otherwise. - */ -static int cgroup_set_cg_mnt_tbl_shared_mnt(char *mount_path, int *mnt_tbl_idx) -{ - int i, shared_mnt = 0; - - /* Check if controllers share mount points */ - for (i = 0; i < *mnt_tbl_idx; i++) { - if (strncmp(mount_path, cg_mount_table[i].mount.path, FILENAME_MAX) == 0) { - cg_mount_table[i].shared_mnt = 1; - shared_mnt = 1; - break; - } - } - - return shared_mnt; -} - -static void cgroup_cg_mount_table_append(const char *name, const char *mount_path, - enum cg_version_t version, int *mnt_tbl_idx, - const char *mnt_opts, int shared_mnt) -{ - int i = *mnt_tbl_idx; - - strncpy(cg_mount_table[i].name, name, CONTROL_NAMELEN_MAX); - cg_mount_table[i].name[CONTROL_NAMELEN_MAX-1] = '\0'; - - strncpy(cg_mount_table[i].mount.path, mount_path, FILENAME_MAX); - cg_mount_table[i].mount.path[FILENAME_MAX-1] = '\0'; - - cg_mount_table[i].shared_mnt = shared_mnt; - cg_mount_table[i].version = version; - cg_mount_table[i].mount.next = NULL; - - cgroup_dbg("Found cgroup option %s, count %d\n", mnt_opts, i); - - (*mnt_tbl_idx)++; -} - -/** - * Process a cgroup v1 mount and add it to cg_mount_table if it's not a - * duplicate. - * - * @param controllers List of controllers from /proc/cgroups - * @param ent File system description of cgroup mount being processed - * @param mnt_tbl_idx cg_mount_table index - */ -STATIC int cgroup_process_v1_mnt(char *controllers[], struct mntent *ent, int *mnt_tbl_idx) -{ - char *strtok_buffer = NULL, *mntopt = NULL; - int shared_mnt, duplicate; - int i, j, ret = 0; - char c = 0; - - for (i = 0; controllers[i] != NULL; i++) { - mntopt = hasmntopt(ent, controllers[i]); - - if (!mntopt) - continue; - - c = mntopt[strlen(controllers[i])]; - - if (c != '\0' && c != ',') - continue; - - cgroup_dbg("found %s in %s\n", controllers[i], ent->mnt_opts); - - /* Check if controllers share mount points */ - shared_mnt = cgroup_set_cg_mnt_tbl_shared_mnt(ent->mnt_dir, mnt_tbl_idx); - - /* Do not have duplicates in mount table */ - duplicate = 0; - for (j = 0; j < *mnt_tbl_idx; j++) { - if (strncmp(controllers[i], cg_mount_table[j].name, FILENAME_MAX) == 0) { - duplicate = 1; - break; - } - } - - if (duplicate) { - cgroup_dbg("controller %s is already mounted on %s\n", mntopt, - cg_mount_table[j].mount.path); - ret = cg_add_duplicate_mount(&cg_mount_table[j], ent->mnt_dir); - if (ret) - goto out; - /* Continue with next controller */ - continue; - } - - cgroup_cg_mount_table_append(controllers[i], ent->mnt_dir, CGROUP_V1, mnt_tbl_idx, - ent->mnt_opts, shared_mnt); - - if ((*mnt_tbl_idx) >= CG_CONTROLLER_MAX) - goto out; - } - - /* Doesn't match the controller. Check if it is a named hierarchy. */ - mntopt = hasmntopt(ent, "name"); - - if (mntopt) { - mntopt = strtok_r(mntopt, ",", &strtok_buffer); - if (!mntopt) - goto out; - -#ifdef OPAQUE_HIERARCHY - /* Ignore the opaque hierarchy. */ - if (strcmp(mntopt, OPAQUE_HIERARCHY) == 0) - goto out; -#endif - /* Check if controllers share mount points */ - shared_mnt = cgroup_set_cg_mnt_tbl_shared_mnt(ent->mnt_dir, mnt_tbl_idx); - - /* Check if it is a duplicate */ - duplicate = 0; - for (j = 0; j < *mnt_tbl_idx; j++) { - if (strncmp(mntopt, cg_mount_table[j].name, FILENAME_MAX) == 0) { - duplicate = 1; - break; - } - } - - if (duplicate) { - cgroup_dbg("controller %s is already mounted on %s\n", mntopt, - cg_mount_table[j].mount.path); - ret = cg_add_duplicate_mount(&cg_mount_table[j], ent->mnt_dir); - goto out; - } - - cgroup_cg_mount_table_append(mntopt, ent->mnt_dir, CGROUP_V1, mnt_tbl_idx, - ent->mnt_opts, shared_mnt); - } - -out: - return ret; -} - -/** - * Process a cgroup v2 mount and add it to cg_mount_table if it's not a - * duplicate. - * - * @param ent File system description of cgroup mount being processed - * @param mnt_tbl_idx cg_mount_table index - */ -STATIC int cgroup_process_v2_mnt(struct mntent *ent, int *mnt_tbl_idx) -{ - char *ret_c = NULL, line[CGV2_CONTROLLERS_LL_MAX], *stok_buff = NULL; - char *controller = NULL, *controllers = NULL; - char cgroup_controllers_path[FILENAME_MAX]; - int ret = 0, i, duplicate, shared_mnt; - FILE *fp = NULL; - - /* - * Save off this mount point. This may be used later to - * build the cg_path. - */ - strncpy(cg_cgroup_v2_mount_path, ent->mnt_dir, FILENAME_MAX-1); - cg_cgroup_v2_mount_path[FILENAME_MAX-1] = '\0'; - - /* determine what v2 controllers are available on this mount */ - snprintf(cgroup_controllers_path, FILENAME_MAX, "%s/%s", ent->mnt_dir, - CGV2_CONTROLLERS_FILE); - - fp = fopen(cgroup_controllers_path, "re"); - if (!fp) { - ret = ECGOTHER; - goto out; - } - - ret_c = fgets(line, CGV2_CONTROLLERS_LL_MAX, fp); - if (ret_c == NULL) { - struct cg_mount_point *tmp, *t; - - ret = ECGEOF; - - tmp = malloc(sizeof(struct cg_mount_point)); - if (tmp == NULL) { - last_errno = errno; - ret = ECGOTHER; - goto out; - } - - strncpy(tmp->path, cg_cgroup_v2_mount_path, sizeof(tmp->path) - 1); - tmp->path[sizeof(tmp->path)-1] = '\0'; - tmp->next = NULL; - - t = cg_cgroup_v2_empty_mount_paths; - if (t == NULL) { - cg_cgroup_v2_empty_mount_paths = tmp; - goto out; - } - - while(t->next != NULL) - t = t->next; - t->next = tmp; - - goto out; - } - - /* Remove the trailing newline */ - ret_c[strlen(ret_c) - 1] = '\0'; - - /* - * The "cgroup" controller is a pseudo-controller that has settings that a user may - * wish to read/modify. Add it to our cg_mount_table so that it can be manipulated - * like other "normal" controllers - */ - controllers = malloc(strlen(ret_c) + strlen(CGROUP_FILE_PREFIX) + 2); - if (!controllers) { - ret = ECGOTHER; - goto out; - } - - sprintf(controllers, "%s %s", ret_c, CGROUP_FILE_PREFIX); - - /* - * cgroup.controllers returns a list of available controllers in - * the following format: - * cpuset cpu io memory pids rdma - */ - controller = strtok_r(controllers, " ", &stok_buff); - do { - /* Check if controllers share mount points */ - shared_mnt = cgroup_set_cg_mnt_tbl_shared_mnt(ent->mnt_dir, mnt_tbl_idx); - - /* Do not have duplicates in mount table */ - duplicate = 0; - for (i = 0; i < *mnt_tbl_idx; i++) { - if (strncmp(cg_mount_table[i].name, controller, FILENAME_MAX) == 0) { - duplicate = 1; - break; - } - } - - if (duplicate) { - cgroup_dbg("controller %s is already mounted on %s\n", controller, - cg_mount_table[i].mount.path); - - ret = cg_add_duplicate_mount(&cg_mount_table[i], ent->mnt_dir); - if (ret) - break; - - continue; - } - - /* This controller is not in the mount table. add it */ - cgroup_cg_mount_table_append(controller, ent->mnt_dir, CGROUP_V2, mnt_tbl_idx, - controller, shared_mnt); - - if ((*mnt_tbl_idx) >= CG_CONTROLLER_MAX) - goto out; - } while ((controller = strtok_r(NULL, " ", &stok_buff))); - -out: - if (fp) - fclose(fp); - - if (controllers) - free(controllers); - - return ret; -} - -/* - * Free global variables filled by previous cgroup_init(). This function - * should be called with cg_mount_table_lock taken. - */ -static void cgroup_free_cg_mount_table(void) -{ - struct cg_mount_point *mount, *tmp; - int i; - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - mount = cg_mount_table[i].mount.next; - - while (mount) { - tmp = mount; - mount = mount->next; - free(tmp); - } - } - - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(&cg_cgroup_v2_mount_path, 0, sizeof(cg_cgroup_v2_mount_path)); - memset(&cg_cgroup_v2_empty_mount_paths, 0, sizeof(cg_cgroup_v2_empty_mount_paths)); -} - -/* - * Parses the mount options of the given mount point and checks for the - * option in the list of mount options and sets is_set accordingly. - * @mnt: Mount point name to search for mount points. - * @mnt_opt: Mount option to be searched. - * @is_set: Set to 1, when mount option is found, 0 otherwise. - * - * Returns 0, in case of success and ECGOTHER on failure. - */ -static int check_mount_point_opt(const char *mnt, const char *mnt_opt, int * const is_set) -{ - struct mntent *ent, *temp_ent = NULL; - char mntent_buffer[4 * FILENAME_MAX]; - char *mntopt = NULL; - char mnt_opt_delim; - FILE *proc_mount; - int ret = 0; - - if (!mnt || !mnt_opt || !is_set) - return ECGINVAL; - - proc_mount = setmntent(mnt, "r"); - if (!proc_mount) { - cgroup_err("cannot open %s: %s\n", mnt, strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - temp_ent = (struct mntent *) malloc(sizeof(struct mntent)); - if (!temp_ent) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - ent = getmntent_r(proc_mount, temp_ent, mntent_buffer, sizeof(mntent_buffer)); - if (!ent) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - *is_set = 0; - while((mntopt = hasmntopt(ent, mnt_opt))) { - mnt_opt_delim = mntopt[strlen(mnt_opt)]; - if (mnt_opt_delim == '\0' || mnt_opt_delim == ',') { - *is_set = 1; - break; - } - } - - if (*is_set == 0) { - cgroup_dbg("%s, not found in the list of ", mnt_opt); - cgroup_cont("mount options of %s\n", mnt); - } - -err: - if (proc_mount) - endmntent(proc_mount); - - if (temp_ent) - free(temp_ent); - - return ret; -} - -/* - * Reads /proc/cgroups and populates the controllers/subsys_name. This - * function should be called with cg_mount_table_lock taken. - */ -static int cgroup_populate_controllers(char *controllers[CG_CONTROLLER_MAX]) -{ - int hierarchy, num_cgroups, enabled; - char subsys_name[FILENAME_MAX]; - char mnt_opt[] = "subset=pid"; - FILE *proc_cgroup; - char *buf = NULL; - int mnt_opt_set; - int ret = 0; - int err, i = 0; - - proc_cgroup = fopen("/proc/cgroups", "re"); - if (!proc_cgroup) { - cgroup_warn("cannot open /proc/cgroups: %s\n", strerror(errno)); - ret = check_mount_point_opt("/proc/self/mounts", mnt_opt, &mnt_opt_set); - if (ret) - goto err; - - if (!mnt_opt_set) - ret = ECGINVAL; - /* - * /proc, mounted with subset=pid is valid. cgroup v2 doesn't - * depend on /proc/cgroups to parse the available controllers. - */ - goto err; - } - - /* - * The first line of the file has stuff we are not interested in. - * So just read it and discard the information. - */ - buf = malloc(CGV2_CONTROLLERS_LL_MAX); - if (!buf) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - if (!fgets(buf, CGV2_CONTROLLERS_LL_MAX, proc_cgroup)) { - cgroup_err("cannot read /proc/cgroups: %s\n", strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - while (!feof(proc_cgroup)) { - /* - * check Linux Kernel sources/kernel/cgroup/cgroup.c cgroup_init_early(), - * MAX_CGROUP_TYPE_NAMELEN check for details on why 32 is used. - */ - err = fscanf(proc_cgroup, "%32s %d %d %d", subsys_name, &hierarchy, &num_cgroups, - &enabled); - if (err < 0) - break; - - controllers[i] = strdup(subsys_name); - if (controllers[i] == NULL) { - last_errno = errno; - ret = ECGOTHER; - break; - } - i++; - } - -err: - if (proc_cgroup) - fclose(proc_cgroup); - - if (buf) - free(buf); - - if (ret != 0) { - for (i = 0; controllers[i]; i++) { - free(controllers[i]); - controllers[i] = NULL; - } - } - - return ret; -} - -/* - * Reads /proc/self/mounts and populates the cgroup v1/v2 mount points into the - * global cg_mount_table. - * This function should be called with cg_mount_table_lock taken. - */ -static int cgroup_populate_mount_points(char *controllers[CG_CONTROLLER_MAX]) -{ - char mntent_buffer[4 * FILENAME_MAX]; - struct mntent *ent, *temp_ent = NULL; - int found_mnt = 0; - FILE *proc_mount; - int ret = 0; - - proc_mount = fopen("/proc/self/mounts", "re"); - if (proc_mount == NULL) { - cgroup_err("cannot open /proc/self/mounts: %s\n", strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - temp_ent = (struct mntent *) malloc(sizeof(struct mntent)); - if (!temp_ent) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - while ((ent = getmntent_r(proc_mount, temp_ent, mntent_buffer, - sizeof(mntent_buffer))) != NULL) { - - if (strcmp(ent->mnt_type, "cgroup") == 0) { - if (controllers[0] == NULL) { - cgroup_err("cgroup v1 requires /proc/cgroups, check if /proc "); - cgroup_cont("is mounted with subset=pid option.\n"); - ret = ECGINVAL; - goto err; - } - - ret = cgroup_process_v1_mnt(controllers, ent, &found_mnt); - if (ret) - goto err; - - if (found_mnt >= CG_CONTROLLER_MAX) - break; - - continue; - } - - if (strcmp(ent->mnt_type, "cgroup2") == 0) { - ret = cgroup_process_v2_mnt(ent, &found_mnt); - if (ret == ECGEOF) { - /* The controllers file was empty. Ignore and move on. */ - ret = 0; - continue; - } - - if (ret) - goto err; - - if (found_mnt >= CG_CONTROLLER_MAX) - break; - } - } - - if (!found_mnt) - ret = ECGROUPNOTMOUNTED; - - if (found_mnt >= CG_CONTROLLER_MAX) { - cgroup_err("Mount points exceeds CG_CONTROLLER_MAX"); - ret = ECGMAXVALUESEXCEEDED; - /* - * There are loops in the libcgroup codebase that expect - * there to be a null name entry at the end of the - * cg_mount_table[]. - */ - cg_mount_table[CG_CONTROLLER_MAX - 1].name[0] = '\0'; - } - -err: - if (proc_mount) - fclose(proc_mount); - - if (temp_ent) - free(temp_ent); - - return ret; -} - -/** - * cgroup_init(), initializes the MOUNT_POINT. - * - * This code is theoretically thread safe now. Its not really tested so it can - * blow up. If does for you, please let us know with your test case and we can - * really make it thread safe. - */ -int cgroup_init(void) -{ - static char *controllers[CG_CONTROLLER_MAX]; - int ret = 0; - int i; - - cgroup_set_default_logger(-1); - - pthread_rwlock_wrlock(&cg_mount_table_lock); - - /* Free global variables filled by previous cgroup_init() */ - cgroup_free_cg_mount_table(); - - ret = cgroup_populate_controllers(controllers); - if (ret) - goto unlock_exit; - - ret = cgroup_populate_mount_points(controllers); - if (ret) - goto unlock_exit; - - cgroup_initialized = 1; - -unlock_exit: - for (i = 0; controllers[i]; i++) { - free(controllers[i]); - controllers[i] = NULL; - } - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} - -static int cg_test_mounted_fs(void) -{ - char mntent_buff[4 * FILENAME_MAX]; - struct mntent *temp_ent = NULL; - struct mntent *ent = NULL; - FILE *proc_mount = NULL; - int ret = 1; - - proc_mount = fopen("/proc/self/mounts", "re"); - if (proc_mount == NULL) - return 0; - - temp_ent = (struct mntent *) malloc(sizeof(struct mntent)); - if (!temp_ent) { - /* We just fail at the moment. */ - fclose(proc_mount); - return 0; - } - - ent = getmntent_r(proc_mount, temp_ent, mntent_buff, sizeof(mntent_buff)); - if (!ent) { - ret = 0; - goto done; - } - - while (strcmp(ent->mnt_type, "cgroup") != 0 && - strcmp(ent->mnt_type, "cgroup2") != 0) { - ent = getmntent_r(proc_mount, temp_ent, mntent_buff, sizeof(mntent_buff)); - if (ent == NULL) { - ret = 0; - goto done; - } - } -done: - fclose(proc_mount); - free(temp_ent); - - return ret; -} - -static inline pid_t cg_gettid(void) -{ - return syscall(__NR_gettid); -} - -static char *cg_concat_path(const char *pref, const char *suf, char *path) -{ - if ((suf[strlen(suf)-1] == '/') || ((strlen(suf) == 0) && (pref[strlen(pref)-1] == '/'))) - snprintf(path, FILENAME_MAX, "%s%s", pref, suf+((suf[0] == '/') ? 1 : 0)); - else - snprintf(path, FILENAME_MAX, "%s%s/", pref, suf+((suf[0] == '/') ? 1 : 0)); - - path[FILENAME_MAX-1] = '\0'; - - return path; -} - -/* Call with cg_mount_table_lock taken */ -/* path value have to have size at least FILENAME_MAX */ -char *cg_build_path_locked(const char *name, char *path, const char *type) -{ - /* - * len is the allocation size for path, that stores: - * cg_mount_table[i].mount.path + '/' + cg_namespace_table[i] + '/' - */ - int i, ret, len = (FILENAME_MAX * 2) + 2; - char *tmp_systemd_default_cgroup, *_path = NULL; - - /* - * systemd_default_cgroup can't be clobbered. The user may pass - * multiple cgroups, hence use temporary variable for manipulations - * for example: - * cgget -g cpu:/ -g cpu:cgrp1 -g cpu:/cgrp2 - */ - tmp_systemd_default_cgroup = calloc(1, (sizeof(char) * len)); - if (!tmp_systemd_default_cgroup) { - cgroup_err("Failed to allocate memory for tmp_systemd_default_cgroup\n"); - goto out; - } - -#ifdef WITH_SYSTEMD - /* - * If the user specifies the name as /, they are - * effectively overriding the systemd_default_cgroup but if the name - * is "/", the cgroup root path is systemd_default_cgroup - */ - if (strlen(systemd_default_cgroup) && name && name[0] == '/' && name[1] != '\0') - tmp_systemd_default_cgroup[0] = '\0'; - else - snprintf(tmp_systemd_default_cgroup, len, "%s/", systemd_default_cgroup); - - /* allocate more space for systemd_default_cgroup + '/' */ - len += (FILENAME_MAX + 1); -#endif - /* - * Recent gcc are unhappy when sizeof(dest) <= sizeof(src) with - * snprintf()'s. Alternative is to use multiple strncpy()/strcat(), - * work around it by allocating large temporary buffer _path and - * copying the constructed _path into path. - */ - _path = malloc(len); - if (!_path) { - cgroup_err("Failed to allocate memory for _path\n"); - goto out; - } - - /* - * If no type is specified, and there's a valid cgroup v2 mount, then - * build up a path to this mount (and cgroup name if supplied). - * This can be used to create a cgroup v2 cgroup that's not attached to - * any controller. - */ - if (!type && strlen(cg_cgroup_v2_mount_path) > 0) { - ret = snprintf(_path, len, "%s/%s", cg_cgroup_v2_mount_path, - tmp_systemd_default_cgroup); - if (ret >= FILENAME_MAX) - cgroup_dbg("filename too long: %s", _path); - - strncpy(path, _path, FILENAME_MAX - 1); - path[FILENAME_MAX - 1] = '\0'; - - if (name) { - char *tmp; - - tmp = strdup(path); - if (tmp == NULL) { - path = NULL; - goto out; - } - - cg_concat_path(tmp, name, path); - free(tmp); - } - goto out; - } - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - /* Two ways to successfully move forward here: - * 1. The "type" controller matches the name of a mounted - * controller - * 2. The "type" controller requested is "cgroup" and there's - * a "real" controller mounted as cgroup v2 - */ - if ((type && strcmp(cg_mount_table[i].name, type) == 0) || - (type && strcmp(type, CGROUP_FILE_PREFIX) == 0 && - cg_mount_table[i].version == CGROUP_V2)) { - - if (cg_namespace_table[i]) - ret = snprintf(_path, len, "%s/%s%s/", cg_mount_table[i].mount.path, - tmp_systemd_default_cgroup, cg_namespace_table[i]); - else - ret = snprintf(_path, len, "%s/%s", cg_mount_table[i].mount.path, - tmp_systemd_default_cgroup); - - if (ret >= FILENAME_MAX) - cgroup_dbg("filename too long: %s", _path); - - strncpy(path, _path, FILENAME_MAX - 1); - path[FILENAME_MAX - 1] = '\0'; - - if (name) { - char *tmp; - - tmp = strdup(path); - if (tmp == NULL) - break; - - cg_concat_path(tmp, name, path); - free(tmp); - } - goto out; - } - } - path = NULL; - -out: - if (_path) - free(_path); - - if (tmp_systemd_default_cgroup) - free(tmp_systemd_default_cgroup); - - return path; -} - -char *cg_build_path(const char *name, char *path, const char *type) -{ - pthread_rwlock_rdlock(&cg_mount_table_lock); - path = cg_build_path_locked(name, path, type); - pthread_rwlock_unlock(&cg_mount_table_lock); - - return path; -} - -static int cgroup_get_cg_type(const char * const path, char * const type, - size_t type_sz) -{ - char cg_type_path[FILENAME_MAX]; - char cg_type[CGV2_CONTROLLERS_LL_MAX]; - int len, err = 0; - FILE *fp = NULL; - - snprintf(cg_type_path, FILENAME_MAX, "%scgroup.type", path); - fp = fopen(cg_type_path, "re"); - if (!fp) { - if (errno == ENOENT) { - /* file cgroup.type, doesn't exist for root cgroup. */ - snprintf(type, type_sz, "cgroup.procs"); - goto out; - } else { - cgroup_warn("failed to open file %s: %s\n", cg_type_path, strerror(errno)); - err = ECGOTHER; - goto out; - } - } - - if (fgets(cg_type, CGV2_CONTROLLERS_LL_MAX, fp) == NULL) { - cgroup_warn("failed to read file %s: %s\n", cg_type_path, strerror(errno)); - err = ECGOTHER; - goto out; - } - - len = strlen(cg_type) - 1; - /* - * Append cgroup.threads to the path, if the cgroup.type is threaded - * and cgroup.procs for type domain, domain threaded. domain type is - * used for regular cgroup and domain threaded for root of threaded - * cgroup v2 subtree. Another possible type is domain invalid, it's - * an invalid state, under the threaded subtree. - */ - if (strncmp(cg_type, "domain", len) == 0 || - strncmp(cg_type, "domain threaded", len) == 0 || - strncmp(cg_type, "domain invalid", len) == 0) { - snprintf(type, type_sz, "cgroup.procs"); - } else if (strncmp(cg_type, "threaded", len) == 0) { - snprintf(type, type_sz, "cgroup.threads"); - } else { - cgroup_warn("invalid %scgroup.type: %s\n", path, cg_type); - err = ECGOTHER; - } - -out: - if (fp) - fclose(fp); - - return err; -} - -int cgroup_build_tasks_procs_path(char * const path, size_t path_sz, const char * const cg_name, - const char * const ctrl_name) -{ - enum cg_version_t version; - char cg_type[CGV2_CONTROLLERS_LL_MAX]; - int err = ECGOTHER; - - if (!cg_build_path(cg_name, path, ctrl_name)) - goto error; - - err = cgroup_get_controller_version(ctrl_name, &version); - if (err) - goto error; - - switch (version) { - case CGROUP_V1: - strncat(path, "tasks", path_sz - strlen(path)); - err = 0; - break; - case CGROUP_V2: - err = cgroup_get_cg_type(path, cg_type, sizeof(cg_type)); - if (err) - goto error; - - strncat(path, cg_type, path_sz - strlen(path)); - break; - default: - err = ECGOTHER; - break; - } - -error: - if (err) - path[0] = '\0'; - - cgroup_dbg("cgroup build procs path: %s\n", path); - - return err; -} - -STATIC int cgroupv2_controller_enabled(const char * const cg_name, const char * const ctrl_name) -{ - char path[FILENAME_MAX] = {0}; - char *parent = NULL, *dname; - enum cg_version_t version; - bool enabled; - int error; - - error = cgroup_get_controller_version(ctrl_name, &version); - if (error) - return error; - - if (version != CGROUP_V2) - return 0; - - if (ctrl_name == NULL) - /* cgroup v2 supports cgroups with no controllers. */ - return 0; - - if (strncmp(cg_name, "/", strlen(cg_name)) == 0) - /* - * The root cgroup has been requested. All version 2 - * controllers are enabled on the root cgroup. - */ - return 0; - - if (!cg_build_path(cg_name, path, ctrl_name)) - goto err; - - parent = strdup(path); - if (!parent) { - error = ECGOTHER; - goto err; - } - - dname = dirname(parent); - - error = cgroupv2_get_subtree_control(dname, ctrl_name, &enabled); - if (error) - goto err; - - if (enabled) - error = 0; -err: - if (parent) - free(parent); - - return error; -} - -static int __cgroup_attach_task_pid(char *path, pid_t tid) -{ - FILE *tasks = NULL; - int ret = 0; - - tasks = fopen(path, "we"); - if (!tasks) { - switch (errno) { - case EPERM: - ret = ECGROUPNOTOWNER; - break; - case ENOENT: - ret = ECGROUPNOTEXIST; - break; - default: - ret = ECGROUPNOTALLOWED; - } - goto err; - } - ret = fprintf(tasks, "%d", tid); - if (ret < 0) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - ret = fflush(tasks); - if (ret) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - fclose(tasks); - return 0; -err: - cgroup_warn("cannot write tid %d to %s:%s\n", tid, path, strerror(errno)); - if (tasks) - fclose(tasks); - return ret; -} - -/** - * cgroup_attach_task_pid is used to assign tasks to a cgroup. - * struct cgroup *cgroup: The cgroup to assign the thread to. - * pid_t tid: The thread to be assigned to the cgroup. - * - * returns 0 on success. - * returns ECGROUPNOTOWNER if the caller does not have access to the cgroup. - * returns ECGROUPNOTALLOWED for other causes of failure. - */ -int cgroup_attach_task_pid(struct cgroup *cgroup, pid_t tid) -{ - char path[FILENAME_MAX] = {0}; - char *controller_name; - int empty_cgroup = 0; - int i, ret = 0; - - if (!cgroup_initialized) { - cgroup_warn("libcgroup is not initialized\n"); - return ECGROUPNOTINITIALIZED; - } - - /* if the cgroup is NULL, attach the task to the root cgroup. */ - if (!cgroup) { - pthread_rwlock_rdlock(&cg_mount_table_lock); - for (i = 0; i < CG_CONTROLLER_MAX && cg_mount_table[i].name[0] != '\0'; i++) { - ret = cgroup_build_tasks_procs_path(path, sizeof(path), NULL, - cg_mount_table[i].name); - if (ret) - return ret; - - ret = __cgroup_attach_task_pid(path, tid); - if (ret) { - pthread_rwlock_unlock(&cg_mount_table_lock); - return ret; - } - } - pthread_rwlock_unlock(&cg_mount_table_lock); - } else { - for (i = 0; i < cgroup->index; i++) { - if (!cgroup_test_subsys_mounted(cgroup->controller[i]->name)) { - cgroup_warn("subsystem %s is not mounted\n", - cgroup->controller[i]->name); - return ECGROUPSUBSYSNOTMOUNTED; - } - } - - if (cgroup->index == 0) - /* Valid empty cgroup v2 with no controllers added. */ - empty_cgroup = 1; - - for (i = 0, controller_name = NULL; - empty_cgroup > 0 || i < cgroup->index; - i++, empty_cgroup--) { - - if (cgroup->controller[i]) - controller_name = cgroup->controller[i]->name; - - ret = cgroupv2_controller_enabled(cgroup->name, controller_name); - if (ret) - return ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgroup->name, - controller_name); - if (ret) - return ret; - - ret = __cgroup_attach_task_pid(path, tid); - if (ret) - return ret; - } - } - return 0; -} - -/** - * cgroup_attach_task is used to attach the current thread to a cgroup. - * struct cgroup *cgroup: The cgroup to assign the current thread to. - * - * See cg_attach_task_pid for return values. - */ -int cgroup_attach_task(struct cgroup *cgroup) -{ - pid_t tid = cg_gettid(); - int error; - - error = cgroup_attach_task_pid(cgroup, tid); - - return error; -} - -/** - * cg_mkdir_p, emulate the mkdir -p command (recursively creating paths) - * @path: path to create - */ -int cg_mkdir_p(const char *path) -{ - char *real_path = NULL; - char *tmp_path = NULL; - struct stat st; - int ret = 0; - int i = 0; - char pos; - - real_path = strdup(path); - if (!real_path) { - last_errno = errno; - return ECGOTHER; - } - - do { - while (real_path[i] != '\0' && real_path[i] == '/') - i++; - - if (real_path[i] == '\0') - break; /* The path ends with '/', ignore it. */ - - while (real_path[i] != '\0' && real_path[i] != '/') - i++; - - pos = real_path[i]; - real_path[i] = '\0'; /* Temporarily overwrite "/" */ - - /* 0775 == S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH */ - ret = mkdir(real_path, 0775); - if (ret) { - switch (errno) { - case EEXIST: - ret = 0; /* Not fatal really */ - break; - case EPERM: - ret = ECGROUPNOTOWNER; - goto done; - case EROFS: - /* - * Check if path exists, use tmp_path to - * keep Coverity happy - */ - tmp_path = real_path; - ret = stat(tmp_path, &st); - if (ret == 0) - break; /* Path exists */ - default: /* fallthrough */ - ret = ECGROUPNOTALLOWED; - goto done; - } - } - real_path[i] = pos; - } while (real_path[i]); - -done: - free(real_path); - - return ret; -} - -/* - * create_control_group() - * This is the basic function used to create the control group. This function - * just makes the group. It does not set any permissions, or any control values. - * The argument path is the fully qualified path name to make it generic. - */ -static int cg_create_control_group(const char *path) -{ - int error; - - if (!cg_test_mounted_fs()) - return ECGROUPNOTMOUNTED; - - error = cg_mkdir_p(path); - return error; -} - -/* - * set_control_value() - * This is the low level function for putting in a value in a control file. - * This function takes in the complete path and sets the value in val in that file. - */ -static int cg_set_control_value(char *path, const char *val) -{ - char *str_val_start; - char *str_val; - int ctl_file; - size_t len; - char *pos; - - if (!cg_test_mounted_fs()) - return ECGROUPNOTMOUNTED; - - ctl_file = open(path, O_RDWR | O_CLOEXEC); - - if (ctl_file == -1) { - if (errno == EPERM) { - /* - * We need to set the correct error value, does the - * group exist but we don't have the subsystem mounted - * at that point, or is it that the group does not exist. - * So we check if the tasks file exist. Before that, we - * need to extract the path. - */ - char *path_dir_end; - FILE *control_file; - char *tasks_path; - - path_dir_end = strrchr(path, '/'); - if (path_dir_end == NULL) - return ECGROUPVALUENOTEXIST; - path_dir_end = '\0'; - - /* task_path contain: $path/tasks */ - tasks_path = (char *)malloc(strlen(path) + 6 + 1); - if (tasks_path == NULL) { - last_errno = errno; - return ECGOTHER; - } - strcpy(tasks_path, path); - strcat(tasks_path, "/tasks"); - - /* Test tasks file for read flag */ - control_file = fopen(tasks_path, "re"); - if (!control_file) { - if (errno == ENOENT) { - free(tasks_path); - return ECGROUPSUBSYSNOTMOUNTED; - } - } else { - fclose(control_file); - } - - free(tasks_path); - return ECGROUPNOTALLOWED; - } - return ECGROUPVALUENOTEXIST; - } - - /* - * Split the multiline value into lines. One line is a special - * case of multiline value. - */ - str_val = strdup(val); - if (str_val == NULL) { - last_errno = errno; - close(ctl_file); - return ECGOTHER; - } - - str_val_start = str_val; - pos = str_val; - - do { - str_val = pos; - pos = strchr(str_val, '\n'); - - if (pos) { - *pos = '\0'; - ++pos; - } - - len = strlen(str_val); - if (len > 0) { - if (write(ctl_file, str_val, len) == -1) { - last_errno = errno; - free(str_val_start); - close(ctl_file); - return ECGOTHER; - } - } else - cgroup_warn("skipping empty line for %s\n", path); - } while (pos); - - if (close(ctl_file)) { - last_errno = errno; - free(str_val_start); - return ECGOTHER; - } - - free(str_val_start); - return 0; -} - -/** - * Walk the settings in controller and write their values to disk - * - * @param base The full path to the base of this cgroup - * @param controller The controller whose values are being updated - * @param ignore_non_dirty_values If set skips writing non-dirty controller settings - */ -STATIC int cgroup_set_values_recursive(const char * const base, - const struct cgroup_controller * const controller, - bool ignore_non_dirty_values) -{ - struct control_value *cv; - struct stat path_stat; - int ret, j, error = 0; - char *path = NULL; - - for (j = 0; j < controller->index; j++) { - cv = controller->values[j]; - - /* - * ignore_non_dirty_values is set while writing into - * existing cgroup to modify controller settings and - * unset during cgroup creation. The subtle difference - * is that dirty flag is unset for all the controller - * settings during cgroup creation, whereas some or all - * controller settings have the dirty flag set during - * modification. - * - * Be careful with ignore_non_dirty_values flag, setting - * it writing only the controller settings that has it - * dirty value set. - */ - if (ignore_non_dirty_values && cv->dirty == false) - continue; - - /* We don't support, writing multiline settings */ - if (strcspn(cv->value, "\n") < (strlen(cv->value) - 1)) - continue; - - ret = asprintf(&path, "%s%s", base, cv->name); - if (ret < 0) { - last_errno = errno; - error = ECGOTHER; - goto err; - } - - /* skip read-only settings */ - ret = (stat(path, &path_stat)); - if (ret < 0) { - last_errno = errno; - error = ECGROUPVALUENOTEXIST;; - goto err; - } - - if (!(path_stat.st_mode & S_IWUSR)) - continue; - - cgroup_dbg("setting %s to \"%s\", pathlen %d\n", path, cv->value, ret); - - error = cg_set_control_value(path, cv->value); - free(path); - path = NULL; - - if (error) { - /* Ignore the errors on deprecated settings */ - if (last_errno == EOPNOTSUPP) { - error = 0; - continue; - } - goto err; - } - cv->dirty = false; - } - -err: - /* - * As currently written, path should always be null as we are\ - * exiting this function, but let's check just in case, and free it - * if it's non-null - */ - if (path) - free(path); - - return error; -} - -/** - * Check if the requested cgroup controller is enabled in the specified file - * - * @param path Cgroup directory - * @param ctrl_name Name of the controller to check - * @param output parameter that indicates whether the controller is enabled - * @param file to open and parse - * 0 = cgroup.subtree_control - * 1 = cgroup.controllers - */ -STATIC int __cgroupv2_get_enabled(const char *path, const char *ctrl_name, - bool * const enabled, int file_enum) -{ - char *path_copy = NULL, *saveptr = NULL, *token, *ret_c, *filename; - int ret, error = ECGROUPNOTMOUNTED; - char buffer[FILENAME_MAX]; - FILE *fp = NULL; - - if (!path || !ctrl_name || !enabled) - return ECGOTHER; - - *enabled = false; - - switch (file_enum) { - case 0: /* cgroup.subtree_control */ - filename = CGV2_SUBTREE_CTRL_FILE; - break; - case 1: /* cgroup.controllers */ - filename = CGV2_CONTROLLERS_FILE; - break; - default: - return ECGINVAL; - } - - path_copy = (char *)malloc(FILENAME_MAX); - if (!path_copy) { - error = ECGOTHER; - goto out; - } - - ret = snprintf(path_copy, FILENAME_MAX, "%s/%s", path, filename); - if (ret < 0) { - error = ECGOTHER; - goto out; - } - - fp = fopen(path_copy, "re"); - if (!fp) { - cgroup_warn("fopen failed\n"); - last_errno = errno; - error = ECGOTHER; - goto out; - } - - ret_c = fgets(buffer, sizeof(buffer), fp); - if (ret_c == NULL) - /* The subtree control file is empty */ - goto out; - - /* Remove the trailing newline */ - ret_c[strlen(ret_c) - 1] = '\0'; - - /* - * Split the enabled controllers by " " and evaluate if the - * requested controller is enabled. - */ - token = strtok_r(buffer, " ", &saveptr); - do { - if (strncmp(ctrl_name, token, FILENAME_MAX) == 0) { - error = 0; - *enabled = true; - break; - } - } while ((token = strtok_r(NULL, " ", &saveptr))); - -out: - if (path_copy) - free(path_copy); - if (fp) - fclose(fp); - - return error; -} - -/** - * Check if the requested cgroup controller is enabled on this subtree - * - * @param path Cgroup directory - * @param ctrl_name Name of the controller to check - * @param output parameter that indicates whether the controller is enabled - */ -STATIC int cgroupv2_get_subtree_control(const char *path, const char *ctrl_name, - bool * const enabled) -{ - return __cgroupv2_get_enabled(path, ctrl_name, enabled, 0); -} -/** - * Check if the requested cgroup controller is enabled in this cgroup's cgroup.controllers file - * - * @param path Cgroup directory - * @param ctrl_name Name of the controller to check - * @param output parameter that indicates whether the controller is enabled - */ -static int cgroupv2_get_controllers(const char *path, const char *ctrl_name, - bool * const enabled) -{ - return __cgroupv2_get_enabled(path, ctrl_name, enabled, 1); -} - -/** - * Enable/Disable a controller in the cgroup v2 subtree_control file - * - * @param path Directory that contains the subtree_control file - * @param ctrl_name Name of the controller to be enabled/disabled - * @param enable Enable/Disable the given controller - */ -STATIC int cgroupv2_subtree_control(const char *path, const char *ctrl_name, bool enable) -{ - int ret, error = ECGOTHER; - char *path_copy = NULL; - char *value = NULL; - - if (!path || !ctrl_name) - return ECGOTHER; - - value = (char *)malloc(FILENAME_MAX); - if (!value) - goto out; - - path_copy = (char *)malloc(FILENAME_MAX); - if (!path_copy) - goto out; - - ret = snprintf(path_copy, FILENAME_MAX, "%s/%s", path, CGV2_SUBTREE_CTRL_FILE); - if (ret < 0) - goto out; - - if (enable) - ret = snprintf(value, FILENAME_MAX, "+%s", ctrl_name); - else - ret = snprintf(value, FILENAME_MAX, "-%s", ctrl_name); - if (ret < 0) - goto out; - - error = cg_set_control_value(path_copy, value); - if (error) - goto out; - -out: - if (value) - free(value); - if (path_copy) - free(path_copy); - return error; -} - -/** - * Recursively enable/disable a controller in the cgv2 subtree_control file - * - * @param path Directory that contains the subtree_control file - * @param ctrl_name Name of the controller to be enabled/disabled - * @param enable Enable/Disable the given controller - */ -STATIC int cgroupv2_subtree_control_recursive(char *path, const char *ctrl_name, bool enable) -{ - char *path_copy, *tmp_path, *stok_buff = NULL; - bool found_mount = false; - size_t mount_len; - int i, error = 0; - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - if (strncmp(cg_mount_table[i].name, ctrl_name, - sizeof(cg_mount_table[i].name)) == 0) { - found_mount = true; - break; - } - } - - if (!found_mount) - return ECGROUPSUBSYSNOTMOUNTED; - - path_copy = strdup(path); - if (!path_copy) - return ECGOTHER; - - /* - * Null terminate the path_copy to match the string length of the - * controller mount. We'll incrementally build up the string, subdir - * by subdir, and enable the subtree control file each step of the way - */ - mount_len = strlen(cg_mount_table[i].mount.path); - path_copy[mount_len] = '\0'; - - tmp_path = strtok_r(&path[mount_len], "/", &stok_buff); - do { - if (tmp_path) { - strcat(path_copy, "/"); - strcat(path_copy, tmp_path); - } - - error = cg_create_control_group(path_copy); - if (error) - goto out; - - error = cgroupv2_subtree_control(path_copy, ctrl_name, enable); - if (error) - goto out; - } while ((tmp_path = strtok_r(NULL, "/", &stok_buff))); - -out: - free(path_copy); - return error; -} - -/** - * cgroup_modify_cgroup modifies the cgroup control files. - * struct cgroup *cgroup: The name will be the cgroup to be modified. - * The values will be the values to be modified, those not mentioned in the - * structure will not be modified. - * - * The uids cannot be modified yet. - * - * returns 0 on success. - */ - -int cgroup_modify_cgroup(struct cgroup *cgroup) -{ - char base[FILENAME_MAX]; - int error = 0; - int i; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!cgroup) - return ECGROUPNOTALLOWED; - - for (i = 0; i < cgroup->index; i++) { - if (!cgroup_test_subsys_mounted(cgroup->controller[i]->name)) { - cgroup_warn("subsystem %s is not mounted\n", cgroup->controller[i]->name); - return ECGROUPSUBSYSNOTMOUNTED; - } - } - - for (i = 0; i < cgroup->index; i++) { - if (!cg_build_path(cgroup->name, base, cgroup->controller[i]->name)) - continue; - - error = cgroup_set_values_recursive(base, cgroup->controller[i], true); - if (error) - goto err; - } -err: - return error; -} - -int cgroup_copy_controller_values(struct cgroup_controller * const dst, - const struct cgroup_controller * const src) -{ - int i, ret = 0; - - if (!dst || !src) - return ECGFAIL; - - strncpy(dst->name, src->name, CONTROL_NAMELEN_MAX); - for (i = 0; i < src->index; i++, dst->index++) { - struct control_value *src_val = src->values[i]; - struct control_value *dst_val; - - dst->values[i] = calloc(1, sizeof(struct control_value)); - if (!dst->values[i]) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - dst_val = dst->values[i]; - strncpy(dst_val->value, src_val->value, CG_CONTROL_VALUE_MAX); - strncpy(dst_val->name, src_val->name, FILENAME_MAX); - - if (src_val->multiline_value) { - dst_val->multiline_value = strdup(src_val->multiline_value); - if (!dst_val->multiline_value) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - } else { - dst_val->multiline_value = NULL; - } - - if (src_val->prev_name) { - dst_val->prev_name = strdup(src_val->prev_name); - if (!dst_val->prev_name) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - } else { - dst_val->prev_name = NULL; - } - /* - * set dirty flag unconditionally, as we overwrite - * destination controller values. - */ - dst_val->dirty = true; - } - - return ret; - -err: - dst->index = 0; - for (i = 0; i < src->index; i++) { - if (dst->values[i]) { - if (dst->values[i]->multiline_value) - free(dst->values[i]->multiline_value); - - if (dst->values[i]->prev_name) - free(dst->values[i]->prev_name); - - free(dst->values[i]); - } - } - - return ret; -} - -/** - * @dst: Destination control group - * @src: Source from which values will be copied to dst - * - * Create a duplicate copy of src in dst. This will be useful for those who - * that intend to create new instances based on an existing control group - */ -int cgroup_copy_cgroup(struct cgroup *dst, struct cgroup *src) -{ - int ret = 0, i; - - if (!dst || !src) - return ECGROUPNOTEXIST; - - /* Should we just use the restrict keyword instead? */ - if (dst == src) - return ECGFAIL; - - cgroup_free_controllers(dst); - - for (i = 0; i < src->index; i++, dst->index++) { - struct cgroup_controller *src_ctlr = src->controller[i]; - struct cgroup_controller *dst_ctlr; - - dst->controller[i] = calloc(1, sizeof(struct cgroup_controller)); - if (!dst->controller[i]) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - dst_ctlr = dst->controller[i]; - ret = cgroup_copy_controller_values(dst_ctlr, src_ctlr); - if (ret) - goto err; - } -err: - return ret; -} - -/** - * Chown and chmod the tasks file in cg_path - * - * @param uid The UID that will own the tasks file - * @param gid The GID that will own the tasks file - * @param fperm The permissions to place on the tasks file - */ -STATIC int cgroup_chown_chmod_tasks(const char * const cg_path, uid_t uid, gid_t gid, mode_t fperm) -{ - int ret, error; - char *tasks_path = NULL; - - tasks_path = (char *)malloc(FILENAME_MAX); - if (tasks_path == NULL) - return ECGOTHER; - - ret = snprintf(tasks_path, FILENAME_MAX, "%s/tasks", cg_path); - if (ret < 0 || ret >= FILENAME_MAX) { - last_errno = errno; - error = ECGOTHER; - goto err; - } - - error = cg_chown(tasks_path, uid, gid); - if (!error && fperm != NO_PERMS) - error = cg_chmod_path(tasks_path, fperm, 1); - - if (error) { - last_errno = errno; - error = ECGOTHER; - } - -err: - if (tasks_path) - free(tasks_path); - - return error; -} - -static int _cgroup_create_cgroup(const struct cgroup * const cgroup, - const struct cgroup_controller * const controller, - int ignore_ownership) -{ - enum cg_version_t version = CGROUP_UNK; - char *fts_path[2]; - char *base = NULL; - char *path = NULL; - int error; - - fts_path[0] = (char *)malloc(FILENAME_MAX); - if (!fts_path[0]) { - last_errno = errno; - return ECGOTHER; - } - fts_path[1] = NULL; - path = fts_path[0]; - - if (controller) { - if (!cg_build_path(cgroup->name, path, controller->name)) { - error = ECGOTHER; - goto err; - } - - error = cgroup_get_controller_version(controller->name, &version); - if (error) - goto err; - - if (version == CGROUP_V2) { - char *parent, *dname; - - parent = strdup(path); - if (!parent) { - error = ECGOTHER; - goto err; - } - - dname = dirname(parent); - - error = cgroupv2_subtree_control_recursive(dname, controller->name, true); - free(parent); - if (error) - goto err; - } - } else { - if (!cg_build_path(cgroup->name, path, NULL)) { - error = ECGOTHER; - goto err; - } - } - - error = cg_create_control_group(path); - if (error) - goto err; - - base = strdup(path); - - if (!base) { - last_errno = errno; - error = ECGOTHER; - goto err; - } - - if (!ignore_ownership) { - cgroup_dbg("Changing ownership of %s\n", fts_path[0]); - error = cg_chown_recursive(fts_path, cgroup->control_uid, cgroup->control_gid); - if (!error) - error = cg_chmod_recursive_controller(fts_path[0], - cgroup->control_dperm, - cgroup->control_dperm != NO_PERMS, - cgroup->control_fperm, - cgroup->control_fperm != NO_PERMS, - 1, cgroup_ignored_tasks_files); - } - - if (error) - goto err; - - if (controller) { - error = cgroup_set_values_recursive(base, controller, false); - if (error) - goto err; - } - - if (!ignore_ownership && version == CGROUP_V1) { - error = cgroup_chown_chmod_tasks(base, cgroup->tasks_uid, cgroup->tasks_gid, - cgroup->task_fperm); - if (error) - goto err; - } -err: - if (path) - free(path); - if (base) - free(base); - - return error; -} - -/** - * cgroup_create_cgroup creates a new control group. - * struct cgroup *cgroup: The control group to be created - * - * returns 0 on success. We recommend calling cg_delete_cgroup if this - * routine fails. That should do the cleanup operation. If ECGCANTSETVALUE - * is returned, the group was created successfully but not all controller - * parameters were successfully set. - */ -int cgroup_create_cgroup(struct cgroup *cgroup, int ignore_ownership) -{ - int error = 0; - int i; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!cgroup) - return ECGROUPNOTALLOWED; - - for (i = 0; i < cgroup->index; i++) { - if (!cgroup_test_subsys_mounted(cgroup->controller[i]->name)) - return ECGROUPSUBSYSNOTMOUNTED; - } - - if (cgroup->index == 0) { - /* Create an empty cgroup v2 cgroup */ - error = _cgroup_create_cgroup(cgroup, NULL, ignore_ownership); - if (error) - /* - * Since we only attempted to create a single cgroup, - * _cgroup_create_cgroup() can capably undo the failure and no - * interventions are required here. - */ - return error; - } - - /* - * XX: One important test to be done is to check, if you have - * multiple subsystems mounted at one point, all of them *have* be - * on the cgroup data structure. If not, we fail. - */ - for (i = 0; i < cgroup->index; i++) { - error = _cgroup_create_cgroup(cgroup, cgroup->controller[i], ignore_ownership); - if (error) { - int del_error; - - /* - * This will remove any cgroup directories that were made, but it won't - * undo changes that have been written to the parent cgroup's - * subtree_control file. To safely undo changes there, we would need to - * save the subtree_control file's previous value and restore it. - */ - del_error = cgroup_delete_cgroup(cgroup, 1); - if (del_error) - cgroup_err("Failed to delete %s: %s\n", cgroup->name, - cgroup_strerror(del_error)); - return error; - } - } - - return 0; -} - -/** - * Obtain the calculated parent name of specified cgroup; no validation of - * the existence of the child or parent group is performed. - * - * Given the path-like hierarchy of cgroup names, this function returns the - * dirname() of the cgroup name as the likely parent name; the caller is - * responsible for validating parent as appropriate. - * - * @param cgroup The cgroup to query for parent's name - * @param parent Output, name of parent's group, or NULL if the - * provided cgroup is the root group. - * Caller is responsible to free the returned string. - * @return 0 on success, > 0 on error - */ -static int cgroup_get_parent_name(struct cgroup *cgroup, char **parent) -{ - char *pdir = NULL; - char *dir = NULL; - int ret = 0; - - dir = strdup(cgroup->name); - if (!dir) { - last_errno = errno; - return ECGOTHER; - } - cgroup_dbg("group name is %s\n", dir); - - pdir = dirname(dir); - cgroup_dbg("parent's group name is %s\n", pdir); - - /* Check for root group */ - if (strlen(cgroup->name) == 0 || !strcmp(cgroup->name, pdir)) { - cgroup_dbg("specified cgroup \"%s\" is root group\n", cgroup->name); - *parent = NULL; - } else { - *parent = strdup(pdir); - if (*parent == NULL) { - last_errno = errno; - ret = ECGOTHER; - } - } - free(dir); - - return ret; -} - -/* - * Checks if the cgroup's controller shares the mount point with any other - * controller in cg_mount_table. - * Returns 1 if shared or 0. - */ -static int is_cgrp_ctrl_shared_mnt(char *controller) -{ - int ret = 0; - int i; - - if (!controller) - return ret; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - - if (strncmp(cg_mount_table[i].name, controller, CONTROL_NAMELEN_MAX) == 0 && - cg_mount_table[i].shared_mnt) { - ret = 1; - break; - } - } - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} -/** - * Find the parent of the specified directory. It returns the parent in - * hierarchy of given controller (the parent is usually name/.. unless name - * is a mount point. It is assumed both the cgroup (and, therefore, parent) - * already exist, and will fail otherwise. - * - * When namespaces are used, a group can have different parents for - * different controllers. - * - * @param cgroup The cgroup - * @param controller The controller - * @param parent Output, name of parent's group (if the group has parent) or - * NULL, if the provided cgroup is the root group and has no parent. - * Caller is responsible to free the returned string! - * @return 0 on success, >0 on error. - */ -static int cgroup_find_parent(struct cgroup *cgroup, char *controller, char **parent) -{ - struct stat stat_child, stat_parent; - char child_path[FILENAME_MAX]; - char *parent_path = NULL; - int ret = 0; - - *parent = NULL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - if (!cg_build_path_locked(cgroup->name, child_path, controller)) { - pthread_rwlock_unlock(&cg_mount_table_lock); - return ECGFAIL; - } - pthread_rwlock_unlock(&cg_mount_table_lock); - - cgroup_dbg("path is %s\n", child_path); - - if (asprintf(&parent_path, "%s/..", child_path) < 0) - return ECGFAIL; - - cgroup_dbg("parent's name is %s\n", parent_path); - - if (stat(child_path, &stat_child) < 0) { - if (is_cgrp_ctrl_shared_mnt(controller)) { - last_errno = errno; - ret = ECGROUPNOTEXIST; - goto free_parent; - } - last_errno = errno; - ret = ECGOTHER; - goto free_parent; - } - - if (stat(parent_path, &stat_parent) < 0) { - last_errno = errno; - ret = ECGOTHER; - goto free_parent; - } - - /* Is the specified "name" a mount point? */ - if (stat_parent.st_dev != stat_child.st_dev) { - *parent = NULL; - ret = 0; - cgroup_dbg("Parent is on different device\n"); - } else { - ret = cgroup_get_parent_name(cgroup, parent); - } - -free_parent: - free(parent_path); - return ret; -} - -/** - * @cgroup: cgroup data structure to be filled with parent values and then - * passed down for creation - * @ignore_ownership: Ignore doing a chown on the newly created cgroup - * @return 0 on success, > 0 on failure. If ECGCANTSETVALUE is returned, - * the group was created - * successfully, but not all controller parameters were copied from the - * parent successfully; unfortunately, this is expected... - */ -int cgroup_create_cgroup_from_parent(struct cgroup *cgroup, int ignore_ownership) -{ - struct cgroup *parent_cgroup = NULL; - char *parent = NULL; - int ret = ECGFAIL; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - ret = cgroup_get_parent_name(cgroup, &parent); - if (ret) - return ret; - - if (parent == NULL) { - /* - * The group to create is root group! - * TODO: find better error code? - */ - return ECGFAIL; - } - - cgroup_dbg("parent is %s\n", parent); - parent_cgroup = cgroup_new_cgroup(parent); - if (!parent_cgroup) { - ret = ECGFAIL; - goto err_nomem; - } - - if (cgroup_get_cgroup(parent_cgroup)) { - ret = ECGFAIL; - goto err_parent; - } - - cgroup_dbg("got parent group for %s\n", parent_cgroup->name); - ret = cgroup_copy_cgroup(cgroup, parent_cgroup); - if (ret) - goto err_parent; - - cgroup_dbg("copied parent group %s to %s\n", parent_cgroup->name, cgroup->name); - ret = cgroup_create_cgroup(cgroup, ignore_ownership); - -err_parent: - cgroup_free(&parent_cgroup); -err_nomem: - free(parent); - return ret; -} - -/** - * Move all processes from one task file to another. - * @param input_tasks Pre-opened file to read tasks from. - * @param output_tasks Pre-opened file to write tasks to. - * @return 0 on succes, >0 on error. - */ -static int cg_move_task_files(FILE *input_tasks, FILE *output_tasks) -{ - int ret = 0; - int tids; - - while (!feof(input_tasks)) { - ret = fscanf(input_tasks, "%d", &tids); - if (ret == EOF || ret == 0) { - ret = 0; - break; - } - if (ret < 0) - break; - - ret = fprintf(output_tasks, "%d", tids); - if (ret < 0 && errno != ESRCH) - break; - - /* Flush the file, we need only one process per write() call. */ - ret = fflush(output_tasks); - if (ret < 0) { - if (errno == ESRCH) - ret = 0; - else - break; - } - } - - if (ret < 0) { - last_errno = errno; - return ECGOTHER; - } - return 0; -} - -/** - * Remove one cgroup from specific controller. The function moves all - * processes from it to given target group. - * - * The function succeeds if the group to remove is already removed - when - * cgroup_delete_cgroup is called with group with two controllers mounted - * to the same hierarchy, this function is called once for each of these - * controllers. And during the second call the group is already removed... - * - * @param cgroup_name Name of the group to remove. - * @param controller Name of the controller. - * @param target_tasks Opened tasks file of the target group, where all - * processes should be moved. - * @param flags Flag indicating whether the errors from task - * migration should be ignored (CGROUP_DELETE_IGNORE_MIGRATION) or not (0). - * @returns 0 on success, >0 on error. - */ -static int cg_delete_cgroup_controller(char *cgroup_name, char *controller, FILE *target_tasks, - int flags) -{ - char path[FILENAME_MAX]; - FILE *delete_tasks; - int ret = 0; - - cgroup_dbg("Removing group %s:%s\n", controller, cgroup_name); - - if (!(flags & CGFLAG_DELETE_EMPTY_ONLY)) { - /* Open tasks file of the group to delete. */ - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgroup_name, controller); - if (ret != 0) - return ECGROUPSUBSYSNOTMOUNTED; - - delete_tasks = fopen(path, "re"); - if (delete_tasks) { - ret = cg_move_task_files(delete_tasks, target_tasks); - if (ret != 0) { - cgroup_warn("removing tasks from %s failed: %s\n", path, - cgroup_strerror(ret)); - } - fclose(delete_tasks); - } else { - /* - * Can't open the tasks file. If the file does not exist, - * ignore it - the group has been already removed. - */ - if (errno != ENOENT) { - cgroup_err("cannot open %s: %s\n", path, strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - } - } - - if (ret != 0 && !(flags & CGFLAG_DELETE_IGNORE_MIGRATION)) - return ret; - } - - /* Remove the group. */ - if (!cg_build_path(cgroup_name, path, controller)) - return ECGROUPSUBSYSNOTMOUNTED; - - ret = rmdir(path); - if (ret == 0 || errno == ENOENT) - return 0; - - if ((flags & CGFLAG_DELETE_EMPTY_ONLY) && (errno == EBUSY)) - return ECGNONEMPTY; - - cgroup_warn("cannot remove directory %s: %s\n", path, strerror(errno)); - last_errno = errno; - - return ECGOTHER; -} - -/** - * Recursively delete one control group. Moves all tasks from the group and - * its subgroups to given task file. - * - * @param cgroup_name The group to delete. - * @param controller The controller, where to delete. - * @param target_tasks Opened file, where all tasks should be moved. - * @param flags Combination of CGFLAG_DELETE_* flags. The function assumes - * that CGFLAG_DELETE_RECURSIVE is set. - * @param delete_root Whether the group itself should be removed(1) or not(0). - */ -static int cg_delete_cgroup_controller_recursive(char *cgroup_name, char *controller, - FILE *target_tasks, int flags, int delete_root) -{ - char child_name[FILENAME_MAX + 1]; - struct cgroup_file_info info; - int level, group_len; - void *handle; - int ret; - - cgroup_dbg("Recursively removing %s:%s\n", controller, cgroup_name); - - ret = cgroup_walk_tree_begin(controller, cgroup_name, 0, &handle, &info, &level); - - if (ret == 0) - ret = cgroup_walk_tree_set_flags(&handle, CGROUP_WALK_TYPE_POST_DIR); - - if (ret != 0) { - cgroup_walk_tree_end(&handle); - return ret; - } - - group_len = strlen(info.full_path); - - /* Skip the root group, it will be handled explicitly at the end. */ - ret = cgroup_walk_tree_next(0, &handle, &info, level); - - while (ret == 0) { - if (info.type == CGROUP_FILE_TYPE_DIR && info.depth > 0) { - snprintf(child_name, sizeof(child_name), "%s/%s", cgroup_name, - info.full_path + group_len); - - ret = cg_delete_cgroup_controller(child_name, controller, target_tasks, - flags); - if (ret != 0) - break; - } - - ret = cgroup_walk_tree_next(0, &handle, &info, level); - } - if (ret == ECGEOF) { - /* Iteration finished successfully, remove the root group. */ - ret = 0; - if (delete_root) - ret = cg_delete_cgroup_controller(cgroup_name, controller, target_tasks, - flags); - } - - cgroup_walk_tree_end(&handle); - - return ret; -} - -/** - * cgroup_delete cgroup deletes a control group. - * struct cgroup *cgroup takes the group which is to be deleted. - * - * returns 0 on success. - */ -int cgroup_delete_cgroup(struct cgroup *cgroup, int ignore_migration) -{ - int flags = ignore_migration ? CGFLAG_DELETE_IGNORE_MIGRATION : 0; - - return cgroup_delete_cgroup_ext(cgroup, flags); -} - -int cgroup_delete_cgroup_ext(struct cgroup *cgroup, int flags) -{ - int first_error = 0, first_errno = 0; - int cgrp_del_on_shared_mnt = 0; - char parent_path[FILENAME_MAX]; - char *controller_name = NULL; - FILE *parent_tasks = NULL; - char *parent_name = NULL; - int delete_group = 1; - int empty_cgroup = 0; - int i, ret; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!cgroup) - return ECGROUPNOTALLOWED; - - if ((flags & CGFLAG_DELETE_RECURSIVE) - && (flags & CGFLAG_DELETE_EMPTY_ONLY)) - return ECGINVAL; - - if (cgroup->index == 0) - /* Valid empty cgroup v2 with not controllers added. */ - empty_cgroup = 1; - - for (i = 0; i < cgroup->index; i++) { - if (!cgroup_test_subsys_mounted(cgroup->controller[i]->name)) - return ECGROUPSUBSYSNOTMOUNTED; - } - - /* - * Remove the group from all controllers and in the case of cgroup - * with no controllers, perform all actions of a single controller. - */ - for (i = 0; - empty_cgroup > 0 || i < cgroup->index; i++, empty_cgroup--) { - - ret = 0; - controller_name = NULL; - - if (cgroup->controller[i]) - controller_name = cgroup->controller[i]->name; - - /* Find parent, it can be different for each controller */ - if (!(flags & CGFLAG_DELETE_EMPTY_ONLY)) { - ret = cgroup_find_parent(cgroup, controller_name, &parent_name); - if (ret) { - /* - * ECGROPNOTEXIST is returned on cgroup v1, where - * controllers share the mount points. When cgroup - * is deleted on one of symbolic link (controller) - * and they should pass on other controllers sharing - * the mount point. - * - * cgrp_del_shared_mnt serves as an extra check - * flag that gets set, when the cgroup exists and - * is deleted or else sets an error. - */ - if (first_error == 0 && - (ret != ECGROUPNOTEXIST || - (ret == ECGROUPNOTEXIST && cgrp_del_on_shared_mnt == 0))) { - first_errno = last_errno; - first_error = ECGOTHER; - } - continue; - } - - if (is_cgrp_ctrl_shared_mnt(controller_name)) - cgrp_del_on_shared_mnt = 1; - - if (parent_name == NULL) { - /* Root group is being deleted. */ - if (!(flags & CGFLAG_DELETE_RECURSIVE)) - /* root group is being deleted in non-recursive mode */ - continue; - /* - * Move all tasks to the root group and - * do not delete it afterwards. - */ - parent_name = strdup("."); - if (parent_name == NULL) { - if (first_error == 0) { - first_errno = errno; - first_error = ECGOTHER; - } - continue; - } - delete_group = 0; - } - } - - if (parent_name) { - /* Tasks need to be moved, pre-open target tasks file */ - ret = cgroup_build_tasks_procs_path(parent_path, sizeof(parent_path), - parent_name, controller_name); - if (ret != 0) { - if (first_error == 0) - first_error = ECGFAIL; - free(parent_name); - continue; - } - - parent_tasks = fopen(parent_path, "we"); - if (!parent_tasks) { - if (first_error == 0) { - cgroup_warn("cannot open tasks file %s: %s\n", parent_path, - strerror(errno)); - first_errno = errno; - first_error = ECGOTHER; - } - free(parent_name); - continue; - } - } - if (flags & CGFLAG_DELETE_RECURSIVE) { - ret = cg_delete_cgroup_controller_recursive(cgroup->name, controller_name, - parent_tasks, flags, - delete_group); - } else { - ret = cg_delete_cgroup_controller(cgroup->name, controller_name, - parent_tasks, flags); - } - - if (parent_tasks) { - fclose(parent_tasks); - parent_tasks = NULL; - } - free(parent_name); - parent_name = NULL; - /* - * If any of the controller delete fails, remember the first - * error code, but continue with next controller and try remove - * the group from all of them. - */ - if (ret) { - /* - * ECGNONEMPTY is more or less not an error, but an - * indication that something was not removed. - * Therefore it should be replaced by any other error. - */ - if (ret != ECGNONEMPTY && - (first_error == 0 || first_errno == ECGNONEMPTY)) { - first_errno = last_errno; - first_error = ret; - } - } - } - - /* - * Restore the last_errno to the first errno from - * cg_delete_cgroup_controller[_ext]. - */ - if (first_errno != 0) - last_errno = first_errno; - - return first_error; -} - -/* - * This function should really have more checks, but this version will assume - * that the callers have taken care of everything. Including the locking. - */ -static int cg_rd_ctrl_file(const char *subsys, const char *cgroup, const char *file, char **value) -{ - char path[FILENAME_MAX]; - FILE *ctrl_file = NULL; - int ret; - - if (!cg_build_path_locked(cgroup, path, subsys)) - return ECGFAIL; - - strncat(path, file, sizeof(path) - strlen(path)); - ctrl_file = fopen(path, "re"); - if (!ctrl_file) - return ECGROUPVALUENOTEXIST; - - *value = calloc(CG_CONTROL_VALUE_MAX, 1); - if (!*value) { - fclose(ctrl_file); - last_errno = errno; - return ECGOTHER; - } - - /* Using %as crashes when we try to read from files like memory.stat */ - ret = fread(*value, 1, CG_CONTROL_VALUE_MAX-1, ctrl_file); - if (ret < 0) { - free(*value); - *value = NULL; - } else { - /* Remove trailing \n */ - if (ret > 0 && (*value)[ret-1] == '\n') - (*value)[ret-1] = '\0'; - } - - fclose(ctrl_file); - - return 0; -} - -/* - * Call this function with required locks taken. - */ -int cgroup_fill_cgc(struct dirent *ctrl_dir, struct cgroup *cgroup, struct cgroup_controller *cgc, - int cg_index) -{ - char path[FILENAME_MAX+1]; - struct stat stat_buffer; - char *ctrl_value = NULL; - char *ctrl_name = NULL; - char *ctrl_file = NULL; - char *tmp_path = NULL; - char *d_name = NULL; - char *buffer = NULL; - int tmp_len = 0; - int error = 0; - - d_name = strdup(ctrl_dir->d_name); - - if (!strcmp(d_name, ".") || !strcmp(d_name, "..")) { - error = ECGINVAL; - goto fill_error; - } - - /* - * This part really needs to be optimized out. Probably use some - * sort of a flag, but this is fine for now. - */ - cg_build_path_locked(cgroup->name, path, cg_mount_table[cg_index].name); - strncat(path, d_name, sizeof(path) - strlen(path)); - - error = stat(path, &stat_buffer); - - if (error) { - error = ECGFAIL; - goto fill_error; - } - - /* - * We have already stored the tasks_uid & tasks_gid. This check is - * to avoid the overwriting of the values stored in - * control_uid & cotrol_gid. tasks file will have the uid and gid of - * the user who is capable of putting a task to this cgroup. - * control_uid and control_gid is meant for the users who are capable - * of managing the cgroup shares. - * - * The strstr() function will return the pointer to the - * beginning of the sub string "/tasks". - */ - tmp_len = strlen(path) - strlen("/tasks"); - - /* tmp_path would be pointing to the last six characters */ - tmp_path = (char *)path + tmp_len; - - /* - * Checking to see, if this is actually a 'tasks' file We need to - * compare the last 6 bytes - */ - if (strcmp(tmp_path, "/tasks")) { - cgroup->control_uid = stat_buffer.st_uid; - cgroup->control_gid = stat_buffer.st_gid; - } - - ctrl_name = strtok_r(d_name, ".", &buffer); - - if (!ctrl_name) { - error = ECGFAIL; - goto fill_error; - } - - ctrl_file = strtok_r(NULL, ".", &buffer); - - if (!ctrl_file) { - error = ECGINVAL; - goto fill_error; - } - - if (strcmp(ctrl_name, cg_mount_table[cg_index].name) == 0) { - error = cg_rd_ctrl_file(cg_mount_table[cg_index].name, cgroup->name, - ctrl_dir->d_name, &ctrl_value); - if (error || !ctrl_value) - goto fill_error; - - if (cgroup_add_value_string(cgc, ctrl_dir->d_name, ctrl_value)) { - error = ECGFAIL; - goto fill_error; - } - } -fill_error: - if (ctrl_value) - free(ctrl_value); - free(d_name); - - return error; -} - -/* - * cgroup_get_cgroup reads the cgroup data from the filesystem. - * struct cgroup has the name of the group to be populated - * - * return 0 on success. - */ -int cgroup_get_cgroup(struct cgroup *cgroup) -{ - char cgrp_ctrl_path[FILENAME_MAX]; - struct dirent *ctrl_dir = NULL; - char mnt_path[FILENAME_MAX]; - int initial_controller_cnt; - char *control_path = NULL; - int controller_cnt = 0; - DIR *dir = NULL; - int error; - int i, j; - int ret; - - if (!cgroup_initialized) { - /* ECGROUPNOTINITIALIZED */ - return ECGROUPNOTINITIALIZED; - } - - if (!cgroup) { - /* ECGROUPNOTALLOWED */ - return ECGROUPNOTALLOWED; - } - - initial_controller_cnt = cgroup->index; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - for (i = 0; i < CG_CONTROLLER_MAX && cg_mount_table[i].name[0] != '\0'; i++) { - struct cgroup_controller *cgc; - struct stat stat_buffer; - int mnt_path_len; - - if (initial_controller_cnt > 0) { - bool skip_this_controller = true; - - /* - * The user has specified a list of controllers they are interested - * in. Only operate on the specified controllers - */ - for (j = 0; j < cgroup->index; j++) { - if (strncmp(cg_mount_table[i].name, cgroup->controller[j]->name, - CONTROL_NAMELEN_MAX) == 0) - skip_this_controller = false; - } - - if (skip_this_controller) - continue; - } - - if (!cg_build_path_locked(NULL, mnt_path, cg_mount_table[i].name)) - continue; - - mnt_path_len = strlen(mnt_path); - strncat(mnt_path, cgroup->name, FILENAME_MAX - mnt_path_len - 1); - mnt_path[sizeof(mnt_path) - 1] = '\0'; - - if (access(mnt_path, F_OK)) - continue; - - if (!cg_build_path_locked(cgroup->name, cgrp_ctrl_path, cg_mount_table[i].name)) { - /* This fails when the cgroup does not exist for that controller. */ - continue; - } - - /* Get the uid and gid information. */ - if (cg_mount_table[i].version == CGROUP_V1) { - ret = asprintf(&control_path, "%s/tasks", cgrp_ctrl_path); - - if (ret < 0) { - last_errno = errno; - error = ECGOTHER; - goto unlock_error; - } - - if (stat(control_path, &stat_buffer)) { - last_errno = errno; - free(control_path); - error = ECGOTHER; - goto unlock_error; - } - - cgroup->tasks_uid = stat_buffer.st_uid; - cgroup->tasks_gid = stat_buffer.st_gid; - - free(control_path); - } else { /* cgroup v2 */ - bool enabled; - - error = cgroupv2_get_controllers(cgrp_ctrl_path, cg_mount_table[i].name, - &enabled); - if (error == ECGROUPNOTMOUNTED) { - /* - * This controller isn't enabled. Only hide it from the - * user if they've chosen to view all enabled controllers. - * - * If they've specified the controllers they're interested in - * and we've made it this far, then they are explicitly - * interested in this controller and we should not remove it. - */ - if (initial_controller_cnt == 0) { - controller_cnt++; - continue; - } - } else if (error) { - goto unlock_error; - } - } - - if (initial_controller_cnt) - cgc = cgroup_get_controller(cgroup, cg_mount_table[i].name); - else - cgc = cgroup_add_controller(cgroup, cg_mount_table[i].name); - if (!cgc) { - error = ECGINVAL; - goto unlock_error; - } - - dir = opendir(cgrp_ctrl_path); - if (!dir) { - last_errno = errno; - error = ECGOTHER; - goto unlock_error; - } - - controller_cnt++; - - while ((ctrl_dir = readdir(dir)) != NULL) { - /* Skip over non regular files */ - if (ctrl_dir->d_type != DT_REG) - continue; - - error = cgroup_fill_cgc(ctrl_dir, cgroup, cgc, i); - for (j = 0; j < cgc->index; j++) - cgc->values[j]->dirty = false; - - if (error == ECGFAIL) { - closedir(dir); - goto unlock_error; - } - } - closedir(dir); - - if (!strcmp(cgc->name, "memory")) { - /* - * Make sure that memory.limit_in_bytes is placed before - * memory.memsw.limit_in_bytes in the list of values - */ - int memsw_limit = -1; - int mem_limit = -1; - - for (j = 0; j < cgc->index; j++) { - if (!strcmp(cgc->values[j]->name, "memory.memsw.limit_in_bytes")) - memsw_limit = j; - else if (!strcmp(cgc->values[j]->name, "memory.limit_in_bytes")) - mem_limit = j; - } - - if (memsw_limit >= 0 && memsw_limit < mem_limit) { - struct control_value *val = cgc->values[memsw_limit]; - - cgc->values[memsw_limit] = cgc->values[mem_limit]; - cgc->values[mem_limit] = val; - } - } - } - - /* - * Check if the group really exists or not. The cgroup->index controller count can't - * be used in this case because cgroup v2 allows controllers to be enabled/disabled in - * the subtree_control file. Rather, cgroup_get_cgroup() tracks the number of possible - * controllers in the controller_cnt variable and uses that to determine if the cgroup - * exists or not. - */ - if (!controller_cnt) { - error = ECGROUPNOTEXIST; - goto unlock_error; - } - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return 0; - -unlock_error: - pthread_rwlock_unlock(&cg_mount_table_lock); - /* - * XX: Need to figure out how to cleanup? Cleanup just the stuff - * we added, or the whole structure. - */ - cgroup_free_controllers(cgroup); - cgroup = NULL; - - return error; -} - -/** - * cg_prepare_cgroup Process the selected rule. Prepare the cgroup structure - * which can be used to add the task to destination cgroup. - * - * returns 0 on success. - */ -static int cg_prepare_cgroup(struct cgroup *cgroup, pid_t pid, const char *dest, - const char * const controllers[]) -{ - struct cgroup_controller *cptr = NULL; - const char *controller = NULL; - int ret = 0, i; - - /* Fill in cgroup details. */ - cgroup_dbg("Will move pid %d to cgroup '%s'\n", pid, dest); - - strncpy(cgroup->name, dest, FILENAME_MAX); - cgroup->name[FILENAME_MAX-1] = '\0'; - - /* Scan all the controllers */ - for (i = 0; i < CG_CONTROLLER_MAX; i++) { - int j = 0; - - if (!controllers[i]) - return 0; - controller = controllers[i]; - - /* If first string is "*" that means all the mounted controllers. */ - if (strcmp(controller, "*") == 0) { - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (j = 0; j < CG_CONTROLLER_MAX && - cg_mount_table[j].name[0] != '\0'; j++) { - cgroup_dbg("Adding controller %s\n", cg_mount_table[j].name); - cptr = cgroup_add_controller(cgroup, cg_mount_table[j].name); - if (!cptr) { - cgroup_warn("adding controller '%s' failed\n", - cg_mount_table[j].name); - pthread_rwlock_unlock(&cg_mount_table_lock); - cgroup_free_controllers(cgroup); - return ECGROUPNOTALLOWED; - } - } - pthread_rwlock_unlock(&cg_mount_table_lock); - return ret; - } - - /* It is individual controller names and not "*" */ - cgroup_dbg("Adding controller %s\n", controller); - cptr = cgroup_add_controller(cgroup, controller); - if (!cptr) { - cgroup_warn("adding controller '%s' failed\n", controller); - cgroup_free_controllers(cgroup); - return ECGROUPNOTALLOWED; - } - } - - return ret; -} - -/** - * Determines if the rule is a wildcard rule and if so, compares the wildcard - * rule against the new process. If the new process matches the wildcard rule, - * then this function returns true. Otherwise it returns false. - * - * @param rule_procname The procname field of the rule - * @param procname The name of the new process - * @return True if the procname matches the rule. False otherwise - */ -STATIC bool cgroup_compare_wildcard_procname(const char * const rule_procname, - const char * const procname) -{ - size_t rule_strlen = strlen(rule_procname); - - if (rule_procname[rule_strlen - 1] != '*') - /* This rule does not end in a wildcard */ - return false; - - /* Compare the two strings up to the asterisk */ - if (strncmp(rule_procname, procname, rule_strlen - 1) != 0) - /* The strings did not match */ - return false; - - /* All checks passed. The wildcarded process matched this rule */ - return true; -} - -static int cgroup_find_matching_destination(char *cgroup_list[], const char * const rule_dest, - int *matching_index) -{ - size_t rule_strlen = strlen(rule_dest); - int ret = -ENODATA; - int i; - - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (cgroup_list[i] == NULL) - break; - - if (rule_dest[rule_strlen - 1] == '/') { - /* - * Avoid a weird corner case where given a rule dest - * like 'folder/', we _don't_ want to match 'folder1' - */ - if (strlen(cgroup_list[i]) >= rule_strlen && - cgroup_list[i][rule_strlen - 1] != '/') - continue; - - /* - * Strip off the '/' at the end of the rule, as - * the destination from the cgroup_list will not - * have a trailing '/' - */ - rule_strlen--; - } - - if (strncmp(rule_dest, cgroup_list[i], - rule_strlen) == 0) { - *matching_index = i; - ret = 0; - break; - } - } - - return ret; -} - -static int cgroup_find_matching_controller(char * const *rule_controllers, - const char * const pid_controller, int *matching_index) -{ - int ret = -ENODATA; - int i; - - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (rule_controllers[i] == NULL) - break; - - if (strlen(rule_controllers[i]) != strlen(pid_controller)) - continue; - - if (strncmp(pid_controller, rule_controllers[i], strlen(pid_controller)) == 0) { - *matching_index = i; - ret = 0; - break; - } - } - - return ret; -} - -/** - * Evaluates if rule is an ignore rule and the pid/procname match this rule. - * If rule is an ignore rule and the pid/procname match this rule, then this - * function returns true. Otherwise it returns false. - * - * @param rule The rule being evaluated - * @param pid PID of the process being compared - * @param procname Process name of the process being compared - * @return True if the rule is an ignore rule and this pid/procname - * match the rule. False otherwise - */ -STATIC bool cgroup_compare_ignore_rule(const struct cgroup_rule * const rule, pid_t pid, - const char * const procname) -{ - char *controller_list[MAX_MNT_ELEMENTS] = { '\0' }; - char *cgroup_list[MAX_MNT_ELEMENTS] = { '\0' }; - int rule_matching_controller_idx; - int cgroup_list_matching_idx; - bool found_match = false; - char *token, *saveptr; - int ret, i; - - if (!rule->is_ignore) - /* Immediately return if the 'ignore' option is not set */ - return false; - - ret = cg_get_cgroups_from_proc_cgroups(pid, cgroup_list, controller_list, - MAX_MNT_ELEMENTS); - if (ret < 0) - goto out; - - ret = cgroup_find_matching_destination(cgroup_list, rule->destination, - &cgroup_list_matching_idx); - if (ret < 0) - /* No cgroups matched */ - goto out; - - token = strtok_r(controller_list[cgroup_list_matching_idx], ",", &saveptr); - while (token != NULL) { - - ret = cgroup_find_matching_controller(rule->controllers, token, - &rule_matching_controller_idx); - if (ret == 0) - /* We found a matching controller */ - break; - - token = strtok_r(NULL, ",", &saveptr); - } - - if (!rule->procname) { - /* - * The rule procname is empty, thus it's a wildcard and - * all processes match. - */ - found_match = true; - goto out; - } - - if (!strcmp(rule->procname, procname)) { - found_match = true; - goto out; - } - - if (cgroup_compare_wildcard_procname(rule->procname, procname)) - found_match = true; - -out: - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (controller_list[i]) - free(controller_list[i]); - if (cgroup_list[i]) - free(cgroup_list[i]); - } - - return found_match; -} - -static struct cgroup_rule *cgroup_find_matching_rule_uid_gid(uid_t uid, gid_t gid, - struct cgroup_rule *rule) -{ - /* Temporary user data */ - struct passwd *usr = NULL; - - /* Temporary group data */ - struct group *grp = NULL; - - /* Temporary string pointer */ - char *sp = NULL; - - /* Loop variable */ - int i = 0; - - while (rule) { - /* Skip "%" which indicates continuation of previous rule. */ - if (rule->username[0] == '%') { - rule = rule->next; - continue; - } - /* The wildcard rule always matches. */ - if ((rule->uid == CGRULE_WILD) && (rule->gid == CGRULE_WILD)) - return rule; - - /* This is the simple case of the UID matching. */ - if (rule->uid == uid) - return rule; - - /* This is the simple case of the GID matching. */ - if (rule->gid == gid) - return rule; - - /* If this is a group rule, the UID might be a member. */ - if (rule->username[0] == '@') { - /* Get the group data. */ - sp = &(rule->username[1]); - grp = getgrnam(sp); - if (!grp) { - rule = rule->next; - continue; - } - - /* Get the data for UID. */ - usr = getpwuid(uid); - if (!usr) { - rule = rule->next; - continue; - } - - /* If UID is a member of group, we matched. */ - for (i = 0; grp->gr_mem[i]; i++) { - if (!(strcmp(usr->pw_name, grp->gr_mem[i]))) - return rule; - } - } - - /* If we haven't matched, try the next rule. */ - rule = rule->next; - } - - /* If we get here, no rules matched. */ - return NULL; -} - -/** - * Finds the first rule in the cached list that matches the given UID, GID - * or PROCESS NAME, and returns a pointer to that rule. - * This function uses rl_lock. - * - * This function may NOT be thread safe. - * @param uid The UID to match - * @param gid The GID to match - * @param procname The PROCESS NAME to match - * @return Pointer to the first matching rule, or NULL if no match - * TODO: Determine thread-safeness and fix if not safe. - */ -static struct cgroup_rule *cgroup_find_matching_rule(uid_t uid, gid_t gid, pid_t pid, - const char *procname) -{ - /* Return value */ - struct cgroup_rule *ret = rl.head; - char *base = NULL; - - pthread_rwlock_wrlock(&rl_lock); - while (ret) { - ret = cgroup_find_matching_rule_uid_gid(uid, gid, ret); - if (!ret) - break; - if (cgroup_compare_ignore_rule(ret, pid, procname)) - /* - * This pid matched a rule that instructs the - * cgrules daemon to ignore this process. - */ - break; - if (ret->is_ignore) { - /* - * The rule currently being examined is an ignore - * rule, but it didn't match this pid. Move on to - * the next rule - */ - ret = ret->next; - continue; - } - if (!procname) - /* If procname is NULL, return a rule matching UID or GID. */ - break; - if (!ret->procname) - /* If no process name in a rule, that means wildcard */ - break; - if (!strcmp(ret->procname, procname)) - break; - - base = cgroup_basename(procname); - if (!strcmp(ret->procname, base)) - /* Check a rule of basename. */ - break; - if (cgroup_compare_wildcard_procname(ret->procname, procname)) - break; - ret = ret->next; - free(base); - base = NULL; - } - pthread_rwlock_unlock(&rl_lock); - - if (base) - free(base); - - return ret; -} - -/* - * Procedure the existence of cgroup "prefix" is in subsystem - * controller_name return 0 on success - */ -int cgroup_exist_in_subsystem(char *controller_name, char *prefix) -{ - char path[FILENAME_MAX]; - char *ret_path; - DIR *dir; - int ret; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - ret_path = cg_build_path_locked(prefix, path, controller_name); - pthread_rwlock_unlock(&cg_mount_table_lock); - if (!ret_path) { - ret = 1; - goto end; - } - - dir = opendir(path); - if (dir == NULL) { - /* cgroup in wanted subsystem does not exist */ - ret = 1; - } else { - /* cgroup in wanted subsystem exists */ - ret = 0; - closedir(dir); - } -end: - return ret; -} - -/* - * Auxiliary function return a pointer to the string which is copy of - * input string and end with the slash - */ -char *cgroup_copy_with_slash(char *input) -{ - int len = strlen(input); - char *output; - - /* If input does not end with '/', allocate one more space for it */ - if ((input[len-1]) != '/') - len = len+1; - - output = (char *)malloc(sizeof(char)*(len+1)); - if (output == NULL) - return NULL; - - strcpy(output, input); - output[len-1] = '/'; - output[len] = '\0'; - - return output; -} - -/* Add controller to a group if it is not exists create it */ -static int add_controller(struct cgroup **pgroup, char *group_name, - char controller_name[FILENAME_MAX]) -{ - struct cgroup_controller *controller = NULL; - struct cgroup *group = pgroup[0]; - int ret = 0; - - if (group == NULL) { - /* It is the first controllerc the group have to be created */ - group = cgroup_new_cgroup(group_name); - if (group == NULL) { - ret = ECGFAIL; - goto end; - } - pgroup[0] = group; - } - - controller = cgroup_add_controller(group, controller_name); - if (controller == NULL) { - cgroup_free(&group); - ret = ECGFAIL; - } -end: - return ret; -} - -/* - * Create control group based given template if the group already don't exist - * dest is template name with substitute variables tmp is used cgrules rule. - */ -static int cgroup_create_template_group(char *orig_group_name, struct cgroup_rule *tmp, int flags) -{ - - struct cgroup *template_group = NULL; - char *template_name = NULL; /* Name of the template. */ - char *group_name = NULL; /* Name of the group based on */ - /* template variables are substituted.*/ - char *template_position; /* Denotes directory in template */ - /* path which is investigated. */ - char *group_position; /* Denotes directory in cgroup path */ - /* which is investigated. */ - - int ret = 0; - int exist; - int i; - - /* Template name and group name have to have '/' sign at the end */ - template_name = cgroup_copy_with_slash(tmp->destination); - if (template_name == NULL) { - ret = ECGOTHER; - last_errno = errno; - goto end; - } - group_name = cgroup_copy_with_slash(orig_group_name); - if (group_name == NULL) { - ret = ECGOTHER; - last_errno = errno; - free(template_name); - template_name = NULL; - goto end; - } - - /* Set start positions */ - template_position = strchr(template_name, '/'); - group_position = strchr(group_name, '/'); - - /* - * Go recursively through whole path to template group and create - * given directory if it does not exist yet - */ - while ((group_position != NULL) && (template_position != NULL)) { - /* Set new subpath */ - group_position[0] = '\0'; - template_position[0] = '\0'; - template_group = NULL; - - /* Test for which controllers wanted group does not exist */ - i = 0; - while (tmp->controllers[i] != NULL) { - exist = cgroup_exist_in_subsystem(tmp->controllers[i], group_name); - - if (exist != 0) { - /* The cgroup does not exist */ - ret = add_controller(&template_group, group_name, - tmp->controllers[i]); - if (ret != 0) - goto while_end; - } - i++; - } - - if (template_group != NULL) { - /* New group have to be created */ - if (strcmp(group_name, template_name) == 0) { - /* The prefix cgroup without template */ - ret = cgroup_create_cgroup(template_group, 0); - } else { - /* Use template to create relevant cgroup */ - ret = cgroup_config_create_template_group(template_group, - template_name, flags); - } - - if (ret != 0) { - cgroup_free(&template_group); - goto while_end; - } - cgroup_dbg("Group %s created - based on template %s\n", group_name, - template_name); - - cgroup_free(&template_group); - } - template_position[0] = '/'; - group_position[0] = '/'; - template_position = strchr(++template_position, '/'); - group_position = strchr(++group_position, '/'); - } - -while_end: - if ((template_position != NULL) && (template_position[0] == '\0')) - template_position[0] = '/'; - if ((group_position != NULL) && (group_position[0] == '\0')) - group_position[0] = '/'; - -end: - if (group_name != NULL) - free(group_name); - if (template_name != NULL) - free(template_name); - - return ret; -} - -int cgroup_change_cgroup_flags(uid_t uid, gid_t gid, const char *procname, pid_t pid, int flags) -{ - /* Temporary pointer to a rule */ - struct cgroup_rule *tmp = NULL; - - /* Temporary variables for destination substitution */ - char newdest[FILENAME_MAX]; - struct passwd *user_info; - struct group *group_info; - int available; - int written; - int i, j; - - /* Return codes */ - int ret = 0; - - /* We need to check this before doing anything else! */ - if (!cgroup_initialized) { - cgroup_warn("libcgroup is not initialized\n"); - ret = ECGROUPNOTINITIALIZED; - goto finished; - } - - /* - * User had asked to find the matching rule (if one exist) in the - * cached rules but the list might be empty due to the inactive - * cgrulesengd. Lets emulate its behaviour of caching the rules by - * reloading the rules from the configuration file. - */ - if ((flags & CGFLAG_USECACHE) && (rl.head == NULL)) { - cgroup_warn("no cached rules found, trying to reload from %s.\n", - CGRULES_CONF_FILE); - - ret = cgroup_reload_cached_rules(); - if (ret != 0) - goto finished; - } - - /* - * If the user did not ask for cached rules, we must parse the - * configuration to find a matching rule (if one exists). - * Else, we'll find the first match in the cached list (rl). - */ - if (!(flags & CGFLAG_USECACHE)) { - cgroup_dbg("Not using cached rules for PID %d.\n", pid); - ret = cgroup_parse_rules(false, uid, gid, procname); - - /* The configuration file has an error! We must exit now. */ - if (ret != -1 && ret != 0) { - cgroup_err("failed to parse the configuration rules\n"); - goto finished; - } - - /* We did not find a matching rule, so we're done. */ - if (ret == 0) { - cgroup_dbg("No rule found to match PID: %d, UID: %d, GID: %d\n", - pid, uid, gid); - goto finished; - } - - /* Otherwise, we did match a rule and it's in trl. */ - tmp = trl.head; - } else { - /* Find the first matching rule in the cached list. */ - tmp = cgroup_find_matching_rule(uid, gid, pid, procname); - if (!tmp) { - cgroup_dbg("No rule found to match PID: %d, UID: %d, GID: %d\n", - pid, uid, gid); - ret = 0; - goto finished; - } - } - cgroup_dbg("Found matching rule %s for PID: %d, UID: %d, GID: %d\n", - tmp->username, pid, uid, gid); - - if (tmp->is_ignore) { - /* - * This rule has instructed us that this pid is not to be - * processed and should be ignored - */ - cgroup_dbg("Matching rule is an ignore rule\n"); - ret = 0; - goto finished; - } - - /* If we are here, then we found a matching rule, so execute it. */ - do { - cgroup_dbg("Executing rule %s for PID %d... ", tmp->username, pid); - - /* Destination substitutions */ - for (j = i = 0; i < strlen(tmp->destination) && - (j < FILENAME_MAX - 2); ++i, ++j) { - if (tmp->destination[i] == '%') { - /* How many bytes did we write / error check */ - written = 0; - /* How many bytes can we write */ - available = FILENAME_MAX - j - 2; - /* Substitution */ - switch (tmp->destination[++i]) { - case 'U': - written = snprintf(newdest+j, available, "%d", uid); - break; - case 'u': - user_info = getpwuid(uid); - if (user_info) { - written = snprintf(newdest + j, available, "%s", - user_info->pw_name); - } else { - written = snprintf(newdest + j, available, "%d", - uid); - } - break; - case 'G': - written = snprintf(newdest + j, available, "%d", gid); - break; - case 'g': - group_info = getgrgid(gid); - if (group_info) { - written = snprintf(newdest + j, available, "%s", - group_info->gr_name); - } else { - written = snprintf(newdest + j, available, "%d", - gid); - } - break; - case 'P': - written = snprintf(newdest + j, available, "%d", pid); - break; - case 'p': - if (procname) { - written = snprintf(newdest + j, available, "%s", - procname); - } else { - written = snprintf(newdest + j, available, "%d", - pid); - } - break; - } - written = min(written, available); - /* - * written<1 only when either error occurred - * during snprintf or if no substitution was made - * at all. In both cases, we want to just copy - * input string. - */ - if (written < 1) { - newdest[j] = '%'; - if (available > 1) - newdest[++j] = tmp->destination[i]; - } else { - /* - * In next iteration, we will write just - * after the substitution, but j will get - * incremented in the meantime. - */ - j += written - 1; - } - } else { - if (tmp->destination[i] == '\\') - ++i; - newdest[j] = tmp->destination[i]; - } - } - - newdest[j] = 0; - if (strcmp(newdest, tmp->destination) != 0) { - /* Destination tag contains templates */ - - cgroup_dbg("control group %s is template\n", newdest); - ret = cgroup_create_template_group(newdest, tmp, flags); - if (ret) { - cgroup_warn("failed to create cgroup based on template %s\n", - newdest); - goto finished; - } - } - - /* Apply the rule */ - ret = cgroup_change_cgroup_path(newdest, pid, - (const char * const *)tmp->controllers); - if (ret) { - cgroup_warn("failed to apply the rule. Error was: %d\n", ret); - goto finished; - } - cgroup_dbg("OK!\n"); - - /* - * Now, check for multi-line rules. As long as the "next" - * rule starts with '%', it's actually part of the rule that - * we just executed. - */ - tmp = tmp->next; - } while (tmp && (tmp->username[0] == '%')); - -finished: - return ret; -} - -int cgroup_change_cgroup_uid_gid_flags(uid_t uid, gid_t gid, pid_t pid, int flags) -{ - return cgroup_change_cgroup_flags(uid, gid, NULL, pid, flags); -} - -/** - * Provides backwards-compatibility with older versions of the API. - * This function is deprecated, and cgroup_change_cgroup_uid_gid_flags() - * should be used instead. In fact, this function simply calls the newer - * one with flags set to 0 (none). - * @param uid The UID to match - * @param gid The GID to match - * @param pid The PID of the process to move - * @return 0 on success, > 0 on error - */ -int cgroup_change_cgroup_uid_gid(uid_t uid, gid_t gid, pid_t pid) -{ - return cgroup_change_cgroup_uid_gid_flags(uid, gid, pid, 0); -} - -/** - * Changes the cgroup of a program based on the path provided. In this case, - * the user must already know into which cgroup the task should be placed and - * no rules will be parsed. - * - * returns 0 on success. - */ -int cgroup_change_cgroup_path(const char *dest, pid_t pid, const char *const controllers[]) -{ - struct dirent *task_dir = NULL; - char path[FILENAME_MAX]; - struct cgroup cgroup; - int nr, ret; - pid_t tid; - DIR *dir; - - if (!cgroup_initialized) { - cgroup_warn("libcgroup is not initialized\n"); - return ECGROUPNOTINITIALIZED; - } - memset(&cgroup, 0, sizeof(struct cgroup)); - - - if (is_cgroup_mode_unified() && !controllers) { - /* - * Do not require the user to pass in an array of controller strings on - * cgroup v2 systems. The hierarchy will be the same regardless of - * whether controllers are provided or not. - */ - strncpy(cgroup.name, dest, FILENAME_MAX); - cgroup.name[FILENAME_MAX-1] = '\0'; - } else { - if (!controllers) - return ECGINVAL; - - ret = cg_prepare_cgroup(&cgroup, pid, dest, controllers); - if (ret) - return ret; - } - - /* Add process to cgroup */ - ret = cgroup_attach_task_pid(&cgroup, pid); - if (ret) { - cgroup_warn("cgroup_attach_task_pid failed: %d\n", ret); - goto finished; - } - - /* Add all threads to cgroup */ - snprintf(path, FILENAME_MAX, "/proc/%d/task/", pid); - dir = opendir(path); - if (!dir) { - last_errno = errno; - ret = ECGOTHER; - goto finished; - } - - while ((task_dir = readdir(dir)) != NULL) { - nr = sscanf(task_dir->d_name, "%i", &tid); - if (nr < 1) - continue; - - if (tid == pid) - continue; - - ret = cgroup_attach_task_pid(&cgroup, tid); - if (ret) { - cgroup_warn("cgroup_attach_task_pid failed: %d\n", ret); - break; - } - } - - closedir(dir); - -finished: - cgroup_free_controllers(&cgroup); - - return ret; -} - -/** - * Changes the cgroup of all running PIDs based on the rules in the config file. - * If a rules exists for a PID, then the PID is placed in the correct group. - * - * This function may be called after creating new control groups to move - * running PIDs into the newly created control groups. - * @return 0 on success, < 0 on error - */ -int cgroup_change_all_cgroups(void) -{ - struct dirent *pid_dir = NULL; - char *path = "/proc/"; - DIR *dir; - - dir = opendir(path); - if (!dir) - return -ECGOTHER; - - while ((pid_dir = readdir(dir)) != NULL) { - int err, pid; - uid_t euid; - gid_t egid; - char *procname = NULL; - - err = sscanf(pid_dir->d_name, "%i", &pid); - if (err < 1) - continue; - - err = cgroup_get_uid_gid_from_procfs(pid, &euid, &egid); - if (err) - continue; - - err = cgroup_get_procname_from_procfs(pid, &procname); - if (err) - continue; - - err = cgroup_change_cgroup_flags(euid, egid, procname, pid, CGFLAG_USECACHE); - if (err) - cgroup_dbg("cgroup change pid %i failed\n", pid); - - free(procname); - } - - closedir(dir); - return 0; -} - -/** - * Print the cached rules table. This function should be called only after - * first calling cgroup_parse_config(), but it will work with an empty rule - * list. - * @param fp The file stream to print to - */ -void cgroup_print_rules_config(FILE *fp) -{ - /* Iterator */ - struct cgroup_rule *itr = NULL; - - /* Loop variable */ - int i = 0; - - pthread_rwlock_rdlock(&rl_lock); - - if (!(rl.head)) { - fprintf(fp, "The rules table is empty.\n\n"); - pthread_rwlock_unlock(&rl_lock); - return; - } - - itr = rl.head; - while (itr) { - fprintf(fp, "Rule: %s", itr->username); - if (itr->procname) - fprintf(fp, ":%s", itr->procname); - fprintf(fp, "\n"); - - if (itr->uid == CGRULE_WILD) - fprintf(fp, " UID: any\n"); - else if (itr->uid == CGRULE_INVALID) - fprintf(fp, " UID: N/A\n"); - else - fprintf(fp, " UID: %d\n", itr->uid); - - if (itr->gid == CGRULE_WILD) - fprintf(fp, " GID: any\n"); - else if (itr->gid == CGRULE_INVALID) - fprintf(fp, " GID: N/A\n"); - else - fprintf(fp, " GID: %d\n", itr->gid); - - fprintf(fp, " DEST: %s\n", itr->destination); - - fprintf(fp, " CONTROLLERS:\n"); - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (itr->controllers[i]) - fprintf(fp, " %s\n", itr->controllers[i]); - } - fprintf(fp, " OPTIONS:\n"); - if (itr->is_ignore) - fprintf(fp, " IS_IGNORE: True\n"); - else - fprintf(fp, " IS_IGNORE: False\n"); - fprintf(fp, "\n"); - itr = itr->next; - } - pthread_rwlock_unlock(&rl_lock); -} - -/** - * Reloads the rules list, using the given configuration file. - * This function is probably NOT thread safe (calls cgroup_parse_rules()). - * @return 0 on success, > 0 on failure - */ -int cgroup_reload_cached_rules(void) -{ - /* Return codes */ - int ret = 0; - - cgroup_dbg("Reloading cached rules from %s.\n", CGRULES_CONF_FILE); - ret = cgroup_parse_rules(true, CGRULE_INVALID, CGRULE_INVALID, NULL); - if (ret) { - cgroup_warn("error parsing configuration file '%s': %d\n", CGRULES_CONF_FILE, ret); - ret = ECGRULESPARSEFAIL; - goto finished; - } - - #ifdef CGROUP_DEBUG - cgroup_print_rules_config(stdout); - #endif -finished: - return ret; -} - -/** - * Initializes the rules cache. - * @return 0 on success, > 0 on error - */ -int cgroup_init_rules_cache(void) -{ - /* Return codes */ - int ret = 0; - - /* Attempt to read the configuration file and cache the rules. */ - ret = cgroup_parse_rules(true, CGRULE_INVALID, CGRULE_INVALID, NULL); - if (ret) { - cgroup_dbg("Could not initialize rule cache, error was: %d\n", ret); - } - - return ret; -} - -/** - * cgroup_get_current_controller_path - * @pid: pid of the current process for which the path is to be determined - * @controller: name of the controller for which to determine current path - * @current_path: a pointer that is filled with the value of the current - * path as seen in /proc//cgroup - */ -int cgroup_get_current_controller_path(pid_t pid, const char *controller, char **current_path) -{ - FILE *pid_cgroup_fd = NULL; - enum cg_version_t version; - enum cg_setup_mode_t mode; - bool unified = false; - char *path = NULL; - int ret; - - if (!cgroup_initialized) { - cgroup_warn("libcgroup is not initialized\n"); - return ECGROUPNOTINITIALIZED; - } - - if (!current_path) - return ECGOTHER; - - mode = cgroup_setup_mode(); - if (mode == CGROUP_MODE_LEGACY && !controller) - return ECGOTHER; - - /* - * both unified/hybrid can have the controller mounted as - * cgroup v2 version. - */ - if (!controller) { - unified = true; - } else { - ret = cgroup_get_controller_version(controller, &version); - if (ret) { - cgroup_warn("Failed to get version of the controller: %s\n", controller); - ret = ECGINVAL; - goto cleanup_path; - } - unified = (version == CGROUP_V2); - } - - ret = asprintf(&path, "/proc/%d/cgroup", pid); - if (ret <= 0) { - cgroup_warn("cannot allocate memory (/proc/pid/cgroup) ret %d\n", ret); - return ret; - } - - ret = ECGROUPNOTEXIST; - pid_cgroup_fd = fopen(path, "re"); - if (!pid_cgroup_fd) - goto cleanup_path; - - /* - * Why do we grab the cg_mount_table_lock?, the reason is that the - * cgroup of a pid can change via the cgroup_attach_task_pid() call. - * To make sure, we return consitent and safe results, we acquire the - * lock upfront. We can optimize by acquiring and releasing - * the lock in the while loop, but that will be more expensive. - */ - pthread_rwlock_rdlock(&cg_mount_table_lock); - while (!feof(pid_cgroup_fd)) { - char controllers[FILENAME_MAX]; - char cgroup_path[FILENAME_MAX]; - char *savedptr; - char *token; - int num; - - /* - * with unified mode, the /proc/pid/cgroup the output is - * similar to that of cgroup legacy and hybrid modes: - * hierarchy-ID:controller-list:cgroup-path - * - * the difference is that in cgroup v2: - * - hierarchy-ID is always 0 (one hierarchy allowed) - * - controller-list is empty - */ - if (mode == CGROUP_MODE_UNIFIED || unified) { - ret = fscanf(pid_cgroup_fd, "%d::%4096s\n", &num, cgroup_path); - if (ret != 2) { - /* - * we are interested only in unified format - * line, skip this line. - */ - if (unified) { - ret = fscanf(pid_cgroup_fd, "%*[^\n]\n"); - if (ret == 0) - continue; - } - - cgroup_warn("read failed for pid_cgroup_fd ret %d\n", ret); - last_errno = errno; - ret = ECGOTHER; - goto done; - } - - /* check if the controller is enabled in cgroup v2 */ - if (controller) { - ret = cgroupv2_controller_enabled(cgroup_path, controller); - if (ret) - goto done; - } - - *current_path = strdup(cgroup_path); - if (!*current_path) { - last_errno = errno; - ret = ECGOTHER; - goto done; - } - ret = 0; - goto done; - } - - /* - * 4096 == FILENAME_MAX, keeping the coverity happy with precision - * for the cgroup_path. - */ - ret = fscanf(pid_cgroup_fd, "%d:%[^:]:%4096s\n", &num, controllers, cgroup_path); - /* - * Magic numbers like "3" seem to be integrating into my daily - * life, I need some magic to help make them disappear :) - */ - if (ret != 3) { - cgroup_warn("read failed for pid_cgroup_fd ret %d\n", ret); - last_errno = errno; - ret = ECGOTHER; - goto done; - } - - token = strtok_r(controllers, ",", &savedptr); - while (token) { - if (strncmp(controller, token, strlen(controller) + 1) == 0) { - *current_path = strdup(cgroup_path); - if (!*current_path) { - last_errno = errno; - ret = ECGOTHER; - goto done; - } - ret = 0; - goto done; - } - token = strtok_r(NULL, ",", &savedptr); - } - } - -done: - pthread_rwlock_unlock(&cg_mount_table_lock); - fclose(pid_cgroup_fd); -cleanup_path: - free(path); - - return ret; -} - -const char *cgroup_strerror(int code) -{ - int idx = code % ECGROUPNOTCOMPILED; - - if (code == ECGOTHER) { -#ifdef STRERROR_R_CHAR_P - return strerror_r(cgroup_get_last_errno(), errtext, MAXLEN); -#else - return strerror_r(cgroup_get_last_errno(), errtext, sizeof (errtext)) ? - "unknown error" : errtext; -#endif - } - if (idx >= sizeof(cgroup_strerror_codes)/sizeof(cgroup_strerror_codes[0])) - return "Invalid error code"; - - return cgroup_strerror_codes[idx]; -} - -/** - * Return last errno, which caused ECGOTHER error. - */ -int cgroup_get_last_errno(void) -{ - return last_errno; -} - -static int cg_walk_node(FTS *fts, FTSENT *ent, const int depth, struct cgroup_file_info *info, - int dir) -{ - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - cgroup_dbg("seeing file %s\n", ent->fts_path); - - info->path = ent->fts_name; - info->parent = ent->fts_parent->fts_name; - info->full_path = ent->fts_path; - info->depth = ent->fts_level; - info->type = CGROUP_FILE_TYPE_OTHER; - - if (depth && (info->depth > depth)) - return 0; - - switch (ent->fts_info) { - case FTS_DNR: - case FTS_ERR: - errno = ent->fts_errno; - break; - case FTS_D: - if (dir & CGROUP_WALK_TYPE_PRE_DIR) - info->type = CGROUP_FILE_TYPE_DIR; - break; - case FTS_DC: - case FTS_NSOK: - case FTS_NS: - case FTS_DP: - if (dir & CGROUP_WALK_TYPE_POST_DIR) - info->type = CGROUP_FILE_TYPE_DIR; - break; - case FTS_F: - info->type = CGROUP_FILE_TYPE_FILE; - break; - case FTS_DEFAULT: - break; - } - return ret; -} - -int cgroup_walk_tree_next(int depth, void **handle, struct cgroup_file_info *info, int base_level) -{ - struct cgroup_tree_handle *entry; - FTSENT *ent; - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - entry = (struct cgroup_tree_handle *) *handle; - - ent = fts_read(entry->fts); - if (!ent) - return ECGEOF; - if (!base_level && depth) - base_level = ent->fts_level + depth; - - ret = cg_walk_node(entry->fts, ent, base_level, info, entry->flags); - - *handle = entry; - return ret; -} - -int cgroup_walk_tree_end(void **handle) -{ - struct cgroup_tree_handle *entry; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - entry = (struct cgroup_tree_handle *) *handle; - - fts_close(entry->fts); - free(entry); - *handle = NULL; - - return 0; -} - -/* TODO: Need to decide a better place to put this function. */ -int cgroup_walk_tree_begin(const char *controller, const char *base_path, int depth, void **handle, - struct cgroup_file_info *info, int *base_level) -{ - struct cgroup_tree_handle *entry; - char full_path[FILENAME_MAX]; - char *cg_path[2]; - FTSENT *ent; - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - cgroup_dbg("path is %s\n", base_path); - - if (!cg_build_path(base_path, full_path, controller)) - return ECGOTHER; - - entry = calloc(sizeof(struct cgroup_tree_handle), 1); - - if (!entry) { - last_errno = errno; - *handle = NULL; - return ECGOTHER; - } - - entry->flags |= CGROUP_WALK_TYPE_PRE_DIR; - - *base_level = 0; - cg_path[0] = full_path; - cg_path[1] = NULL; - - entry->fts = fts_open(cg_path, FTS_LOGICAL | FTS_NOCHDIR | FTS_NOSTAT, NULL); - if (entry->fts == NULL) { - free(entry); - last_errno = errno; - *handle = NULL; - return ECGOTHER; - } - ent = fts_read(entry->fts); - if (!ent) { - cgroup_warn("fts_read failed\n"); - fts_close(entry->fts); - free(entry); - *handle = NULL; - return ECGINVAL; - } - if (!*base_level && depth) - *base_level = ent->fts_level + depth; - - ret = cg_walk_node(entry->fts, ent, *base_level, info, entry->flags); - if (ret != 0) { - fts_close(entry->fts); - free(entry); - *handle = NULL; - } else { - *handle = entry; - } - return ret; -} - -int cgroup_walk_tree_set_flags(void **handle, int flags) -{ - struct cgroup_tree_handle *entry; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - if ((flags & CGROUP_WALK_TYPE_PRE_DIR) && - (flags & CGROUP_WALK_TYPE_POST_DIR)) - return ECGINVAL; - - entry = (struct cgroup_tree_handle *) *handle; - entry->flags = flags; - - *handle = entry; - return 0; -} - -/* - * This parses a stat line which is in the form of (name value) pair - * separated by a space. - */ -static int cg_read_stat(FILE *fp, struct cgroup_stat *cgroup_stat) -{ - char *saveptr = NULL; - ssize_t read_bytes; - char *line = NULL; - size_t len = 0; - char *token; - int ret = 0; - - read_bytes = getline(&line, &len, fp); - if (read_bytes == -1) { - ret = ECGEOF; - goto out_free; - } - - token = strtok_r(line, " ", &saveptr); - if (!token) { - ret = ECGINVAL; - goto out_free; - } - strncpy(cgroup_stat->name, token, FILENAME_MAX - 1); - - token = strtok_r(NULL, " ", &saveptr); - if (!token) { - ret = ECGINVAL; - goto out_free; - } - strncpy(cgroup_stat->value, token, CG_VALUE_MAX - 1); - -out_free: - free(line); - - return ret; -} - -int cgroup_read_value_end(void **handle) -{ - FILE *fp; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - fp = (FILE *)*handle; - fclose(fp); - *handle = NULL; - - return 0; -} - -int cgroup_read_value_next(void **handle, char *buffer, int max) -{ - char *ret_c; - int ret = 0; - FILE *fp; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!buffer || !handle) - return ECGINVAL; - - fp = (FILE *)*handle; - ret_c = fgets(buffer, max, fp); - if (ret_c == NULL) - ret = ECGEOF; - - return ret; -} - -int cgroup_read_value_begin(const char * const controller, const char *path, - const char * const name, void **handle, char *buffer, int max) -{ - char stat_file[FILENAME_MAX + sizeof(name)]; - char stat_path[FILENAME_MAX]; - char *ret_c = NULL; - int ret = 0; - FILE *fp; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!buffer || !handle) - return ECGINVAL; - - if (!cg_build_path(path, stat_path, controller)) - return ECGOTHER; - - snprintf(stat_file, sizeof(stat_file), "%s/%s", stat_path, - name); - fp = fopen(stat_file, "re"); - if (!fp) { - cgroup_warn("fopen failed\n"); - last_errno = errno; - *handle = NULL; - return ECGOTHER; - } - - ret_c = fgets(buffer, max, fp); - if (ret_c == NULL) - ret = ECGEOF; - - *handle = fp; - - return ret; -} - -int cgroup_read_stats_end(void **handle) -{ - FILE *fp; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - fp = (FILE *)*handle; - if (fp == NULL) - return ECGINVAL; - - fclose(fp); - - return 0; -} - -int cgroup_read_stats_next(void **handle, struct cgroup_stat *cgroup_stat) -{ - FILE *fp; - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle || !cgroup_stat) - return ECGINVAL; - - fp = (FILE *)*handle; - ret = cg_read_stat(fp, cgroup_stat); - *handle = fp; - - return ret; -} - -/* TODO: Need to decide a better place to put this function. */ -int cgroup_read_stats_begin(const char *controller, const char *path, void **handle, - struct cgroup_stat *cgroup_stat) -{ - char stat_file[FILENAME_MAX + sizeof(".stat")]; - char stat_path[FILENAME_MAX]; - int ret = 0; - FILE *fp; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!cgroup_stat || !handle) - return ECGINVAL; - - if (!cg_build_path(path, stat_path, controller)) - return ECGOTHER; - - snprintf(stat_file, sizeof(stat_file), "%s/%s.stat", stat_path, controller); - - fp = fopen(stat_file, "re"); - if (!fp) { - cgroup_warn("fopen failed\n"); - return ECGINVAL; - } - - ret = cg_read_stat(fp, cgroup_stat); - *handle = fp; - - return ret; -} - -int cgroup_get_task_end(void **handle) -{ - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!*handle) - return ECGINVAL; - - fclose((FILE *) *handle); - *handle = NULL; - - return 0; -} - -int cgroup_get_task_next(void **handle, pid_t *pid) -{ - int ret; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - ret = fscanf((FILE *) *handle, "%u", pid); - - if (ret != 1) { - if (ret == EOF) - return ECGEOF; - last_errno = errno; - return ECGOTHER; - } - - return 0; -} - -int cgroup_get_task_begin(const char *cgroup, const char *controller, void **handle, pid_t *pid) -{ - char path[FILENAME_MAX]; - char *fullpath = NULL; - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!cg_build_path(cgroup, path, controller)) - return ECGOTHER; - - ret = asprintf(&fullpath, "%s/tasks", path); - - if (ret < 0) { - last_errno = errno; - return ECGOTHER; - } - - *handle = (void *) fopen(fullpath, "re"); - free(fullpath); - - if (!*handle) { - last_errno = errno; - return ECGOTHER; - } - ret = cgroup_get_task_next(handle, pid); - - return ret; -} - -int cgroup_get_controller_end(void **handle) -{ - int *pos = (int *) *handle; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!pos) - return ECGINVAL; - - free(pos); - *handle = NULL; - - return 0; -} - -int cgroup_get_controller_next(void **handle, struct cgroup_mount_point *info) -{ - int *pos = (int *) *handle; - int ret = 0; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!pos) - return ECGINVAL; - - if (!info) - return ECGINVAL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - if (cg_mount_table[*pos].name[0] == '\0') { - ret = ECGEOF; - goto out_unlock; - } - - if (strncmp(cg_mount_table[*pos].name, CGROUP_FILE_PREFIX, CONTROL_NAMELEN_MAX) == 0) - /* - * For now, hide the "cgroup" pseudo-controller from the user. This may be - * worth revisiting in the future. - */ - (*pos)++; - - if (cg_mount_table[*pos].name[0] == '\0') { - ret = ECGEOF; - goto out_unlock; - } - - strncpy(info->name, cg_mount_table[*pos].name, FILENAME_MAX - 1); - info->name[FILENAME_MAX - 1] = '\0'; - - strncpy(info->path, cg_mount_table[*pos].mount.path, FILENAME_MAX - 1); - info->path[FILENAME_MAX - 1] = '\0'; - - (*pos)++; - *handle = pos; - -out_unlock: - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} - -int cgroup_get_controller_begin(void **handle, struct cgroup_mount_point *info) -{ - int *pos; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!info) - return ECGINVAL; - - pos = malloc(sizeof(int)); - - if (!pos) { - last_errno = errno; - return ECGOTHER; - } - - *pos = 0; - - *handle = pos; - - return cgroup_get_controller_next(handle, info); -} - -/** - * Get process data (euid and egid) from /proc//status file. - * @param pid: The process id - * @param euid: The uid of param pid - * @param egid: The gid of param pid - * @return 0 on success, > 0 on error. - */ -int cgroup_get_uid_gid_from_procfs(pid_t pid, uid_t *euid, gid_t *egid) -{ - char path[FILENAME_MAX]; - uid_t ruid, suid, fsuid; - gid_t rgid, sgid, fsgid; - bool found_euid = false; - bool found_egid = false; - char buf[4092]; - FILE *f; - - sprintf(path, "/proc/%d/status", pid); - f = fopen(path, "re"); - if (!f) - return ECGROUPNOTEXIST; - - while (fgets(buf, sizeof(buf), f)) { - if (!strncmp(buf, "Uid:", 4)) { - if (sscanf((buf + strlen("Uid:") + 1), "%d%d%d%d", - &ruid, euid, &suid, &fsuid) != 4) - break; - cgroup_dbg("Scanned proc values are %d %d %d %d\n", - ruid, *euid, suid, fsuid); - found_euid = true; - } else if (!strncmp(buf, "Gid:", 4)) { - if (sscanf((buf + strlen("Gid:") + 1), "%d%d%d%d", - &rgid, egid, &sgid, &fsgid) != 4) - break; - cgroup_dbg("Scanned proc values are %d %d %d %d\n", - rgid, *egid, sgid, fsgid); - found_egid = true; - } - if (found_euid && found_egid) - break; - } - fclose(f); - if (!found_euid || !found_egid) { - /* - * This method doesn't match the file format of - * /proc//status. The format has been changed and we - * should catch up the change. - */ - cgroup_warn("invalid file format of /proc/%d/status\n", pid); - return ECGFAIL; - } - return 0; -} - -/** - * Given a pid, this function will return the controllers and cgroups that - * the pid is a member of. The caller is expected to allocate the - * controller_list[] and cgroup_list[] arrays as well as null each entry in - * the arrays. This function will allocate the necessary memory for each - * string within the arrays. - * - * @param pid The process id - * @param cgroup_list[] An array of char pointers to hold the cgroups - * @param controller_list[] An array of char pointers to hold the list - * of controllers - * @param list_len The size of the arrays - */ -STATIC int cg_get_cgroups_from_proc_cgroups(pid_t pid, char *cgroup_list[], - char *controller_list[], int list_len) -{ - char path[FILENAME_MAX]; - char *stok_buff = NULL; - size_t buff_len; - char buf[4092]; - int ret = 0; - int idx = 0; - FILE *f; - -#ifdef UNIT_TEST - sprintf(path, "%s", TEST_PROC_PID_CGROUP_FILE); -#else - sprintf(path, "/proc/%d/cgroup", pid); -#endif - f = fopen(path, "re"); - if (!f) - return ECGROUPNOTEXIST; - - while (fgets(buf, sizeof(buf), f)) { - /* - * Each line in /proc/{pid}/cgroup is like the following: - * - * {cg#}:{controller}:{cgname} - * - * e.g. - * 7:devices:/user.slice - */ - - /* Read in the cgroup number. we don't care about it */ - stok_buff = strtok(buf, ":"); - /* Read in the controller name */ - stok_buff = strtok(NULL, ":"); - - /* - * After this point, we have allocated memory. if we return - * an error code after this, it's up to us to free the memory - * we allocated - */ - controller_list[idx] = strndup(stok_buff, strlen(stok_buff) + 1); - - /* Read in the cgroup name */ - stok_buff = strtok(NULL, ":"); - - if (stok_buff == NULL) { - /* - * An empty controller is reported on some kernels. - * It may look like this: - * 0::/user.slice/user-1000.slice/session-1.scope - * - * Ignore this controller and move on. Note that we - * need to free the controller list entry we made. - */ - free(controller_list[idx]); - controller_list[idx] = NULL; - continue; - } - - buff_len = strlen(stok_buff); - if (stok_buff[buff_len - 1] == '\n') - buff_len--; /* Don't copy the trailing newline char */ - - /* Read in the cgroup name */ - if (buff_len > 1) { - /* Strip off the leading '/' for every cgroup but the root cgroup */ - cgroup_list[idx] = malloc(buff_len); - snprintf(cgroup_list[idx], buff_len, "%s", &stok_buff[1]); - } else { - /* Retain the leading '/' since we're in the root cgroup */ - cgroup_list[idx] = strndup(stok_buff, buff_len); - } - - idx++; - if (idx >= list_len) { - cgroup_warn("Maximum mount elements reached. Consider increasing "); - cgroup_warn("MAX_MNT_ELEMENTS\n"); - break; - } - } - fclose(f); - return ret; -} - -/** - * Get process name from /proc//status file. - * @param pid: The process id - * @param pname_status : The process name - * @return 0 on success, > 0 on error. - */ -static int cg_get_procname_from_proc_status(pid_t pid, char **procname_status) -{ - char path[FILENAME_MAX]; - int ret = ECGFAIL; - char buf[4092]; - FILE *f; - int len; - - sprintf(path, "/proc/%d/status", pid); - f = fopen(path, "re"); - if (!f) - return ECGROUPNOTEXIST; - - while (fgets(buf, sizeof(buf), f)) { - if (!strncmp(buf, "Name:", 5)) { - len = strlen(buf); - if (buf[len - 1] == '\n') - buf[len - 1] = '\0'; - *procname_status = strdup(buf + strlen("Name:") + 1); - if (*procname_status == NULL) { - last_errno = errno; - ret = ECGOTHER; - break; - } - ret = 0; - break; - } - } - fclose(f); - return ret; -} - -/** - * Get process name from /proc//cmdline file. - * This function is mainly for getting a script name (shell, perl, etc). - * A script name is written into the second or later argument of - * /proc//cmdline. This function gets each argument and - * compares it to a process name taken from /proc//status. - * @param pid: The process id - * @param pname_status : The process name taken from /proc//status - * @param pname_cmdline: The process name taken from /proc//cmdline - * @return 0 on success, > 0 on error. - */ -static int cg_get_procname_from_proc_cmdline(pid_t pid, const char *pname_status, - char **pname_cmdline) -{ - char pid_cwd_path[FILENAME_MAX]; - char pid_cmd_path[FILENAME_MAX]; - char buf_pname[FILENAME_MAX]; - char buf_cwd[FILENAME_MAX]; - int ret = ECGFAIL; - int len = 0; - int c = 0; - FILE *f; - - memset(buf_cwd, '\0', sizeof(buf_cwd)); - sprintf(pid_cwd_path, "/proc/%d/cwd", pid); - - if (readlink(pid_cwd_path, buf_cwd, sizeof(buf_cwd)) < 0) - return ECGROUPNOTEXIST; - - /* readlink doesn't append a null */ - buf_cwd[FILENAME_MAX - 1] = '\0'; - - sprintf(pid_cmd_path, "/proc/%d/cmdline", pid); - f = fopen(pid_cmd_path, "re"); - if (!f) - return ECGROUPNOTEXIST; - - while (c != EOF) { - c = fgetc(f); - if ((c != EOF) && (c != '\0') && (len < FILENAME_MAX - 1)) { - buf_pname[len] = c; - len++; - continue; - } - buf_pname[len] = '\0'; - - if (len == FILENAME_MAX - 1) - while ((c != EOF) && (c != '\0')) - c = fgetc(f); - - /* - * The taken process name from /proc//status is - * shortened to 15 characters if it is over. So the name - * should be compared by its length. - */ - if (strncmp(pname_status, basename(buf_pname), TASK_COMM_LEN - 1)) { - len = 0; - continue; - } - - if (buf_pname[0] == '/') { - *pname_cmdline = strdup(buf_pname); - if (*pname_cmdline == NULL) { - last_errno = errno; - ret = ECGOTHER; - break; - } - ret = 0; - break; - } - - strcat(buf_cwd, "/"); - strcat(buf_cwd, buf_pname); - if (!realpath(buf_cwd, pid_cmd_path)) { - last_errno = errno; - ret = ECGOTHER; - break; - } - - *pname_cmdline = strdup(pid_cmd_path); - if (*pname_cmdline == NULL) { - last_errno = errno; - ret = ECGOTHER; - break; - } - ret = 0; - break; - } - fclose(f); - return ret; -} - -/** - * Get a process name from /proc file system. - * This function allocates memory for a process name, writes a process - * name onto it. So a caller should free the memory when unusing it. - * @param pid: The process id - * @param procname: The process name - * @return 0 on success, > 0 on error. - */ -int cgroup_get_procname_from_procfs(pid_t pid, char **procname) -{ - char path[FILENAME_MAX]; - char buf[FILENAME_MAX]; - char *pname_cmdline; - char *pname_status; - int ret; - - ret = cg_get_procname_from_proc_status(pid, &pname_status); - if (ret) - return ret; - - /* Get the full patch of process name from /proc//exe. */ - memset(buf, '\0', sizeof(buf)); - snprintf(path, FILENAME_MAX, "/proc/%d/exe", pid); - if (readlink(path, buf, sizeof(buf)) < 0) { - /* - * readlink() fails if a kernel thread, and a process name - * is taken from /proc//status. - */ - *procname = pname_status; - return 0; - } - /* readlink doesn't append a null */ - buf[FILENAME_MAX - 1] = '\0'; - - if (!strncmp(pname_status, basename(buf), TASK_COMM_LEN - 1)) { - /* - * The taken process name from /proc//status is - * shortened to 15 characters if it is over. So the name - * should be compared by its length. - */ - free(pname_status); - *procname = strdup(buf); - if (*procname == NULL) { - last_errno = errno; - return ECGOTHER; - } - return 0; - } - - /* - * The above strncmp() is not 0 if a shell script, because - * /proc//exe links a shell command (/bin/bash etc.) and the - * pname_status represents a shell script name. Then the full path - * of a shell script is taken from /proc//cmdline. - */ - ret = cg_get_procname_from_proc_cmdline(pid, pname_status, &pname_cmdline); - if (!ret) { - *procname = pname_cmdline; - free(pname_status); - return 0; - } - - /* - * The above strncmp() is not 0 also if executing a symbolic link, - * /proc/pid/exe points to real executable name then. Return it as - * the last resort. - */ - free(pname_status); - *procname = strdup(buf); - if (*procname == NULL) { - last_errno = errno; - return ECGOTHER; - } - - return 0; -} - -int cgroup_register_unchanged_process(pid_t pid, int flags) -{ - char buff[sizeof(CGRULE_SUCCESS_STORE_PID)]; - struct sockaddr_un addr; - size_t ret_len; - int ret = 1; - int sk; - - sk = socket(PF_UNIX, SOCK_STREAM, 0); - if (sk < 0) - return 1; - - memset(&addr, 0, sizeof(addr)); - addr.sun_family = AF_UNIX; - strcpy(addr.sun_path, CGRULE_CGRED_SOCKET_PATH); - - if (connect(sk, (struct sockaddr *)&addr, - sizeof(addr.sun_family) + strlen(CGRULE_CGRED_SOCKET_PATH)) < 0) { - /* If the daemon does not work, this function returns 0 as success. */ - ret = 0; - goto close; - } - if (write(sk, &pid, sizeof(pid)) < 0) - goto close; - - if (write(sk, &flags, sizeof(flags)) < 0) - goto close; - - ret_len = read(sk, buff, sizeof(buff)); - if (ret_len != sizeof(buff)) - goto close; - - if (strncmp(buff, CGRULE_SUCCESS_STORE_PID, sizeof(buff))) - goto close; - - ret = 0; -close: - close(sk); - - return ret; -} - -int cgroup_get_subsys_mount_point(const char *controller, char **mount_point) -{ - int ret = ECGROUPNOTEXIST; - int i; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!controller) - return ECGINVAL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - if (strncmp(cg_mount_table[i].name, controller, FILENAME_MAX)) - continue; - - *mount_point = strdup(cg_mount_table[i].mount.path); - - if (!*mount_point) { - last_errno = errno; - ret = ECGOTHER; - goto out_exit; - } - - ret = 0; - break; - } -out_exit: - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} - -int cgroup_get_all_controller_end(void **handle) -{ - FILE *proc_cgroup = (FILE *) *handle; - - if (!proc_cgroup) - return ECGINVAL; - - fclose(proc_cgroup); - *handle = NULL; - - return 0; -} - -int cgroup_get_all_controller_next(void **handle, struct controller_data *info) -{ - FILE *proc_cgroup = (FILE *) *handle; - int hierarchy, num_cgroups, enabled; - char subsys_name[FILENAME_MAX]; - int err = 0; - - if (!proc_cgroup) - return ECGINVAL; - - if (!info) - return ECGINVAL; - - /* - * check Linux Kernel sources/kernel/cgroup/cgroup.c cgroup_init_early(), - * MAX_CGROUP_TYPE_NAMELEN check for details on why 32 is used. - */ - err = fscanf(proc_cgroup, "%32s %d %d %d\n", subsys_name, &hierarchy, &num_cgroups, - &enabled); - - if (err != 4) - return ECGEOF; - - strncpy(info->name, subsys_name, FILENAME_MAX); - info->name[FILENAME_MAX-1] = '\0'; - info->hierarchy = hierarchy; - info->num_cgroups = num_cgroups; - info->enabled = enabled; - - return 0; -} - -int cgroup_get_all_controller_begin(void **handle, struct controller_data *info) -{ - FILE *proc_cgroup = NULL; - char buf[FILENAME_MAX]; - int ret; - - if (!info) - return ECGINVAL; - - proc_cgroup = fopen("/proc/cgroups", "re"); - if (!proc_cgroup) { - last_errno = errno; - return ECGOTHER; - } - - if (!fgets(buf, FILENAME_MAX, proc_cgroup)) { - last_errno = errno; - fclose(proc_cgroup); - *handle = NULL; - return ECGOTHER; - } - *handle = proc_cgroup; - - ret = cgroup_get_all_controller_next(handle, info); - if (ret != 0) { - fclose(proc_cgroup); - *handle = NULL; - } - - return ret; -} - -static int pid_compare(const void *a, const void *b) -{ - const pid_t *pid1, *pid2; - - pid1 = (pid_t *) a; - pid2 = (pid_t *) b; - - return (*pid1 - *pid2); -} - -/* pids needs to be completely uninitialized so that we can set it up - * - * Caller must free up pids. - */ -int cgroup_get_procs(char *name, char *controller, pid_t **pids, int *size) -{ - char cgroup_path[FILENAME_MAX]; - int tot_procs = 16; - pid_t *tmp_list; - FILE *procs; - int n = 0; - int err; - - cg_build_path(name, cgroup_path, controller); - strncat(cgroup_path, "/cgroup.procs", FILENAME_MAX-strlen(cgroup_path)); - - procs = fopen(cgroup_path, "r"); - if (!procs) { - last_errno = errno; - *pids = NULL; - *size = 0; - if (errno == ENOENT) - return ECGROUPUNSUPP; - else - return ECGOTHER; - } - - /* Keep doubling the memory allocated if needed */ - tmp_list = malloc(sizeof(pid_t) * tot_procs); - if (!tmp_list) { - last_errno = errno; - fclose(procs); - return ECGOTHER; - } - - while (!feof(procs)) { - while (!feof(procs) && n < tot_procs) { - pid_t pid; - - err = fscanf(procs, "%u", &pid); - if (err == EOF) - break; - tmp_list[n] = pid; - n++; - } - if (!feof(procs)) { - pid_t *orig_list = tmp_list; - - tot_procs *= 2; - tmp_list = realloc(tmp_list, sizeof(pid_t) * tot_procs); - if (!tmp_list) { - last_errno = errno; - fclose(procs); - free(orig_list); - *pids = NULL; - *size = 0; - return ECGOTHER; - } - } - } - fclose(procs); - - *size = n; - qsort(tmp_list, n, sizeof(pid_t), &pid_compare); - *pids = tmp_list; - - return 0; -} - -int cgroup_dictionary_create(struct cgroup_dictionary **dict, - int flags) -{ - if (!dict) - return ECGINVAL; - - *dict = (struct cgroup_dictionary *) calloc(1, sizeof(struct cgroup_dictionary)); - if (!*dict) { - last_errno = errno; - return ECGOTHER; - } - (*dict)->flags = flags; - - return 0; -} - -int cgroup_dictionary_add(struct cgroup_dictionary *dict, const char *name, const char *value) -{ - struct cgroup_dictionary_item *it; - - if (!dict) - return ECGINVAL; - - it = (struct cgroup_dictionary_item *) malloc(sizeof(struct cgroup_dictionary_item)); - if (!it) { - last_errno = errno; - return ECGOTHER; - } - - it->next = NULL; - it->name = name; - it->value = value; - - if (dict->tail) { - dict->tail->next = it; - dict->tail = it; - } else { - /* It is the first item */ - dict->tail = it; - dict->head = it; - } - - return 0; -} - -int cgroup_dictionary_free(struct cgroup_dictionary *dict) -{ - struct cgroup_dictionary_item *it; - - if (!dict) - return ECGINVAL; - - it = dict->head; - while (it) { - struct cgroup_dictionary_item *del = it; - - it = it->next; - if (!(dict->flags & CG_DICT_DONT_FREE_ITEMS)) { - free((void *)del->value); - free((void *)del->name); - } - free(del); - } - free(dict); - - return 0; -} - -int cgroup_dictionary_iterator_begin(struct cgroup_dictionary *dict, void **handle, - const char **name, const char **value) -{ - struct cgroup_dictionary_iterator *iter; - - *handle = NULL; - - if (!dict) - return ECGINVAL; - - iter = (struct cgroup_dictionary_iterator *) - malloc(sizeof(struct cgroup_dictionary_iterator)); - if (!iter) { - last_errno = errno; - return ECGOTHER; - } - - iter->item = dict->head; - *handle = iter; - - return cgroup_dictionary_iterator_next(handle, name, value); -} - -int cgroup_dictionary_iterator_next(void **handle, const char **name, const char **value) -{ - struct cgroup_dictionary_iterator *iter; - - if (!handle) - return ECGINVAL; - - iter = *handle; - - if (!iter) - return ECGINVAL; - - if (!iter->item) - return ECGEOF; - - *name = iter->item->name; - *value = iter->item->value; - iter->item = iter->item->next; - - return 0; -} - -void cgroup_dictionary_iterator_end(void **handle) -{ - if (!handle) - return; - - free(*handle); - *handle = NULL; -} - -int cgroup_get_subsys_mount_point_begin(const char *controller, void **handle, char *path) -{ - int i; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - if (!handle || !path || !controller) - return ECGINVAL; - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) - if (strcmp(controller, cg_mount_table[i].name) == 0) - break; - - if (cg_mount_table[i].name[0] == '\0') { - /* The controller is not mounted at all */ - *handle = NULL; - *path = '\0'; - return ECGEOF; - } - - /* - * 'handle' is pointer to struct cg_mount_point, which should be - * returned next. - */ - *handle = cg_mount_table[i].mount.next; - strcpy(path, cg_mount_table[i].mount.path); - - return 0; -} - -int cgroup_get_subsys_mount_point_next(void **handle, char *path) -{ - struct cg_mount_point *it; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - if (!handle || !path) - return ECGINVAL; - - it = *handle; - if (!it) { - *handle = NULL; - *path = '\0'; - return ECGEOF; - } - - *handle = it->next; - strcpy(path, it->path); - - return 0; -} - -int cgroup_get_subsys_mount_point_end(void **handle) -{ - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (!handle) - return ECGINVAL; - - *handle = NULL; - - return 0; -} - -int cgroup_get_controller_version(const char * const controller, enum cg_version_t * const version) -{ - int i; - - if (!version) - return ECGINVAL; - - if (!controller && strlen(cg_cgroup_v2_mount_path) > 0) { - *version = CGROUP_V2; - return 0; - } - - if (!controller) - return ECGINVAL; - - *version = CGROUP_UNK; - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - if (strncmp(cg_mount_table[i].name, controller, - sizeof(cg_mount_table[i].name)) == 0) { - *version = cg_mount_table[i].version; - return 0; - } - } - - return ECGROUPNOTEXIST; -} - -static int search_and_append_mnt_path(struct cg_mount_point **mount_point, char *path) -{ - struct cg_mount_point *mnt_point, *mnt_tmp, *mnt_prev; - - mnt_tmp = *mount_point; - while(mnt_tmp) { - if (strcmp(mnt_tmp->path, path) == 0) - return ECGVALUEEXISTS; - - mnt_prev = mnt_tmp; - mnt_tmp = mnt_tmp->next; - } - - mnt_point = malloc(sizeof(struct cg_mount_point)); - if (mnt_point == NULL) { - last_errno = errno; - return ECGOTHER; - } - - strncpy(mnt_point->path, path, FILENAME_MAX - 1); - mnt_point->path[FILENAME_MAX - 1] = '\0'; - - mnt_point->next = NULL; - - if (*mount_point == NULL) - *mount_point = mnt_point; - else - mnt_prev->next = mnt_point; - - return 0; -} - -/** - * List the mount paths, that matches the specified version - * - * @param cgrp_version The cgroup type/version - * @param mount_paths Holds the list of mount paths - * @return 0 success and list of mounts paths in mount_paths - * ECGOTHER on failure and mount_paths is NULL. - */ -int cgroup_list_mount_points(const enum cg_version_t cgrp_version, char ***mount_paths) -{ - struct cg_mount_point *mount_point, *mnt_tmp = NULL; - char **mnt_paths = NULL; - int i, idx = 0; - int ret; - - if (!cgroup_initialized) - return ECGROUPNOTINITIALIZED; - - if (cgrp_version != CGROUP_V1 && cgrp_version != CGROUP_V2) - return ECGINVAL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - if (cg_mount_table[i].version != cgrp_version) - continue; - - mount_point = &cg_mount_table[i].mount; - while (mount_point) { - ret = search_and_append_mnt_path(&mnt_tmp, mount_point->path); - if (ret != 0 && ret != ECGVALUEEXISTS) - goto err; - - /* Avoid adding duplicate mount points */ - if (ret != ECGVALUEEXISTS) - idx++; - - mount_point = mount_point->next; - } - } - - /* - * Cgroup v2 can be mounted without any controller and these mount - * paths are not part of the cg_mount_table. Check and append - * them to mnt_paths. - */ - if (cgrp_version == CGROUP_V2 && cg_cgroup_v2_empty_mount_paths ) { - mount_point = cg_cgroup_v2_empty_mount_paths; - while(mount_point) { - ret = search_and_append_mnt_path(&mnt_tmp, mount_point->path); - if (ret) - goto err; - - idx++; - mount_point = mount_point->next; - } - } - - mnt_paths = malloc(sizeof(char*) * (idx + 1)); - if (mnt_paths == NULL) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - for (i = 0, mount_point = mnt_tmp; - mount_point; - mount_point = mount_point->next, i++) { - - mnt_paths[i] = strdup(mount_point->path); - if (mnt_paths[i] == NULL) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - } - mnt_paths[i] = '\0'; - - ret = 0; - *mount_paths = mnt_paths; - -err: - pthread_rwlock_unlock(&cg_mount_table_lock); - - while(mnt_tmp) { - mount_point = mnt_tmp; - mnt_tmp = mnt_tmp->next; - free(mount_point); - } - - if (ret != 0 && mnt_paths) { - for (i = 0; i < idx; i++) - free(mnt_paths[i]); - free(mnt_paths); - *mount_paths = NULL; - } - - return ret; -} - -const struct cgroup_library_version *cgroup_version(void) -{ - return &library_version; -} - -/** - * Finds the current cgroup setup mode (legacy/unified/hybrid). - * Returns unknown of failure and setup mode on success. - */ -enum cg_setup_mode_t cgroup_setup_mode(void) -{ -#define CGROUP2_SUPER_MAGIC 0x63677270 -#define CGROUP_SUPER_MAGIC 0x27E0EB - - unsigned int cg_setup_mode_bitmask = 0U; - enum cg_setup_mode_t setup_mode; - struct statfs cgrp_buf; - int i, ret = 0; - - if (!cgroup_initialized) { - return ECGROUPNOTINITIALIZED; - } - - setup_mode = CGROUP_MODE_UNK; - - pthread_rwlock_wrlock(&cg_mount_table_lock); - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - ret = statfs(cg_mount_table[i].mount.path, &cgrp_buf); - if (ret) { - setup_mode = CGROUP_MODE_UNK; - cgroup_err("Failed to get stats of '%s'\n", cg_mount_table[i].mount.path); - goto out; - } - - if (cgrp_buf.f_type == CGROUP2_SUPER_MAGIC) - cg_setup_mode_bitmask |= (1U << 0); - else if (cgrp_buf.f_type == CGROUP_SUPER_MAGIC) - cg_setup_mode_bitmask |= (1U << 1); - } - - if (cg_cgroup_v2_empty_mount_paths) - cg_setup_mode_bitmask |= (1U << 0); - - if (cg_setup_mode_bitmask & (1U << 0) && cg_setup_mode_bitmask & (1U << 1)) - setup_mode = CGROUP_MODE_HYBRID; - else if (cg_setup_mode_bitmask & (1U << 0)) - setup_mode = CGROUP_MODE_UNIFIED; - else if (cg_setup_mode_bitmask & (1U << 1)) - setup_mode = CGROUP_MODE_LEGACY; - -out: - pthread_rwlock_unlock(&cg_mount_table_lock); - return setup_mode; -} - -int cgroup_get_controller_count(struct cgroup *cgroup) -{ - if (!cgroup) - return -1; - - return cgroup->index; -} - -struct cgroup_controller *cgroup_get_controller_by_index(struct cgroup *cgroup, int index) -{ - if (!cgroup) - return NULL; - - if (index >= cgroup->index) - return NULL; - - return cgroup->controller[index]; -} - -char *cgroup_get_controller_name(struct cgroup_controller *controller) -{ - if (!controller) - return NULL; - - return controller->name; -} diff --git a/lib/libcgroup-3.1.0/src/config.c b/lib/libcgroup-3.1.0/src/config.c deleted file mode 100644 index 767857841c7..00000000000 --- a/lib/libcgroup-3.1.0/src/config.c +++ /dev/null @@ -1,2300 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright IBM Corporation. 2007 - * - * Authors: Balbir Singh - * Dhaval Giani - * - * TODOs: - * 1. Implement our own hashing scheme - * - * Code initiated and designed by Balbir Singh. All faults are most likely - * his mistake. - * - * Cleanup and changes to use the "official" structures and functions made - * by Dhaval Giani. All faults will still be Balbir's mistake :) - */ - -#include "tools/tools-common.h" - -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - -unsigned int MAX_CGROUPS = 64; /* NOTE: This value changes dynamically */ -unsigned int MAX_TEMPLATES = 64;/* NOTE: This value changes dynamically */ - -enum tc_switch_t { - CGROUP, - TEMPLATE, -}; - -extern FILE *yyin; -extern int yyparse(void); - -static struct cgroup default_group; -static int default_group_set; - -/* - * The basic global data structures. - * - * config_mount_table -> Where what controller is mounted - * table_index -> Where in the table are we. - * config_table_lock -> Serializing access to config_mount_table. - * cgroup_table -> Which cgroups have to be created. - * cgroup_table_index -> Where in the cgroup_table we are. - */ -static struct cg_mount_table_s config_mount_table[CG_CONTROLLER_MAX]; -static struct cg_mount_table_s config_namespace_table[CG_CONTROLLER_MAX]; -static int config_table_index; -static int namespace_table_index; -static pthread_rwlock_t config_table_lock = PTHREAD_RWLOCK_INITIALIZER; -static pthread_rwlock_t namespace_table_lock = PTHREAD_RWLOCK_INITIALIZER; -static struct cgroup *config_cgroup_table; -static int cgroup_table_index; - -/* - * template structures filled by cgroup_parse_config when the configuration - * file is parsing (analogous to config_cgroup_table and cgroup_table_index - * for cgroups) - */ -static struct cgroup *config_template_table; -static int config_template_table_index; - -/* - * template structures used for templates cache, config_template_table and - * cgroup_template_table_index are rewritten in each cgroup_parse_config - * thus not only if we want to reload template cache - */ -static struct cgroup *template_table; -static int template_table_index; -static struct cgroup_string_list *template_files; - - -/* Needed for the type while mounting cgroupfs. */ -#define CGROUP_FILESYSTEM "cgroup" - -#ifdef WITH_SYSTEMD -/* Directory that holds dynamically created internal libcgroup files */ -static const char * const systemd_def_cgrp_file_dir = "/var/run/libcgroup/"; - -/* File that stores the relative delegated systemd cgroup path */ -static const char * const systemd_default_cgroup_file = "/var/run/libcgroup/systemd"; - -/* Lock that protects systemd_default_cgroup_file */ -static pthread_rwlock_t systemd_default_cgroup_lock = PTHREAD_RWLOCK_INITIALIZER; - -/* - * cgroup_systemd_opts is dynamically allocated, hence having head - * and tail helps in traversing. - */ -static struct cgroup_systemd_opts *cgroup_systemd_opts_head = NULL; -static struct cgroup_systemd_opts *cgroup_systemd_opts_tail = NULL; - -static int config_create_slice_scope(char * const tmp_systemd_default_cgroup); -#endif - -/* - * NOTE: All these functions return 1 on success and not 0 as is the - * library convention - */ -/* - * This call just sets the name of the cgroup. It will always be called in - * the end, because the parser will work bottom up. It works for cgroup and - * templates tables based on flag variable: - * CGROUP ... cgroup - * TEMPLATE ... template - */ -int config_insert_cgroup(char *cg_name, int flag) -{ - - struct cgroup *config_cgroup; - struct cgroup *config_table; - unsigned int *max; - int *table_index; - - switch (flag) { - case CGROUP: - table_index = &cgroup_table_index; - config_table = config_cgroup_table; - max = &MAX_CGROUPS; - break; - case TEMPLATE: - table_index = &config_template_table_index; - config_table = config_template_table; - max = &MAX_TEMPLATES; - break; - default: - return 0; - } - - if (*table_index >= *max - 1) { - struct cgroup *newblk; - unsigned int oldlen; - - if (*max >= INT_MAX) { - last_errno = ENOMEM; - return 0; - } - oldlen = *max; - *max *= 2; - - newblk = realloc(config_table, (*max * sizeof(struct cgroup))); - if (!newblk) { - last_errno = ENOMEM; - return 0; - } - - memset(newblk + oldlen, 0, (*max - oldlen) * sizeof(struct cgroup)); - init_cgroup_table(newblk + oldlen, *max - oldlen); - config_table = newblk; - switch (flag) { - case CGROUP: - config_cgroup_table = config_table; - break; - case TEMPLATE: - config_template_table = config_table; - break; - default: - return 0; - } - cgroup_dbg("maximum %d\n", *max); - cgroup_dbg("reallocated config_table to %p\n", config_table); - } - - config_cgroup = &config_table[*table_index]; - strncpy(config_cgroup->name, cg_name, FILENAME_MAX - 1); - - /* Since this will be the last part to be parsed. */ - *table_index = *table_index + 1; - free(cg_name); - - return 1; -} - -/* - * This call just sets the name of the cgroup. It will always be called in - * the end, because the parser will work bottom up. - */ -int cgroup_config_insert_cgroup(char *cg_name) -{ - int ret; - - ret = config_insert_cgroup(cg_name, CGROUP); - return ret; -} - -/* - * This call just sets the name of the template. It will always be called - * in the end, because the parser will work bottom up. - */ -int template_config_insert_cgroup(char *cg_name) -{ - int ret; - - ret = config_insert_cgroup(cg_name, TEMPLATE); - return ret; -} - -/* - * This function sets the various controller's control files. It will always - * append values for config_cgroup/template_table_index entry in the - * config_cgroup/template_table. The index is incremented in - * cgroup/template_config_insert_cgroup. - * flag variable switch between cgroup/templates variables: - * CGROUP ... cgroup - * TEMPLATE ... template - */ -int config_parse_controller_options(char *controller, struct cgroup_dictionary *values, int flag) -{ - struct cgroup_controller *cgc; - struct cgroup *config_cgroup; - const char *name, *value; - void *iter = NULL; - int *table_index; - int error; - - switch (flag) { - case CGROUP: - table_index = &cgroup_table_index; - config_cgroup = &config_cgroup_table[*table_index]; - break; - case TEMPLATE: - table_index = &config_template_table_index; - config_cgroup = &config_template_table[*table_index]; - break; - default: - return 0; - } - - cgroup_dbg("Adding controller %s\n", controller); - cgc = cgroup_add_controller(config_cgroup, controller); - if (!cgc) - goto parse_error; - - /* - * Did we just specify the controller to create the correct set of - * directories, without setting any values? - */ - if (!values) - goto done; - - error = cgroup_dictionary_iterator_begin(values, &iter, &name, &value); - while (error == 0) { - cgroup_dbg("[1] name value pair being processed is %s=%s\n", name, value); - if (!name) - goto parse_error; - error = cgroup_add_value_string(cgc, name, value); - if (error) - goto parse_error; - error = cgroup_dictionary_iterator_next(&iter, &name, &value); - } - cgroup_dictionary_iterator_end(&iter); - iter = NULL; - - if (error != ECGEOF) - goto parse_error; - -done: - free(controller); - - return 1; - -parse_error: - free(controller); - cgroup_dictionary_iterator_end(&iter); - cgroup_delete_cgroup(config_cgroup, 1); - *table_index = *table_index - 1; - - return 0; -} - -/* - * This function sets the various controller's control files. It will always - * append values for cgroup_table_index entry in the cgroup_table. - * The index is incremented in cgroup_config_insert_cgroup - */ - -int cgroup_config_parse_controller_options(char *controller, struct cgroup_dictionary *values) -{ - int ret; - - ret = config_parse_controller_options(controller, values, CGROUP); - return ret; -} - -/* - * This function sets the various controller's control files. It will always - * append values for config_template_table_index entry in the - * config_template_table. - * The index is incremented in template_config_insert_cgroup - */ - -int template_config_parse_controller_options(char *controller, struct cgroup_dictionary *values) -{ - int ret; - - ret = config_parse_controller_options(controller, values, TEMPLATE); - return ret; -} - -/* - * Sets the tasks file's uid and gid for cgroup and templates tables based - * on flag variable: - * CGROUP ... cgroup - * TEMPLATE ... template - */ -int config_group_task_perm(char *perm_type, char *value, int flag) -{ - struct group *group, *group_buffer; - struct passwd *pw, *pw_buffer; - char buffer[CGROUP_BUFFER_LEN]; - struct cgroup *config_cgroup; - long val = atoi(value); - int table_index; - - switch (flag) { - case CGROUP: - table_index = cgroup_table_index; - config_cgroup = &config_cgroup_table[table_index]; - break; - case TEMPLATE: - table_index = config_template_table_index; - config_cgroup = &config_template_table[table_index]; - break; - default: - return 0; - } - - if (!strcmp(perm_type, "uid")) { - if (!val) { - pw = (struct passwd *) malloc(sizeof(struct passwd)); - if (!pw) - goto group_task_error; - - getpwnam_r(value, pw, buffer, CGROUP_BUFFER_LEN, &pw_buffer); - if (pw_buffer == NULL) { - free(pw); - goto group_task_error; - } - - val = pw->pw_uid; - free(pw); - } - config_cgroup->tasks_uid = val; - } - - if (!strcmp(perm_type, "gid")) { - if (!val) { - group = (struct group *) malloc(sizeof(struct group)); - - if (!group) - goto group_task_error; - - if (getgrnam_r(value, group, buffer, - CGROUP_BUFFER_LEN, &group_buffer) != 0) { - free(group); - goto group_task_error; - } - - val = group->gr_gid; - free(group); - } - config_cgroup->tasks_gid = val; - } - - if (!strcmp(perm_type, "fperm")) { - char *endptr; - - val = strtol(value, &endptr, 8); - if (*endptr) - goto group_task_error; - config_cgroup->task_fperm = val; - } - - free(perm_type); - free(value); - - return 1; - -group_task_error: - free(perm_type); - free(value); - cgroup_delete_cgroup(config_cgroup, 1); - table_index--; - - return 0; -} - -/* - * Sets the tasks file's uid and gid - */ -int cgroup_config_group_task_perm(char *perm_type, char *value) -{ - int ret; - - ret = config_group_task_perm(perm_type, value, CGROUP); - return ret; -} - -/* - * Sets the tasks file's uid and gid for templates - */ -int template_config_group_task_perm(char *perm_type, char *value) -{ - int ret; - - ret = config_group_task_perm(perm_type, value, TEMPLATE); - return ret; -} - -/* - * Sets the admin file's uid and gid for cgroup and templates tables based - * on flag variable: - * CGROUP ... cgroup - * TEMPLATE ... templates - */ -int config_group_admin_perm(char *perm_type, char *value, int flag) -{ - struct group *group, *group_buffer; - struct passwd *pw, *pw_buffer; - char buffer[CGROUP_BUFFER_LEN]; - struct cgroup *config_cgroup; - long val = atoi(value); - int table_index; - - switch (flag) { - case CGROUP: - table_index = cgroup_table_index; - config_cgroup = &config_cgroup_table[table_index]; - break; - case TEMPLATE: - table_index = config_template_table_index; - config_cgroup = &config_template_table[table_index]; - break; - default: - return 0; - } - - if (!strcmp(perm_type, "uid")) { - if (!val) { - pw = (struct passwd *) malloc(sizeof(struct passwd)); - if (!pw) - goto admin_error; - - getpwnam_r(value, pw, buffer, CGROUP_BUFFER_LEN, &pw_buffer); - if (pw_buffer == NULL) { - free(pw); - goto admin_error; - } - - val = pw->pw_uid; - free(pw); - } - config_cgroup->control_uid = val; - } - - if (!strcmp(perm_type, "gid")) { - if (!val) { - group = (struct group *) malloc(sizeof(struct group)); - if (!group) - goto admin_error; - - if (getgrnam_r(value, group, buffer, CGROUP_BUFFER_LEN, - &group_buffer) != 0) { - free(group); - goto admin_error; - } - - val = group->gr_gid; - free(group); - } - config_cgroup->control_gid = val; - } - - if (!strcmp(perm_type, "fperm")) { - char *endptr; - - val = strtol(value, &endptr, 8); - if (*endptr) - goto admin_error; - config_cgroup->control_fperm = val; - } - - if (!strcmp(perm_type, "dperm")) { - char *endptr; - - val = strtol(value, &endptr, 8); - if (*endptr) - goto admin_error; - config_cgroup->control_dperm = val; - } - - free(perm_type); - free(value); - - return 1; - -admin_error: - free(perm_type); - free(value); - cgroup_delete_cgroup(config_cgroup, 1); - table_index--; - - return 0; -} - -/* - * Set the control file's uid and gid - */ -int cgroup_config_group_admin_perm(char *perm_type, char *value) -{ - int ret; - - ret = config_group_admin_perm(perm_type, value, CGROUP); - return ret; -} - -/* - * Set the control file's uid and gid for templates - */ -int template_config_group_admin_perm(char *perm_type, char *value) -{ - int ret; - - ret = config_group_admin_perm(perm_type, value, TEMPLATE); - return ret; -} - -/* - * The moment we have found the controller's information insert it into - * the config_mount_table. - */ -int cgroup_config_insert_into_mount_table(char *name, char *mount_point) -{ - int i; - - if (config_table_index >= CG_CONTROLLER_MAX) - return 0; - - pthread_rwlock_wrlock(&config_table_lock); - - /* Merge controller names with the same mount point */ - for (i = 0; i < config_table_index; i++) { - if (strcmp(config_mount_table[i].mount.path, mount_point) == 0) { - char *cname = config_mount_table[i].name; - - strncat(cname, ",", FILENAME_MAX - strlen(cname) - 1); - strncat(cname, name, FILENAME_MAX - strlen(cname) - 1); - goto done; - } - } - - strncpy(config_mount_table[config_table_index].name, name, CONTROL_NAMELEN_MAX - 1); - config_mount_table[config_table_index].name[CONTROL_NAMELEN_MAX - 1] = '\0'; - - strncpy(config_mount_table[config_table_index].mount.path, mount_point, FILENAME_MAX - 1); - config_mount_table[config_table_index].mount.path[FILENAME_MAX - 1] = '\0'; - - config_mount_table[config_table_index].mount.next = NULL; - config_table_index++; -done: - pthread_rwlock_unlock(&config_table_lock); - free(name); - free(mount_point); - - return 1; -} - -/* - * Cleanup all the data from the config_mount_table - */ -void cgroup_config_cleanup_mount_table(void) -{ - memset(&config_mount_table, 0, sizeof(struct cg_mount_table_s) * CG_CONTROLLER_MAX); -} - -/* - * The moment we have found the controller's information insert it into - * the config_mount_table. - */ -int cgroup_config_insert_into_namespace_table(char *name, char *nspath) -{ - char *ns_tbl_name, *ns_tbl_path; - if (namespace_table_index >= CG_CONTROLLER_MAX) - return 0; - - pthread_rwlock_wrlock(&namespace_table_lock); - - ns_tbl_name = config_namespace_table[namespace_table_index].name; - strncpy(ns_tbl_name, name, CONTROL_NAMELEN_MAX - 1); - ns_tbl_name[CONTROL_NAMELEN_MAX - 1 ] = '\0'; - - ns_tbl_path = config_namespace_table[namespace_table_index].mount.path; - strncpy(ns_tbl_path, nspath, FILENAME_MAX - 1); - ns_tbl_path[FILENAME_MAX - 1] = '\0'; - - config_namespace_table[namespace_table_index].mount.next = NULL; - namespace_table_index++; - - pthread_rwlock_unlock(&namespace_table_lock); - free(name); - free(nspath); - return 1; -} - -/* - * Cleanup all the data from the config_mount_table - */ -void cgroup_config_cleanup_namespace_table(void) -{ - memset(&config_namespace_table, 0, sizeof(struct cg_mount_table_s) * CG_CONTROLLER_MAX); -} - -/** - * Add necessary options for mount. Currently only 'none' option is added - * for mounts with only 'name=xxx' and without real controller. - */ -static int cgroup_config_ajdust_mount_options(struct cg_mount_table_s *mount, unsigned long *flags) -{ - char *opts = strdup(mount->name); - char *controller = NULL; - char *save = NULL; - int name_only = 1; - char *token; - - *flags = 0; - if (opts == NULL) - return ECGFAIL; - - token = strtok_r(opts, ",", &save); - while (token != NULL) { - if (strncmp(token, "name=", 5) != 0) { - name_only = 0; - - if (!controller) { - controller = strdup(token); - if (controller == NULL) - break; - - strncpy(mount->name, controller, sizeof(mount->name)); - mount->name[sizeof(mount->name)-1] = '\0'; - } - - if (strncmp(token, "nodev", strlen("nodev")) == 0) - *flags |= MS_NODEV; - - if (strncmp(token, "noexec", strlen("noexec")) == 0) - *flags |= MS_NOEXEC; - - if (strncmp(token, "nosuid", strlen("nosuid")) == 0) - *flags |= MS_NOSUID; - - } else if (!name_only) { - /* - * We have controller + name=, do the right thing, - * since we are rebuilding mount->name - */ - strncat(mount->name, ",", FILENAME_MAX - strlen(mount->name)-1); - strncat(mount->name, token, FILENAME_MAX - strlen(mount->name) - 1); - } - token = strtok_r(NULL, ",", &save); - } - - free(controller); - free(opts); - - if (name_only) { - strncat(mount->name, ",", FILENAME_MAX - strlen(mount->name)-1); - strncat(mount->name, "none", FILENAME_MAX - strlen(mount->name) - 1); - } - - return 0; -} - -/* - * Start mounting the mount table - */ -static int cgroup_config_mount_fs(void) -{ - unsigned long flags; - struct stat buff; - int error; - int ret; - int i; - - for (i = 0; i < config_table_index; i++) { - struct cg_mount_table_s *curr = &(config_mount_table[i]); - - ret = stat(curr->mount.path, &buff); - if (ret < 0 && errno != ENOENT) { - cgroup_err("cannot access %s: %s\n", curr->mount.path, strerror(errno)); - last_errno = errno; - error = ECGOTHER; - goto out_err; - } - - if (errno == ENOENT) { - ret = cg_mkdir_p(curr->mount.path); - if (ret) { - cgroup_err("cannot create directory %s\n", curr->mount.path); - error = ret; - goto out_err; - } - } else if (!S_ISDIR(buff.st_mode)) { - cgroup_err("%s already exists but it is not a directory\n", - curr->mount.path); - errno = ENOTDIR; - last_errno = errno; - error = ECGOTHER; - goto out_err; - } - - error = cgroup_config_ajdust_mount_options(curr, &flags); - if (error) - goto out_err; - - ret = mount(CGROUP_FILESYSTEM, curr->mount.path, CGROUP_FILESYSTEM, flags, - curr->name); - - if (ret < 0) { - cgroup_err("cannot mount %s to %s: %s\n", curr->name, curr->mount.path, - strerror(errno)); - error = ECGMOUNTFAIL; - goto out_err; - } - } - - return 0; -out_err: - /* - * If we come here, we have failed. Since we have touched only - * mountpoints prior to i, we shall operate on only them now. - */ - config_table_index = i; - - return error; -} - -static int convert_controller_versions(struct cgroup *cgroup) -{ - enum cg_version_t current_version, convert_version; - struct cgroup *cgrp_cpy, *convert_cgrp = NULL; - struct cgroup_controller *cgc; - int i, j, ret; - - if (!cgroup) - return ECGINVAL; - - /* no controllers added */ - if (cgroup->index == 0) - return ECGINVAL; - - cgrp_cpy = cgroup_new_cgroup(cgroup->name); - if (!cgrp_cpy) { - cgroup_err("Failed to create cgroup %s\n", cgroup->name); - return ECGROUPNOTCREATED; - } - - /* copy the non-controllers details */ - cgrp_cpy->index = 0; - - ret = cgroup_set_uid_gid(cgrp_cpy, - cgroup->tasks_uid, cgroup->tasks_gid, - cgroup->control_uid, cgroup->control_gid); - /* cgroup existence is checked, so ignore ret value. */ - - cgroup_set_permissions(cgrp_cpy, cgroup->control_dperm, - cgroup->control_fperm, cgroup->task_fperm); - - for (i = 0; i < cgroup->index; i++) { - /* - * the controller version settings read from cgconfig.conf, - * may mismatch with the system's controller version. Hence - * assign the convert version (expected version) to the - * system's version of the controller and current version - * to the opposite of convert version. - */ - convert_version = cgroup->controller[i]->version; - current_version = convert_version == CGROUP_V1 ? CGROUP_V2 : CGROUP_V1; - - cgc = cgroup_add_controller(cgrp_cpy, cgroup->controller[i]->name); - if (!cgc) { - cgroup_err("Failed to allocated controller.\n"); - ret = ECGFAIL; - goto err; - } - - for (j = 0; j < cgroup->controller[i]->index; j++) { - ret = cgroup_add_value_string(cgc, - cgroup->controller[i]->values[j]->name, - cgroup->controller[i]->values[j]->value); - if (ret) { - cgroup_err("Failed to add setting to %s\n", cgc->name); - goto err; - } - } - - /* - * There might be more than one controller parsed from the - * cgconfig.conf file, let's create cgroup with one controller - * and see if it fails and if it does, let's try converting - * it and retry the cgroup creation, otherwise move on to - * the next controller. - */ - ret = cgroup_create_cgroup(cgrp_cpy, 0); - if (!ret) - goto next_controller; - - /* - * The controller version != cgroup->controller[i] version, - * let try to convert the controller to the current version - * and retry. - */ - convert_cgrp = cgroup_new_cgroup(cgroup->name); - if (!convert_cgrp) { - cgroup_err("Failed to created cgroup %s\n", cgroup->name); - ret = ECGROUPNOTCREATED; - goto err; - } - ret = cgroup_convert_cgroup(convert_cgrp, convert_version, cgrp_cpy, - current_version); - if (ret) { - cgroup_err("Conversion of controller failed.\n"); - goto err; - } - - ret = cgroup_create_cgroup(convert_cgrp, 0); - if (ret) { - cgroup_err("Failed to create cgroup %s\n", cgroup->name); - goto err; - } - cgroup_free(&convert_cgrp); -next_controller: - cgroup_free_controller(cgc); - cgrp_cpy->index = 0; - } - - ret = 0; -err: - cgroup_free(&convert_cgrp); - cgroup_free(&cgrp_cpy); - return ret; -} -/* - * Actually create the groups once the parsing has been finished - */ -static int cgroup_config_create_groups(void) -{ - int error = 0; - int i; - - for (i = 0; i < cgroup_table_index; i++) { - struct cgroup *cgroup = &config_cgroup_table[i]; - - error = cgroup_create_cgroup(cgroup, 0); - cgroup_dbg("creating group %s, error %d\n", cgroup->name, error); - if (error) { - /* - * Attempt to convert the controller version - * and retry. - */ - error = convert_controller_versions(cgroup); - if (error) - return error; - } - } - - return error; -} - -/* - * Destroy the cgroups - */ -static int cgroup_config_destroy_groups(void) -{ - int error = 0, ret = 0; - int i; - - for (i = 0; i < cgroup_table_index; i++) { - struct cgroup *cgroup = &config_cgroup_table[i]; - - error = cgroup_delete_cgroup_ext(cgroup, CGFLAG_DELETE_RECURSIVE | - CGFLAG_DELETE_IGNORE_MIGRATION); - if (error) - /* store the error, but continue deleting the rest */ - ret = error; - } - - return ret; -} - -/* - * Unmount the controllers - */ -static int cgroup_config_unmount_controllers(void) -{ - int error; - int i; - - for (i = 0; i < config_table_index; i++) { - /* We ignore failures and ensure that all mounted containers are unmounted */ - error = umount(config_mount_table[i].mount.path); - if (error < 0) - cgroup_dbg("Unmount failed\n"); - error = rmdir(config_mount_table[i].mount.path); - if (error < 0) - cgroup_dbg("rmdir failed\n"); - } - - return 0; -} - -static int config_validate_namespaces(void) -{ - char *namespace = NULL; - char *mount_path = NULL; - int j, subsys_count; - int error = 0; - int i; - - pthread_rwlock_wrlock(&cg_mount_table_lock); - for (i = 0; cg_mount_table[i].name[0] != '\0'; i++) { - /* - * If we get the path in the first run, then we are good, - * else we will need to go for two loops. This should be - * optimized in the future - */ - mount_path = cg_mount_table[i].mount.path; - - /* - * Setup the namespace for the subsystems having the same - * mount point. - */ - if (!cg_namespace_table[i]) { - namespace = NULL; - } else { - namespace = cg_namespace_table[i]; - if (!namespace) { - last_errno = errno; - error = ECGOTHER; - goto out_error; - } - } - - /* - * We want to handle all the subsytems that are mounted - * together. So initialize j to start from the next point - * in the mount table. - */ - - j = i + 1; - - /* - * Search through the mount table to locate which subsystems - * are mounted together. - */ - while (!strncmp(cg_mount_table[j].mount.path, mount_path, FILENAME_MAX)) { - if (!namespace && cg_namespace_table[j]) { - /* In case namespace is not setup, set it up */ - namespace = cg_namespace_table[j]; - if (!namespace) { - last_errno = errno; - error = ECGOTHER; - goto out_error; - } - } - j++; - } - subsys_count = j; - - /* If there is no namespace, then continue on :) */ - if (!namespace) { - i = subsys_count - 1; - continue; - } - - /* - * Validate/setup the namespace - * If no namespace is specified, copy the namespace we have - * stored. If a namespace is specified, confirm if it is the - * same as we have stored. If not, we fail. - */ - for (j = i; j < subsys_count; j++) { - if (!cg_namespace_table[j]) { - cg_namespace_table[j] = strdup(namespace); - if (!cg_namespace_table[j]) { - last_errno = errno; - error = ECGOTHER; - goto out_error; - } - } else if (strcmp(namespace, cg_namespace_table[j])) { - error = ECGNAMESPACEPATHS; - goto out_error; - } - } - /* i++ in the for loop will increment it */ - i = subsys_count - 1; - } -out_error: - pthread_rwlock_unlock(&cg_mount_table_lock); - - return error; -} - -/* - * Should always be called after cgroup_init() has been called - * - * NOT to be called outside the library. Is handled internally when we are - * looking to load namespace configurations. - * - * This function will order the namespace table in the same fashion as how - * the mou table is setup. - * - * Also it will setup namespaces for all the controllers mounted. In case a - * controller does not have a namespace assigned to it, it will set it to null. - */ -static int config_order_namespace_table(void) -{ - int error = 0; - int i = 0; - - pthread_rwlock_wrlock(&cg_mount_table_lock); - /* Set everything to NULL */ - for (i = 0; i < CG_CONTROLLER_MAX; i++) - cg_namespace_table[i] = NULL; - - memset(cg_namespace_table, 0, CG_CONTROLLER_MAX * sizeof(cg_namespace_table[0])); - - /* Now fill up the namespace table looking at the table we have otherwise. */ - for (i = 0; i < namespace_table_index; i++) { - int j; - int flag = 0; - - for (j = 0; cg_mount_table[j].name[0] != '\0'; j++) { - if (strncmp(config_namespace_table[i].name, cg_mount_table[j].name, - CONTROL_NAMELEN_MAX) == 0) { - - flag = 1; - - if (cg_namespace_table[j]) { - error = ECGNAMESPACEPATHS; - goto error_out; - } - - cg_namespace_table[j] = strdup( - config_namespace_table[i].mount.path); - if (!cg_namespace_table[j]) { - last_errno = errno; - error = ECGOTHER; - goto error_out; - } - } - } - if (!flag) { - error = ECGNAMESPACECONTROLLER; - break; - } - } -error_out: - pthread_rwlock_unlock(&cg_mount_table_lock); - - return error; -} - -/** - * Free all memory allocated during cgroup_parse_config(), namely - * config_cgroup_table and config_template_table. - */ -static void cgroup_free_config(void) -{ - int i; - - if (config_cgroup_table) { - for (i = 0; i < cgroup_table_index; i++) - cgroup_free_controllers(&config_cgroup_table[i]); - free(config_cgroup_table); - config_cgroup_table = NULL; - } - - config_table_index = 0; - if (config_template_table) { - for (i = 0; i < config_template_table_index; i++) - cgroup_free_controllers(&config_template_table[i]); - - free(config_template_table); - config_template_table = NULL; - } - config_template_table_index = 0; - - cgroup_cleanup_systemd_opts(); -} - -/** - * Applies default permissions/uid/gid to all groups in config file. - */ -static void cgroup_config_apply_default(void) -{ - int i; - - if (config_cgroup_table) { - for (i = 0; i < cgroup_table_index; i++) { - struct cgroup *c = &config_cgroup_table[i]; - - if (c->control_dperm == NO_PERMS) - c->control_dperm = default_group.control_dperm; - if (c->control_fperm == NO_PERMS) - c->control_fperm = default_group.control_fperm; - if (c->control_gid == NO_UID_GID) - c->control_gid = default_group.control_gid; - if (c->control_uid == NO_UID_GID) - c->control_uid = default_group.control_uid; - if (c->task_fperm == NO_PERMS) - c->task_fperm = default_group.task_fperm; - if (c->tasks_gid == NO_UID_GID) - c->tasks_gid = default_group.tasks_gid; - if (c->tasks_uid == NO_UID_GID) - c->tasks_uid = default_group.tasks_uid; - } - } -} - -static int cgroup_parse_config(const char *pathname) -{ - int ret; - - yyin = fopen(pathname, "re"); - - if (!yyin) { - cgroup_err("failed to open file %s\n", pathname); - last_errno = errno; - return ECGOTHER; - } - - config_cgroup_table = calloc(MAX_CGROUPS, sizeof(struct cgroup)); - if (!config_cgroup_table) { - ret = ECGFAIL; - goto err; - } - - config_template_table = calloc(MAX_TEMPLATES, sizeof(struct cgroup)); - if (!config_template_table) { - ret = ECGFAIL; - goto err; - } - - /* Clear all internal variables so this function can be called twice. */ - init_cgroup_table(config_cgroup_table, MAX_CGROUPS); - init_cgroup_table(config_template_table, MAX_TEMPLATES); - memset(config_namespace_table, 0, sizeof(config_namespace_table)); - memset(config_mount_table, 0, sizeof(config_mount_table)); - config_table_index = 0; - namespace_table_index = 0; - cgroup_table_index = 0; - config_template_table_index = 0; - - if (!default_group_set) { - /* init the default cgroup */ - init_cgroup_table(&default_group, 1); - } - - /* Parser calls longjmp() on really fatal error (like out-of-memory). */ - ret = setjmp(parser_error_env); - if (!ret) - ret = yyparse(); - if (ret) { - /* Either yyparse failed or longjmp() was called. */ - cgroup_err("failed to parse file %s\n", pathname); - ret = ECGCONFIGPARSEFAIL; - goto err; - } - -err: - if (yyin) - fclose(yyin); - if (ret) - cgroup_free_config(); - - return ret; -} - -int _cgroup_config_compare_groups(const void *p1, const void *p2) -{ - const struct cgroup *g1 = p1; - const struct cgroup *g2 = p2; - - return strcmp(g1->name, g2->name); -} - -static void cgroup_config_sort_groups(void) -{ - qsort(config_cgroup_table, cgroup_table_index, sizeof(struct cgroup), - _cgroup_config_compare_groups); -} - -/* - * The main function which does all the setup of the data structures and finally creates the - * cgroups - */ -int cgroup_config_load_config(const char *pathname) -{ -#ifdef WITH_SYSTEMD - /* slice[FILENAME_MAX] + '/' + scope[FILENAME_MAX] */ - char tmp_systemd_default_cgroup[FILENAME_MAX * 2 + 1] = "\0"; -#endif - int namespace_enabled = 0; - int mount_enabled = 0; - int tmp_errno; - int error; - int ret; - - ret = cgroup_parse_config(pathname); - if (ret != 0) - return ret; - - namespace_enabled = (config_namespace_table[0].name[0] != '\0'); - mount_enabled = (config_mount_table[0].name[0] != '\0'); - - /* The configuration should have namespace or mount, not both. */ - if (namespace_enabled && mount_enabled) { - free(config_cgroup_table); - return ECGMOUNTNAMESPACE; - } - - error = cgroup_config_mount_fs(); - if (error) - goto err_mnt; - - error = cgroup_init(); - if (error == ECGROUPNOTMOUNTED && cgroup_table_index == 0 - && config_template_table_index == 0) { - /* The config file seems to be empty. */ - error = 0; - goto err_mnt; - } - if (error) - goto err_mnt; - - /* - * The very first thing is to sort the namespace table. If we fail - * we unmount everything and get out. - */ - - error = config_order_namespace_table(); - if (error) - goto err_mnt; - - error = config_validate_namespaces(); - if (error) - goto err_mnt; - -#ifdef WITH_SYSTEMD - error = config_create_slice_scope(tmp_systemd_default_cgroup); - if (!error) { - error = ECGROUPPARSEFAIL; - goto err_mnt; - } -#endif - - cgroup_config_apply_default(); - error = cgroup_config_create_groups(); - cgroup_dbg("creating all cgroups now, error=%d\n", error); - if (error) - goto err_grp; - -#ifdef WITH_SYSTEMD - /* - * Setting up systemd_default_cgroup, during creation - * of slice/scopes, clobbers the path returned by cg_build_path(), - * by appending the systemd_default_cgroup to it and - * its required only after all of the slices/scopes are created. - * The user might also set setdefault in more than one systemd - * delegate settings, in that case the last parsed one overwrites - * the systemd_default_cgroup. - */ - if (strlen(tmp_systemd_default_cgroup)) - snprintf(systemd_default_cgroup, sizeof(systemd_default_cgroup), - "%s", tmp_systemd_default_cgroup); -#endif - - cgroup_free_config(); - - return 0; -err_grp: - /* - * Save off the error that has already occurred. The errno from - * cgroup_config_destroy_groups() is secondary to the original error that was reported, - * and thus can be discarded; - */ - tmp_errno = last_errno; - cgroup_config_destroy_groups(); - last_errno = tmp_errno; -err_mnt: - cgroup_config_unmount_controllers(); - cgroup_free_config(); - - return error; -} - -/* unmounts given mount, but only if it is empty */ -static int cgroup_config_try_unmount(struct cg_mount_table_s *mount_info) -{ - struct cg_mount_point *mount = &(mount_info->mount); - char *controller, *controller_list; - struct cgroup_file_info info; - void *handle = NULL; - char *saveptr = NULL; - int ret, lvl; - - /* parse the first controller name from list of controllers */ - controller_list = strdup(mount_info->name); - if (!controller_list) { - last_errno = errno; - return ECGOTHER; - } - controller = strtok_r(controller_list, ",", &saveptr); - if (!controller) { - free(controller_list); - return ECGINVAL; - } - - /* check if the hierarchy is empty */ - ret = cgroup_walk_tree_begin(controller, "/", 0, &handle, &info, &lvl); - free(controller_list); - if (ret == ECGCONTROLLEREXISTS) - return 0; - if (ret) - return ret; - - /* skip the first found directory, it's '/' */ - ret = cgroup_walk_tree_next(0, &handle, &info, lvl); - /* find any other subdirectory */ - while (ret == 0) { - if (info.type == CGROUP_FILE_TYPE_DIR) - break; - ret = cgroup_walk_tree_next(0, &handle, &info, lvl); - } - cgroup_walk_tree_end(&handle); - if (ret == 0) { - cgroup_dbg("won't unmount %s: hieararchy is not empty\n", mount_info->name); - return 0; /* the hieararchy is not empty */ - } - if (ret != ECGEOF) - return ret; - - /* - * ret must be ECGEOF now = there is only root group in the - * hierarchy -> unmount all mount points. - */ - ret = 0; - while (mount) { - int err; - - cgroup_dbg("unmounting %s at %s\n", mount_info->name, mount->path); - err = umount(mount->path); - if (err && !ret) { - ret = ECGOTHER; - last_errno = errno; - } - mount = mount->next; - } - return ret; -} - -int cgroup_config_unload_config(const char *pathname, int flags) -{ - int namespace_enabled = 0; - int mount_enabled = 0; - int ret, i, error; - - cgroup_dbg("%s: parsing %s\n", __func__, pathname); - ret = cgroup_parse_config(pathname); - if (ret) - goto err; - - namespace_enabled = (config_namespace_table[0].name[0] != '\0'); - mount_enabled = (config_mount_table[0].name[0] != '\0'); - /* The configuration should have namespace or mount, not both. */ - if (namespace_enabled && mount_enabled) { - free(config_cgroup_table); - return ECGMOUNTNAMESPACE; - } - - ret = config_order_namespace_table(); - if (ret) - goto err; - - ret = config_validate_namespaces(); - if (ret) - goto err; - - /* Delete the groups in reverse order, i.e. subgroups first, then parents. */ - cgroup_config_sort_groups(); - for (i = cgroup_table_index-1; i >= 0; i--) { - struct cgroup *cgroup = &config_cgroup_table[i]; - - cgroup_dbg("removing %s\n", pathname); - error = cgroup_delete_cgroup_ext(cgroup, flags); - if (error && !ret) - /* store the error, but continue deleting the rest */ - ret = error; - } - - /* Delete templates */ - for (i = 0; i < config_template_table_index; i++) { - struct cgroup *cgroup = &config_template_table[i]; - - cgroup_dbg("removing %s\n", pathname); - error = cgroup_delete_cgroup_ext(cgroup, flags); - if (error && !ret) - ret = error; /* store the error, but continue deleting the rest */ - } - config_template_table_index = 0; - - if (mount_enabled) { - for (i = 0; i < config_table_index; i++) { - struct cg_mount_table_s *m = &(config_mount_table[i]); - - cgroup_dbg("unmounting %s\n", m->name); - error = cgroup_config_try_unmount(m); - if (error && !ret) - ret = error; - } - } -err: - cgroup_free_config(); - - return ret; -} - -static int cgroup_config_unload_controller(const struct cgroup_mount_point *mount_info) -{ - struct cgroup_controller *cgc = NULL; - struct cgroup *cgroup = NULL; - enum cg_version_t version; - char path[FILENAME_MAX]; - int ret, error; - void *handle; - - cgroup = cgroup_new_cgroup("."); - if (cgroup == NULL) - return ECGFAIL; - - cgc = cgroup_add_controller(cgroup, mount_info->name); - if (cgc == NULL) { - ret = ECGFAIL; - goto out_error; - } - - ret = cgroup_delete_cgroup_ext(cgroup, CGFLAG_DELETE_RECURSIVE); - if (ret != 0) - goto out_error; - - ret = cgroup_get_controller_version(mount_info->name, &version); - if (ret != 0) - goto out_error; - - if (version == CGROUP_V2) - /* do not unmount the controller */ - goto out_error; - - /* unmount everything */ - ret = cgroup_get_subsys_mount_point_begin(mount_info->name, &handle, path); - while (ret == 0) { - error = umount(path); - if (error) { - cgroup_warn("cannot unmount controller %s on %s: %s\n", mount_info->name, - path, strerror(errno)); - last_errno = errno; - ret = ECGOTHER; - goto out_error; - } - ret = cgroup_get_subsys_mount_point_next(&handle, path); - } - - cgroup_get_subsys_mount_point_end(&handle); - if (ret == ECGEOF) - ret = 0; -out_error: - if (cgroup) - cgroup_free(&cgroup); - - return ret; -} - -int cgroup_unload_cgroups(void) -{ - struct cgroup_mount_point info; - void *ctrl_handle = NULL; - char *curr_path = NULL; - int error = 0; - int ret = 0; - - error = cgroup_init(); - - if (error) { - ret = error; - goto out_error; - } - - error = cgroup_get_controller_begin(&ctrl_handle, &info); - while (error == 0) { - if (!curr_path || strcmp(info.path, curr_path) != 0) { - if (curr_path) - free(curr_path); - - curr_path = strdup(info.path); - if (!curr_path) - goto out_errno; - - error = cgroup_config_unload_controller(&info); - if (error) { - /* remember the error and continue unloading the rest. */ - cgroup_warn("cannot clear controller %s\n", info.name); - ret = error; - error = 0; - } - } - error = cgroup_get_controller_next(&ctrl_handle, &info); - } - if (error == ECGEOF) - error = 0; - if (error) - ret = error; -out_error: - if (curr_path) - free(curr_path); - cgroup_get_controller_end(&ctrl_handle); - - return ret; - -out_errno: - last_errno = errno; - cgroup_get_controller_end(&ctrl_handle); - - return ECGOTHER; -} - -/** - * Defines the default group. The parser puts content of 'default { }' to - * topmost group in config_cgroup_table. - * This function copies the permissions from it to our default cgroup. - */ -int cgroup_config_define_default(void) -{ - struct cgroup *config_cgroup = &config_cgroup_table[cgroup_table_index]; - - init_cgroup_table(&default_group, 1); - if (config_cgroup->control_dperm != NO_PERMS) - default_group.control_dperm = config_cgroup->control_dperm; - if (config_cgroup->control_fperm != NO_PERMS) - default_group.control_fperm = config_cgroup->control_fperm; - if (config_cgroup->control_gid != NO_UID_GID) - default_group.control_gid = config_cgroup->control_gid; - if (config_cgroup->control_uid != NO_UID_GID) - default_group.control_uid = config_cgroup->control_uid; - if (config_cgroup->task_fperm != NO_PERMS) - default_group.task_fperm = config_cgroup->task_fperm; - if (config_cgroup->tasks_gid != NO_UID_GID) - default_group.tasks_gid = config_cgroup->tasks_gid; - if (config_cgroup->tasks_uid != NO_UID_GID) - default_group.tasks_uid = config_cgroup->tasks_uid; - - /* - * Reset all changes made by 'default { }' to the topmost group so - * it can be used by following 'group { }'. - */ - init_cgroup_table(config_cgroup, 1); - - return 0; -} - -int cgroup_config_set_default(struct cgroup *new_default) -{ - if (!new_default) - return ECGINVAL; - - init_cgroup_table(&default_group, 1); - - default_group.control_dperm = new_default->control_dperm; - default_group.control_fperm = new_default->control_fperm; - default_group.control_gid = new_default->control_gid; - default_group.control_uid = new_default->control_uid; - default_group.task_fperm = new_default->task_fperm; - default_group.tasks_gid = new_default->tasks_gid; - default_group.tasks_uid = new_default->tasks_uid; - default_group_set = 1; - - return 0; -} - -/** - * Reloads the templates list, using the given configuration file. - * @return 0 on success, > 0 on failure - */ -int cgroup_reload_cached_templates(char *pathname) -{ - int ret = 0; - int i; - - if (template_table) { - /* template structures have to be free */ - for (i = 0; i < template_table_index; i++) - cgroup_free_controllers(&template_table[i]); - - free(template_table); - template_table = NULL; - } - template_table_index = 0; - - if ((config_template_table_index != 0) || (config_table_index != 0)) { - /* config template structures have to be free as well*/ - cgroup_free_config(); - } - - /* reloading data to config template structures */ - cgroup_dbg("Reloading cached templates from %s.\n", pathname); - ret = cgroup_parse_config(pathname); - if (ret) { - cgroup_dbg("Could not reload template cache, error was: %d\n", ret); - return ret; - } - - /* copy data to templates cache structures */ - template_table_index = config_template_table_index; - template_table = calloc(template_table_index, sizeof(struct cgroup)); - if (template_table == NULL) { - ret = ECGOTHER; - return ret; - } - - for (i = 0; i < template_table_index; i++) { - cgroup_copy_cgroup(&template_table[i], &config_template_table[i]); - strcpy((template_table[i]).name, (config_template_table[i]).name); - template_table[i].tasks_uid = config_template_table[i].tasks_uid; - template_table[i].tasks_gid = config_template_table[i].tasks_gid; - template_table[i].task_fperm = config_template_table[i].task_fperm; - template_table[i].control_uid = config_template_table[i].control_uid; - template_table[i].control_gid = config_template_table[i].control_gid; - template_table[i].control_fperm = config_template_table[i].control_fperm; - template_table[i].control_dperm = config_template_table[i].control_dperm; - } - - return ret; -} - -/** - * Initializes the templates cache. - * @return 0 on success, > 0 on error - */ -int cgroup_init_templates_cache(char *pathname) -{ - int ret = 0; - int i; - - if (template_table) { - /* template structures have to be free */ - for (i = 0; i < template_table_index; i++) - cgroup_free_controllers(&template_table[i]); - - free(template_table); - template_table = NULL; - } - template_table_index = 0; - - if ((config_template_table_index != 0) || (config_table_index != 0)) { - /* config structures have to be clean */ - cgroup_free_config(); - } - - cgroup_dbg("Loading cached templates from %s.\n", pathname); - /* Attempt to read the configuration file and cache the rules. */ - ret = cgroup_parse_config(pathname); - if (ret) { - cgroup_dbg("Could not initialize rule cache, error was: %d\n", ret); - return ret; - } - - /* copy template data to templates cache structures */ - template_table_index = config_template_table_index; - template_table = calloc(template_table_index, sizeof(struct cgroup)); - if (template_table == NULL) { - ret = ECGOTHER; - return ret; - } - - for (i = 0; i < template_table_index; i++) { - cgroup_copy_cgroup(&template_table[i], &config_template_table[i]); - strcpy((template_table[i]).name, (config_template_table[i]).name); - template_table[i].tasks_uid = config_template_table[i].tasks_uid; - template_table[i].tasks_gid = config_template_table[i].tasks_gid; - template_table[i].task_fperm = config_template_table[i].task_fperm; - template_table[i].control_uid = config_template_table[i].control_uid; - template_table[i].control_gid = config_template_table[i].control_gid; - template_table[i].control_fperm = config_template_table[i].control_fperm; - template_table[i].control_dperm = config_template_table[i].control_dperm; - } - - return ret; -} - -/** - * Setting source files of templates. This function has to be called before - * any call of cgroup_load_templates_cache_from_files. - * @param tmpl_files - */ -void cgroup_templates_cache_set_source_files(struct cgroup_string_list *tmpl_files) -{ - template_files = tmpl_files; -} - -/** - * Appending cgroup templates parsed by parser to template_table - * @param offset number of templates already in the table - */ -int cgroup_add_cgroup_templates(int offset) -{ - int i, ti, ret; - - for (i = 0; i < config_template_table_index; i++) { - ti = i + offset; - ret = cgroup_copy_cgroup(&template_table[ti], &config_template_table[i]); - if (ret) - return ret; - - strcpy((template_table[ti]).name, (config_template_table[i]).name); - template_table[ti].tasks_uid = config_template_table[i].tasks_uid; - template_table[ti].tasks_gid = config_template_table[i].tasks_gid; - template_table[ti].task_fperm = config_template_table[i].task_fperm; - template_table[ti].control_uid = config_template_table[i].control_uid; - template_table[ti].control_gid = config_template_table[i].control_gid; - template_table[ti].control_fperm = config_template_table[i].control_fperm; - template_table[ti].control_dperm = config_template_table[i].control_dperm; - } - - return 0; -} - -/** - * Expand template table based on new number of parsed templates, - * i.e. on value of config_template_table_index. Change value of - * template_table_index. - * @return 0 on success, < 0 on error - */ -int cgroup_expand_template_table(void) -{ - int i; - - template_table = realloc(template_table, - (template_table_index + config_template_table_index) - *sizeof(struct cgroup)); - if (template_table == NULL) - return -ECGOTHER; - - for (i = 0; i < config_template_table_index; i++) - template_table[i + template_table_index].index = 0; - - template_table_index += config_template_table_index; - - return 0; -} - -/** - * Load the templates cache from files. Before calling this function, - * cgroup_templates_cache_set_source_files has to be called first. - * @param file_index index of file which was unable to be parsed - * @return 0 on success, > 0 on error - */ -int cgroup_load_templates_cache_from_files(int *file_index) -{ - int template_table_last_index; - char *pathname; - int i, j; - int ret; - - if (!template_files) { - /* source files has not been set */ - cgroup_dbg("Template source files have not been set. Using only %s\n", - CGCONFIG_CONF_FILE); - - if (template_table_index == 0) - /* the rules cache is empty */ - return cgroup_init_templates_cache(CGCONFIG_CONF_FILE); - else - /* cache is not empty */ - return cgroup_reload_cached_templates(CGCONFIG_CONF_FILE); - } - - if (template_table) { - /* template structures have to be free */ - for (i = 0; i < template_table_index; i++) - cgroup_free_controllers(&template_table[i]); - - free(template_table); - template_table = NULL; - } - template_table_index = 0; - - if ((config_template_table_index != 0) || (config_table_index != 0)) { - /* config structures have to be clean before parsing */ - cgroup_free_config(); - } - - for (j = 0; j < template_files->count; j++) { - pathname = template_files->items[j]; - - cgroup_dbg("Parsing templates from %s.\n", pathname); - /* Attempt to read the configuration file and cache the rules. */ - ret = cgroup_parse_config(pathname); - if (ret) { - cgroup_dbg("Could not initialize rule cache, error was: %d\n", ret); - *file_index = j; - return ret; - } - - if (config_template_table_index > 0) { - template_table_last_index = template_table_index; - ret = cgroup_expand_template_table(); - if (ret) { - cgroup_dbg("Could not expand template table, error was: %d\n", - -ret); - *file_index = j; - return -ret; - } - - /* copy template data to templates cache structures */ - cgroup_dbg("Copying templates to template table from %s.\n", pathname); - ret = cgroup_add_cgroup_templates(template_table_last_index); - if (ret) { - cgroup_dbg("Unable to copy cgroup\n"); - *file_index = j; - return ret; - } - cgroup_dbg("Templates to template table copied\n"); - } - } - - return 0; -} - -/* - * Create a given cgroup, based on template configuration if it is present - * if the template is not present cgroup is creted using cgroup_create_cgroup - */ -int cgroup_config_create_template_group(struct cgroup *cgroup, char *template_name, int flags) -{ - struct cgroup *aux_cgroup = NULL; - struct cgroup_controller *cgc; - char buffer[FILENAME_MAX]; - struct cgroup *t_cgroup; - int i, j, k; - int ret = 0; - int found; - - /* - * If the user did not ask for cached rules, we must parse the - * configuration file and prepare template structures now. - * We use CGCONFIG_CONF_FILE by default - */ - if (!(flags & CGFLAG_USE_TEMPLATE_CACHE)) { - int fileindex; - - /* the rules cache is empty */ - ret = cgroup_load_templates_cache_from_files( - &fileindex); - if (ret != 0) { - if (fileindex < 0) { - cgroup_dbg("Template source files have not been set\n"); - } else { - cgroup_dbg("Failed to load template rules from %s. ", - template_files->items[fileindex]); - } - } - - if (ret != 0) { - cgroup_dbg("Failed initialize templates cache.\n"); - return ret; - } - } - - for (i = 0; cgroup->controller[i] != NULL; i++) { - /* - * for each controller we have to add to cgroup structure - * either template cgroup or empty controller. - */ - - found = 0; - /* look for relevant template - test name x controller pair */ - for (j = 0; j < template_table_index; j++) { - - t_cgroup = &template_table[j]; - if (strcmp(t_cgroup->name, template_name) != 0) { - /* template name does not match skip template */ - continue; - } - - /* template name match */ - for (k = 0; t_cgroup->controller[k] != NULL; k++) { - if (strcmp((cgroup->controller[i])->name, - (t_cgroup->controller[k])->name) != 0) { - /* controller name does not match */ - continue; - } - - /* - * name and controller match template found - * variables substituted in template - */ - strncpy(buffer, t_cgroup->name, FILENAME_MAX-1); - buffer[sizeof(buffer) - 1] = '\0'; - strncpy(t_cgroup->name, cgroup->name, FILENAME_MAX-1); - t_cgroup->name[sizeof(t_cgroup->name) - 1] = '\0'; - - ret = cgroup_create_cgroup(t_cgroup, flags); - - strncpy(t_cgroup->name, buffer, FILENAME_MAX-1); - t_cgroup->name[sizeof(t_cgroup->name) - 1] = '\0'; - if (ret) { - cgroup_dbg("creating group %s, error %d\n", cgroup->name, - ret); - goto end; - } else { - /* go to new controller */ - j = template_table_index; - found = 1; - continue; - } - - } - } - - if (found == 1) - continue; - - /* - * no template is present for given name x controller pair - * add controller to result cgroup. - */ - aux_cgroup = cgroup_new_cgroup(cgroup->name); - if (!aux_cgroup) { - ret = ECGINVAL; - fprintf(stderr, "cgroup %s can't be created\n", cgroup->name); - goto end; - } - cgc = cgroup_add_controller(aux_cgroup, (cgroup->controller[i])->name); - if (cgc == NULL) { - ret = ECGINVAL; - fprintf(stderr, "cgroup %s can't be created\n", cgroup->name); - goto end; - } - ret = cgroup_create_cgroup(aux_cgroup, flags); - if (ret) { - ret = ECGINVAL; - fprintf(stderr, "cgroup %s can't be created\n", cgroup->name); - goto end; - } - } - -end: - cgroup_free(&aux_cgroup); - return ret; -} - -#ifdef WITH_SYSTEMD -int cgroup_add_systemd_opts(const char * const config, const char * const value) -{ - struct cgroup_systemd_opts *curr = cgroup_systemd_opts_tail; - int len; - - if (strcmp(config, "slice") == 0) { - snprintf(curr->slice_name, FILENAME_MAX, "%s", value); - - len = strlen(curr->slice_name) - 6; - if (strcmp(curr->slice_name + len, ".slice")) - goto err; - - } else if (strcmp(config, "scope") == 0) { - snprintf(curr->scope_name, FILENAME_MAX, "%s", value); - - len = strlen(curr->scope_name) - 6; - if (strcmp(curr->scope_name + len, ".scope")) - goto err; - - } else if (strcmp(config, "setdefault") == 0 && strcasecmp(value, "yes") == 0) { - curr->setdefault = 1; - } else if (strcmp(config, "pid") == 0) { - /* - * If the atoi() fails, the pid value is zero and also - * avoid allowing init task (systemd). - */ - curr->pid = atoi(value); - if (curr->pid <= 1) - goto err; - } else - goto err; - - return 1; -err: - cgroup_err("Invalid systemd configuration %s value %s\n", config, value); - cgroup_cleanup_systemd_opts(); - return 0; -} - -int cgroup_alloc_systemd_opts(const char * const config, const char * const value) -{ - struct cgroup_systemd_opts *new_cgrp_systemd_opts; - - /* - * check for the allowed systemd configurations. We don't - * check for values, they will be checked by systemd anyway. - */ - if (strcmp(config, "slice") != 0 && - strcmp(config, "scope") != 0 && - strcmp(config, "setdefault") != 0 && - strcmp(config, "pid") != 0) { - cgroup_err("Invalid systemd configuration %s\n", config); - goto err; - } - - new_cgrp_systemd_opts = calloc(1, sizeof(struct cgroup_systemd_opts)); - if (!new_cgrp_systemd_opts) { - cgroup_err("Failed to allocate memory for cgroup_systemd_opts\n"); - goto err; - } - - if (!cgroup_systemd_opts_head) - cgroup_systemd_opts_tail = cgroup_systemd_opts_head = new_cgrp_systemd_opts; - else { - cgroup_systemd_opts_tail->next = new_cgrp_systemd_opts; - cgroup_systemd_opts_tail = new_cgrp_systemd_opts; - } - - return cgroup_add_systemd_opts(config, value); -err: - cgroup_cleanup_systemd_opts(); - return 0; -} - -void cgroup_cleanup_systemd_opts(void) -{ - struct cgroup_systemd_opts *curr, *next; - - for (curr = cgroup_systemd_opts_head; curr; curr = next) { - next = curr->next; - free(curr); - } - - cgroup_systemd_opts_head = cgroup_systemd_opts_tail = NULL; -} - -/* - * Helper function to remove the systemd_default_cgroup_file. - * systemd_default_cgroup_lock is expected to be held by the - * caller. - */ -static int remove_systemd_default_cgroup_file(void) -{ - int ret; - - ret = unlink(systemd_default_cgroup_file); - if (ret < 0 && errno != ENOENT) { - cgroup_err("Failed to remove %s\n", systemd_default_cgroup_file); - return 0; - } - - return 1; -} -/* - * Helper function to create systemd_default_cgroup_file and write systemd - * default cgroup slice/scope into it. This file will be read by - * cgroup_set_default_systemd_cgroup() for setting - * systemd_default_cgroup used to form the cgroup path. - */ -int cgroup_write_systemd_default_cgroup(const char * const slice, - const char * const scope) -{ - FILE *systemd_def_cgrp_f; - int ret, len; - - pthread_rwlock_wrlock(&systemd_default_cgroup_lock); - - ret = mkdir(systemd_def_cgrp_file_dir, 0755); - if (ret != 0 && errno != EEXIST) { - cgroup_err("Failed to create directory %s\n", systemd_def_cgrp_file_dir); - ret = 0; - goto out; - } - - systemd_def_cgrp_f = fopen(systemd_default_cgroup_file, "w"); - if (!systemd_def_cgrp_f) { - cgroup_err("Failed to create file %s\n", systemd_default_cgroup_file); - ret = 0; - goto out; - } - - len = strlen(slice) + strlen(scope) + 1; - - ret = fprintf(systemd_def_cgrp_f, "%s/%s", slice, scope); - fclose(systemd_def_cgrp_f); - if (ret != len) { - cgroup_err("Incomplete systemd default cgroup written to %s\n", - systemd_default_cgroup_file); - ret = remove_systemd_default_cgroup_file(); - /* Ignore the return value, we are already in error path */ - ret = 0; - goto out; - } - - ret = 1; -out: - pthread_rwlock_unlock(&systemd_default_cgroup_lock); - return ret; -} - -/** - * Create the systemd slice and scope. The slice/scope are parsed and available in - * the cgroup_systemd_opts_head list. This function skips the slice and scope creation - * if previously created. - * - * Returns 1 on success and 0 on failure. - */ -static int config_create_slice_scope(char * const tmp_systemd_default_cgroup) -{ - struct cgroup_systemd_opts *curr, *def = NULL; - struct cgroup_systemd_scope_opts scope_opts; - int ret = 0; - - if (!tmp_systemd_default_cgroup) - return 0; - - if (cgroup_set_default_scope_opts(&scope_opts)) - return 0; - - pthread_rwlock_wrlock(&systemd_default_cgroup_lock); - ret = remove_systemd_default_cgroup_file(); - pthread_rwlock_unlock(&systemd_default_cgroup_lock); - if (!ret) - return 0; - - for (curr = cgroup_systemd_opts_head; curr; curr = curr->next) { - - if (!strlen(curr->slice_name)) { - cgroup_err("Invalid systemd setting, missing slice name.\n"); - goto err; - } - - if (!strlen(curr->scope_name)) { - cgroup_err("Invalid systemd setting, missing scope name.\n"); - goto err; - } - - /* incase of multiple setdefault configurations, set it to latest scope */ - if (curr->setdefault) - def = curr; - - if (curr->pid) - scope_opts.pid = curr->pid; - - ret = cgroup_create_scope(curr->scope_name, curr->slice_name, &scope_opts); - if (ret) - goto err; - - cgroup_dbg("Created systemd slice %s scope %s default %d pid %d\n", - curr->slice_name, curr->scope_name, curr->setdefault, curr->pid); - } - - if (def) { - if (!cgroup_write_systemd_default_cgroup(def->slice_name, def->scope_name)) - goto err; - - snprintf(tmp_systemd_default_cgroup, sizeof(systemd_default_cgroup), - "%s/%s", def->slice_name, def->scope_name); - - cgroup_dbg("Setting/Writing systemd default cgroup %s to file %s\n", - tmp_systemd_default_cgroup, systemd_default_cgroup_file); - - } - - return 1; -err: - return 0; -} - -/* - * This function builds the canonical path for the systemd default cgroup - * based on the cgroup setup mode and if the cgroup doesn't exist removes - * the systemd default cgroup file. This function expects the caller to be - * holding the systemd_default_cgroup_lock. - */ -static bool systemd_default_cgroup_exists(void) -{ - char path[FILENAME_MAX] = "\0"; - char cgrp_procs_path[FILENAME_MAX + 13]; /* 13 = strlen(/cgroup.procs) */ - bool exists = false; - - switch (cgroup_setup_mode()) { - case CGROUP_MODE_HYBRID: - /* - * check for empty cgroup v2, the most common usage in - * the hybrid case. - */ - if (cg_build_path("", path, NULL)) - break; - case CGROUP_MODE_UNIFIED: - /* fallthrough */ - case CGROUP_MODE_LEGACY: - cg_build_path("", path, "cpu"); - /* fallthrough */ - case CGROUP_MODE_UNK: - break; - } - - if (!strlen(path)) { - cgroup_dbg("Unable to form canonical path for %s", systemd_default_cgroup); - goto err; - } - - snprintf(cgrp_procs_path, sizeof(cgrp_procs_path), "%s/cgroup.procs", path); - if (access(cgrp_procs_path, F_OK)) { - /* - * systemd has already removed the scope cgroup, hence delete - * the file too. - */ - cgroup_dbg("%s doesn't exists, deleting %s", path, systemd_default_cgroup_file); - unlink(systemd_default_cgroup_file); - goto err; - } - - exists = true; -err: - return exists; -} - -int cgroup_set_default_systemd_cgroup(void) -{ - FILE *systemd_def_cgrp_f; - size_t len; - - pthread_rwlock_wrlock(&systemd_default_cgroup_lock); - - systemd_def_cgrp_f = fopen(systemd_default_cgroup_file, "r"); - if (!systemd_def_cgrp_f) { - cgroup_dbg("Unable to read %s ", systemd_default_cgroup_file); - goto err; - } - - len = fread(systemd_default_cgroup, sizeof(char), FILENAME_MAX, systemd_def_cgrp_f); - fclose(systemd_def_cgrp_f); - /* at the minimum it should be .slice/.scope == 15 */ - if (len < 15) { - cgroup_dbg("Malformed systemd default cgroup %s", systemd_default_cgroup); - goto err; - } - - if (systemd_default_cgroup_exists()) { - pthread_rwlock_unlock(&systemd_default_cgroup_lock); - return 1; - } -err: - pthread_rwlock_unlock(&systemd_default_cgroup_lock); - cgroup_dbg(", continuing without systemd default cgroup.\n", systemd_default_cgroup); - systemd_default_cgroup[0] = '\0'; - - return 0; -} -#else -int cgroup_add_systemd_opts(const char * const config, const char * const value) -{ - return 1; -} - -int cgroup_alloc_systemd_opts(const char * const config, const char * const value) -{ - return 1; -} - -void cgroup_cleanup_systemd_opts(void) { } - -int cgroup_set_default_systemd_cgroup(void) -{ - return 0; -} -#endif diff --git a/lib/libcgroup-3.1.0/src/daemon/Makefile.am b/lib/libcgroup-3.1.0/src/daemon/Makefile.am deleted file mode 100644 index 2616294e234..00000000000 --- a/lib/libcgroup-3.1.0/src/daemon/Makefile.am +++ /dev/null @@ -1,14 +0,0 @@ -@CODE_COVERAGE_RULES@ - -AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include -I$(top_builddir)/include - -if WITH_DAEMON - -sbin_PROGRAMS = cgrulesengd -cgrulesengd_SOURCES = cgrulesengd.c cgrulesengd.h ../tools/tools-common.h ../tools/tools-common.c -cgrulesengd_LIBS = $(CODE_COVERAGE_LIBS) -cgrulesengd_CFLAGS = $(CODE_COVERAGE_CFLAGS) -cgrulesengd_LDADD = $(top_builddir)/src/libcgroup.la -lrt -cgrulesengd_LDFLAGS = -L$(top_builddir)/src/.libs - -endif diff --git a/lib/libcgroup-3.1.0/src/daemon/Makefile.in b/lib/libcgroup-3.1.0/src/daemon/Makefile.in deleted file mode 100644 index df55f69cf7a..00000000000 --- a/lib/libcgroup-3.1.0/src/daemon/Makefile.in +++ /dev/null @@ -1,732 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -@WITH_DAEMON_TRUE@sbin_PROGRAMS = cgrulesengd$(EXEEXT) -subdir = src/daemon -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(sbindir)" -PROGRAMS = $(sbin_PROGRAMS) -am__cgrulesengd_SOURCES_DIST = cgrulesengd.c cgrulesengd.h \ - ../tools/tools-common.h ../tools/tools-common.c -am__dirstamp = $(am__leading_dot)dirstamp -@WITH_DAEMON_TRUE@am_cgrulesengd_OBJECTS = \ -@WITH_DAEMON_TRUE@ cgrulesengd-cgrulesengd.$(OBJEXT) \ -@WITH_DAEMON_TRUE@ ../tools/cgrulesengd-tools-common.$(OBJEXT) -cgrulesengd_OBJECTS = $(am_cgrulesengd_OBJECTS) -@WITH_DAEMON_TRUE@cgrulesengd_DEPENDENCIES = \ -@WITH_DAEMON_TRUE@ $(top_builddir)/src/libcgroup.la -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -cgrulesengd_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgrulesengd_CFLAGS) \ - $(CFLAGS) $(cgrulesengd_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ../tools/$(DEPDIR)/cgrulesengd-tools-common.Po \ - ./$(DEPDIR)/cgrulesengd-cgrulesengd.Po -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(cgrulesengd_SOURCES) -DIST_SOURCES = $(am__cgrulesengd_SOURCES_DIST) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include -I$(top_builddir)/include -@WITH_DAEMON_TRUE@cgrulesengd_SOURCES = cgrulesengd.c cgrulesengd.h ../tools/tools-common.h ../tools/tools-common.c -@WITH_DAEMON_TRUE@cgrulesengd_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_DAEMON_TRUE@cgrulesengd_CFLAGS = $(CODE_COVERAGE_CFLAGS) -@WITH_DAEMON_TRUE@cgrulesengd_LDADD = $(top_builddir)/src/libcgroup.la -lrt -@WITH_DAEMON_TRUE@cgrulesengd_LDFLAGS = -L$(top_builddir)/src/.libs -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/daemon/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/daemon/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -install-sbinPROGRAMS: $(sbin_PROGRAMS) - @$(NORMAL_INSTALL) - @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ - fi; \ - for p in $$list; do echo "$$p $$p"; done | \ - sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p \ - || test -f $$p1 \ - ; then echo "$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n;h' \ - -e 's|.*|.|' \ - -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ - sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) files[d] = files[d] " " $$1; \ - else { print "f", $$3 "/" $$4, $$1; } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-sbinPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' \ - `; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(sbindir)" && rm -f $$files - -clean-sbinPROGRAMS: - @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list -../tools/$(am__dirstamp): - @$(MKDIR_P) ../tools - @: > ../tools/$(am__dirstamp) -../tools/$(DEPDIR)/$(am__dirstamp): - @$(MKDIR_P) ../tools/$(DEPDIR) - @: > ../tools/$(DEPDIR)/$(am__dirstamp) -../tools/cgrulesengd-tools-common.$(OBJEXT): ../tools/$(am__dirstamp) \ - ../tools/$(DEPDIR)/$(am__dirstamp) - -cgrulesengd$(EXEEXT): $(cgrulesengd_OBJECTS) $(cgrulesengd_DEPENDENCIES) $(EXTRA_cgrulesengd_DEPENDENCIES) - @rm -f cgrulesengd$(EXEEXT) - $(AM_V_CCLD)$(cgrulesengd_LINK) $(cgrulesengd_OBJECTS) $(cgrulesengd_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -rm -f ../tools/*.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@../tools/$(DEPDIR)/cgrulesengd-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgrulesengd-cgrulesengd.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -cgrulesengd-cgrulesengd.o: cgrulesengd.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -MT cgrulesengd-cgrulesengd.o -MD -MP -MF $(DEPDIR)/cgrulesengd-cgrulesengd.Tpo -c -o cgrulesengd-cgrulesengd.o `test -f 'cgrulesengd.c' || echo '$(srcdir)/'`cgrulesengd.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgrulesengd-cgrulesengd.Tpo $(DEPDIR)/cgrulesengd-cgrulesengd.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgrulesengd.c' object='cgrulesengd-cgrulesengd.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -c -o cgrulesengd-cgrulesengd.o `test -f 'cgrulesengd.c' || echo '$(srcdir)/'`cgrulesengd.c - -cgrulesengd-cgrulesengd.obj: cgrulesengd.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -MT cgrulesengd-cgrulesengd.obj -MD -MP -MF $(DEPDIR)/cgrulesengd-cgrulesengd.Tpo -c -o cgrulesengd-cgrulesengd.obj `if test -f 'cgrulesengd.c'; then $(CYGPATH_W) 'cgrulesengd.c'; else $(CYGPATH_W) '$(srcdir)/cgrulesengd.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgrulesengd-cgrulesengd.Tpo $(DEPDIR)/cgrulesengd-cgrulesengd.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgrulesengd.c' object='cgrulesengd-cgrulesengd.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -c -o cgrulesengd-cgrulesengd.obj `if test -f 'cgrulesengd.c'; then $(CYGPATH_W) 'cgrulesengd.c'; else $(CYGPATH_W) '$(srcdir)/cgrulesengd.c'; fi` - -../tools/cgrulesengd-tools-common.o: ../tools/tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -MT ../tools/cgrulesengd-tools-common.o -MD -MP -MF ../tools/$(DEPDIR)/cgrulesengd-tools-common.Tpo -c -o ../tools/cgrulesengd-tools-common.o `test -f '../tools/tools-common.c' || echo '$(srcdir)/'`../tools/tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ../tools/$(DEPDIR)/cgrulesengd-tools-common.Tpo ../tools/$(DEPDIR)/cgrulesengd-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='../tools/tools-common.c' object='../tools/cgrulesengd-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -c -o ../tools/cgrulesengd-tools-common.o `test -f '../tools/tools-common.c' || echo '$(srcdir)/'`../tools/tools-common.c - -../tools/cgrulesengd-tools-common.obj: ../tools/tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -MT ../tools/cgrulesengd-tools-common.obj -MD -MP -MF ../tools/$(DEPDIR)/cgrulesengd-tools-common.Tpo -c -o ../tools/cgrulesengd-tools-common.obj `if test -f '../tools/tools-common.c'; then $(CYGPATH_W) '../tools/tools-common.c'; else $(CYGPATH_W) '$(srcdir)/../tools/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) ../tools/$(DEPDIR)/cgrulesengd-tools-common.Tpo ../tools/$(DEPDIR)/cgrulesengd-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='../tools/tools-common.c' object='../tools/cgrulesengd-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgrulesengd_CFLAGS) $(CFLAGS) -c -o ../tools/cgrulesengd-tools-common.obj `if test -f '../tools/tools-common.c'; then $(CYGPATH_W) '../tools/tools-common.c'; else $(CYGPATH_W) '$(srcdir)/../tools/tools-common.c'; fi` - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(PROGRAMS) -installdirs: - for dir in "$(DESTDIR)$(sbindir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -rm -f ../tools/$(DEPDIR)/$(am__dirstamp) - -rm -f ../tools/$(am__dirstamp) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-sbinPROGRAMS \ - mostlyclean-am - -distclean: distclean-am - -rm -f ../tools/$(DEPDIR)/cgrulesengd-tools-common.Po - -rm -f ./$(DEPDIR)/cgrulesengd-cgrulesengd.Po - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: install-sbinPROGRAMS - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f ../tools/$(DEPDIR)/cgrulesengd-tools-common.Po - -rm -f ./$(DEPDIR)/cgrulesengd-cgrulesengd.Po - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-sbinPROGRAMS - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-generic clean-libtool clean-sbinPROGRAMS cscopelist-am \ - ctags ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-sbinPROGRAMS install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am uninstall-sbinPROGRAMS - -.PRECIOUS: Makefile - -@CODE_COVERAGE_RULES@ - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.c b/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.c deleted file mode 100644 index 51988de50b6..00000000000 --- a/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.c +++ /dev/null @@ -1,1290 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright Red Hat Inc. 2008 - * - * Author: Steve Olivieri - * Author: Vivek Goyal - * - * Some part of the programs have been derived from Dhaval Giani's posting - * for daemon to place the task in right container. Original copyright notice - * follows. - * - * Copyright IBM Corporation, 2007 - * Author: Dhaval Giani linux.vnet.ibm.com> - * Derived from test_cn_proc.c by Matt Helsley - * Original copyright notice follows - * - * Copyright (C) Matt Helsley, IBM Corp. 2005 - * Derived from fcctl.c by Guillaume Thouvenin - * Original copyright notice follows: - * - * Copyright (C) 2005 BULL SA. - * Written by Guillaume Thouvenin bull.net> - * - * TODO Stop using netlink for communication (or at least rewrite that part). - */ - -#include "../libcgroup-internal.h" -#include "../tools/tools-common.h" -#include "cgrulesengd.h" -#include "libcgroup.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -#include -#include -#include -#include - -#include -#include -#include -#include - -#define NUM_PER_REALLOCATIOM (100) - -/* list of config files from CGCONFIG_CONF_FILE and CGCONFIG_CONF_DIR */ -static struct cgroup_string_list template_files; - -/* Log file, NULL if logging to file is disabled */ -FILE *logfile; - -/* Log facility, 0 if logging to syslog is disabled */ -int logfacility; - -/* Current log level */ -int loglevel; - -/* Owner of the socket, -1 means no change */ -uid_t socket_user = -1; - -/* Owner of the socket, -1 means no change */ -gid_t socket_group = -1; - -/** - * Prints the usage information for this program and, optionally, an error - * message. This function uses vfprintf. - * @param fd The file stream to print to - * @param msg The error message to print (printf style) - * @param ... Any args to msg (printf style) - */ -static void usage(FILE *fd, const char *msg, ...) -{ - /* List of args to msg */ - va_list ap; - - /* Put all args after msg into the list. */ - va_start(ap, msg); - - if (msg) - vfprintf(fd, msg, ap); - fprintf(fd, "\n"); - fprintf(fd, "cgrulesengd -- a daemon for the cgroups rules engine\n\n"); - fprintf(fd, "Usage : cgrulesengd [options]\n\n"); - fprintf(fd, " options :\n"); - fprintf(fd, " -q | --quiet\t\t quiet mode\n"); - fprintf(fd, " -v | --verbose\t\t verbose mode\n"); - fprintf(fd, " -f | --logfile=\t write log to file\n"); - fprintf(fd, " -s[facility] | --syslog=[facility]\t write log to syslog\n"); - fprintf(fd, " -n | --nodaemon\t\t don't fork daemon\n"); - fprintf(fd, " -d | --debug\t\t same as -v -v -n -f -\n"); - fprintf(fd, " -Q | --nolog\t\t disable logging\n"); - fprintf(fd, " -u | --socket-user= set"); - fprintf(fd, " " CGRULE_CGRED_SOCKET_PATH " socket user\n"); - fprintf(fd, " -g | --socket-group= set"); - fprintf(fd, " " CGRULE_CGRED_SOCKET_PATH " socket group\n"); - fprintf(fd, " -h | --help\t\t show this help\n\n"); - va_end(ap); -} - -/** - * Prints a formatted message (like vprintf()) to all log destinations. - * Flushes the file stream's buffer so that the message is immediately - * readable. - * @param level The log level (LOG_EMERG ... LOG_DEBUG) - * @param format The format for the message (vprintf style) - * @param ap Any args to format (vprintf style) - */ -void flog_write(int level, const char *format, va_list ap) -{ - int copy = 0; - va_list cap; - - /* Check the log level */ - if (level > loglevel) - return; - - /* copy the argument list if needed - it can be processed only once */ - if (logfile && logfacility) { - copy = 1; - va_copy(cap, ap); - } - - if (logfile) { - /* Print the message to the given stream. */ - vfprintf(logfile, format, ap); - - /* - * Flush the stream's buffer, so the data - * is readable immediately. - */ - fflush(logfile); - } - - if (logfacility) { - if (copy) { - vsyslog(LOG_MAKEPRI(logfacility, level), format, cap); - va_end(cap); - } else { - vsyslog(LOG_MAKEPRI(logfacility, level), format, ap); - } - } -} - -/** - * Prints a formatted message (like printf()) to all log destinations. - * Flushes the file stream's buffer so that the message is immediately - * readable. - * @param level The log level (LOG_EMERG ... LOG_DEBUG) - * @param format The format for the message (printf style) - * @param ... Any args to format (printf style) - */ -void flog(int level, const char *format, ...) -{ - va_list ap; - - va_start(ap, format); - flog_write(level, format, ap); - va_end(ap); -} - -/** - * Libcgroup logging callback. It must translate libcgroup log levels - * to cgrulesengd native (=syslog). - */ -void flog_cgroup(void *userdata, int cgroup_level, const char *format, va_list ap) -{ - int level = 0; - - switch (cgroup_level) { - case CGROUP_LOG_ERROR: - level = LOG_ERR; - break; - case CGROUP_LOG_WARNING: - level = LOG_WARNING; - break; - case CGROUP_LOG_INFO: - level = LOG_INFO; - break; - case CGROUP_LOG_DEBUG: - level = LOG_DEBUG; - break; - } - flog_write(level, format, ap); -} - -struct parent_info { - __u64 timestamp; - pid_t pid; -}; - -struct array_parent_info { - int index; - int num_allocation; - struct parent_info **parent_info; -}; - -struct array_parent_info array_pi; - -static int cgre_store_parent_info(pid_t pid) -{ - struct parent_info *info; - struct timespec tp; - __u64 uptime_ns; - - if (clock_gettime(CLOCK_MONOTONIC, &tp) < 0) { - flog(LOG_WARNING, "Failed to get time\n"); - return 1; - } - uptime_ns = ((__u64)tp.tv_sec * 1000 * 1000 * 1000) + tp.tv_nsec; - - if (array_pi.index >= array_pi.num_allocation) { - int alloc = array_pi.num_allocation + NUM_PER_REALLOCATIOM; - void *new_array = realloc(array_pi.parent_info, sizeof(info) * alloc); - if (!new_array) { - flog(LOG_WARNING, "Failed to allocate memory\n"); - return 1; - } - array_pi.parent_info = new_array; - array_pi.num_allocation = alloc; - } - - info = calloc(1, sizeof(struct parent_info)); - if (!info) { - flog(LOG_WARNING, "Failed to allocate memory\n"); - return 1; - } - info->timestamp = uptime_ns; - info->pid = pid; - - array_pi.parent_info[array_pi.index] = info; - array_pi.index++; - - return 0; -} - -static void cgre_remove_old_parent_info(__u64 key_timestamp) -{ - int i, j; - - for (i = 0; i < array_pi.index; i++) { - if (key_timestamp < array_pi.parent_info[i]->timestamp) - continue; - - free(array_pi.parent_info[i]); - for (j = i; j < array_pi.index - 1; j++) - array_pi.parent_info[j] = array_pi.parent_info[j + 1]; - array_pi.index--; - i--; - } -} - -static int cgre_was_parent_changed_when_forking(const struct proc_event *ev) -{ - __u64 timestamp_parent; - __u64 timestamp_child; - pid_t parent_pid; - int i; - - parent_pid = ev->event_data.fork.parent_pid; - timestamp_child = ev->timestamp_ns; - - cgre_remove_old_parent_info(timestamp_child); - - for (i = 0; i < array_pi.index; i++) { - if (parent_pid != array_pi.parent_info[i]->pid) - continue; - - timestamp_parent = array_pi.parent_info[i]->timestamp; - if (timestamp_child > timestamp_parent) - continue; - - return 1; - } - - return 0; -} - -struct unchanged_pid { - pid_t pid; - int flags; -} unchanged_pid_t; - -struct array_unchanged { - int index; - int num_allocation; - struct unchanged_pid *proc; -}; - -struct array_unchanged array_unch; - -static int cgre_store_unchanged_process(pid_t pid, int flags) -{ - int i; - - for (i = 0; i < array_unch.index; i++) { - if (array_unch.proc[i].pid != pid) - continue; - /* pid is stored already. */ - return 0; - } - - if (array_unch.index >= array_unch.num_allocation) { - int alloc = array_unch.num_allocation + NUM_PER_REALLOCATIOM; - void *new_array = realloc(array_unch.proc, sizeof(unchanged_pid_t) * alloc); - if (!new_array) { - flog(LOG_WARNING, "Failed to allocate memory\n"); - return 1; - } - array_unch.proc = new_array; - array_unch.num_allocation = alloc; - } - array_unch.proc[array_unch.index].pid = pid; - array_unch.proc[array_unch.index].flags = flags; - array_unch.index++; - - flog(LOG_DEBUG, "Store the unchanged process (PID: %d, FLAGS: %d)\n", pid, flags); - - return 0; -} - -static void cgre_remove_unchanged_process(pid_t pid) -{ - int i, j; - - for (i = 0; i < array_unch.index; i++) { - if (array_unch.proc[i].pid != pid) - continue; - - for (j = i; j < array_unch.index - 1; j++) - memcpy(&array_unch.proc[j], &array_unch.proc[j + 1], - sizeof(struct unchanged_pid)); - array_unch.index--; - flog(LOG_DEBUG, "Remove the unchanged process (PID: %d)\n", pid); - return; - } -} - -static int cgre_is_unchanged_process(pid_t pid) -{ - int i; - - for (i = 0; i < array_unch.index; i++) { - if (array_unch.proc[i].pid != pid) - continue; - return 1; - } - - return 0; -} - -static int cgre_is_unchanged_child(pid_t pid) -{ - int i; - - for (i = 0; i < array_unch.index; i++) { - if (array_unch.proc[i].pid != pid) - continue; - if (array_unch.proc[i].flags & CGROUP_DAEMON_UNCHANGE_CHILDREN) - return 1; - break; - } - - return 0; -} - -/** - * Process an event from the kernel, and determine the correct UID/GID/PID - * to pass to libcgroup. Then, libcgroup will decide the cgroup to move - * the PID to, if any. - * @param ev The event to process - * @param type The type of event to process (part of ev) - * @return 0 on success, > 0 on failure - */ -int cgre_process_event(const struct proc_event *ev, const int type) -{ - pid_t pid = 0, log_pid = 0; - uid_t euid, log_uid = 0; - gid_t egid, log_gid = 0; - pid_t ppid, cpid; - char *procname; - - int ret = 0; - - switch (type) { - case PROC_EVENT_UID: - case PROC_EVENT_GID: - /* - * If the unchanged process, the daemon should not change - * the cgroup of the process. - */ - if (cgre_is_unchanged_process(ev->event_data.id.process_pid)) - return 0; - pid = ev->event_data.id.process_pid; - break; - case PROC_EVENT_FORK: - ppid = ev->event_data.fork.parent_pid; - cpid = ev->event_data.fork.child_pid; - if (cgre_is_unchanged_child(ppid)) { - if (cgre_store_unchanged_process(cpid, CGROUP_DAEMON_UNCHANGE_CHILDREN)) - return 1; - } - - /* - * If this process was forked while changing parent's - * cgroup, this process's cgroup also should be changed. - */ - if (!cgre_was_parent_changed_when_forking(ev)) - return 0; - pid = ev->event_data.fork.child_pid; - break; - case PROC_EVENT_EXIT: - cgre_remove_unchanged_process(ev->event_data.exit.process_pid); - return 0; - case PROC_EVENT_EXEC: - /* - * If the unchanged process, the daemon should not change - * the cgroup of the process. - */ - if (cgre_is_unchanged_process(ev->event_data.exec.process_pid)) - return 0; - pid = ev->event_data.exec.process_pid; - break; - default: - break; - } - - ret = cgroup_get_uid_gid_from_procfs(pid, &euid, &egid); - if (ret == ECGROUPNOTEXIST) - /* - * cgroup_get_uid_gid_from_procfs() returns ECGROUPNOTEXIST - * if a process finished and that is not a problem. - */ - return 0; - else if (ret) - return ret; - - ret = cgroup_get_procname_from_procfs(pid, &procname); - if (ret == ECGROUPNOTEXIST) - return 0; - else if (ret) - return ret; - - /* - * Now that we have the UID, the GID, and the PID, we can make a - * call to libcgroup to change the cgroup for this PID. - */ - log_pid = pid; - switch (type) { - case PROC_EVENT_UID: - log_uid = ev->event_data.id.e.euid; - log_gid = egid; - euid = ev->event_data.id.e.euid; - break; - case PROC_EVENT_GID: - log_uid = euid; - log_gid = ev->event_data.id.e.egid; - egid = ev->event_data.id.e.egid; - break; - case PROC_EVENT_FORK: - log_uid = euid; - log_gid = egid; - break; - case PROC_EVENT_EXEC: - log_uid = euid; - log_gid = egid; - break; - default: - break; - } - - ret = cgroup_change_cgroup_flags(euid, egid, procname, pid, CGFLAG_USECACHE); - if (ret == ECGOTHER) { - /* - * A process finished already but we may have missed - * changing it, make sure to apply to forked children. - */ - if (cgroup_get_last_errno() == ESRCH || cgroup_get_last_errno() == ENOENT) - ret = cgre_store_parent_info(pid); - else - ret = 0; - } else if (ret) { - flog(LOG_WARNING, "Cgroup change for PID: %d, UID: %d, GID: %d, ", log_pid, - log_uid, log_gid); - flog(LOG_WARNING, "PROCNAME: %s FAILED! (Error Code: %d)\n", procname, ret); - } else { - flog(LOG_INFO, "Cgroup change for PID: %d, UID: %d, GID: %d, PROCNAME: %s OK\n", - log_pid, log_uid, log_gid, procname); - ret = cgre_store_parent_info(pid); - } - free(procname); - - return ret; -} - -/** - * Handle a netlink message. - * In the event of PROC_EVENT_UID or PROC_EVENT_GID, we pass the event along - * to cgre_process_event for further processing. All other events are ignored. - * @param cn_hdr The netlink message - * @return 0 on success, > 0 on error - */ -static int cgre_handle_msg(struct cn_msg *cn_hdr) -{ - /* The event to consider */ - struct proc_event *ev; - - /* Return codes */ - int ret = 0; - - /* Get the event data. We only care about two event types. */ - ev = (struct proc_event *)cn_hdr->data; - switch (ev->what) { - case PROC_EVENT_UID: - flog(LOG_DEBUG, "UID Event: PID = %d, tGID = %d, rUID = %d, eUID = %d\n", - ev->event_data.id.process_pid, ev->event_data.id.process_tgid, - ev->event_data.id.r.ruid, ev->event_data.id.e.euid); - ret = cgre_process_event(ev, PROC_EVENT_UID); - break; - case PROC_EVENT_GID: - flog(LOG_DEBUG, "GID Event: PID = %d, tGID = %d, rGID = %d, eGID = %d\n", - ev->event_data.id.process_pid, ev->event_data.id.process_tgid, - ev->event_data.id.r.rgid, ev->event_data.id.e.egid); - ret = cgre_process_event(ev, PROC_EVENT_GID); - break; - case PROC_EVENT_FORK: - ret = cgre_process_event(ev, PROC_EVENT_FORK); - break; - case PROC_EVENT_EXIT: - ret = cgre_process_event(ev, PROC_EVENT_EXIT); - break; - case PROC_EVENT_EXEC: - flog(LOG_DEBUG, "EXEC Event: PID = %d, tGID = %d\n", - ev->event_data.exec.process_pid, ev->event_data.exec.process_tgid); - ret = cgre_process_event(ev, PROC_EVENT_EXEC); - break; - default: - break; - } - - return ret; -} - -static int cgre_receive_netlink_msg(int sk_nl) -{ - struct sockaddr_nl from_nla; - socklen_t from_nla_len; - struct cn_msg *cn_hdr; - struct nlmsghdr *nlh; - char buff[BUFF_SIZE]; - size_t recv_len; - - memset(buff, 0, sizeof(buff)); - from_nla_len = sizeof(from_nla); - recv_len = recvfrom(sk_nl, buff, sizeof(buff), 0, (struct sockaddr *)&from_nla, - &from_nla_len); - if (recv_len == ENOBUFS) { - flog(LOG_ERR, "ERROR: NETLINK BUFFER FULL, MESSAGE DROPPED!\n"); - return 0; - } - - if (recv_len < 1) - return 0; - - if (from_nla_len != sizeof(from_nla)) { - flog(LOG_ERR, "Bad address size reading netlink socket\n"); - return 0; - } - - if (from_nla.nl_groups != CN_IDX_PROC || from_nla.nl_pid != 0) - return 0; - - nlh = (struct nlmsghdr *)buff; - while (NLMSG_OK(nlh, recv_len)) { - cn_hdr = NLMSG_DATA(nlh); - - if (nlh->nlmsg_type == NLMSG_NOOP) { - nlh = NLMSG_NEXT(nlh, recv_len); - continue; - } - if ((nlh->nlmsg_type == NLMSG_ERROR) || (nlh->nlmsg_type == NLMSG_OVERRUN)) - break; - if (cgre_handle_msg(cn_hdr) < 0) - return 1; - if (nlh->nlmsg_type == NLMSG_DONE) - break; - nlh = NLMSG_NEXT(nlh, recv_len); - } - - return 0; -} - -static void cgre_receive_unix_domain_msg(int sk_unix) -{ - struct sockaddr_un caddr; - char path[FILENAME_MAX]; - struct stat buff_stat; - socklen_t caddr_len; - size_t ret_len; - int fd_client; - int flags; - pid_t pid; - - caddr_len = sizeof(caddr); - fd_client = accept(sk_unix, (struct sockaddr *)&caddr, &caddr_len); - if (fd_client < 0) { - flog(LOG_WARNING, "Warning: 'accept' command error: %s\n", strerror(errno)); - return; - } - - ret_len = read(fd_client, &pid, sizeof(pid)); - if (ret_len != sizeof(pid)) { - flog(LOG_WARNING, "Warning: 'read' command error: %s\n", strerror(errno)); - goto close; - } - - sprintf(path, "/proc/%d", pid); - if (stat(path, &buff_stat)) { - flog(LOG_WARNING, "Warning: there is no such process (PID: %d)\n", pid); - goto close; - } - - ret_len = read(fd_client, &flags, sizeof(flags)); - if (ret_len != sizeof(flags)) { - flog(LOG_WARNING, "Warning: error reading daemon socket: %s\n", strerror(errno)); - goto close; - } - - if (flags == CGROUP_DAEMON_CANCEL_UNCHANGE_PROCESS) - cgre_remove_unchanged_process(pid); - else if (cgre_store_unchanged_process(pid, flags)) - goto close; - - if (write(fd_client, CGRULE_SUCCESS_STORE_PID, sizeof(CGRULE_SUCCESS_STORE_PID)) < 0) { - flog(LOG_WARNING, "Warning: cannot write to daemon socket: %s\n", strerror(errno)); - goto close; - } - -close: - close(fd_client); -} - -static int cgre_create_netlink_socket_process_msg(void) -{ - int sk_nl = 0, sk_unix = 0, sk_max; - enum proc_cn_mcast_op *mcop_msg; - struct sockaddr_nl my_nla; - struct sockaddr_un saddr; - struct nlmsghdr *nl_hdr; - struct cn_msg *cn_hdr; - char buff[BUFF_SIZE]; - fd_set fds, readfds; - sigset_t sigset; - int rc = -1; - - /* - * Create an endpoint for communication. Use the kernel user interface - * device (PF_NETLINK) which is a datagram oriented service (SOCK_DGRAM). - * The protocol used is the connector protocol (NETLINK_CONNECTOR) - */ - sk_nl = socket(PF_NETLINK, SOCK_DGRAM, NETLINK_CONNECTOR); - if (sk_nl == -1) { - flog(LOG_ERR, "Error: error opening netlink socket: %s\n", strerror(errno)); - return rc; - } - - my_nla.nl_family = AF_NETLINK; - my_nla.nl_groups = CN_IDX_PROC; - my_nla.nl_pid = getpid(); - my_nla.nl_pad = 0; - - if (bind(sk_nl, (struct sockaddr *)&my_nla, sizeof(my_nla)) < 0) { - flog(LOG_ERR, "Error: error binding netlink socket: %s\n", strerror(errno)); - goto close_and_exit; - } - - nl_hdr = (struct nlmsghdr *)buff; - cn_hdr = (struct cn_msg *)NLMSG_DATA(nl_hdr); - mcop_msg = (enum proc_cn_mcast_op *)&cn_hdr->data[0]; - flog(LOG_DEBUG, "Sending proc connector: PROC_CN_MCAST_LISTEN...\n"); - memset(buff, 0, sizeof(buff)); - *mcop_msg = PROC_CN_MCAST_LISTEN; - - /* fill the netlink header */ - nl_hdr->nlmsg_len = SEND_MESSAGE_LEN; - nl_hdr->nlmsg_type = NLMSG_DONE; - nl_hdr->nlmsg_flags = 0; - nl_hdr->nlmsg_seq = 0; - nl_hdr->nlmsg_pid = getpid(); - - /* fill the connector header */ - cn_hdr->id.idx = CN_IDX_PROC; - cn_hdr->id.val = CN_VAL_PROC; - cn_hdr->seq = 0; - cn_hdr->ack = 0; - cn_hdr->len = sizeof(enum proc_cn_mcast_op); - flog(LOG_DEBUG, "Sending netlink message len=%d, cn_msg len=%d\n", nl_hdr->nlmsg_len, - (int) sizeof(struct cn_msg)); - - if (send(sk_nl, nl_hdr, nl_hdr->nlmsg_len, 0) != nl_hdr->nlmsg_len) { - flog(LOG_ERR, "Error: failed to send netlink message (mcast ctl op): %s\n", - strerror(errno)); - goto close_and_exit; - } - flog(LOG_DEBUG, "Message sent\n"); - - /* Setup Unix domain socket. */ - sk_unix = socket(PF_UNIX, SOCK_STREAM, 0); - if (sk_unix < 0) { - flog(LOG_ERR, "Error creating UNIX socket: %s\n", strerror(errno)); - goto close_and_exit; - } - - memset(&saddr, 0, sizeof(saddr)); - saddr.sun_family = AF_UNIX; - strcpy(saddr.sun_path, CGRULE_CGRED_SOCKET_PATH); - unlink(CGRULE_CGRED_SOCKET_PATH); - - if (bind(sk_unix, (struct sockaddr *)&saddr, - sizeof(saddr.sun_family) + strlen(CGRULE_CGRED_SOCKET_PATH)) < 0) { - flog(LOG_ERR, "Error binding UNIX socket %s: %s\n", CGRULE_CGRED_SOCKET_PATH, - strerror(errno)); - goto close_and_exit; - } - - if (listen(sk_unix, 1) < 0) { - flog(LOG_ERR, "Error listening on UNIX socket %s: %s\n", CGRULE_CGRED_SOCKET_PATH, - strerror(errno)); - goto close_and_exit; - } - - /* change the owner */ - if (chown(CGRULE_CGRED_SOCKET_PATH, socket_user, socket_group) < 0) { - flog(LOG_ERR, "Error changing %s socket owner: %s\n", CGRULE_CGRED_SOCKET_PATH, - strerror(errno)); - goto close_and_exit; - } - - flog(LOG_DEBUG, "Socket %s owner successfully set to %d:%d\n", CGRULE_CGRED_SOCKET_PATH, - (int) socket_user, (int) socket_group); - - if (chmod(CGRULE_CGRED_SOCKET_PATH, 0660) < 0) { - flog(LOG_ERR, "Error changing %s socket permissions: %s\n", - CGRULE_CGRED_SOCKET_PATH, strerror(errno)); - goto close_and_exit; - } - - FD_ZERO(&readfds); - FD_SET(sk_nl, &readfds); - FD_SET(sk_unix, &readfds); - if (sk_nl < sk_unix) - sk_max = sk_unix; - else - sk_max = sk_nl; - - sigemptyset(&sigset); - sigaddset(&sigset, SIGUSR2); - for (;;) { - /* - * For avoiding the deadlock and "Interrupted system call" - * error, restrict the effective range of SIGUSR2 signal. - */ - sigprocmask(SIG_UNBLOCK, &sigset, NULL); - sigprocmask(SIG_BLOCK, &sigset, NULL); - - memcpy(&fds, &readfds, sizeof(fd_set)); - if (select(sk_max + 1, &fds, NULL, NULL, NULL) < 0) { - flog(LOG_ERR, "Selecting error: %s\n", strerror(errno)); - goto close_and_exit; - } - - if (FD_ISSET(sk_nl, &fds)) { - if (cgre_receive_netlink_msg(sk_nl)) - break; - } - - if (FD_ISSET(sk_unix, &fds)) - cgre_receive_unix_domain_msg(sk_unix); - } - -close_and_exit: - if (sk_nl >= 0) - close(sk_nl); - if (sk_unix >= 0) - close(sk_unix); - - return rc; -} - -/** - * Start logging. Opens syslog and/or log file and sets log level. - * @param logp Path of the log file, NULL if no log file was specified - * @param logf Syslog facility, NULL if no facility was specified - * @param logv Log verbosity, 1 is the default, 0 = no logging, 4 = everything - */ -static void cgre_start_log(const char *logp, int logf, int logv) -{ - /* Current system time */ - time_t tm; - - /* Log levels */ - int loglevels[] = { - LOG_EMERG, /* -q */ - LOG_ERR, /* default */ - LOG_WARNING, /* -v */ - LOG_INFO, /* -vv */ - LOG_DEBUG /* -vvv */ - }; - - /* Set default logging destination if nothing was specified */ - if (!logp && !logf) - logf = LOG_DAEMON; - - /* Open log file */ - if (logp) { - if (strcmp("-", logp) == 0) { - logfile = stdout; - } else { - logfile = fopen(logp, "a"); - if (!logfile) { - fprintf(stderr, "Failed to open log file %s,", logp); - fprintf(stderr, " error: %s. Continuing anyway.\n", - strerror(errno)); - logfile = stdout; - } - } - } else - logfile = NULL; - - /* Open syslog */ - if (logf) { - openlog("CGRE", LOG_CONS | LOG_PID, logf); - logfacility = logf; - } else - logfacility = 0; - - /* Set the log level */ - if (logv < 0) - logv = 0; - if (logv >= sizeof(loglevels)/sizeof(int)) - logv = sizeof(loglevels)/sizeof(int)-1; - - loglevel = loglevels[logv]; - cgroup_set_logger(flog_cgroup, CGROUP_LOG_DEBUG, NULL); - - flog(LOG_DEBUG, "CGroup Rules Engine Daemon log started\n"); - - tm = time(0); - flog(LOG_DEBUG, "Current time: %s\n", ctime(&tm)); - flog(LOG_DEBUG, "Opened log file: %s, log facility: %d,log level: %d\n", logp, logfacility, - loglevel); -} - -/** - * Turns this program into a daemon. In doing so, we fork() and kill the - * parent process. Note too that stdout, stdin, and stderr are closed in - * daemon mode, and a file descriptor for a log file is opened. - * @param logp Path of the log file, NULL if no log file was specified - * @param logf Syslog facility, 0 if no facility was specified - * @param daemon False to turn off daemon mode (no fork, leave FDs open) - * @param logv Log verbosity, 1 is the default, 0 = no logging, 5 = everything - * @return 0 on success, > 0 on error - */ -int cgre_start_daemon(const char *logp, const int logf, const unsigned char daemon, const int logv) -{ - /* PID returned from the fork() */ - pid_t pid; - - /* Fork and die. */ - if (daemon) { - pid = fork(); - if (pid < 0) { - openlog("CGRE", LOG_CONS, LOG_DAEMON|LOG_WARNING); - syslog(LOG_DAEMON|LOG_WARNING, "Failed to fork, error: %s", - strerror(errno)); - closelog(); - - fprintf(stderr, "Failed to fork(), %s\n", strerror(errno)); - return 1; - } else if (pid > 0) { - exit(EXIT_SUCCESS); - } - } else { - flog(LOG_DEBUG, "Not using daemon mode\n"); - pid = getpid(); - } - - cgre_start_log(logp, logf, logv); - - if (!daemon) { - /* We can skip the rest, since we're not becoming a daemon. */ - flog(LOG_INFO, "Proceeding with PID %d\n", getpid()); - return 0; - } - - /* Get a new SID for the child. */ - if (setsid() < 0) { - flog(LOG_ERR, "Failed to get a new SID, error: %s\n", strerror(errno)); - return 2; - } - - /* Change to the root directory. */ - if (chdir("/") < 0) { - flog(LOG_ERR, "Failed to chdir to /, error: %s\n", strerror(errno)); - return 3; - } - - /* Close standard file descriptors. */ - close(STDIN_FILENO); - if (logfile != stdout) - close(STDOUT_FILENO); - close(STDERR_FILENO); - - /* If we make it this far, we're a real daemon! Or we chose not to. */ - flog(LOG_INFO, "Proceeding with PID %d\n", getpid()); - - return 0; -} - -/** - * Catch the SIGUSR2 signal and reload the rules configuration. - * This function makes use of the logfile and flog() to print the new rules. - * @param signum The signal that we caught (always SIGUSR2) - */ -void cgre_flash_rules(int signum) -{ - /* Current time */ - time_t tm = time(0); - - int fileindex; - - flog(LOG_INFO, "Reloading rules configuration\n"); - flog(LOG_DEBUG, "Current time: %s\n", ctime(&tm)); - - /* Ask libcgroup to reload the rules table. */ - cgroup_reload_cached_rules(); - - /* Print the results of the new table to our log file. */ - if (logfile && loglevel >= LOG_INFO) { - cgroup_print_rules_config(logfile); - fprintf(logfile, "\n"); - } - - /* Ask libcgroup to reload the template rules table. */ - cgroup_load_templates_cache_from_files(&fileindex); -} - -/** - * Catch the SIGUSR1 signal and reload the rules configuration. - * This function makes use of the logfile and flog() to print the new rules. - * @param signum The signal that we caught (always SIGUSR1) - */ -void cgre_flash_templates(int signum) -{ - /* Current time */ - time_t tm = time(0); - - int fileindex; - - flog(LOG_INFO, "Reloading templates configuration.\n"); - flog(LOG_DEBUG, "Current time: %s\n", ctime(&tm)); - - /* Ask libcgroup to reload the templates table. */ - cgroup_load_templates_cache_from_files(&fileindex); -} - -/** - * Catch the SIGTERM and SIGINT signals so that we can exit gracefully. - * Before exiting, this function makes use of the logfile and flog(). - * @param signum The signal that we caught (SIGTERM, SIGINT) - */ -void cgre_catch_term(int signum) -{ - /* Current time */ - time_t tm = time(0); - - flog(LOG_INFO, "Stopped CGroup Rules Engine Daemon at %s\n", ctime(&tm)); - - /* Close the log file, if we opened one */ - if (logfile && logfile != stdout) - fclose(logfile); - - /* Close syslog */ - if (logfacility) - closelog(); - - exit(EXIT_SUCCESS); -} - -/** - * Parse the syslog facility as received on command line. - * @param arg Command line argument with the syslog facility - * @return the syslog facility (e.g. LOG_DAEMON) or 0 on error - */ -static int cgre_parse_syslog_facility(const char *arg) -{ - if (arg == NULL) - return 0; - - if (strlen(arg) > 1) - return 0; - - switch (arg[0]) { - case '0': - return LOG_LOCAL0; - case '1': - return LOG_LOCAL1; - case '2': - return LOG_LOCAL2; - case '3': - return LOG_LOCAL3; - case '4': - return LOG_LOCAL4; - case '5': - return LOG_LOCAL5; - case '6': - return LOG_LOCAL6; - case '7': - return LOG_LOCAL7; - case 'D': - return LOG_DAEMON; - default: - return 0; - } -} - -int main(int argc, char *argv[]) -{ - /* Patch to the log file */ - const char *logp = NULL; - - /* Syslog facility */ - int facility = 0; - - /* Verbose level */ - int verbosity = 1; - - /* For catching signals */ - struct sigaction sa; - - /* Should we daemonize? */ - unsigned char daemon = 1; - - /* Return codes */ - int ret = 0; - - struct passwd *pw; - struct group *gr; - - /* Command line arguments */ - const char *short_options = "hvqf:s::ndQu:g:"; - struct option long_options[] = { - {"help", no_argument, NULL, 'h'}, - {"verbose", no_argument, NULL, 'v'}, - {"quiet", no_argument, NULL, 'q'}, - {"logfile", required_argument, NULL, 'f'}, - {"syslog", optional_argument, NULL, 's'}, - {"nodaemon", no_argument, NULL, 'n'}, - {"debug", no_argument, NULL, 'd'}, - {"nolog", no_argument, NULL, 'Q'}, - {"socket-user", required_argument, NULL, 'u'}, - {"socket-group", required_argument, NULL, 'g'}, - {NULL, 0, NULL, 0} - }; - - int fileindex; - - /* Make sure the user is root. */ - if (getuid() != 0) { - fprintf(stderr, "Error: Only root can start/stop the control"); - fprintf(stderr, " group rules engine daemon\n"); - ret = 1; - goto finished; - } - - /* - * Check environment variable CGROUP_LOGLEVEL. If it's set to - * DEBUG, set appropriate verbosity level. - */ - char *level_str = getenv("CGROUP_LOGLEVEL"); - - if (level_str != NULL) { - if (cgroup_parse_log_level_str(level_str) == CGROUP_LOG_DEBUG) { - verbosity = 4; - logp = "-"; - } - } - - while (1) { - int c; - - c = getopt_long(argc, argv, short_options, long_options, NULL); - if (c == -1) - break; - - switch (c) { - case 'h': /* --help */ - usage(stdout, "Help:\n"); - ret = 0; - goto finished; - - case 'v': /* --verbose */ - verbosity++; - break; - - case 'q': /* --quiet */ - verbosity--; - break; - - case 'Q': /* --nolog */ - verbosity = 0; - break; - - case 'f': /* --logfile= */ - logp = optarg; - break; - - case 's': /* --syslog=[facility] */ - if (optarg) { - facility = cgre_parse_syslog_facility(optarg); - if (facility == 0) { - fprintf(stderr, "Unknown syslog facility: %s\n", optarg); - ret = 2; - goto finished; - } - } else { - facility = LOG_DAEMON; - } - break; - - case 'n': /* --no-fork */ - daemon = 0; - break; - - case 'd': /* --debug */ - /* same as -vvn */ - daemon = 0; - verbosity = 4; - logp = "-"; - break; - case 'u': /* --socket-user */ - pw = getpwnam(optarg); - if (pw == NULL) { - usage(stderr, "Cannot find user %s", optarg); - ret = 3; - goto finished; - } - socket_user = pw->pw_uid; - flog(LOG_DEBUG, "Using socket user %s id %d\n", optarg, (int)socket_user); - break; - case 'g': /* --socket-group */ - gr = getgrnam(optarg); - if (gr == NULL) { - usage(stderr, "Cannot find group %s", optarg); - ret = 3; - goto finished; - } - socket_group = gr->gr_gid; - flog(LOG_DEBUG, "Using socket group %s id %d\n", optarg, - (int)socket_group); - break; - default: - usage(stderr, ""); - ret = 2; - goto finished; - } - } - - /* Initialize libcgroup. */ - ret = cgroup_init(); - if (ret != 0) { - fprintf(stderr, "Error: libcgroup initialization failed, %s\n", - cgroup_strerror(ret)); - goto finished; - } - - /* Ask libcgroup to load the configuration rules. */ - ret = cgroup_string_list_init(&template_files, CGCONFIG_CONF_FILES_LIST_MINIMUM_SIZE); - if (ret) { - fprintf(stderr, "%s: cannot init file list, out of memory?\n", argv[0]); - goto finished_without_temp_files; - } - /* first add CGCONFIG_CONF_FILE into file list */ - ret = cgroup_string_list_add_item(&template_files, CGCONFIG_CONF_FILE); - if (ret) { - fprintf(stderr, "%s: cannot add file to list, out of memory?\n", argv[0]); - goto finished; - } - - /* then read CGCONFIG_CONF_DIR directory for additional config files */ - cgroup_string_list_add_directory(&template_files, CGCONFIG_CONF_DIR, argv[0]); - - ret = cgroup_init_rules_cache(); - if (ret != 0) { - fprintf(stderr, "Error: libcgroup failed to initialize rules"); - fprintf(stderr, "cache from %s. %s\n", CGRULES_CONF_FILE, cgroup_strerror(ret)); - goto finished; - } - - /* ask libcgroup to load template rules as well */ - cgroup_templates_cache_set_source_files(&template_files); - ret = cgroup_load_templates_cache_from_files(&fileindex); - if (ret != 0) { - if (fileindex < 0) - fprintf(stderr, "Error: Template source files have not been set\n"); - else - fprintf(stderr, "Error: Failed to initialize template rules from %s.%s\n", - template_files.items[fileindex], cgroup_strerror(-ret)); - goto finished; - } - - /* Now, start the daemon. */ - ret = cgre_start_daemon(logp, facility, daemon, verbosity); - if (ret < 0) { - fprintf(stderr, "Error: Failed to launch the daemon, %s\n", cgroup_strerror(ret)); - goto finished; - } - - /* - * Set up the signal handler to reload the cached rules upon - * reception of a SIGUSR2 signal. - */ - memset(&sa, 0, sizeof(sa)); - sa.sa_handler = &cgre_flash_rules; - sigemptyset(&sa.sa_mask); - ret = sigaction(SIGUSR2, &sa, NULL); - if (ret) { - flog(LOG_ERR, "Failed to set up signal handler for SIGUSR2. Error: %s\n", - strerror(errno)); - goto finished; - } - - /* - * Set up the signal handler to reload templates cache upon - * reception of a SIGUSR1 signal. - */ - sa.sa_handler = &cgre_flash_templates; - ret = sigaction(SIGUSR1, &sa, NULL); - if (ret) { - flog(LOG_ERR, "Failed to set up signal handler for SIGUSR1. Error: %s\n", - strerror(errno)); - goto finished; - } - - /* - * Set up the signal handler to catch SIGINT and SIGTERM so that - * we can exit gracefully - */ - sa.sa_handler = &cgre_catch_term; - ret = sigaction(SIGINT, &sa, NULL); - ret |= sigaction(SIGTERM, &sa, NULL); - if (ret) { - flog(LOG_ERR, "Failed to set up the signal handler. Error: %s\n", strerror(errno)); - goto finished; - } - - /* Print the configuration to the log file, or stdout. */ - if (logfile && loglevel >= LOG_INFO) - cgroup_print_rules_config(logfile); - - /* Scan for running applications with rules */ - ret = cgroup_change_all_cgroups(); - if (ret) - flog(LOG_WARNING, "Failed to initialize running tasks.\n"); - - flog(LOG_INFO, "Started the CGroup Rules Engine Daemon.\n"); - - /* We loop endlesly in this function, unless we encounter an error. */ - ret = cgre_create_netlink_socket_process_msg(); - -finished: - cgroup_string_list_free(&template_files); - -finished_without_temp_files: - if (logfile && logfile != stdout) - fclose(logfile); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.h b/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.h deleted file mode 100644 index 70ad3981ecb..00000000000 --- a/lib/libcgroup-3.1.0/src/daemon/cgrulesengd.h +++ /dev/null @@ -1,122 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright Red Hat Inc. 2008 - * - * Author: Steve Olivieri - */ - -#ifndef _CGRULESENGD_H -#define _CGRULESENGD_H - -#include - -#ifdef __cplusplus -extern "C" { -#endif - -#include "config.h" -#include "libcgroup.h" - -#include -#include - -#ifndef _GNU_SOURCE -#define _GNU_SOURCE -#endif - -#ifndef __USE_GNU -#define __USE_GNU -#endif - -/* The following ten macros are all for the Netlink code. */ -#define SEND_MESSAGE_LEN (NLMSG_LENGTH(sizeof(struct cn_msg) + sizeof(enum proc_cn_mcast_op))) -#define RECV_MESSAGE_LEN (NLMSG_LENGTH(sizeof(struct cn_msg) + sizeof(struct proc_event))) - -#define SEND_MESSAGE_SIZE (NLMSG_SPACE(SEND_MESSAGE_LEN)) -#define RECV_MESSAGE_SIZE (NLMSG_SPACE(RECV_MESSAGE_LEN)) - -#define BUFF_SIZE (max(max(SEND_MESSAGE_SIZE, RECV_MESSAGE_SIZE), 1024)) -#define MIN_RECV_SIZE (min(SEND_MESSAGE_SIZE, RECV_MESSAGE_SIZE)) - -#define PROC_CN_MCAST_LISTEN (1) -#define PROC_CN_MCAST_IGNORE (2) - -/** - * Prints the usage information for this program and, optionally, - * an error message. This function uses vfprintf. - * @param fd The file stream to print to - * @param msg The error message to print (printf style) - * @param ... Any args to msg (printf style) - */ -void cgre_usage(FILE *fd, const char *msg, ...); - -/** - * Prints a formatted message (like printf()) to all log destinations. - * Flushes the file stream's buffer so that the message is immediately - * readable. - * @param level The log level (LOG_EMERG ... LOG_DEBUG) - * @param format The format for the message (printf style) - * @param ... Any args to format (printf style) - */ -void flog(int level, const char *msg, ...); - -/** - * Process an event from the kernel, and determine the correct UID/GID/PID - * to pass to libcgroup. Then, libcgroup will decide the cgroup to move - * the PID to, if any. - * @param ev The event to process - * @param type The type of event to process (part of ev) - * @return 0 on success, > 0 on failure - */ -int cgre_process_event(const struct proc_event *ev, const int type); - -/** - * Handle a netlink message. - * In the event of PROC_EVENT_UID or PROC_EVENT_GID, we pass the event - * along to cgre_process_event for further processing. All other events - * are ignored. - * @param cn_hdr The netlink message - * @return 0 on success, > 0 on error - */ -int cgre_handle_message(struct cn_msg *cn_hdr); - -/** - * Turns this program into a daemon. In doing so, we fork() and kill the - * parent process. Note too that stdout, stdin, and stderr are closed in - * daemon mode, and a file descriptor for a log file is opened. - * @param logp Path of the log file, NULL if no log file was specified - * @param logf Syslog facility, NULL if no facility was specified - * @param daemon False to turn off daemon mode (no fork, leave FDs open) - * @param logv Log verbosity: - * 2 is the default, 0 = no logging, 5 = everything - * @return 0 on success, > 0 on error - */ -int cgre_start_daemon(const char *logp, const int logf, const unsigned char daemon, - const int logv); - -/** - * Catch the SIGUSR2 signal and reload the rules configuration. - * This function makes use of the logfile and flog() to print the new rules. - * @param signum The signal that we caught (always SIGUSR2) - */ -void cgre_flash_rules(int signum); - -/** - * Catch the SIGUSR1 signal and reload the rules configuration. - * This function makes use of the logfile and flog() to print the new rules. - * @param signum The signal that we caught (always SIGUSR1) - */ -void cgre_flash_templates(int signum); - -/** - * Catch the SIGTERM and SIGINT signal so that we can exit gracefully. - * Before exiting, this function makes use of the logfile and flog(). - * @param signum The signal that we caught (SIGTERM, SIGINT) - */ -void cgre_catch_term(int signum); - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* _CGRULESENGD_H */ diff --git a/lib/libcgroup-3.1.0/src/lex.c b/lib/libcgroup-3.1.0/src/lex.c deleted file mode 100644 index 7cae1bbadd7..00000000000 --- a/lib/libcgroup-3.1.0/src/lex.c +++ /dev/null @@ -1,1851 +0,0 @@ - -#line 2 "lex.c" - -#define YY_INT_ALIGNED short int - -/* A lexical scanner generated by flex */ - -#define FLEX_SCANNER -#define YY_FLEX_MAJOR_VERSION 2 -#define YY_FLEX_MINOR_VERSION 6 -#define YY_FLEX_SUBMINOR_VERSION 4 -#if YY_FLEX_SUBMINOR_VERSION > 0 -#define FLEX_BETA -#endif - -/* First, we deal with platform-specific or compiler-specific issues. */ - -/* begin standard C headers. */ -#include -#include -#include -#include - -/* end standard C headers. */ - -/* flex integer type definitions */ - -#ifndef FLEXINT_H -#define FLEXINT_H - -/* C99 systems have . Non-C99 systems may or may not. */ - -#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L - -/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, - * if you want the limit (max/min) macros for int types. - */ -#ifndef __STDC_LIMIT_MACROS -#define __STDC_LIMIT_MACROS 1 -#endif - -#include -typedef int8_t flex_int8_t; -typedef uint8_t flex_uint8_t; -typedef int16_t flex_int16_t; -typedef uint16_t flex_uint16_t; -typedef int32_t flex_int32_t; -typedef uint32_t flex_uint32_t; -#else -typedef signed char flex_int8_t; -typedef short int flex_int16_t; -typedef int flex_int32_t; -typedef unsigned char flex_uint8_t; -typedef unsigned short int flex_uint16_t; -typedef unsigned int flex_uint32_t; - -/* Limits of integral types. */ -#ifndef INT8_MIN -#define INT8_MIN (-128) -#endif -#ifndef INT16_MIN -#define INT16_MIN (-32767-1) -#endif -#ifndef INT32_MIN -#define INT32_MIN (-2147483647-1) -#endif -#ifndef INT8_MAX -#define INT8_MAX (127) -#endif -#ifndef INT16_MAX -#define INT16_MAX (32767) -#endif -#ifndef INT32_MAX -#define INT32_MAX (2147483647) -#endif -#ifndef UINT8_MAX -#define UINT8_MAX (255U) -#endif -#ifndef UINT16_MAX -#define UINT16_MAX (65535U) -#endif -#ifndef UINT32_MAX -#define UINT32_MAX (4294967295U) -#endif - -#ifndef SIZE_MAX -#define SIZE_MAX (~(size_t)0) -#endif - -#endif /* ! C99 */ - -#endif /* ! FLEXINT_H */ - -/* begin standard C++ headers. */ - -/* TODO: this is always defined, so inline it */ -#define yyconst const - -#if defined(__GNUC__) && __GNUC__ >= 3 -#define yynoreturn __attribute__((__noreturn__)) -#else -#define yynoreturn -#endif - -/* Returned upon end-of-file. */ -#define YY_NULL 0 - -/* Promotes a possibly negative, possibly signed char to an - * integer in range [0..255] for use as an array index. - */ -#define YY_SC_TO_UI(c) ((YY_CHAR) (c)) - -/* Enter a start condition. This macro really ought to take a parameter, - * but we do it the disgusting crufty way forced on us by the ()-less - * definition of BEGIN. - */ -#define BEGIN (yy_start) = 1 + 2 * -/* Translate the current start state into a value that can be later handed - * to BEGIN to return to the state. The YYSTATE alias is for lex - * compatibility. - */ -#define YY_START (((yy_start) - 1) / 2) -#define YYSTATE YY_START -/* Action number for EOF rule of a given start state. */ -#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) -/* Special action meaning "start processing a new file". */ -#define YY_NEW_FILE yyrestart( yyin ) -#define YY_END_OF_BUFFER_CHAR 0 - -/* Size of default input buffer. */ -#ifndef YY_BUF_SIZE -#ifdef __ia64__ -/* On IA-64, the buffer size is 16k, not 8k. - * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. - * Ditto for the __ia64__ case accordingly. - */ -#define YY_BUF_SIZE 32768 -#else -#define YY_BUF_SIZE 16384 -#endif /* __ia64__ */ -#endif - -/* The state buf must be large enough to hold one state per character in the main buffer. - */ -#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) - -#ifndef YY_TYPEDEF_YY_BUFFER_STATE -#define YY_TYPEDEF_YY_BUFFER_STATE -typedef struct yy_buffer_state *YY_BUFFER_STATE; -#endif - -#ifndef YY_TYPEDEF_YY_SIZE_T -#define YY_TYPEDEF_YY_SIZE_T -typedef size_t yy_size_t; -#endif - -extern int yyleng; - -extern FILE *yyin, *yyout; - -#define EOB_ACT_CONTINUE_SCAN 0 -#define EOB_ACT_END_OF_FILE 1 -#define EOB_ACT_LAST_MATCH 2 - - #define YY_LESS_LINENO(n) - #define YY_LINENO_REWIND_TO(ptr) - -/* Return all but the first "n" matched characters back to the input stream. */ -#define yyless(n) \ - do \ - { \ - /* Undo effects of setting up yytext. */ \ - int yyless_macro_arg = (n); \ - YY_LESS_LINENO(yyless_macro_arg);\ - *yy_cp = (yy_hold_char); \ - YY_RESTORE_YY_MORE_OFFSET \ - (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ - YY_DO_BEFORE_ACTION; /* set up yytext again */ \ - } \ - while ( 0 ) -#define unput(c) yyunput( c, (yytext_ptr) ) - -#ifndef YY_STRUCT_YY_BUFFER_STATE -#define YY_STRUCT_YY_BUFFER_STATE -struct yy_buffer_state - { - FILE *yy_input_file; - - char *yy_ch_buf; /* input buffer */ - char *yy_buf_pos; /* current position in input buffer */ - - /* Size of input buffer in bytes, not including room for EOB - * characters. - */ - int yy_buf_size; - - /* Number of characters read into yy_ch_buf, not including EOB - * characters. - */ - int yy_n_chars; - - /* Whether we "own" the buffer - i.e., we know we created it, - * and can realloc() it to grow it, and should free() it to - * delete it. - */ - int yy_is_our_buffer; - - /* Whether this is an "interactive" input source; if so, and - * if we're using stdio for input, then we want to use getc() - * instead of fread(), to make sure we stop fetching input after - * each newline. - */ - int yy_is_interactive; - - /* Whether we're considered to be at the beginning of a line. - * If so, '^' rules will be active on the next match, otherwise - * not. - */ - int yy_at_bol; - - int yy_bs_lineno; /**< The line count. */ - int yy_bs_column; /**< The column count. */ - - /* Whether to try to fill the input buffer when we reach the - * end of it. - */ - int yy_fill_buffer; - - int yy_buffer_status; - -#define YY_BUFFER_NEW 0 -#define YY_BUFFER_NORMAL 1 - /* When an EOF's been seen but there's still some text to process - * then we mark the buffer as YY_EOF_PENDING, to indicate that we - * shouldn't try reading from the input source any more. We might - * still have a bunch of tokens to match, though, because of - * possible backing-up. - * - * When we actually see the EOF, we change the status to "new" - * (via yyrestart()), so that the user can continue scanning by - * just pointing yyin at a new input file. - */ -#define YY_BUFFER_EOF_PENDING 2 - - }; -#endif /* !YY_STRUCT_YY_BUFFER_STATE */ - -/* Stack of input buffers. */ -static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ -static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ -static YY_BUFFER_STATE * yy_buffer_stack = NULL; /**< Stack as an array. */ - -/* We provide macros for accessing buffer states in case in the - * future we want to put the buffer states in a more general - * "scanner state". - * - * Returns the top of the stack, or NULL. - */ -#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ - ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ - : NULL) -/* Same as previous macro, but useful when we know that the buffer stack is not - * NULL or when we need an lvalue. For internal use only. - */ -#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] - -/* yy_hold_char holds the character lost when yytext is formed. */ -static char yy_hold_char; -static int yy_n_chars; /* number of characters read into yy_ch_buf */ -int yyleng; - -/* Points to current character in buffer. */ -static char *yy_c_buf_p = NULL; -static int yy_init = 0; /* whether we need to initialize */ -static int yy_start = 0; /* start state number */ - -/* Flag which is used to allow yywrap()'s to do buffer switches - * instead of setting up a fresh yyin. A bit of a hack ... - */ -static int yy_did_buffer_switch_on_eof; - -void yyrestart ( FILE *input_file ); -void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer ); -YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size ); -void yy_delete_buffer ( YY_BUFFER_STATE b ); -void yy_flush_buffer ( YY_BUFFER_STATE b ); -void yypush_buffer_state ( YY_BUFFER_STATE new_buffer ); -void yypop_buffer_state ( void ); - -static void yyensure_buffer_stack ( void ); -static void yy_load_buffer_state ( void ); -static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file ); -#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER ) - -YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size ); -YY_BUFFER_STATE yy_scan_string ( const char *yy_str ); -YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len ); - -void *yyalloc ( yy_size_t ); -void *yyrealloc ( void *, yy_size_t ); -void yyfree ( void * ); - -#define yy_new_buffer yy_create_buffer -#define yy_set_interactive(is_interactive) \ - { \ - if ( ! YY_CURRENT_BUFFER ){ \ - yyensure_buffer_stack (); \ - YY_CURRENT_BUFFER_LVALUE = \ - yy_create_buffer( yyin, YY_BUF_SIZE ); \ - } \ - YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ - } -#define yy_set_bol(at_bol) \ - { \ - if ( ! YY_CURRENT_BUFFER ){\ - yyensure_buffer_stack (); \ - YY_CURRENT_BUFFER_LVALUE = \ - yy_create_buffer( yyin, YY_BUF_SIZE ); \ - } \ - YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ - } -#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) - -/* Begin user sect3 */ -typedef flex_uint8_t YY_CHAR; - -FILE *yyin = NULL, *yyout = NULL; - -typedef int yy_state_type; - -extern int yylineno; -int yylineno = 1; - -extern char *yytext; -#ifdef yytext_ptr -#undef yytext_ptr -#endif -#define yytext_ptr yytext - -static yy_state_type yy_get_previous_state ( void ); -static yy_state_type yy_try_NUL_trans ( yy_state_type current_state ); -static int yy_get_next_buffer ( void ); -static void yynoreturn yy_fatal_error ( const char* msg ); - -/* Done after the current pattern has been matched and before the - * corresponding action - sets up yytext. - */ -#define YY_DO_BEFORE_ACTION \ - (yytext_ptr) = yy_bp; \ - yyleng = (int) (yy_cp - yy_bp); \ - (yy_hold_char) = *yy_cp; \ - *yy_cp = '\0'; \ - (yy_c_buf_p) = yy_cp; -#define YY_NUM_RULES 17 -#define YY_END_OF_BUFFER 18 -/* This struct is not used in this scanner, - but its presence is necessary. */ -struct yy_trans_info - { - flex_int32_t yy_verify; - flex_int32_t yy_nxt; - }; -static const flex_int16_t yy_accept[75] = - { 0, - 0, 0, 18, 16, 2, 1, 16, 14, 14, 14, - 14, 14, 14, 14, 14, 14, 2, 3, 4, 0, - 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, - 14, 0, 3, 3, 3, 4, 4, 14, 14, 14, - 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, - 14, 8, 14, 6, 14, 7, 14, 9, 5, 14, - 14, 14, 14, 14, 14, 14, 13, 14, 12, 14, - 14, 11, 10, 0 - } ; - -static const YY_CHAR yy_ec[256] = - { 0, - 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 2, 1, 4, 5, 1, 6, 1, 1, 1, - 1, 7, 1, 6, 6, 6, 6, 6, 6, 6, - 6, 6, 6, 6, 6, 6, 6, 1, 1, 1, - 1, 1, 1, 6, 6, 6, 6, 6, 6, 6, - 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, - 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, - 1, 6, 1, 1, 6, 1, 8, 6, 9, 10, - - 11, 12, 13, 6, 14, 6, 15, 16, 17, 18, - 19, 20, 6, 21, 22, 23, 24, 6, 6, 6, - 25, 6, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1 - } ; - -static const YY_CHAR yy_meta[26] = - { 0, - 1, 1, 2, 1, 1, 3, 1, 3, 3, 3, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3, 3 - } ; - -static const flex_int16_t yy_base[79] = - { 0, - 0, 24, 95, 96, 96, 96, 90, 0, 83, 81, - 70, 71, 81, 77, 62, 19, 30, 84, 83, 80, - 96, 0, 66, 70, 62, 56, 62, 57, 55, 54, - 58, 31, 72, 71, 70, 69, 68, 55, 60, 43, - 48, 54, 47, 40, 47, 41, 42, 35, 38, 34, - 34, 0, 44, 0, 38, 0, 37, 0, 0, 32, - 34, 42, 26, 40, 37, 23, 0, 35, 0, 30, - 23, 0, 0, 96, 36, 25, 39, 42 - } ; - -static const flex_int16_t yy_def[79] = - { 0, - 74, 1, 74, 74, 74, 74, 75, 76, 76, 76, - 76, 76, 76, 76, 76, 76, 74, 77, 78, 75, - 74, 76, 76, 76, 76, 76, 76, 76, 76, 76, - 76, 74, 77, 77, 77, 78, 78, 76, 76, 76, - 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, - 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, - 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, - 76, 76, 76, 0, 74, 74, 74, 74 - } ; - -static const flex_int16_t yy_nxt[122] = - { 0, - 4, 5, 6, 7, 4, 8, 4, 9, 8, 10, - 8, 8, 11, 8, 8, 8, 12, 13, 8, 14, - 8, 15, 16, 8, 8, 17, 30, 22, 18, 31, - 19, 32, 32, 73, 33, 33, 20, 20, 20, 34, - 72, 34, 36, 71, 36, 70, 69, 68, 67, 66, - 65, 64, 63, 62, 61, 60, 59, 58, 57, 56, - 55, 54, 53, 52, 51, 50, 49, 48, 47, 37, - 37, 35, 35, 35, 46, 45, 44, 43, 42, 41, - 40, 39, 38, 21, 37, 35, 29, 28, 27, 26, - 25, 24, 23, 21, 74, 3, 74, 74, 74, 74, - - 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, - 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, - 74 - } ; - -static const flex_int16_t yy_chk[122] = - { 0, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 2, 16, 76, 2, 16, - 2, 17, 32, 71, 17, 32, 75, 75, 75, 77, - 70, 77, 78, 68, 78, 66, 65, 64, 63, 62, - 61, 60, 57, 55, 53, 51, 50, 49, 48, 47, - 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, - 36, 35, 34, 33, 31, 30, 29, 28, 27, 26, - 25, 24, 23, 20, 19, 18, 15, 14, 13, 12, - 11, 10, 9, 7, 3, 74, 74, 74, 74, 74, - - 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, - 74, 74, 74, 74, 74, 74, 74, 74, 74, 74, - 74 - } ; - -static yy_state_type yy_last_accepting_state; -static char *yy_last_accepting_cpos; - -extern int yy_flex_debug; -int yy_flex_debug = 0; - -/* The intent behind this definition is that it'll catch - * any uses of REJECT which flex missed. - */ -#define REJECT reject_used_but_not_detected -#define yymore() yymore_used_but_not_detected -#define YY_MORE_ADJ 0 -#define YY_RESTORE_YY_MORE_OFFSET -char *yytext; -#line 1 "lex.l" -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright IBM Corporation. 2007 - * - * Authors: Balbir Singh - */ -#line 9 "lex.l" -#include -#include -#include -#include "parse.h" -#pragma GCC diagnostic ignored "-Wunused-function" - -int line_no = 1; -jmp_buf parser_error_env; - -#define YY_FATAL_ERROR(msg) \ - do { \ - fprintf(stderr, "%s\n", msg); \ - longjmp(parser_error_env, 1); \ - } while(0); -#line 510 "lex.c" -#define YY_NO_INPUT 1 -#line 512 "lex.c" - -#define INITIAL 0 - -#ifndef YY_NO_UNISTD_H -/* Special case for "unistd.h", since it is non-ANSI. We include it way - * down here because we want the user's section 1 to have been scanned first. - * The user has a chance to override it with an option. - */ -#include -#endif - -#ifndef YY_EXTRA_TYPE -#define YY_EXTRA_TYPE void * -#endif - -static int yy_init_globals ( void ); - -/* Accessor methods to globals. - These are made visible to non-reentrant scanners for convenience. */ - -int yylex_destroy ( void ); - -int yyget_debug ( void ); - -void yyset_debug ( int debug_flag ); - -YY_EXTRA_TYPE yyget_extra ( void ); - -void yyset_extra ( YY_EXTRA_TYPE user_defined ); - -FILE *yyget_in ( void ); - -void yyset_in ( FILE * _in_str ); - -FILE *yyget_out ( void ); - -void yyset_out ( FILE * _out_str ); - - int yyget_leng ( void ); - -char *yyget_text ( void ); - -int yyget_lineno ( void ); - -void yyset_lineno ( int _line_number ); - -/* Macros after this point can all be overridden by user definitions in - * section 1. - */ - -#ifndef YY_SKIP_YYWRAP -#ifdef __cplusplus -extern "C" int yywrap ( void ); -#else -extern int yywrap ( void ); -#endif -#endif - -#ifndef YY_NO_UNPUT - -#endif - -#ifndef yytext_ptr -static void yy_flex_strncpy ( char *, const char *, int ); -#endif - -#ifdef YY_NEED_STRLEN -static int yy_flex_strlen ( const char * ); -#endif - -#ifndef YY_NO_INPUT -#ifdef __cplusplus -static int yyinput ( void ); -#else -static int input ( void ); -#endif - -#endif - -/* Amount of stuff to slurp up with each read. */ -#ifndef YY_READ_BUF_SIZE -#ifdef __ia64__ -/* On IA-64, the buffer size is 16k, not 8k */ -#define YY_READ_BUF_SIZE 16384 -#else -#define YY_READ_BUF_SIZE 8192 -#endif /* __ia64__ */ -#endif - -/* Copy whatever the last rule matched to the standard output. */ -#ifndef ECHO -/* This used to be an fputs(), but since the string might contain NUL's, - * we now use fwrite(). - */ -#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0) -#endif - -/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, - * is returned in "result". - */ -#ifndef YY_INPUT -#define YY_INPUT(buf,result,max_size) \ - if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ - { \ - int c = '*'; \ - int n; \ - for ( n = 0; n < max_size && \ - (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ - buf[n] = (char) c; \ - if ( c == '\n' ) \ - buf[n++] = (char) c; \ - if ( c == EOF && ferror( yyin ) ) \ - YY_FATAL_ERROR( "input in flex scanner failed" ); \ - result = n; \ - } \ - else \ - { \ - errno=0; \ - while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \ - { \ - if( errno != EINTR) \ - { \ - YY_FATAL_ERROR( "input in flex scanner failed" ); \ - break; \ - } \ - errno=0; \ - clearerr(yyin); \ - } \ - }\ -\ - -#endif - -/* No semi-colon after return; correct usage is to write "yyterminate();" - - * we don't want an extra ';' after the "return" because that will cause - * some compilers to complain about unreachable statements. - */ -#ifndef yyterminate -#define yyterminate() return YY_NULL -#endif - -/* Number of entries by which start-condition stack grows. */ -#ifndef YY_START_STACK_INCR -#define YY_START_STACK_INCR 25 -#endif - -/* Report a fatal error. */ -#ifndef YY_FATAL_ERROR -#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) -#endif - -/* end tables serialization structures and prototypes */ - -/* Default declaration of generated scanner - a define so the user can - * easily add parameters. - */ -#ifndef YY_DECL -#define YY_DECL_IS_OURS 1 - -extern int yylex (void); - -#define YY_DECL int yylex (void) -#endif /* !YY_DECL */ - -/* Code executed at the beginning of each rule, after yytext and yyleng - * have been set up. - */ -#ifndef YY_USER_ACTION -#define YY_USER_ACTION -#endif - -/* Code executed at the end of each rule. */ -#ifndef YY_BREAK -#define YY_BREAK /*LINTED*/break; -#endif - -#define YY_RULE_SETUP \ - if ( yyleng > 0 ) \ - YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \ - (yytext[yyleng - 1] == '\n'); \ - YY_USER_ACTION - -/** The main scanner function which does all the work. - */ -YY_DECL -{ - yy_state_type yy_current_state; - char *yy_cp, *yy_bp; - int yy_act; - - if ( !(yy_init) ) - { - (yy_init) = 1; - -#ifdef YY_USER_INIT - YY_USER_INIT; -#endif - - if ( ! (yy_start) ) - (yy_start) = 1; /* first start state */ - - if ( ! yyin ) - yyin = stdin; - - if ( ! yyout ) - yyout = stdout; - - if ( ! YY_CURRENT_BUFFER ) { - yyensure_buffer_stack (); - YY_CURRENT_BUFFER_LVALUE = - yy_create_buffer( yyin, YY_BUF_SIZE ); - } - - yy_load_buffer_state( ); - } - - { -#line 27 "lex.l" - -#line 732 "lex.c" - - while ( /*CONSTCOND*/1 ) /* loops until end-of-file is reached */ - { - yy_cp = (yy_c_buf_p); - - /* Support of yytext. */ - *yy_cp = (yy_hold_char); - - /* yy_bp points to the position in yy_ch_buf of the start of - * the current run. - */ - yy_bp = yy_cp; - - yy_current_state = (yy_start); - yy_current_state += YY_AT_BOL(); -yy_match: - do - { - YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ; - if ( yy_accept[yy_current_state] ) - { - (yy_last_accepting_state) = yy_current_state; - (yy_last_accepting_cpos) = yy_cp; - } - while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) - { - yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 75 ) - yy_c = yy_meta[yy_c]; - } - yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; - ++yy_cp; - } - while ( yy_base[yy_current_state] != 96 ); - -yy_find_action: - yy_act = yy_accept[yy_current_state]; - if ( yy_act == 0 ) - { /* have to back up */ - yy_cp = (yy_last_accepting_cpos); - yy_current_state = (yy_last_accepting_state); - yy_act = yy_accept[yy_current_state]; - } - - YY_DO_BEFORE_ACTION; - -do_action: /* This label is used only to access EOF actions. */ - - switch ( yy_act ) - { /* beginning of action switch */ - case 0: /* must back up */ - /* undo the effects of YY_DO_BEFORE_ACTION */ - *yy_cp = (yy_hold_char); - yy_cp = (yy_last_accepting_cpos); - yy_current_state = (yy_last_accepting_state); - goto yy_find_action; - -case 1: -/* rule 1 can match eol */ -YY_RULE_SETUP -#line 28 "lex.l" -{line_no++;} - YY_BREAK -case 2: -YY_RULE_SETUP -#line 29 "lex.l" -{/* DO NOTHING */} - YY_BREAK -case 3: -YY_RULE_SETUP -#line 30 "lex.l" -{/* Comments */} - YY_BREAK -case 4: -YY_RULE_SETUP -#line 31 "lex.l" -{/* Comments */} - YY_BREAK -case 5: -YY_RULE_SETUP -#line 32 "lex.l" -{return MOUNT;} - YY_BREAK -case 6: -YY_RULE_SETUP -#line 33 "lex.l" -{return TASK;} - YY_BREAK -case 7: -YY_RULE_SETUP -#line 34 "lex.l" -{return ADMIN;} - YY_BREAK -case 8: -YY_RULE_SETUP -#line 35 "lex.l" -{return PERM;} - YY_BREAK -case 9: -YY_RULE_SETUP -#line 36 "lex.l" -{return GROUP;} - YY_BREAK -case 10: -YY_RULE_SETUP -#line 37 "lex.l" -{return NAMESPACE;} - YY_BREAK -case 11: -YY_RULE_SETUP -#line 38 "lex.l" -{return TEMPLATE;} - YY_BREAK -case 12: -YY_RULE_SETUP -#line 39 "lex.l" -{return SYSTEMD;} - YY_BREAK -case 13: -YY_RULE_SETUP -#line 40 "lex.l" -{yylval.name = strdup(yytext); return DEFAULT;} - YY_BREAK -case 14: -YY_RULE_SETUP -#line 41 "lex.l" -{yylval.name = strdup(yytext); return ID;} - YY_BREAK -case 15: -/* rule 15 can match eol */ -YY_RULE_SETUP -#line 42 "lex.l" -{yylval.name = strdup(yytext+1); yylval.name[strlen(yylval.name)-1] = '\0'; return ID; } - YY_BREAK -case 16: -YY_RULE_SETUP -#line 43 "lex.l" -{return yytext[0];} - YY_BREAK -case 17: -YY_RULE_SETUP -#line 44 "lex.l" -ECHO; - YY_BREAK -#line 877 "lex.c" -case YY_STATE_EOF(INITIAL): - yyterminate(); - - case YY_END_OF_BUFFER: - { - /* Amount of text matched not including the EOB char. */ - int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; - - /* Undo the effects of YY_DO_BEFORE_ACTION. */ - *yy_cp = (yy_hold_char); - YY_RESTORE_YY_MORE_OFFSET - - if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) - { - /* We're scanning a new file or input source. It's - * possible that this happened because the user - * just pointed yyin at a new source and called - * yylex(). If so, then we have to assure - * consistency between YY_CURRENT_BUFFER and our - * globals. Here is the right place to do so, because - * this is the first action (other than possibly a - * back-up) that will match for the new input source. - */ - (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; - YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin; - YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; - } - - /* Note that here we test for yy_c_buf_p "<=" to the position - * of the first EOB in the buffer, since yy_c_buf_p will - * already have been incremented past the NUL character - * (since all states make transitions on EOB to the - * end-of-buffer state). Contrast this with the test - * in input(). - */ - if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) - { /* This was really a NUL. */ - yy_state_type yy_next_state; - - (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; - - yy_current_state = yy_get_previous_state( ); - - /* Okay, we're now positioned to make the NUL - * transition. We couldn't have - * yy_get_previous_state() go ahead and do it - * for us because it doesn't know how to deal - * with the possibility of jamming (and we don't - * want to build jamming into it because then it - * will run more slowly). - */ - - yy_next_state = yy_try_NUL_trans( yy_current_state ); - - yy_bp = (yytext_ptr) + YY_MORE_ADJ; - - if ( yy_next_state ) - { - /* Consume the NUL. */ - yy_cp = ++(yy_c_buf_p); - yy_current_state = yy_next_state; - goto yy_match; - } - - else - { - yy_cp = (yy_c_buf_p); - goto yy_find_action; - } - } - - else switch ( yy_get_next_buffer( ) ) - { - case EOB_ACT_END_OF_FILE: - { - (yy_did_buffer_switch_on_eof) = 0; - - if ( yywrap( ) ) - { - /* Note: because we've taken care in - * yy_get_next_buffer() to have set up - * yytext, we can now set up - * yy_c_buf_p so that if some total - * hoser (like flex itself) wants to - * call the scanner after we return the - * YY_NULL, it'll still work - another - * YY_NULL will get returned. - */ - (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; - - yy_act = YY_STATE_EOF(YY_START); - goto do_action; - } - - else - { - if ( ! (yy_did_buffer_switch_on_eof) ) - YY_NEW_FILE; - } - break; - } - - case EOB_ACT_CONTINUE_SCAN: - (yy_c_buf_p) = - (yytext_ptr) + yy_amount_of_matched_text; - - yy_current_state = yy_get_previous_state( ); - - yy_cp = (yy_c_buf_p); - yy_bp = (yytext_ptr) + YY_MORE_ADJ; - goto yy_match; - - case EOB_ACT_LAST_MATCH: - (yy_c_buf_p) = - &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; - - yy_current_state = yy_get_previous_state( ); - - yy_cp = (yy_c_buf_p); - yy_bp = (yytext_ptr) + YY_MORE_ADJ; - goto yy_find_action; - } - break; - } - - default: - YY_FATAL_ERROR( - "fatal flex scanner internal error--no action found" ); - } /* end of action switch */ - } /* end of scanning one token */ - } /* end of user's declarations */ -} /* end of yylex */ - -/* yy_get_next_buffer - try to read in a new buffer - * - * Returns a code representing an action: - * EOB_ACT_LAST_MATCH - - * EOB_ACT_CONTINUE_SCAN - continue scanning from current position - * EOB_ACT_END_OF_FILE - end of file - */ -static int yy_get_next_buffer (void) -{ - char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; - char *source = (yytext_ptr); - int number_to_move, i; - int ret_val; - - if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) - YY_FATAL_ERROR( - "fatal flex scanner internal error--end of buffer missed" ); - - if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) - { /* Don't try to fill the buffer, so this is an EOF. */ - if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) - { - /* We matched a single character, the EOB, so - * treat this as a final EOF. - */ - return EOB_ACT_END_OF_FILE; - } - - else - { - /* We matched some text prior to the EOB, first - * process it. - */ - return EOB_ACT_LAST_MATCH; - } - } - - /* Try to read more data. */ - - /* First move last chars to start of buffer. */ - number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr) - 1); - - for ( i = 0; i < number_to_move; ++i ) - *(dest++) = *(source++); - - if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) - /* don't do the read, it's not guaranteed to return an EOF, - * just force an EOF - */ - YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; - - else - { - int num_to_read = - YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; - - while ( num_to_read <= 0 ) - { /* Not enough room in the buffer - grow it. */ - - /* just a shorter name for the current buffer */ - YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE; - - int yy_c_buf_p_offset = - (int) ((yy_c_buf_p) - b->yy_ch_buf); - - if ( b->yy_is_our_buffer ) - { - int new_size = b->yy_buf_size * 2; - - if ( new_size <= 0 ) - b->yy_buf_size += b->yy_buf_size / 8; - else - b->yy_buf_size *= 2; - - b->yy_ch_buf = (char *) - /* Include room in for 2 EOB chars. */ - yyrealloc( (void *) b->yy_ch_buf, - (yy_size_t) (b->yy_buf_size + 2) ); - } - else - /* Can't grow it, we don't own it. */ - b->yy_ch_buf = NULL; - - if ( ! b->yy_ch_buf ) - YY_FATAL_ERROR( - "fatal error - scanner input buffer overflow" ); - - (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; - - num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - - number_to_move - 1; - - } - - if ( num_to_read > YY_READ_BUF_SIZE ) - num_to_read = YY_READ_BUF_SIZE; - - /* Read in more data. */ - YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), - (yy_n_chars), num_to_read ); - - YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); - } - - if ( (yy_n_chars) == 0 ) - { - if ( number_to_move == YY_MORE_ADJ ) - { - ret_val = EOB_ACT_END_OF_FILE; - yyrestart( yyin ); - } - - else - { - ret_val = EOB_ACT_LAST_MATCH; - YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = - YY_BUFFER_EOF_PENDING; - } - } - - else - ret_val = EOB_ACT_CONTINUE_SCAN; - - if (((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { - /* Extend the array by 50%, plus the number we really need. */ - int new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc( - (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size ); - if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) - YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); - /* "- 2" to take care of EOB's */ - YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2); - } - - (yy_n_chars) += number_to_move; - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; - - (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; - - return ret_val; -} - -/* yy_get_previous_state - get the state just before the EOB char was reached */ - - static yy_state_type yy_get_previous_state (void) -{ - yy_state_type yy_current_state; - char *yy_cp; - - yy_current_state = (yy_start); - yy_current_state += YY_AT_BOL(); - - for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) - { - YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); - if ( yy_accept[yy_current_state] ) - { - (yy_last_accepting_state) = yy_current_state; - (yy_last_accepting_cpos) = yy_cp; - } - while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) - { - yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 75 ) - yy_c = yy_meta[yy_c]; - } - yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; - } - - return yy_current_state; -} - -/* yy_try_NUL_trans - try to make a transition on the NUL character - * - * synopsis - * next_state = yy_try_NUL_trans( current_state ); - */ - static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) -{ - int yy_is_jam; - char *yy_cp = (yy_c_buf_p); - - YY_CHAR yy_c = 1; - if ( yy_accept[yy_current_state] ) - { - (yy_last_accepting_state) = yy_current_state; - (yy_last_accepting_cpos) = yy_cp; - } - while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) - { - yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 75 ) - yy_c = yy_meta[yy_c]; - } - yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c]; - yy_is_jam = (yy_current_state == 74); - - return yy_is_jam ? 0 : yy_current_state; -} - -#ifndef YY_NO_UNPUT - -#endif - -#ifndef YY_NO_INPUT -#ifdef __cplusplus - static int yyinput (void) -#else - static int input (void) -#endif - -{ - int c; - - *(yy_c_buf_p) = (yy_hold_char); - - if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) - { - /* yy_c_buf_p now points to the character we want to return. - * If this occurs *before* the EOB characters, then it's a - * valid NUL; if not, then we've hit the end of the buffer. - */ - if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) - /* This was really a NUL. */ - *(yy_c_buf_p) = '\0'; - - else - { /* need more input */ - int offset = (int) ((yy_c_buf_p) - (yytext_ptr)); - ++(yy_c_buf_p); - - switch ( yy_get_next_buffer( ) ) - { - case EOB_ACT_LAST_MATCH: - /* This happens because yy_g_n_b() - * sees that we've accumulated a - * token and flags that we need to - * try matching the token before - * proceeding. But for input(), - * there's no matching to consider. - * So convert the EOB_ACT_LAST_MATCH - * to EOB_ACT_END_OF_FILE. - */ - - /* Reset buffer status. */ - yyrestart( yyin ); - - /*FALLTHROUGH*/ - - case EOB_ACT_END_OF_FILE: - { - if ( yywrap( ) ) - return 0; - - if ( ! (yy_did_buffer_switch_on_eof) ) - YY_NEW_FILE; -#ifdef __cplusplus - return yyinput(); -#else - return input(); -#endif - } - - case EOB_ACT_CONTINUE_SCAN: - (yy_c_buf_p) = (yytext_ptr) + offset; - break; - } - } - } - - c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ - *(yy_c_buf_p) = '\0'; /* preserve yytext */ - (yy_hold_char) = *++(yy_c_buf_p); - - YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n'); - - return c; -} -#endif /* ifndef YY_NO_INPUT */ - -/** Immediately switch to a different input stream. - * @param input_file A readable stream. - * - * @note This function does not reset the start condition to @c INITIAL . - */ - void yyrestart (FILE * input_file ) -{ - - if ( ! YY_CURRENT_BUFFER ){ - yyensure_buffer_stack (); - YY_CURRENT_BUFFER_LVALUE = - yy_create_buffer( yyin, YY_BUF_SIZE ); - } - - yy_init_buffer( YY_CURRENT_BUFFER, input_file ); - yy_load_buffer_state( ); -} - -/** Switch to a different input buffer. - * @param new_buffer The new input buffer. - * - */ - void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) -{ - - /* TODO. We should be able to replace this entire function body - * with - * yypop_buffer_state(); - * yypush_buffer_state(new_buffer); - */ - yyensure_buffer_stack (); - if ( YY_CURRENT_BUFFER == new_buffer ) - return; - - if ( YY_CURRENT_BUFFER ) - { - /* Flush out information for old buffer. */ - *(yy_c_buf_p) = (yy_hold_char); - YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); - YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); - } - - YY_CURRENT_BUFFER_LVALUE = new_buffer; - yy_load_buffer_state( ); - - /* We don't actually know whether we did this switch during - * EOF (yywrap()) processing, but the only time this flag - * is looked at is after yywrap() is called, so it's safe - * to go ahead and always set it. - */ - (yy_did_buffer_switch_on_eof) = 1; -} - -static void yy_load_buffer_state (void) -{ - (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; - (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; - yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; - (yy_hold_char) = *(yy_c_buf_p); -} - -/** Allocate and initialize an input buffer state. - * @param file A readable stream. - * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. - * - * @return the allocated buffer state. - */ - YY_BUFFER_STATE yy_create_buffer (FILE * file, int size ) -{ - YY_BUFFER_STATE b; - - b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) ); - if ( ! b ) - YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); - - b->yy_buf_size = size; - - /* yy_ch_buf has to be 2 characters longer than the size given because - * we need to put in 2 end-of-buffer characters. - */ - b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) ); - if ( ! b->yy_ch_buf ) - YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); - - b->yy_is_our_buffer = 1; - - yy_init_buffer( b, file ); - - return b; -} - -/** Destroy the buffer. - * @param b a buffer created with yy_create_buffer() - * - */ - void yy_delete_buffer (YY_BUFFER_STATE b ) -{ - - if ( ! b ) - return; - - if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ - YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; - - if ( b->yy_is_our_buffer ) - yyfree( (void *) b->yy_ch_buf ); - - yyfree( (void *) b ); -} - -/* Initializes or reinitializes a buffer. - * This function is sometimes called more than once on the same buffer, - * such as during a yyrestart() or at EOF. - */ - static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) - -{ - int oerrno = errno; - - yy_flush_buffer( b ); - - b->yy_input_file = file; - b->yy_fill_buffer = 1; - - /* If b is the current buffer, then yy_init_buffer was _probably_ - * called from yyrestart() or through yy_get_next_buffer. - * In that case, we don't want to reset the lineno or column. - */ - if (b != YY_CURRENT_BUFFER){ - b->yy_bs_lineno = 1; - b->yy_bs_column = 0; - } - - b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0; - - errno = oerrno; -} - -/** Discard all buffered characters. On the next scan, YY_INPUT will be called. - * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. - * - */ - void yy_flush_buffer (YY_BUFFER_STATE b ) -{ - if ( ! b ) - return; - - b->yy_n_chars = 0; - - /* We always need two end-of-buffer characters. The first causes - * a transition to the end-of-buffer state. The second causes - * a jam in that state. - */ - b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; - b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; - - b->yy_buf_pos = &b->yy_ch_buf[0]; - - b->yy_at_bol = 1; - b->yy_buffer_status = YY_BUFFER_NEW; - - if ( b == YY_CURRENT_BUFFER ) - yy_load_buffer_state( ); -} - -/** Pushes the new state onto the stack. The new state becomes - * the current state. This function will allocate the stack - * if necessary. - * @param new_buffer The new state. - * - */ -void yypush_buffer_state (YY_BUFFER_STATE new_buffer ) -{ - if (new_buffer == NULL) - return; - - yyensure_buffer_stack(); - - /* This block is copied from yy_switch_to_buffer. */ - if ( YY_CURRENT_BUFFER ) - { - /* Flush out information for old buffer. */ - *(yy_c_buf_p) = (yy_hold_char); - YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); - YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); - } - - /* Only push if top exists. Otherwise, replace top. */ - if (YY_CURRENT_BUFFER) - (yy_buffer_stack_top)++; - YY_CURRENT_BUFFER_LVALUE = new_buffer; - - /* copied from yy_switch_to_buffer. */ - yy_load_buffer_state( ); - (yy_did_buffer_switch_on_eof) = 1; -} - -/** Removes and deletes the top of the stack, if present. - * The next element becomes the new top. - * - */ -void yypop_buffer_state (void) -{ - if (!YY_CURRENT_BUFFER) - return; - - yy_delete_buffer(YY_CURRENT_BUFFER ); - YY_CURRENT_BUFFER_LVALUE = NULL; - if ((yy_buffer_stack_top) > 0) - --(yy_buffer_stack_top); - - if (YY_CURRENT_BUFFER) { - yy_load_buffer_state( ); - (yy_did_buffer_switch_on_eof) = 1; - } -} - -/* Allocates the stack if it does not exist. - * Guarantees space for at least one push. - */ -static void yyensure_buffer_stack (void) -{ - yy_size_t num_to_alloc; - - if (!(yy_buffer_stack)) { - - /* First allocation is just for 2 elements, since we don't know if this - * scanner will even need a stack. We use 2 instead of 1 to avoid an - * immediate realloc on the next call. - */ - num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */ - (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc - (num_to_alloc * sizeof(struct yy_buffer_state*) - ); - if ( ! (yy_buffer_stack) ) - YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); - - memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); - - (yy_buffer_stack_max) = num_to_alloc; - (yy_buffer_stack_top) = 0; - return; - } - - if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ - - /* Increase the buffer to prepare for a possible push. */ - yy_size_t grow_size = 8 /* arbitrary grow size */; - - num_to_alloc = (yy_buffer_stack_max) + grow_size; - (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc - ((yy_buffer_stack), - num_to_alloc * sizeof(struct yy_buffer_state*) - ); - if ( ! (yy_buffer_stack) ) - YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); - - /* zero only the new slots.*/ - memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); - (yy_buffer_stack_max) = num_to_alloc; - } -} - -/** Setup the input buffer state to scan directly from a user-specified character buffer. - * @param base the character buffer - * @param size the size in bytes of the character buffer - * - * @return the newly allocated buffer state object. - */ -YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size ) -{ - YY_BUFFER_STATE b; - - if ( size < 2 || - base[size-2] != YY_END_OF_BUFFER_CHAR || - base[size-1] != YY_END_OF_BUFFER_CHAR ) - /* They forgot to leave room for the EOB's. */ - return NULL; - - b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) ); - if ( ! b ) - YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" ); - - b->yy_buf_size = (int) (size - 2); /* "- 2" to take care of EOB's */ - b->yy_buf_pos = b->yy_ch_buf = base; - b->yy_is_our_buffer = 0; - b->yy_input_file = NULL; - b->yy_n_chars = b->yy_buf_size; - b->yy_is_interactive = 0; - b->yy_at_bol = 1; - b->yy_fill_buffer = 0; - b->yy_buffer_status = YY_BUFFER_NEW; - - yy_switch_to_buffer( b ); - - return b; -} - -/** Setup the input buffer state to scan a string. The next call to yylex() will - * scan from a @e copy of @a str. - * @param yystr a NUL-terminated string to scan - * - * @return the newly allocated buffer state object. - * @note If you want to scan bytes that may contain NUL values, then use - * yy_scan_bytes() instead. - */ -YY_BUFFER_STATE yy_scan_string (const char * yystr ) -{ - - return yy_scan_bytes( yystr, (int) strlen(yystr) ); -} - -/** Setup the input buffer state to scan the given bytes. The next call to yylex() will - * scan from a @e copy of @a bytes. - * @param yybytes the byte buffer to scan - * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. - * - * @return the newly allocated buffer state object. - */ -YY_BUFFER_STATE yy_scan_bytes (const char * yybytes, int _yybytes_len ) -{ - YY_BUFFER_STATE b; - char *buf; - yy_size_t n; - int i; - - /* Get memory for full buffer, including space for trailing EOB's. */ - n = (yy_size_t) (_yybytes_len + 2); - buf = (char *) yyalloc( n ); - if ( ! buf ) - YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" ); - - for ( i = 0; i < _yybytes_len; ++i ) - buf[i] = yybytes[i]; - - buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; - - b = yy_scan_buffer( buf, n ); - if ( ! b ) - YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" ); - - /* It's okay to grow etc. this buffer, and we should throw it - * away when we're done. - */ - b->yy_is_our_buffer = 1; - - return b; -} - -#ifndef YY_EXIT_FAILURE -#define YY_EXIT_FAILURE 2 -#endif - -static void yynoreturn yy_fatal_error (const char* msg ) -{ - fprintf( stderr, "%s\n", msg ); - exit( YY_EXIT_FAILURE ); -} - -/* Redefine yyless() so it works in section 3 code. */ - -#undef yyless -#define yyless(n) \ - do \ - { \ - /* Undo effects of setting up yytext. */ \ - int yyless_macro_arg = (n); \ - YY_LESS_LINENO(yyless_macro_arg);\ - yytext[yyleng] = (yy_hold_char); \ - (yy_c_buf_p) = yytext + yyless_macro_arg; \ - (yy_hold_char) = *(yy_c_buf_p); \ - *(yy_c_buf_p) = '\0'; \ - yyleng = yyless_macro_arg; \ - } \ - while ( 0 ) - -/* Accessor methods (get/set functions) to struct members. */ - -/** Get the current line number. - * - */ -int yyget_lineno (void) -{ - - return yylineno; -} - -/** Get the input stream. - * - */ -FILE *yyget_in (void) -{ - return yyin; -} - -/** Get the output stream. - * - */ -FILE *yyget_out (void) -{ - return yyout; -} - -/** Get the length of the current token. - * - */ -int yyget_leng (void) -{ - return yyleng; -} - -/** Get the current token. - * - */ - -char *yyget_text (void) -{ - return yytext; -} - -/** Set the current line number. - * @param _line_number line number - * - */ -void yyset_lineno (int _line_number ) -{ - - yylineno = _line_number; -} - -/** Set the input stream. This does not discard the current - * input buffer. - * @param _in_str A readable stream. - * - * @see yy_switch_to_buffer - */ -void yyset_in (FILE * _in_str ) -{ - yyin = _in_str ; -} - -void yyset_out (FILE * _out_str ) -{ - yyout = _out_str ; -} - -int yyget_debug (void) -{ - return yy_flex_debug; -} - -void yyset_debug (int _bdebug ) -{ - yy_flex_debug = _bdebug ; -} - -static int yy_init_globals (void) -{ - /* Initialization is the same as for the non-reentrant scanner. - * This function is called from yylex_destroy(), so don't allocate here. - */ - - (yy_buffer_stack) = NULL; - (yy_buffer_stack_top) = 0; - (yy_buffer_stack_max) = 0; - (yy_c_buf_p) = NULL; - (yy_init) = 0; - (yy_start) = 0; - -/* Defined in main.c */ -#ifdef YY_STDINIT - yyin = stdin; - yyout = stdout; -#else - yyin = NULL; - yyout = NULL; -#endif - - /* For future reference: Set errno on error, since we are called by - * yylex_init() - */ - return 0; -} - -/* yylex_destroy is for both reentrant and non-reentrant scanners. */ -int yylex_destroy (void) -{ - - /* Pop the buffer stack, destroying each element. */ - while(YY_CURRENT_BUFFER){ - yy_delete_buffer( YY_CURRENT_BUFFER ); - YY_CURRENT_BUFFER_LVALUE = NULL; - yypop_buffer_state(); - } - - /* Destroy the stack itself. */ - yyfree((yy_buffer_stack) ); - (yy_buffer_stack) = NULL; - - /* Reset the globals. This is important in a non-reentrant scanner so the next time - * yylex() is called, initialization will occur. */ - yy_init_globals( ); - - return 0; -} - -/* - * Internal utility routines. - */ - -#ifndef yytext_ptr -static void yy_flex_strncpy (char* s1, const char * s2, int n ) -{ - - int i; - for ( i = 0; i < n; ++i ) - s1[i] = s2[i]; -} -#endif - -#ifdef YY_NEED_STRLEN -static int yy_flex_strlen (const char * s ) -{ - int n; - for ( n = 0; s[n]; ++n ) - ; - - return n; -} -#endif - -void *yyalloc (yy_size_t size ) -{ - return malloc(size); -} - -void *yyrealloc (void * ptr, yy_size_t size ) -{ - - /* The cast to (char *) in the following accommodates both - * implementations that use char* generic pointers, and those - * that use void* generic pointers. It works with the latter - * because both ANSI C and C++ allow castless assignment from - * any pointer type to void*, and deal with argument conversions - * as though doing an assignment. - */ - return realloc(ptr, size); -} - -void yyfree (void * ptr ) -{ - free( (char *) ptr ); /* see yyrealloc() for (char *) cast */ -} - -#define YYTABLES_NAME "yytables" - -#line 44 "lex.l" - - - diff --git a/lib/libcgroup-3.1.0/src/lex.l b/lib/libcgroup-3.1.0/src/lex.l deleted file mode 100644 index 5f680fc839c..00000000000 --- a/lib/libcgroup-3.1.0/src/lex.l +++ /dev/null @@ -1,45 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright IBM Corporation. 2007 - * - * Authors: Balbir Singh - */ - -%{ -#include -#include -#include -#include "parse.h" -#pragma GCC diagnostic ignored "-Wunused-function" - -int line_no = 1; -jmp_buf parser_error_env; - -#define YY_FATAL_ERROR(msg) \ - do { \ - fprintf(stderr, "%s\n", msg); \ - longjmp(parser_error_env, 1); \ - } while(0); -%} - -%option nounput noinput - -%% -\n {line_no++;} -[ \t] {/* DO NOTHING */} -^[ \t]*#.*[ \t]* {/* Comments */} -^\*.*[ \t]* {/* Comments */} -"mount" {return MOUNT;} -"task" {return TASK;} -"admin" {return ADMIN;} -"perm" {return PERM;} -"group" {return GROUP;} -"namespace" {return NAMESPACE;} -"template" {return TEMPLATE;} -"systemd" {return SYSTEMD;} -"default" {yylval.name = strdup(yytext); return DEFAULT;} -[a-zA-Z0-9_\-\/\.\,\%\@\\]+ {yylval.name = strdup(yytext); return ID;} -\"[^"]*\" {yylval.name = strdup(yytext+1); yylval.name[strlen(yylval.name)-1] = '\0'; return ID; } -. {return yytext[0];} -%% - diff --git a/lib/libcgroup-3.1.0/src/libcgroup-internal.h b/lib/libcgroup-3.1.0/src/libcgroup-internal.h deleted file mode 100644 index 1c423e1d7ba..00000000000 --- a/lib/libcgroup-3.1.0/src/libcgroup-internal.h +++ /dev/null @@ -1,427 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright IBM Corporation. 2008 - * - * Author: Dhaval Giani - */ - -#ifndef __LIBCG_INTERNAL - -#define __LIBCG_INTERNAL - -#ifdef __cplusplus -extern "C" { -#endif - -#include "config.h" - -#include - -#include -#include -#include -#include -#include -#include - -#include -#include - -#define MAX_MNT_ELEMENTS 16 /* Maximum number of mount points/controllers */ -#define MAX_GROUP_ELEMENTS 128 /* Estimated number of groups created */ - -#define CG_CONTROL_VALUE_MAX 4096 /* Maximum length of a value */ - -#define CG_NV_MAX 100 -#define CG_CONTROLLER_MAX 100 -#define CG_OPTIONS_MAX 100 - -/* - * Max number of mounted hierarchies. Event if one controller is mounted - * per hier, it can not exceed CG_CONTROLLER_MAX - */ -#define CG_HIER_MAX CG_CONTROLLER_MAX - -#define CONTROL_NAMELEN_MAX 32 /* Maximum length of a controller's name */ - -/* Definitions for the uid and gid members of a cgroup_rules */ -#define CGRULE_INVALID ((uid_t) -1) -#define CGRULE_WILD ((uid_t) -2) - -#define CGRULE_SUCCESS_STORE_PID "SUCCESS_STORE_PID" -#define CGRULE_OPTION_IGNORE "ignore" /* Definitions for the cgrules options field */ - -#define CGCONFIG_CONF_FILE "/etc/cgconfig.conf" -/* Minimum number of file in template file list for cgrulesengd */ -#define CGCONFIG_CONF_FILES_LIST_MINIMUM_SIZE 4 -#define CGCONFIG_CONF_DIR "/etc/cgconfig.d" - -#define CGRULES_CONF_FILE "/etc/cgrules.conf" -#define CGRULES_CONF_DIR "/etc/cgrules.d" -#define CGRULES_MAX_FIELDS_PER_LINE 3 - -#define CGROUP_BUFFER_LEN (5 * FILENAME_MAX) - -/* Maximum length of a key(:) in the daemon config file */ -#define CGROUP_RULE_MAXKEY (LOGIN_NAME_MAX + FILENAME_MAX + 1) - -/* Maximum length of a line in the daemon config file */ -#define CGROUP_RULE_MAXLINE (FILENAME_MAX + CGROUP_RULE_MAXKEY + CG_CONTROLLER_MAX + 3) - -#define CGROUP_FILE_PREFIX "cgroup" - -/* cgroup v2 files */ -#define CGV2_CONTROLLERS_FILE "cgroup.controllers" -#define CGV2_SUBTREE_CTRL_FILE "cgroup.subtree_control" - -/* maximum line length when reading the cgroup.controllers file */ -#define CGV2_CONTROLLERS_LL_MAX 100 - -#define cgroup_err(x...) cgroup_log(CGROUP_LOG_ERROR, "Error: " x) -#define cgroup_warn(x...) cgroup_log(CGROUP_LOG_WARNING, "Warning: " x) -#define cgroup_info(x...) cgroup_log(CGROUP_LOG_INFO, "Info: " x) -#define cgroup_dbg(x...) cgroup_log(CGROUP_LOG_DEBUG, x) -#define cgroup_cont(x...) cgroup_log(CGROUP_LOG_CONT, x) - -#define CGROUP_DEFAULT_LOGLEVEL CGROUP_LOG_ERROR - -#define max(x, y) ((y) < (x)?(x):(y)) -#define min(x, y) ((y) > (x)?(x):(y)) - -struct control_value { - char name[FILENAME_MAX]; - char value[CG_CONTROL_VALUE_MAX]; - - /* cgget uses this field for values that span multiple lines */ - char *multiline_value; - - /* - * The abstraction layer uses prev_name when there's an - * N->1 or 1->N relationship between cgroup v1 and v2 settings. - */ - char *prev_name; - - bool dirty; -}; - -struct cgroup_controller { - char name[CONTROL_NAMELEN_MAX]; - struct control_value *values[CG_NV_MAX]; - struct cgroup *cgroup; - int index; - enum cg_version_t version; -}; - -struct cgroup { - char name[FILENAME_MAX]; - struct cgroup_controller *controller[CG_CONTROLLER_MAX]; - int index; - uid_t tasks_uid; - gid_t tasks_gid; - mode_t task_fperm; - uid_t control_uid; - gid_t control_gid; - mode_t control_fperm; - mode_t control_dperm; -}; - -struct cg_mount_point { - char path[FILENAME_MAX]; - struct cg_mount_point *next; -}; - -struct cg_mount_table_s { - /** Controller name. */ - char name[CONTROL_NAMELEN_MAX]; - /** - * List of mount points, at least one mount point is there for sure. - */ - struct cg_mount_point mount; - int index; - int shared_mnt; - enum cg_version_t version; -}; - -struct cgroup_rules_data { - pid_t pid; /* pid of the process which needs to change group */ - - /* Details of user under consideration for destination cgroup */ - struct passwd *pw; - /* Gid of the process */ - gid_t gid; -}; - -/* A rule that maps UID/GID to a cgroup */ -struct cgroup_rule { - uid_t uid; - gid_t gid; - bool is_ignore; - char *procname; - char username[LOGIN_NAME_MAX]; - char destination[FILENAME_MAX]; - char *controllers[MAX_MNT_ELEMENTS]; - struct cgroup_rule *next; -}; - -/* Container for a list of rules */ -struct cgroup_rule_list { - struct cgroup_rule *head; - struct cgroup_rule *tail; - int len; -}; - -/* The walk_tree handle */ -struct cgroup_tree_handle { - FTS *fts; - int flags; -}; - -/** - * Internal item of dictionary. Linked list is sufficient for now - we need - * only 'add' operation and simple iterator. In future, this might be easily - * rewritten to dynamic array when random access is needed, just keep in mind - * that the order is important and the iterator should return the items in - * the order they were added there. - */ -struct cgroup_dictionary_item { - const char *name; - const char *value; - struct cgroup_dictionary_item *next; -}; - -/* Flags for cgroup_dictionary_create */ -/** - * All items (i.e. both name and value strings) stored in the dictionary - * should *NOT* be free()d on cgroup_dictionary_free(), only the dictionary - * helper structures (i.e. underlying linked list) should be freed. - */ -#define CG_DICT_DONT_FREE_ITEMS 1 - -/** - * Dictionary of (name, value) items. - * The dictionary keeps its order, iterator iterates in the same order as - * the items were added there. It is *not* hash-style structure, it does - * not provide random access to its items nor quick search. This structure - * should be opaque to users of the dictionary, underlying data structure - * might change anytime and without warnings. - */ -struct cgroup_dictionary { - struct cgroup_dictionary_item *head; - struct cgroup_dictionary_item *tail; - int flags; -}; - -/** Opaque iterator of an dictionary. */ -struct cgroup_dictionary_iterator { - struct cgroup_dictionary_item *item; -}; - -/** - * per thread errno variable, to be used when return code is ECGOTHER - */ -extern __thread int last_errno; - -/** - * 'Exception handler' for lex parser. - */ -extern jmp_buf parser_error_env; - -/* Internal API */ -char *cg_build_path(const char *name, char *path, const char *type); -int cgroup_get_uid_gid_from_procfs(pid_t pid, uid_t *euid, gid_t *egid); -int cgroup_get_procname_from_procfs(pid_t pid, char **procname); -int cg_mkdir_p(const char *path); -struct cgroup *create_cgroup_from_name_value_pairs(const char *name, - struct control_value *name_value, int nv_number); -void init_cgroup_table(struct cgroup *cgroups, size_t count); - -/* - * Main mounting structures - * - * cg_mount_table_lock must be held to access: - * cg_mount_table - * cg_cgroup_v2_mount_path - */ -extern struct cg_mount_table_s cg_mount_table[CG_CONTROLLER_MAX]; -extern char cg_cgroup_v2_mount_path[FILENAME_MAX]; -extern pthread_rwlock_t cg_mount_table_lock; - -/* - * config related structures - */ -extern __thread char *cg_namespace_table[CG_CONTROLLER_MAX]; - -/* - * Default systemd cgroup used by the cg_build_path_locked() and tools - * setting the default cgroup path. - */ -extern char systemd_default_cgroup[FILENAME_MAX * 2 + 1]; - -/* - * config related API - */ -int cgroup_config_insert_cgroup(char *cg_name); -int cgroup_config_parse_controller_options(char *controller, struct cgroup_dictionary *values); -int template_config_insert_cgroup(char *cg_name); -int template_config_parse_controller_options(char *controller, struct cgroup_dictionary *values); -int template_config_group_task_perm(char *perm_type, char *value); -int template_config_group_admin_perm(char *perm_type, char *value); -int cgroup_config_group_task_perm(char *perm_type, char *value); -int cgroup_config_group_admin_perm(char *perm_type, char *value); -int cgroup_config_insert_into_mount_table(char *name, char *mount_point); -int cgroup_config_insert_into_namespace_table(char *name, char *mount_point); -void cgroup_config_cleanup_mount_table(void); -void cgroup_config_cleanup_namespace_table(void); -int cgroup_config_define_default(void); - -/** - * Create an empty dictionary. - */ -extern int cgroup_dictionary_create(struct cgroup_dictionary **dict, int flags); - -/** - * Add an item to existing dictionary. - */ -extern int cgroup_dictionary_add(struct cgroup_dictionary *dict, const char *name, - const char *value); -/** - * Fully destroy existing dictionary. Depending on flags passed to - * cgroup_dictionary_create(), names and values might get destroyed too. - */ -extern int cgroup_dictionary_free(struct cgroup_dictionary *dict); - -/** - * Start iterating through a dictionary. The items are returned in the same - * order as they were added using cgroup_dictionary_add(). - */ -extern int cgroup_dictionary_iterator_begin(struct cgroup_dictionary *dict, void **handle, - const char **name, const char **value); -/** - * Continue iterating through the dictionary. - */ -extern int cgroup_dictionary_iterator_next(void **handle, const char **name, const char **value); - -/** - * Finish iteration through the dictionary. - */ -extern void cgroup_dictionary_iterator_end(void **handle); - -/** - * Changes permissions for given path. If owner_is_umask is specified then - * it uses owner permissions as a mask for group and others permissions. - * - * @param path Patch to chmod. - * @param mode File permissions to set. - * @param owner_is_umask Flag whether path owner permissions should be used - * as a mask for group and - * others permissions. - */ -int cg_chmod_path(const char *path, mode_t mode, int owner_is_umask); - -/** - * Build the path to the tasks or cgroup.procs file - * - * @param path Output variable that will contain the path. Must be of size - * FILENAME_MAX or larger - * @param path_sz Size of the path string - * @param cg_name Cgroup name - * @param ctrl_name Controller name - */ -int cgroup_build_tasks_procs_path(char * const path, size_t path_sz, const char * const cg_name, - const char * const ctrl_name); - -/** - * Build the full path to the controller/setting - * - * @param setting Cgroup virtual filename/setting (optional) - * @param path Output variable to contain the concatenated path - * @param controller Cgroup controller name - * - * @return If successful, a valid pointer to the concatenated path - * - * @note The cg_mount_table_lock must be held prior to calling this function - */ -char *cg_build_path_locked(const char *setting, char *path, const char *controller); - -/** - * Given a cgroup controller and a setting within it, populate the setting's value - * - * @param ctrl_dir dirent representation of the setting, e.g. memory.stat - * @param cgroup current cgroup - * @param cgc current cgroup controller - * @param cg_index Index into the cg_mount_table of the cgroup - * - * @note The cg_mount_table_lock must be held prior to calling this function - */ -int cgroup_fill_cgc(struct dirent *ctrl_dir, struct cgroup *cgroup, struct cgroup_controller *cgc, - int cg_index); - -/** - * Given a controller name, test if it's mounted - * - * @param ctrl_name Controller name - * @return 1 if mounted, 0 if not mounted - */ -int cgroup_test_subsys_mounted(const char *ctrl_name); - -/** - * Create a duplicate copy of values under the specified controller - * - * @dst: Destination controller - * @src: Source controller from which values will be copied to dst - * - * @return 0 on a successful copy, ECGOTHER if the copy failed - */ -int cgroup_copy_controller_values(struct cgroup_controller * const dst, - const struct cgroup_controller * const src); - -/** - * Remove a name/value pair from a controller. - * - * @param controller - * @param name The name of the name/value pair to be removed - * @return 0 on success. ECGROUPNOTEXIST if name does not exist. - */ -int cgroup_remove_value(struct cgroup_controller * const controller, const char * const name); - -/** - * Free the specified controller from the group. - * @param ctrl - * - * Note it's up to the caller to decrement the cgroup's index - */ -void cgroup_free_controller(struct cgroup_controller *ctrl); - -/** - * Functions that are defined as STATIC can be placed within the UNIT_TEST - * ifdef. This will allow them to be included in the unit tests while - * remaining static in a normal libcgroup library build. - */ -#ifdef UNIT_TEST - -#define TEST_PROC_PID_CGROUP_FILE "test-procpidcgroup" - -int cgroup_parse_rules_options(char *options, struct cgroup_rule * const rule); -int cg_get_cgroups_from_proc_cgroups(pid_t pid, char *cgroup_list[], char *controller_list[], - int list_len); -bool cgroup_compare_ignore_rule(const struct cgroup_rule * const rule, pid_t pid, - const char * const procname); -bool cgroup_compare_wildcard_procname(const char * const rule_procname, - const char * const procname); -int cgroup_process_v1_mnt(char *controllers[], struct mntent *ent, int *mnt_tbl_idx); -int cgroup_process_v2_mnt(struct mntent *ent, int *mnt_tbl_idx); -int cgroup_set_values_recursive(const char * const base, - const struct cgroup_controller * const controller, - bool ignore_non_dirty_failures); -int cgroup_chown_chmod_tasks(const char * const cg_path, uid_t uid, gid_t gid, mode_t fperm); -int cgroupv2_subtree_control(const char *path, const char *ctrl_name, bool enable); -int cgroupv2_get_subtree_control(const char *path, const char *ctrl_name, bool * const enabled); -int cgroupv2_controller_enabled(const char * const cg_name, const char * const ctrl_name); - -#endif /* UNIT_TEST */ - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif diff --git a/lib/libcgroup-3.1.0/src/libcgroup.map b/lib/libcgroup-3.1.0/src/libcgroup.map deleted file mode 100644 index b48c71ca988..00000000000 --- a/lib/libcgroup-3.1.0/src/libcgroup.map +++ /dev/null @@ -1,164 +0,0 @@ -CGROUP_0.32 { -global: - cgroup_init; - cgroup_attach_task; - cgroup_modify_cgroup; - cgroup_create_cgroup; - cgroup_delete_cgroup; - cgroup_attach_task_pid; - cgroup_get_cgroup; - cgroup_create_cgroup_from_parent; - cgroup_copy_cgroup; - cgroup_change_cgroup_uid_gid; - cgroup_change_cgroup_path; - cgroup_new_cgroup; - cgroup_add_controller; - cgroup_free; - cgroup_free_controllers; - cgroup_add_value_string; - cgroup_add_value_int64; - cgroup_add_value_uint64; - cgroup_add_value_bool; - cgroup_compare_cgroup; - cgroup_compare_controllers; - cgroup_set_uid_gid; - cgroup_get_uid_gid; - cgroup_get_value_string; - cgroup_set_value_string; - cgroup_get_value_int64; - cgroup_set_value_int64; - cgroup_get_value_uint64; - cgroup_set_value_uint64; - cgroup_get_value_bool; - cgroup_set_value_bool; - cgroup_change_cgroup_uid_gid_flags; - cgroup_print_rules_config; - cgroup_reload_cached_rules; - cgroup_init_rules_cache; - cgroup_get_current_controller_path; - cgroup_config_load_config; -local: - *; -}; - -CGROUP_0.32.1 { -global: - cgroup_strerror; -} CGROUP_0.32; - -CGROUP_0.33 { -global: - cgroup_get_last_errno; - cgroup_walk_tree_begin; - cgroup_walk_tree_next; - cgroup_walk_tree_end; -} CGROUP_0.32.1; - -CGROUP_0.34 { -global: - cgroup_get_task_begin; - cgroup_get_task_end; - cgroup_get_task_next; - cgroup_read_stats_begin; - cgroup_read_stats_next; - cgroup_read_stats_end; - cgroup_walk_tree_set_flags; - cgroup_get_controller_end; - cgroup_get_controller_next; - cgroup_get_controller_begin; - cgroup_unload_cgroups; - cgroup_get_controller; - cgroup_get_uid_gid_from_procfs; - cgroup_get_subsys_mount_point; - cgroup_get_procname_from_procfs; - cgroup_register_unchanged_process; - cgroup_change_cgroup_flags; -} CGROUP_0.33; - -CGROUP_0.35 { -global: - create_cgroup_from_name_value_pairs; - cgroup_delete_cgroup_ext; - cgroup_get_all_controller_begin; - cgroup_get_all_controller_next; - cgroup_get_all_controller_end; - cgroup_get_value_name_count; - cgroup_get_value_name; -} CGROUP_0.34; - -CGROUP_0.36 { -} CGROUP_0.35; - -CGROUP_0.37 { - cgroup_get_procs; - cgroup_read_value_begin; - cgroup_read_value_next; - cgroup_read_value_end; - cg_chmod_recursive; -} CGROUP_0.36; - -CGROUP_0.38 { - cgroup_get_subsys_mount_point_begin; - cgroup_get_subsys_mount_point_next; - cgroup_get_subsys_mount_point_end; - cgroup_set_permissions; - cgroup_config_unload_config; - cgroup_config_set_default; -} CGROUP_0.37; - -CGROUP_0.39 { - cgroup_reload_cached_templates; - cgroup_init_templates_cache; - cgroup_config_create_template_group; - cgroup_change_all_cgroups; - cgroup_set_logger; - cgroup_set_default_logger; - cgroup_set_loglevel; - cgroup_log; - cgroup_parse_log_level_str; -} CGROUP_0.38; - -CGROUP_0.40 { - cgroup_templates_cache_set_source_files; - cgroup_load_templates_cache_from_files; -} CGROUP_0.39; - -CGROUP_0.41 { -} CGROUP_0.40; - -CGROUP_0.42 { - cgroup_add_all_controllers; -} CGROUP_0.41; - -CGROUP_2.0 { - cgroup_build_tasks_procs_path; - cg_build_path_locked; - cgroup_fill_cgc; - cgroup_test_subsys_mounted; - cg_mount_table; - cg_mount_table_lock; - cgroup_get_controller_version; -} CGROUP_0.42; - -CGROUP_3.0 { - cgroup_convert_cgroup; - cgroup_cgxget; - cgroup_cgxset; - cgroup_version; - cgroup_list_mount_points; - - /* libcgroup 3.0.1 */ - cgroup_setup_mode; - cgroup_create_scope; - cgroup_set_default_scope_opts; - cgroup_get_controller_count; - cgroup_get_controller_by_index; - cgroup_get_controller_name; - cgroup_create_scope2; - cgroup_set_default_systemd_cgroup; - cgroup_write_systemd_default_cgroup; - cgroup_setup_mode; - is_cgroup_mode_legacy; - is_cgroup_mode_hybrid; - is_cgroup_mode_unified; -} CGROUP_2.0; diff --git a/lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread b/lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread deleted file mode 100755 index 15946336aabf1f93c7ce34de2420a8b51e6f6614..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 26136 zcmeHQZ)_aJ6`#HH#SSL+IU&IzZL@>`Nx{% zMcfS|PexH#Q2kgAQwA)(Jei;BrXy6%^^kmyV3uAU+9sZG72?}9>0x;p*`=E#^Du}! zm3S)gSe~JBvSfQ=8Sytj_8f?65W=u4-Rpci`FYdCnXooqnCrb*7-hwr;X=868+f%Sg)#;w; zflWP|HYO_NM4v1ImMaNA>{FwAZxxXlF^d@U6`?eQBNPS|=}`AF_@UX6pPZb1_sGy+ z7XND9^v&lUz43Sddho43qYl;s(?lI~sLx#n!x+au41ZYH3W`gcC~pBwZGvMS&Gbd3 zV471x*TG&Hz2X?QqZbXUBruHT+9XDIj}7hA`x1SL8|wc4jX=p2%O#@dm?hXq)(`y( zgjRy&cC21uEymhkMcB{3`7P)U5z&jv;O2H{Qeq#$va&nx!M%3t)-1wspi7Wlulz+0W4`Dgm*U)$0rVz0qiI(`4F6RDj^AAP#*w5)UO zhL-@YUHvj#J6CJq!*CwsUOQW>)sUZheeBo^UrHZ)DShnr=NZHnl4aZ zegf3ro=kMEzE7ry`lsiE4?VUH2IA>$cy*RNhALQu#ZMqmJ3IN%>B)Iz%>UO?|7&kZ zacnOA1wspi76>g6S|GGQXo1iI zp#?$bjq+DVY;a19fka%7)S zrsK-0OIzC>f(1BSx5Ksjvwy4Au0e%et#QPX@OvLHTBe5`1n%1MNx)R_i;nn6NB3tt z+rQE_BX(S|bwmH!H3)aZuK>Thp$wRg80?6DJ+gBNuJ?s5v_NQq&;p?aLJNcz2rUp= zAhbYefzSe>1wOh3R9Lh{H%I%Uc`qgI#YA_hD`0}BN#7C*4-k*_c%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?@%Erb z9iP1#BV_`OcGI&3*Jy@g;<2Y_#3{>ki!$Ghg4FQNf}3%|guQieLuO4Id@%a6b*BhB zc)?4*jwF@L=%c*w1^kr0W> z;i6+qfOKqE=Gh0se$$3WlYEfoO4S5xc$+e92Of2GXrgMt>BAO0P9-!rG}a>@H>jS+ zeUORl;SyxwO2-xnjJeyiE4U5P8_*#R?p6Z{_r%w$zJ$+`^X6HTbDy)Vs=M0>ErXt zdEYukOI`M(yb69eC5P9)bOXfa^SL#`S;%=72S9FupO-&Pd_Jdptw$HVJlEx=Hf`Mm#Mqk{5&e^8MQ)9^a{M1p(mna}&{j}xEsc|+vGif7|-AM{|Wf@In45pz`;HAbi38(i`{e%KI>uH=s3*s9AMaY zn9uV#{=WqL{|B)DqhlW16^=-h^=Cex&py{H)nP8v=$Oy)T_3+bFHE{TwUJ)WpZO6m zKH8u2=lPvVe1ChPuGh5zfN3$G=Ur<*B!3CzPwMrgnSW;;aXp+r%N5{3+s=^Qy1O*# zo1p}MOAlb|Bk26~xt{WOW9P32_PBn3xj0|e+#0~YkN7`eMUsC0XaN7(y)Geh5&o?K z{NuzwcoDuqe1ARvMEvgs@VOp^0RGW&mzci@AJeHndpx>x#81+L`6`I(gCF->ey%SD kjQgI4F4WJvp)D|9_c|^&WB8bC#=qkWuEsq+f-flk4JyOfqyPW_ diff --git a/lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread.c b/lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread.c deleted file mode 100644 index 1b3b06e4359..00000000000 --- a/lib/libcgroup-3.1.0/src/libcgroup_systemd_idle_thread.c +++ /dev/null @@ -1,11 +0,0 @@ -#include - -#define SECS_PER_DAY (60 * 60 *24) - -int main(void) -{ - while(1) - sleep(1 * SECS_PER_DAY); - - return 0; -} diff --git a/lib/libcgroup-3.1.0/src/log.c b/lib/libcgroup-3.1.0/src/log.c deleted file mode 100644 index 93cecd480ba..00000000000 --- a/lib/libcgroup-3.1.0/src/log.c +++ /dev/null @@ -1,92 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright Red Hat, Inc. 2012 - * - * Author: Jan Safranek - */ - -#include -#include - -#include -#include -#include -#include -#include - -static cgroup_logger_callback cgroup_logger; -static void *cgroup_logger_userdata; -static int cgroup_loglevel; - -static void cgroup_default_logger(void *userdata, int level, const char *fmt, - va_list ap) -{ - vfprintf(stdout, fmt, ap); -} - -void cgroup_log(int level, const char *fmt, ...) -{ - va_list ap; - - if (!cgroup_logger) - return; - - if (level > cgroup_loglevel) - return; - - va_start(ap, fmt); - cgroup_logger(cgroup_logger_userdata, level, fmt, ap); - va_end(ap); -} - -void cgroup_set_logger(cgroup_logger_callback logger, int loglevel, - void *userdata) -{ - cgroup_logger = logger; - cgroup_set_loglevel(loglevel); - cgroup_logger_userdata = userdata; -} - -void cgroup_set_default_logger(int level) -{ - if (!cgroup_logger) - cgroup_set_logger(cgroup_default_logger, level, NULL); -} - -int cgroup_parse_log_level_str(const char *levelstr) -{ - char *end; - long level; - - errno = 0; - - /* try to parse integer first */ - level = strtol(levelstr, &end, 10); - if (end != levelstr && *end == '\0') - return level; - - if (strcasecmp(levelstr, "ERROR") == 0) - return CGROUP_LOG_ERROR; - if (strcasecmp(levelstr, "WARNING") == 0) - return CGROUP_LOG_WARNING; - if (strcasecmp(levelstr, "INFO") == 0) - return CGROUP_LOG_INFO; - if (strcasecmp(levelstr, "DEBUG") == 0) - return CGROUP_LOG_DEBUG; - - return CGROUP_DEFAULT_LOGLEVEL; -} - -void cgroup_set_loglevel(int loglevel) -{ - if (loglevel != -1) - cgroup_loglevel = loglevel; - else { - char *level_str = getenv("CGROUP_LOGLEVEL"); - - if (level_str != NULL) - cgroup_loglevel = cgroup_parse_log_level_str(level_str); - else - cgroup_loglevel = CGROUP_DEFAULT_LOGLEVEL; - } -} diff --git a/lib/libcgroup-3.1.0/src/pam/Makefile.am b/lib/libcgroup-3.1.0/src/pam/Makefile.am deleted file mode 100644 index 017ef68f5fa..00000000000 --- a/lib/libcgroup-3.1.0/src/pam/Makefile.am +++ /dev/null @@ -1,10 +0,0 @@ -AM_CPPFLAGS = -I $(top_srcdir)/include -I$(top_builddir)/include - -if WITH_PAM - -pamlib_LTLIBRARIES = pam_cgroup.la -pam_cgroup_la_SOURCES = pam_cgroup.c -pam_cgroup_la_LDFLAGS = -module -avoid-version -pam_cgroup_la_LIBADD = $(top_builddir)/src/libcgroup.la -lpam - -endif diff --git a/lib/libcgroup-3.1.0/src/pam/Makefile.in b/lib/libcgroup-3.1.0/src/pam/Makefile.in deleted file mode 100644 index 9b0239de142..00000000000 --- a/lib/libcgroup-3.1.0/src/pam/Makefile.in +++ /dev/null @@ -1,697 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = src/pam -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(pamlibdir)" -LTLIBRARIES = $(pamlib_LTLIBRARIES) -@WITH_PAM_TRUE@pam_cgroup_la_DEPENDENCIES = \ -@WITH_PAM_TRUE@ $(top_builddir)/src/libcgroup.la -am__pam_cgroup_la_SOURCES_DIST = pam_cgroup.c -@WITH_PAM_TRUE@am_pam_cgroup_la_OBJECTS = pam_cgroup.lo -pam_cgroup_la_OBJECTS = $(am_pam_cgroup_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -pam_cgroup_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(pam_cgroup_la_LDFLAGS) $(LDFLAGS) -o $@ -@WITH_PAM_TRUE@am_pam_cgroup_la_rpath = -rpath $(pamlibdir) -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/pam_cgroup.Plo -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(pam_cgroup_la_SOURCES) -DIST_SOURCES = $(am__pam_cgroup_la_SOURCES_DIST) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AM_CPPFLAGS = -I $(top_srcdir)/include -I$(top_builddir)/include -@WITH_PAM_TRUE@pamlib_LTLIBRARIES = pam_cgroup.la -@WITH_PAM_TRUE@pam_cgroup_la_SOURCES = pam_cgroup.c -@WITH_PAM_TRUE@pam_cgroup_la_LDFLAGS = -module -avoid-version -@WITH_PAM_TRUE@pam_cgroup_la_LIBADD = $(top_builddir)/src/libcgroup.la -lpam -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/pam/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/pam/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -install-pamlibLTLIBRARIES: $(pamlib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(pamlib_LTLIBRARIES)'; test -n "$(pamlibdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(pamlibdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(pamlibdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(pamlibdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(pamlibdir)"; \ - } - -uninstall-pamlibLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(pamlib_LTLIBRARIES)'; test -n "$(pamlibdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(pamlibdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(pamlibdir)/$$f"; \ - done - -clean-pamlibLTLIBRARIES: - -test -z "$(pamlib_LTLIBRARIES)" || rm -f $(pamlib_LTLIBRARIES) - @list='$(pamlib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -pam_cgroup.la: $(pam_cgroup_la_OBJECTS) $(pam_cgroup_la_DEPENDENCIES) $(EXTRA_pam_cgroup_la_DEPENDENCIES) - $(AM_V_CCLD)$(pam_cgroup_la_LINK) $(am_pam_cgroup_la_rpath) $(pam_cgroup_la_OBJECTS) $(pam_cgroup_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pam_cgroup.Plo@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LTLIBRARIES) -installdirs: - for dir in "$(DESTDIR)$(pamlibdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-pamlibLTLIBRARIES \ - mostlyclean-am - -distclean: distclean-am - -rm -f ./$(DEPDIR)/pam_cgroup.Plo - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: install-pamlibLTLIBRARIES - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/pam_cgroup.Plo - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-pamlibLTLIBRARIES - -.MAKE: install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-generic clean-libtool clean-pamlibLTLIBRARIES \ - cscopelist-am ctags ctags-am distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man \ - install-pamlibLTLIBRARIES install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am \ - uninstall-pamlibLTLIBRARIES - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/src/pam/pam_cgroup.c b/lib/libcgroup-3.1.0/src/pam/pam_cgroup.c deleted file mode 100644 index b268effeed1..00000000000 --- a/lib/libcgroup-3.1.0/src/pam/pam_cgroup.c +++ /dev/null @@ -1,153 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/* - * Copyright RedHat Inc. 2008 - * - * Author: Vivek Goyal - * - * Derived from pam_limits.c. Original Copyright notice follows. - * - * Copyright (c) Cristian Gafton, 1996-1997, - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, and the entire permission notice in its entirety, - * including the disclaimer of warranties. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. The name of the author may not be used to endorse or promote - * products derived from this software without specific prior - * written permission. - * - * ALTERNATIVELY, this product may be distributed under the terms of - * the GNU Public License, in which case the provisions of the GPL are - * required INSTEAD OF the above restrictions. (This clause is - * necessary due to a potential bad interaction between the GPL and - * the restrictions contained in a BSD-style copyright.) - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, - * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, - * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED - * OF THE POSSIBILITY OF SUCH DAMAGE. - * - * End of original copyright notice. - */ - -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -/* - * Module defines - */ -#define PAM_SM_SESSION - -#include -#include -#include -#include - -/* argument parsing */ -#define PAM_DEBUG_ARG 0x0001 - -static int _pam_parse(const pam_handle_t *pamh, int argc, const char **argv) -{ - int ctrl = 0; - - /* step through arguments */ - for (ctrl = 0; argc-- > 0; ++argv) { - if (!strcmp(*argv, "debug")) - ctrl |= PAM_DEBUG_ARG; - else - pam_syslog(pamh, LOG_ERR, "unknown option: %s", *argv); - } - - return ctrl; -} - -/* now the session stuff */ -PAM_EXTERN int pam_sm_open_session(pam_handle_t *pamh, int flags, int argc, const char **argv) -{ - struct passwd *pwd; - char *user_name; - int ctrl, ret; - pid_t pid; - - D(("called.")); - - ctrl = _pam_parse(pamh, argc, argv); - - ret = pam_get_item(pamh, PAM_USER, (void *) &user_name); - if (user_name == NULL || ret != PAM_SUCCESS) { - pam_syslog(pamh, LOG_ERR, "open_session - error recovering username"); - return PAM_SESSION_ERR; - } - - pwd = pam_modutil_getpwnam(pamh, user_name); - if (!pwd) { - if (ctrl & PAM_DEBUG_ARG) - pam_syslog(pamh, LOG_ERR, "open_session username '%s' does not exist", - user_name); - return PAM_SESSION_ERR; - } - - D(("user name is %s", user_name)); - - /* Initialize libcg */ - ret = cgroup_init(); - if (ret) { - if (ctrl & PAM_DEBUG_ARG) - pam_syslog(pamh, LOG_ERR, "libcgroup initialization failed"); - return PAM_SESSION_ERR; - } - - D(("Initialized libcgroup successfuly.")); - - /* Determine the pid of the task */ - pid = getpid(); - - /* - * Note: We are using default gid here. Is there a way to - * determine under what egid service will be provided? - */ - ret = cgroup_change_cgroup_uid_gid_flags(pwd->pw_uid, pwd->pw_gid, pid, CGFLAG_USECACHE); - if (ret) { - if (ctrl & PAM_DEBUG_ARG) { - pam_syslog(pamh, LOG_ERR, "Change of cgroup for process with username"); - pam_syslog(pamh, LOG_ERR, "%s failed.\n", user_name); - } - return PAM_SESSION_ERR; - } - - if (ctrl & PAM_DEBUG_ARG) { - pam_syslog(pamh, LOG_DEBUG, "Changed cgroup for process %d with username %s.\n", - pid, user_name); - } - - return PAM_SUCCESS; -} - -PAM_EXTERN int pam_sm_close_session(pam_handle_t *pamh, int flags, int argc, const char **argv) -{ - D(("called pam_cgroup close session")); - - /* nothing to do yet */ - return PAM_SUCCESS; -} diff --git a/lib/libcgroup-3.1.0/src/parse.c b/lib/libcgroup-3.1.0/src/parse.c deleted file mode 100644 index b977df0aeeb..00000000000 --- a/lib/libcgroup-3.1.0/src/parse.c +++ /dev/null @@ -1,2061 +0,0 @@ -/* A Bison parser, made by GNU Bison 3.8.2. */ - -/* Bison implementation for Yacc-like parsers in C - - Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation, - Inc. - - 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 3 of the License, or - (at your option) any later version. - - 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, see . */ - -/* As a special exception, you may create a larger work that contains - part or all of the Bison parser skeleton and distribute that work - under terms of your choice, so long as that work isn't itself a - parser generator using the skeleton or a modified version thereof - as a parser skeleton. Alternatively, if you modify or redistribute - the parser skeleton itself, you may (at your option) remove this - special exception, which will cause the skeleton and the resulting - Bison output files to be licensed under the GNU General Public - License without this special exception. - - This special exception was added by the Free Software Foundation in - version 2.2 of Bison. */ - -/* C LALR(1) parser skeleton written by Richard Stallman, by - simplifying the original so-called "semantic" parser. */ - -/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual, - especially those whose name start with YY_ or yy_. They are - private implementation details that can be changed or removed. */ - -/* All symbols defined below should begin with yy or YY, to avoid - infringing on user name space. This should be done even for local - variables, as they might otherwise be expanded by user macros. - There are some unavoidable exceptions within include files to - define necessary library symbols; they are noted "INFRINGES ON - USER NAME SPACE" below. */ - -/* Identify Bison output, and Bison version. */ -#define YYBISON 30802 - -/* Bison version string. */ -#define YYBISON_VERSION "3.8.2" - -/* Skeleton name. */ -#define YYSKELETON_NAME "yacc.c" - -/* Pure parsers. */ -#define YYPURE 0 - -/* Push parsers. */ -#define YYPUSH 0 - -/* Pull parsers. */ -#define YYPULL 1 - - - - -/* First part of user prologue. */ -#line 11 "parse.y" - -#include -#include -#include -#include -#include - -int yylex(void); -extern int line_no; -extern char *yytext; - -static void yyerror(const char *s) -{ - fprintf(stderr, "error at line number %d at %s:%s\n", line_no, yytext, s); -} - -int yywrap(void) -{ - return 1; -} - - -#line 94 "parse.c" - -# ifndef YY_CAST -# ifdef __cplusplus -# define YY_CAST(Type, Val) static_cast (Val) -# define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast (Val) -# else -# define YY_CAST(Type, Val) ((Type) (Val)) -# define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val)) -# endif -# endif -# ifndef YY_NULLPTR -# if defined __cplusplus -# if 201103L <= __cplusplus -# define YY_NULLPTR nullptr -# else -# define YY_NULLPTR 0 -# endif -# else -# define YY_NULLPTR ((void*)0) -# endif -# endif - -/* Use api.header.include to #include this header - instead of duplicating it here. */ -#ifndef YY_YY_PARSE_H_INCLUDED -# define YY_YY_PARSE_H_INCLUDED -/* Debug traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif -#if YYDEBUG -extern int yydebug; -#endif - -/* Token kinds. */ -#ifndef YYTOKENTYPE -# define YYTOKENTYPE - enum yytokentype - { - YYEMPTY = -2, - YYEOF = 0, /* "end of file" */ - YYerror = 256, /* error */ - YYUNDEF = 257, /* "invalid token" */ - ID = 258, /* ID */ - MOUNT = 259, /* MOUNT */ - GROUP = 260, /* GROUP */ - PERM = 261, /* PERM */ - TASK = 262, /* TASK */ - ADMIN = 263, /* ADMIN */ - NAMESPACE = 264, /* NAMESPACE */ - DEFAULT = 265, /* DEFAULT */ - TEMPLATE = 266, /* TEMPLATE */ - SYSTEMD = 267 /* SYSTEMD */ - }; - typedef enum yytokentype yytoken_kind_t; -#endif -/* Token kinds. */ -#define YYEMPTY -2 -#define YYEOF 0 -#define YYerror 256 -#define YYUNDEF 257 -#define ID 258 -#define MOUNT 259 -#define GROUP 260 -#define PERM 261 -#define TASK 262 -#define ADMIN 263 -#define NAMESPACE 264 -#define DEFAULT 265 -#define TEMPLATE 266 -#define SYSTEMD 267 - -/* Value type. */ -#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED -union YYSTYPE -{ -#line 36 "parse.y" - - char *name; - char chr; - int val; - struct cgroup_dictionary *values; - -#line 178 "parse.c" - -}; -typedef union YYSTYPE YYSTYPE; -# define YYSTYPE_IS_TRIVIAL 1 -# define YYSTYPE_IS_DECLARED 1 -#endif - - -extern YYSTYPE yylval; - - -int yyparse (void); - - -#endif /* !YY_YY_PARSE_H_INCLUDED */ -/* Symbol kind. */ -enum yysymbol_kind_t -{ - YYSYMBOL_YYEMPTY = -2, - YYSYMBOL_YYEOF = 0, /* "end of file" */ - YYSYMBOL_YYerror = 1, /* error */ - YYSYMBOL_YYUNDEF = 2, /* "invalid token" */ - YYSYMBOL_ID = 3, /* ID */ - YYSYMBOL_MOUNT = 4, /* MOUNT */ - YYSYMBOL_GROUP = 5, /* GROUP */ - YYSYMBOL_PERM = 6, /* PERM */ - YYSYMBOL_TASK = 7, /* TASK */ - YYSYMBOL_ADMIN = 8, /* ADMIN */ - YYSYMBOL_NAMESPACE = 9, /* NAMESPACE */ - YYSYMBOL_DEFAULT = 10, /* DEFAULT */ - YYSYMBOL_TEMPLATE = 11, /* TEMPLATE */ - YYSYMBOL_SYSTEMD = 12, /* SYSTEMD */ - YYSYMBOL_13_ = 13, /* '{' */ - YYSYMBOL_14_ = 14, /* '}' */ - YYSYMBOL_15_ = 15, /* '=' */ - YYSYMBOL_16_ = 16, /* ';' */ - YYSYMBOL_YYACCEPT = 17, /* $accept */ - YYSYMBOL_start = 18, /* start */ - YYSYMBOL_default = 19, /* default */ - YYSYMBOL_default_conf = 20, /* default_conf */ - YYSYMBOL_group = 21, /* group */ - YYSYMBOL_group_name = 22, /* group_name */ - YYSYMBOL_group_conf = 23, /* group_conf */ - YYSYMBOL_template = 24, /* template */ - YYSYMBOL_template_conf = 25, /* template_conf */ - YYSYMBOL_template_task_or_admin = 26, /* template_task_or_admin */ - YYSYMBOL_namevalue_conf = 27, /* namevalue_conf */ - YYSYMBOL_task_namevalue_conf = 28, /* task_namevalue_conf */ - YYSYMBOL_admin_namevalue_conf = 29, /* admin_namevalue_conf */ - YYSYMBOL_template_task_namevalue_conf = 30, /* template_task_namevalue_conf */ - YYSYMBOL_template_admin_namevalue_conf = 31, /* template_admin_namevalue_conf */ - YYSYMBOL_task_or_admin = 32, /* task_or_admin */ - YYSYMBOL_admin_conf = 33, /* admin_conf */ - YYSYMBOL_task_conf = 34, /* task_conf */ - YYSYMBOL_template_admin_conf = 35, /* template_admin_conf */ - YYSYMBOL_template_task_conf = 36, /* template_task_conf */ - YYSYMBOL_mountvalue_conf = 37, /* mountvalue_conf */ - YYSYMBOL_mount = 38, /* mount */ - YYSYMBOL_namespace_conf = 39, /* namespace_conf */ - YYSYMBOL_namespace = 40, /* namespace */ - YYSYMBOL_systemdvalue_conf = 41, /* systemdvalue_conf */ - YYSYMBOL_systemd = 42 /* systemd */ -}; -typedef enum yysymbol_kind_t yysymbol_kind_t; - - - - -#ifdef short -# undef short -#endif - -/* On compilers that do not define __PTRDIFF_MAX__ etc., make sure - and (if available) are included - so that the code can choose integer types of a good width. */ - -#ifndef __PTRDIFF_MAX__ -# include /* INFRINGES ON USER NAME SPACE */ -# if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__ -# include /* INFRINGES ON USER NAME SPACE */ -# define YY_STDINT_H -# endif -#endif - -/* Narrow types that promote to a signed type and that can represent a - signed or unsigned integer of at least N bits. In tables they can - save space and decrease cache pressure. Promoting to a signed type - helps avoid bugs in integer arithmetic. */ - -#ifdef __INT_LEAST8_MAX__ -typedef __INT_LEAST8_TYPE__ yytype_int8; -#elif defined YY_STDINT_H -typedef int_least8_t yytype_int8; -#else -typedef signed char yytype_int8; -#endif - -#ifdef __INT_LEAST16_MAX__ -typedef __INT_LEAST16_TYPE__ yytype_int16; -#elif defined YY_STDINT_H -typedef int_least16_t yytype_int16; -#else -typedef short yytype_int16; -#endif - -/* Work around bug in HP-UX 11.23, which defines these macros - incorrectly for preprocessor constants. This workaround can likely - be removed in 2023, as HPE has promised support for HP-UX 11.23 - (aka HP-UX 11i v2) only through the end of 2022; see Table 2 of - . */ -#ifdef __hpux -# undef UINT_LEAST8_MAX -# undef UINT_LEAST16_MAX -# define UINT_LEAST8_MAX 255 -# define UINT_LEAST16_MAX 65535 -#endif - -#if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__ -typedef __UINT_LEAST8_TYPE__ yytype_uint8; -#elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \ - && UINT_LEAST8_MAX <= INT_MAX) -typedef uint_least8_t yytype_uint8; -#elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX -typedef unsigned char yytype_uint8; -#else -typedef short yytype_uint8; -#endif - -#if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__ -typedef __UINT_LEAST16_TYPE__ yytype_uint16; -#elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \ - && UINT_LEAST16_MAX <= INT_MAX) -typedef uint_least16_t yytype_uint16; -#elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX -typedef unsigned short yytype_uint16; -#else -typedef int yytype_uint16; -#endif - -#ifndef YYPTRDIFF_T -# if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__ -# define YYPTRDIFF_T __PTRDIFF_TYPE__ -# define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__ -# elif defined PTRDIFF_MAX -# ifndef ptrdiff_t -# include /* INFRINGES ON USER NAME SPACE */ -# endif -# define YYPTRDIFF_T ptrdiff_t -# define YYPTRDIFF_MAXIMUM PTRDIFF_MAX -# else -# define YYPTRDIFF_T long -# define YYPTRDIFF_MAXIMUM LONG_MAX -# endif -#endif - -#ifndef YYSIZE_T -# ifdef __SIZE_TYPE__ -# define YYSIZE_T __SIZE_TYPE__ -# elif defined size_t -# define YYSIZE_T size_t -# elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__ -# include /* INFRINGES ON USER NAME SPACE */ -# define YYSIZE_T size_t -# else -# define YYSIZE_T unsigned -# endif -#endif - -#define YYSIZE_MAXIMUM \ - YY_CAST (YYPTRDIFF_T, \ - (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \ - ? YYPTRDIFF_MAXIMUM \ - : YY_CAST (YYSIZE_T, -1))) - -#define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) - - -/* Stored state numbers (used for stacks). */ -typedef yytype_uint8 yy_state_t; - -/* State numbers in computations. */ -typedef int yy_state_fast_t; - -#ifndef YY_ -# if defined YYENABLE_NLS && YYENABLE_NLS -# if ENABLE_NLS -# include /* INFRINGES ON USER NAME SPACE */ -# define YY_(Msgid) dgettext ("bison-runtime", Msgid) -# endif -# endif -# ifndef YY_ -# define YY_(Msgid) Msgid -# endif -#endif - - -#ifndef YY_ATTRIBUTE_PURE -# if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__) -# define YY_ATTRIBUTE_PURE __attribute__ ((__pure__)) -# else -# define YY_ATTRIBUTE_PURE -# endif -#endif - -#ifndef YY_ATTRIBUTE_UNUSED -# if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__) -# define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__)) -# else -# define YY_ATTRIBUTE_UNUSED -# endif -#endif - -/* Suppress unused-variable warnings by "using" E. */ -#if ! defined lint || defined __GNUC__ -# define YY_USE(E) ((void) (E)) -#else -# define YY_USE(E) /* empty */ -#endif - -/* Suppress an incorrect diagnostic about yylval being uninitialized. */ -#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__ -# if __GNUC__ * 100 + __GNUC_MINOR__ < 407 -# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ - _Pragma ("GCC diagnostic push") \ - _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") -# else -# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ - _Pragma ("GCC diagnostic push") \ - _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ - _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") -# endif -# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ - _Pragma ("GCC diagnostic pop") -#else -# define YY_INITIAL_VALUE(Value) Value -#endif -#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN -# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN -# define YY_IGNORE_MAYBE_UNINITIALIZED_END -#endif -#ifndef YY_INITIAL_VALUE -# define YY_INITIAL_VALUE(Value) /* Nothing. */ -#endif - -#if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__ -# define YY_IGNORE_USELESS_CAST_BEGIN \ - _Pragma ("GCC diagnostic push") \ - _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"") -# define YY_IGNORE_USELESS_CAST_END \ - _Pragma ("GCC diagnostic pop") -#endif -#ifndef YY_IGNORE_USELESS_CAST_BEGIN -# define YY_IGNORE_USELESS_CAST_BEGIN -# define YY_IGNORE_USELESS_CAST_END -#endif - - -#define YY_ASSERT(E) ((void) (0 && (E))) - -#if !defined yyoverflow - -/* The parser invokes alloca or malloc; define the necessary symbols. */ - -# ifdef YYSTACK_USE_ALLOCA -# if YYSTACK_USE_ALLOCA -# ifdef __GNUC__ -# define YYSTACK_ALLOC __builtin_alloca -# elif defined __BUILTIN_VA_ARG_INCR -# include /* INFRINGES ON USER NAME SPACE */ -# elif defined _AIX -# define YYSTACK_ALLOC __alloca -# elif defined _MSC_VER -# include /* INFRINGES ON USER NAME SPACE */ -# define alloca _alloca -# else -# define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS -# include /* INFRINGES ON USER NAME SPACE */ - /* Use EXIT_SUCCESS as a witness for stdlib.h. */ -# ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -# endif -# endif -# endif -# endif -# endif - -# ifdef YYSTACK_ALLOC - /* Pacify GCC's 'empty if-body' warning. */ -# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) -# ifndef YYSTACK_ALLOC_MAXIMUM - /* The OS might guarantee only one guard page at the bottom of the stack, - and a page size can be as small as 4096 bytes. So we cannot safely - invoke alloca (N) if N exceeds 4096. Use a slightly smaller number - to allow for a few compiler-allocated temporary stack slots. */ -# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ -# endif -# else -# define YYSTACK_ALLOC YYMALLOC -# define YYSTACK_FREE YYFREE -# ifndef YYSTACK_ALLOC_MAXIMUM -# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM -# endif -# if (defined __cplusplus && ! defined EXIT_SUCCESS \ - && ! ((defined YYMALLOC || defined malloc) \ - && (defined YYFREE || defined free))) -# include /* INFRINGES ON USER NAME SPACE */ -# ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 -# endif -# endif -# ifndef YYMALLOC -# define YYMALLOC malloc -# if ! defined malloc && ! defined EXIT_SUCCESS -void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# ifndef YYFREE -# define YYFREE free -# if ! defined free && ! defined EXIT_SUCCESS -void free (void *); /* INFRINGES ON USER NAME SPACE */ -# endif -# endif -# endif -#endif /* !defined yyoverflow */ - -#if (! defined yyoverflow \ - && (! defined __cplusplus \ - || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) - -/* A type that is properly aligned for any stack member. */ -union yyalloc -{ - yy_state_t yyss_alloc; - YYSTYPE yyvs_alloc; -}; - -/* The size of the maximum gap between one aligned stack and the next. */ -# define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1) - -/* The size of an array large to enough to hold all stacks, each with - N elements. */ -# define YYSTACK_BYTES(N) \ - ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ - + YYSTACK_GAP_MAXIMUM) - -# define YYCOPY_NEEDED 1 - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ - do \ - { \ - YYPTRDIFF_T yynewbytes; \ - YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ - Stack = &yyptr->Stack_alloc; \ - yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / YYSIZEOF (*yyptr); \ - } \ - while (0) - -#endif - -#if defined YYCOPY_NEEDED && YYCOPY_NEEDED -/* Copy COUNT objects from SRC to DST. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined __GNUC__ && 1 < __GNUC__ -# define YYCOPY(Dst, Src, Count) \ - __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src))) -# else -# define YYCOPY(Dst, Src, Count) \ - do \ - { \ - YYPTRDIFF_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (Dst)[yyi] = (Src)[yyi]; \ - } \ - while (0) -# endif -# endif -#endif /* !YYCOPY_NEEDED */ - -/* YYFINAL -- State number of the termination state. */ -#define YYFINAL 2 -/* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 151 - -/* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 17 -/* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 26 -/* YYNRULES -- Number of rules. */ -#define YYNRULES 48 -/* YYNSTATES -- Number of states. */ -#define YYNSTATES 165 - -/* YYMAXUTOK -- Last valid token kind. */ -#define YYMAXUTOK 267 - - -/* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM - as returned by yylex, with out-of-bounds checking. */ -#define YYTRANSLATE(YYX) \ - (0 <= (YYX) && (YYX) <= YYMAXUTOK \ - ? YY_CAST (yysymbol_kind_t, yytranslate[YYX]) \ - : YYSYMBOL_YYUNDEF) - -/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM - as returned by yylex. */ -static const yytype_int8 yytranslate[] = -{ - 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 16, - 2, 15, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 13, 2, 14, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, - 5, 6, 7, 8, 9, 10, 11, 12 -}; - -#if YYDEBUG -/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ -static const yytype_int16 yyrline[] = -{ - 0, 55, 55, 59, 63, 67, 71, 75, 80, 85, - 95, 101, 120, 124, 130, 140, 150, 161, 181, 191, - 201, 213, 222, 235, 251, 264, 270, 279, 291, 300, - 312, 321, 333, 342, 355, 364, 375, 386, 397, 408, - 420, 429, 440, 452, 461, 472, 484, 493, 504 -}; -#endif - -/** Accessing symbol of state STATE. */ -#define YY_ACCESSING_SYMBOL(State) YY_CAST (yysymbol_kind_t, yystos[State]) - -#if YYDEBUG || 0 -/* The user-facing name of the symbol whose (internal) number is - YYSYMBOL. No bounds checking. */ -static const char *yysymbol_name (yysymbol_kind_t yysymbol) YY_ATTRIBUTE_UNUSED; - -/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. - First, the terminals, then, starting at YYNTOKENS, nonterminals. */ -static const char *const yytname[] = -{ - "\"end of file\"", "error", "\"invalid token\"", "ID", "MOUNT", "GROUP", - "PERM", "TASK", "ADMIN", "NAMESPACE", "DEFAULT", "TEMPLATE", "SYSTEMD", - "'{'", "'}'", "'='", "';'", "$accept", "start", "default", - "default_conf", "group", "group_name", "group_conf", "template", - "template_conf", "template_task_or_admin", "namevalue_conf", - "task_namevalue_conf", "admin_namevalue_conf", - "template_task_namevalue_conf", "template_admin_namevalue_conf", - "task_or_admin", "admin_conf", "task_conf", "template_admin_conf", - "template_task_conf", "mountvalue_conf", "mount", "namespace_conf", - "namespace", "systemdvalue_conf", "systemd", YY_NULLPTR -}; - -static const char * -yysymbol_name (yysymbol_kind_t yysymbol) -{ - return yytname[yysymbol]; -} -#endif - -#define YYPACT_NINF (-62) - -#define yypact_value_is_default(Yyn) \ - ((Yyn) == YYPACT_NINF) - -#define YYTABLE_NINF (-1) - -#define yytable_value_is_error(Yyn) \ - 0 - -/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing - STATE-NUM. */ -static const yytype_int16 yypact[] = -{ - -62, 3, -62, -11, 43, -7, -3, 44, 47, -62, - -62, -62, -62, -62, -62, 46, -62, -62, 48, 59, - 57, 52, 61, 39, 2, -2, 53, 6, 54, 55, - 42, 56, 14, 63, 58, -62, 62, 64, 15, 67, - 65, -62, 49, -62, 66, 68, 16, 69, 70, -62, - 60, 71, 75, 49, 73, -62, 72, 79, 74, 76, - 77, 75, 51, 80, -62, 78, 81, -62, 82, 84, - 19, 83, 75, -62, 85, 87, 89, -62, 20, 90, - 91, 86, 75, -62, 92, -62, 93, 94, -62, -62, - 21, -62, 95, 22, 96, 23, -62, 99, 102, -62, - 24, -62, 97, 103, -62, 104, 100, 106, 109, 101, - 88, 105, 28, 107, 29, -62, -62, 108, 110, 114, - 112, -62, 111, 115, 116, -62, 118, 113, 122, 120, - 117, 124, -62, -62, 119, 89, -62, 121, 87, 123, - 130, 125, -62, 126, 131, 127, -62, -62, 36, -62, - 37, -62, 128, 102, -62, 129, 99, -62, -62, -62, - 38, -62, 41, -62, -62 -}; - -/* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. - Performed when YYTABLE does not specify something else to do. Zero - means the default is an error. */ -static const yytype_int8 yydefact[] = -{ - 8, 0, 1, 0, 0, 0, 0, 0, 0, 4, - 2, 6, 3, 5, 7, 0, 12, 13, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 42, 0, 0, 0, 0, - 0, 45, 0, 9, 0, 0, 0, 0, 0, 48, - 0, 0, 25, 0, 0, 11, 0, 0, 0, 0, - 0, 25, 0, 0, 17, 0, 0, 40, 0, 0, - 0, 0, 25, 43, 0, 0, 0, 10, 0, 0, - 0, 0, 25, 46, 0, 41, 0, 0, 14, 16, - 0, 44, 0, 0, 0, 0, 18, 0, 0, 20, - 0, 47, 0, 0, 15, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 19, 23, 0, 0, 0, - 0, 34, 0, 0, 0, 35, 0, 0, 0, 0, - 0, 0, 24, 26, 0, 0, 28, 0, 0, 0, - 0, 0, 21, 0, 0, 0, 22, 27, 0, 29, - 0, 30, 0, 0, 32, 0, 0, 36, 37, 31, - 0, 33, 0, 38, 39 -}; - -/* YYPGOTO[NTERM-NUM]. */ -static const yytype_int8 yypgoto[] = -{ - -62, -62, -62, -62, -62, -62, -62, -62, -62, -62, - -61, -55, -16, -20, -12, 98, -62, -62, -62, -62, - -62, -62, -62, -62, -62, -62 -}; - -/* YYDEFGOTO[NTERM-NUM]. */ -static const yytype_uint8 yydefgoto[] = -{ - 0, 1, 9, 29, 10, 18, 38, 11, 46, 81, - 70, 93, 95, 112, 114, 60, 121, 125, 142, 146, - 24, 12, 27, 13, 32, 14 -}; - -/* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If - positive, shift that token. If negative, reduce the rule whose - number is the opposite. If YYTABLE_NINF, syntax error. */ -static const yytype_uint8 yytable[] = -{ - 78, 36, 15, 2, 37, 34, 19, 3, 4, 40, - 20, 90, 5, 6, 7, 8, 35, 48, 54, 63, - 41, 100, 87, 87, 87, 106, 109, 87, 49, 55, - 64, 127, 130, 88, 96, 104, 107, 110, 115, 109, - 106, 130, 128, 131, 127, 44, 16, 21, 45, 23, - 157, 158, 163, 17, 33, 164, 58, 59, 79, 80, - 22, 25, 26, 28, 31, 30, 50, 42, 39, 43, - 56, 47, 65, 51, 68, 52, 67, 53, 69, 61, - 57, 62, 74, 150, 84, 66, 72, 75, 73, 76, - 92, 77, 94, 82, 83, 124, 102, 89, 85, 86, - 99, 91, 111, 97, 98, 113, 117, 118, 101, 103, - 105, 108, 122, 116, 120, 119, 123, 134, 137, 148, - 126, 139, 129, 143, 132, 135, 133, 136, 140, 138, - 141, 145, 144, 152, 155, 147, 162, 149, 153, 151, - 156, 160, 154, 0, 159, 161, 0, 0, 0, 0, - 0, 71 -}; - -static const yytype_int16 yycheck[] = -{ - 61, 3, 13, 0, 6, 3, 13, 4, 5, 3, - 13, 72, 9, 10, 11, 12, 14, 3, 3, 3, - 14, 82, 3, 3, 3, 3, 3, 3, 14, 14, - 14, 3, 3, 14, 14, 14, 14, 14, 14, 3, - 3, 3, 14, 14, 3, 3, 3, 3, 6, 3, - 14, 14, 14, 10, 15, 14, 7, 8, 7, 8, - 13, 13, 3, 6, 3, 13, 3, 13, 15, 14, - 3, 15, 3, 15, 3, 13, 16, 13, 3, 13, - 15, 13, 3, 138, 3, 15, 13, 13, 16, 13, - 3, 14, 3, 13, 16, 7, 3, 14, 16, 15, - 14, 16, 3, 13, 13, 3, 3, 3, 16, 15, - 15, 15, 3, 16, 8, 15, 15, 3, 3, 135, - 15, 3, 15, 3, 16, 13, 16, 16, 15, 13, - 8, 7, 15, 3, 3, 16, 156, 16, 13, 16, - 13, 153, 16, -1, 16, 16, -1, -1, -1, -1, - -1, 53 -}; - -/* YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of - state STATE-NUM. */ -static const yytype_int8 yystos[] = -{ - 0, 18, 0, 4, 5, 9, 10, 11, 12, 19, - 21, 24, 38, 40, 42, 13, 3, 10, 22, 13, - 13, 3, 13, 3, 37, 13, 3, 39, 6, 20, - 13, 3, 41, 15, 3, 14, 3, 6, 23, 15, - 3, 14, 13, 14, 3, 6, 25, 15, 3, 14, - 3, 15, 13, 13, 3, 14, 3, 15, 7, 8, - 32, 13, 13, 3, 14, 3, 15, 16, 3, 3, - 27, 32, 13, 16, 3, 13, 13, 14, 27, 7, - 8, 26, 13, 16, 3, 16, 15, 3, 14, 14, - 27, 16, 3, 28, 3, 29, 14, 13, 13, 14, - 27, 16, 3, 15, 14, 15, 3, 14, 15, 3, - 14, 3, 30, 3, 31, 14, 16, 3, 3, 15, - 8, 33, 3, 15, 7, 34, 15, 3, 14, 15, - 3, 14, 16, 16, 3, 13, 16, 3, 13, 3, - 15, 8, 35, 3, 15, 7, 36, 16, 29, 16, - 28, 16, 3, 13, 16, 3, 13, 14, 14, 16, - 31, 16, 30, 14, 14 -}; - -/* YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM. */ -static const yytype_int8 yyr1[] = -{ - 0, 17, 18, 18, 18, 18, 18, 18, 18, 19, - 20, 21, 22, 22, 23, 23, 23, 24, 25, 25, - 25, 26, 26, 27, 27, 27, 28, 28, 29, 29, - 30, 30, 31, 31, 32, 32, 33, 34, 35, 36, - 37, 37, 38, 39, 39, 40, 41, 41, 42 -}; - -/* YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM. */ -static const yytype_int8 yyr2[] = -{ - 0, 2, 2, 2, 2, 2, 2, 2, 0, 4, - 4, 5, 1, 1, 4, 5, 4, 5, 4, 5, - 4, 5, 5, 4, 5, 0, 4, 5, 4, 5, - 4, 5, 4, 5, 5, 5, 4, 4, 4, 4, - 4, 5, 4, 4, 5, 4, 4, 5, 4 -}; - - -enum { YYENOMEM = -2 }; - -#define yyerrok (yyerrstatus = 0) -#define yyclearin (yychar = YYEMPTY) - -#define YYACCEPT goto yyacceptlab -#define YYABORT goto yyabortlab -#define YYERROR goto yyerrorlab -#define YYNOMEM goto yyexhaustedlab - - -#define YYRECOVERING() (!!yyerrstatus) - -#define YYBACKUP(Token, Value) \ - do \ - if (yychar == YYEMPTY) \ - { \ - yychar = (Token); \ - yylval = (Value); \ - YYPOPSTACK (yylen); \ - yystate = *yyssp; \ - goto yybackup; \ - } \ - else \ - { \ - yyerror (YY_("syntax error: cannot back up")); \ - YYERROR; \ - } \ - while (0) - -/* Backward compatibility with an undocumented macro. - Use YYerror or YYUNDEF. */ -#define YYERRCODE YYUNDEF - - -/* Enable debugging if requested. */ -#if YYDEBUG - -# ifndef YYFPRINTF -# include /* INFRINGES ON USER NAME SPACE */ -# define YYFPRINTF fprintf -# endif - -# define YYDPRINTF(Args) \ -do { \ - if (yydebug) \ - YYFPRINTF Args; \ -} while (0) - - - - -# define YY_SYMBOL_PRINT(Title, Kind, Value, Location) \ -do { \ - if (yydebug) \ - { \ - YYFPRINTF (stderr, "%s ", Title); \ - yy_symbol_print (stderr, \ - Kind, Value); \ - YYFPRINTF (stderr, "\n"); \ - } \ -} while (0) - - -/*-----------------------------------. -| Print this symbol's value on YYO. | -`-----------------------------------*/ - -static void -yy_symbol_value_print (FILE *yyo, - yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep) -{ - FILE *yyoutput = yyo; - YY_USE (yyoutput); - if (!yyvaluep) - return; - YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN - YY_USE (yykind); - YY_IGNORE_MAYBE_UNINITIALIZED_END -} - - -/*---------------------------. -| Print this symbol on YYO. | -`---------------------------*/ - -static void -yy_symbol_print (FILE *yyo, - yysymbol_kind_t yykind, YYSTYPE const * const yyvaluep) -{ - YYFPRINTF (yyo, "%s %s (", - yykind < YYNTOKENS ? "token" : "nterm", yysymbol_name (yykind)); - - yy_symbol_value_print (yyo, yykind, yyvaluep); - YYFPRINTF (yyo, ")"); -} - -/*------------------------------------------------------------------. -| yy_stack_print -- Print the state stack from its BOTTOM up to its | -| TOP (included). | -`------------------------------------------------------------------*/ - -static void -yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop) -{ - YYFPRINTF (stderr, "Stack now"); - for (; yybottom <= yytop; yybottom++) - { - int yybot = *yybottom; - YYFPRINTF (stderr, " %d", yybot); - } - YYFPRINTF (stderr, "\n"); -} - -# define YY_STACK_PRINT(Bottom, Top) \ -do { \ - if (yydebug) \ - yy_stack_print ((Bottom), (Top)); \ -} while (0) - - -/*------------------------------------------------. -| Report that the YYRULE is going to be reduced. | -`------------------------------------------------*/ - -static void -yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp, - int yyrule) -{ - int yylno = yyrline[yyrule]; - int yynrhs = yyr2[yyrule]; - int yyi; - YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n", - yyrule - 1, yylno); - /* The symbols being reduced. */ - for (yyi = 0; yyi < yynrhs; yyi++) - { - YYFPRINTF (stderr, " $%d = ", yyi + 1); - yy_symbol_print (stderr, - YY_ACCESSING_SYMBOL (+yyssp[yyi + 1 - yynrhs]), - &yyvsp[(yyi + 1) - (yynrhs)]); - YYFPRINTF (stderr, "\n"); - } -} - -# define YY_REDUCE_PRINT(Rule) \ -do { \ - if (yydebug) \ - yy_reduce_print (yyssp, yyvsp, Rule); \ -} while (0) - -/* Nonzero means print parse trace. It is left uninitialized so that - multiple parsers can coexist. */ -int yydebug; -#else /* !YYDEBUG */ -# define YYDPRINTF(Args) ((void) 0) -# define YY_SYMBOL_PRINT(Title, Kind, Value, Location) -# define YY_STACK_PRINT(Bottom, Top) -# define YY_REDUCE_PRINT(Rule) -#endif /* !YYDEBUG */ - - -/* YYINITDEPTH -- initial size of the parser's stacks. */ -#ifndef YYINITDEPTH -# define YYINITDEPTH 200 -#endif - -/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only - if the built-in stack extension method is used). - - Do not make this value too large; the results are undefined if - YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) - evaluated with infinite-precision integer arithmetic. */ - -#ifndef YYMAXDEPTH -# define YYMAXDEPTH 10000 -#endif - - - - - - -/*-----------------------------------------------. -| Release the memory associated to this symbol. | -`-----------------------------------------------*/ - -static void -yydestruct (const char *yymsg, - yysymbol_kind_t yykind, YYSTYPE *yyvaluep) -{ - YY_USE (yyvaluep); - if (!yymsg) - yymsg = "Deleting"; - YY_SYMBOL_PRINT (yymsg, yykind, yyvaluep, yylocationp); - - YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN - YY_USE (yykind); - YY_IGNORE_MAYBE_UNINITIALIZED_END -} - - -/* Lookahead token kind. */ -int yychar; - -/* The semantic value of the lookahead symbol. */ -YYSTYPE yylval; -/* Number of syntax errors so far. */ -int yynerrs; - - - - -/*----------. -| yyparse. | -`----------*/ - -int -yyparse (void) -{ - yy_state_fast_t yystate = 0; - /* Number of tokens to shift before error messages enabled. */ - int yyerrstatus = 0; - - /* Refer to the stacks through separate pointers, to allow yyoverflow - to reallocate them elsewhere. */ - - /* Their size. */ - YYPTRDIFF_T yystacksize = YYINITDEPTH; - - /* The state stack: array, bottom, top. */ - yy_state_t yyssa[YYINITDEPTH]; - yy_state_t *yyss = yyssa; - yy_state_t *yyssp = yyss; - - /* The semantic value stack: array, bottom, top. */ - YYSTYPE yyvsa[YYINITDEPTH]; - YYSTYPE *yyvs = yyvsa; - YYSTYPE *yyvsp = yyvs; - - int yyn; - /* The return value of yyparse. */ - int yyresult; - /* Lookahead symbol kind. */ - yysymbol_kind_t yytoken = YYSYMBOL_YYEMPTY; - /* The variables used to return semantic value and location from the - action routines. */ - YYSTYPE yyval; - - - -#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) - - /* The number of symbols on the RHS of the reduced rule. - Keep to zero when no symbol should be popped. */ - int yylen = 0; - - YYDPRINTF ((stderr, "Starting parse\n")); - - yychar = YYEMPTY; /* Cause a token to be read. */ - - goto yysetstate; - - -/*------------------------------------------------------------. -| yynewstate -- push a new state, which is found in yystate. | -`------------------------------------------------------------*/ -yynewstate: - /* In all cases, when you get here, the value and location stacks - have just been pushed. So pushing a state here evens the stacks. */ - yyssp++; - - -/*--------------------------------------------------------------------. -| yysetstate -- set current state (the top of the stack) to yystate. | -`--------------------------------------------------------------------*/ -yysetstate: - YYDPRINTF ((stderr, "Entering state %d\n", yystate)); - YY_ASSERT (0 <= yystate && yystate < YYNSTATES); - YY_IGNORE_USELESS_CAST_BEGIN - *yyssp = YY_CAST (yy_state_t, yystate); - YY_IGNORE_USELESS_CAST_END - YY_STACK_PRINT (yyss, yyssp); - - if (yyss + yystacksize - 1 <= yyssp) -#if !defined yyoverflow && !defined YYSTACK_RELOCATE - YYNOMEM; -#else - { - /* Get the current used size of the three stacks, in elements. */ - YYPTRDIFF_T yysize = yyssp - yyss + 1; - -# if defined yyoverflow - { - /* Give user a chance to reallocate the stack. Use copies of - these so that the &'s don't force the real ones into - memory. */ - yy_state_t *yyss1 = yyss; - YYSTYPE *yyvs1 = yyvs; - - /* Each stack pointer address is followed by the size of the - data in use in that stack, in bytes. This used to be a - conditional around just the two extra args, but that might - be undefined if yyoverflow is a macro. */ - yyoverflow (YY_("memory exhausted"), - &yyss1, yysize * YYSIZEOF (*yyssp), - &yyvs1, yysize * YYSIZEOF (*yyvsp), - &yystacksize); - yyss = yyss1; - yyvs = yyvs1; - } -# else /* defined YYSTACK_RELOCATE */ - /* Extend the stack our own way. */ - if (YYMAXDEPTH <= yystacksize) - YYNOMEM; - yystacksize *= 2; - if (YYMAXDEPTH < yystacksize) - yystacksize = YYMAXDEPTH; - - { - yy_state_t *yyss1 = yyss; - union yyalloc *yyptr = - YY_CAST (union yyalloc *, - YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); - if (! yyptr) - YYNOMEM; - YYSTACK_RELOCATE (yyss_alloc, yyss); - YYSTACK_RELOCATE (yyvs_alloc, yyvs); -# undef YYSTACK_RELOCATE - if (yyss1 != yyssa) - YYSTACK_FREE (yyss1); - } -# endif - - yyssp = yyss + yysize - 1; - yyvsp = yyvs + yysize - 1; - - YY_IGNORE_USELESS_CAST_BEGIN - YYDPRINTF ((stderr, "Stack size increased to %ld\n", - YY_CAST (long, yystacksize))); - YY_IGNORE_USELESS_CAST_END - - if (yyss + yystacksize - 1 <= yyssp) - YYABORT; - } -#endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */ - - - if (yystate == YYFINAL) - YYACCEPT; - - goto yybackup; - - -/*-----------. -| yybackup. | -`-----------*/ -yybackup: - /* Do appropriate processing given the current state. Read a - lookahead token if we need one and don't already have one. */ - - /* First try to decide what to do without reference to lookahead token. */ - yyn = yypact[yystate]; - if (yypact_value_is_default (yyn)) - goto yydefault; - - /* Not known => get a lookahead token if don't already have one. */ - - /* YYCHAR is either empty, or end-of-input, or a valid lookahead. */ - if (yychar == YYEMPTY) - { - YYDPRINTF ((stderr, "Reading a token\n")); - yychar = yylex (); - } - - if (yychar <= YYEOF) - { - yychar = YYEOF; - yytoken = YYSYMBOL_YYEOF; - YYDPRINTF ((stderr, "Now at end of input.\n")); - } - else if (yychar == YYerror) - { - /* The scanner already issued an error message, process directly - to error recovery. But do not keep the error token as - lookahead, it is too special and may lead us to an endless - loop in error recovery. */ - yychar = YYUNDEF; - yytoken = YYSYMBOL_YYerror; - goto yyerrlab1; - } - else - { - yytoken = YYTRANSLATE (yychar); - YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); - } - - /* If the proper action on seeing token YYTOKEN is to reduce or to - detect an error, take that action. */ - yyn += yytoken; - if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) - goto yydefault; - yyn = yytable[yyn]; - if (yyn <= 0) - { - if (yytable_value_is_error (yyn)) - goto yyerrlab; - yyn = -yyn; - goto yyreduce; - } - - /* Count tokens shifted since error; after three, turn off error - status. */ - if (yyerrstatus) - yyerrstatus--; - - /* Shift the lookahead token. */ - YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); - yystate = yyn; - YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN - *++yyvsp = yylval; - YY_IGNORE_MAYBE_UNINITIALIZED_END - - /* Discard the shifted token. */ - yychar = YYEMPTY; - goto yynewstate; - - -/*-----------------------------------------------------------. -| yydefault -- do the default action for the current state. | -`-----------------------------------------------------------*/ -yydefault: - yyn = yydefact[yystate]; - if (yyn == 0) - goto yyerrlab; - goto yyreduce; - - -/*-----------------------------. -| yyreduce -- do a reduction. | -`-----------------------------*/ -yyreduce: - /* yyn is the number of a rule to reduce with. */ - yylen = yyr2[yyn]; - - /* If YYLEN is nonzero, implement the default value of the action: - '$$ = $1'. - - Otherwise, the following line sets YYVAL to garbage. - This behavior is undocumented and Bison - users should not rely upon it. Assigning to YYVAL - unconditionally makes the parser a bit smaller, and it avoids a - GCC warning that YYVAL may be used uninitialized. */ - yyval = yyvsp[1-yylen]; - - - YY_REDUCE_PRINT (yyn); - switch (yyn) - { - case 2: /* start: start group */ -#line 56 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1290 "parse.c" - break; - - case 3: /* start: start mount */ -#line 60 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1298 "parse.c" - break; - - case 4: /* start: start default */ -#line 64 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1306 "parse.c" - break; - - case 5: /* start: start namespace */ -#line 68 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1314 "parse.c" - break; - - case 6: /* start: start template */ -#line 72 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1322 "parse.c" - break; - - case 7: /* start: start systemd */ -#line 76 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1330 "parse.c" - break; - - case 8: /* start: %empty */ -#line 80 "parse.y" - { - (yyval.val) = 1; - } -#line 1338 "parse.c" - break; - - case 9: /* default: DEFAULT '{' default_conf '}' */ -#line 86 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if ((yyval.val)) { - cgroup_config_define_default(); - } - } -#line 1349 "parse.c" - break; - - case 10: /* default_conf: PERM '{' task_or_admin '}' */ -#line 96 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - } -#line 1357 "parse.c" - break; - - case 11: /* group: GROUP group_name '{' group_conf '}' */ -#line 102 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if ((yyval.val)) { - (yyval.val) = cgroup_config_insert_cgroup((yyvsp[-3].name)); - if (!(yyval.val)) { - fprintf(stderr, "failed to insert group check size and memory"); - (yyval.val) = ECGOTHER; - return (yyval.val); - } - } else { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1377 "parse.c" - break; - - case 12: /* group_name: ID */ -#line 121 "parse.y" - { - (yyval.name) = (yyvsp[0].name); - } -#line 1385 "parse.c" - break; - - case 13: /* group_name: DEFAULT */ -#line 125 "parse.y" - { - (yyval.name) = (yyvsp[0].name); - } -#line 1393 "parse.c" - break; - - case 14: /* group_conf: ID '{' namevalue_conf '}' */ -#line 131 "parse.y" - { - (yyval.val) = cgroup_config_parse_controller_options((yyvsp[-3].name), (yyvsp[-1].values)); - cgroup_dictionary_free((yyvsp[-1].values)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1407 "parse.c" - break; - - case 15: /* group_conf: group_conf ID '{' namevalue_conf '}' */ -#line 141 "parse.y" - { - (yyval.val) = cgroup_config_parse_controller_options((yyvsp[-3].name), (yyvsp[-1].values)); - cgroup_dictionary_free((yyvsp[-1].values)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1421 "parse.c" - break; - - case 16: /* group_conf: PERM '{' task_or_admin '}' */ -#line 151 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1434 "parse.c" - break; - - case 17: /* template: TEMPLATE ID '{' template_conf '}' */ -#line 162 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if ((yyval.val)) { - (yyval.val) = template_config_insert_cgroup((yyvsp[-3].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGOTHER; - return (yyval.val); - } - } else { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1454 "parse.c" - break; - - case 18: /* template_conf: ID '{' namevalue_conf '}' */ -#line 182 "parse.y" - { - (yyval.val) = template_config_parse_controller_options((yyvsp[-3].name), (yyvsp[-1].values)); - cgroup_dictionary_free((yyvsp[-1].values)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1468 "parse.c" - break; - - case 19: /* template_conf: template_conf ID '{' namevalue_conf '}' */ -#line 192 "parse.y" - { - (yyval.val) = template_config_parse_controller_options((yyvsp[-3].name), (yyvsp[-1].values)); - cgroup_dictionary_free((yyvsp[-1].values)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1482 "parse.c" - break; - - case 20: /* template_conf: PERM '{' template_task_or_admin '}' */ -#line 202 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1495 "parse.c" - break; - - case 21: /* template_task_or_admin: TASK '{' template_task_namevalue_conf '}' template_admin_conf */ -#line 214 "parse.y" - { - (yyval.val) = (yyvsp[-2].val) && (yyvsp[0].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1508 "parse.c" - break; - - case 22: /* template_task_or_admin: ADMIN '{' template_admin_namevalue_conf '}' template_task_conf */ -#line 223 "parse.y" - { - (yyval.val) = (yyvsp[-2].val) && (yyvsp[0].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1521 "parse.c" - break; - - case 23: /* namevalue_conf: ID '=' ID ';' */ -#line 236 "parse.y" - { - struct cgroup_dictionary *dict; - int ret; - ret = cgroup_dictionary_create(&dict, 0); - if (ret == 0) - ret = cgroup_dictionary_add(dict, (yyvsp[-3].name), (yyvsp[-1].name)); - if (ret) { - fprintf(stderr, "parsing failed at line number %d:%s\n", line_no, - cgroup_strerror(ret)); - (yyval.values) = NULL; - cgroup_dictionary_free(dict); - return ECGCONFIGPARSEFAIL; - } - (yyval.values) = dict; - } -#line 1541 "parse.c" - break; - - case 24: /* namevalue_conf: namevalue_conf ID '=' ID ';' */ -#line 252 "parse.y" - { - int ret = 0; - ret = cgroup_dictionary_add((yyvsp[-4].values), (yyvsp[-3].name), (yyvsp[-1].name)); - if (ret != 0) { - fprintf(stderr, "parsing failed at line number %d: %s\n", line_no, - cgroup_strerror(ret)); - (yyval.values) = NULL; - return ECGCONFIGPARSEFAIL; - } - (yyval.values) = (yyvsp[-4].values); - } -#line 1557 "parse.c" - break; - - case 25: /* namevalue_conf: %empty */ -#line 264 "parse.y" - { - (yyval.values) = NULL; - } -#line 1565 "parse.c" - break; - - case 26: /* task_namevalue_conf: ID '=' ID ';' */ -#line 271 "parse.y" - { - (yyval.val) = cgroup_config_group_task_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1578 "parse.c" - break; - - case 27: /* task_namevalue_conf: task_namevalue_conf ID '=' ID ';' */ -#line 280 "parse.y" - { - (yyval.val) = (yyvsp[-4].val) && cgroup_config_group_task_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1591 "parse.c" - break; - - case 28: /* admin_namevalue_conf: ID '=' ID ';' */ -#line 292 "parse.y" - { - (yyval.val) = cgroup_config_group_admin_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1604 "parse.c" - break; - - case 29: /* admin_namevalue_conf: admin_namevalue_conf ID '=' ID ';' */ -#line 301 "parse.y" - { - (yyval.val) = (yyvsp[-4].val) && cgroup_config_group_admin_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1617 "parse.c" - break; - - case 30: /* template_task_namevalue_conf: ID '=' ID ';' */ -#line 313 "parse.y" - { - (yyval.val) = template_config_group_task_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1630 "parse.c" - break; - - case 31: /* template_task_namevalue_conf: template_task_namevalue_conf ID '=' ID ';' */ -#line 322 "parse.y" - { - (yyval.val) = (yyvsp[-4].val) && template_config_group_task_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1643 "parse.c" - break; - - case 32: /* template_admin_namevalue_conf: ID '=' ID ';' */ -#line 334 "parse.y" - { - (yyval.val) = template_config_group_admin_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1656 "parse.c" - break; - - case 33: /* template_admin_namevalue_conf: template_admin_namevalue_conf ID '=' ID ';' */ -#line 343 "parse.y" - { - (yyval.val) = (yyvsp[-4].val) && template_config_group_admin_perm((yyvsp[-3].name), (yyvsp[-1].name)); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1669 "parse.c" - break; - - case 34: /* task_or_admin: TASK '{' task_namevalue_conf '}' admin_conf */ -#line 356 "parse.y" - { - (yyval.val) = (yyvsp[-2].val) && (yyvsp[0].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1682 "parse.c" - break; - - case 35: /* task_or_admin: ADMIN '{' admin_namevalue_conf '}' task_conf */ -#line 365 "parse.y" - { - (yyval.val) = (yyvsp[-2].val) && (yyvsp[0].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1695 "parse.c" - break; - - case 36: /* admin_conf: ADMIN '{' admin_namevalue_conf '}' */ -#line 376 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1708 "parse.c" - break; - - case 37: /* task_conf: TASK '{' task_namevalue_conf '}' */ -#line 387 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1721 "parse.c" - break; - - case 38: /* template_admin_conf: ADMIN '{' template_admin_namevalue_conf '}' */ -#line 398 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1734 "parse.c" - break; - - case 39: /* template_task_conf: TASK '{' template_task_namevalue_conf '}' */ -#line 409 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1747 "parse.c" - break; - - case 40: /* mountvalue_conf: ID '=' ID ';' */ -#line 421 "parse.y" - { - if (!cgroup_config_insert_into_mount_table((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_config_cleanup_mount_table(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1760 "parse.c" - break; - - case 41: /* mountvalue_conf: mountvalue_conf ID '=' ID ';' */ -#line 430 "parse.y" - { - if (!cgroup_config_insert_into_mount_table((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_config_cleanup_mount_table(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1773 "parse.c" - break; - - case 42: /* mount: MOUNT '{' mountvalue_conf '}' */ -#line 441 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1786 "parse.c" - break; - - case 43: /* namespace_conf: ID '=' ID ';' */ -#line 453 "parse.y" - { - if (!cgroup_config_insert_into_namespace_table((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_config_cleanup_namespace_table(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1799 "parse.c" - break; - - case 44: /* namespace_conf: namespace_conf ID '=' ID ';' */ -#line 462 "parse.y" - { - if (!cgroup_config_insert_into_namespace_table((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_config_cleanup_namespace_table(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1812 "parse.c" - break; - - case 45: /* namespace: NAMESPACE '{' namespace_conf '}' */ -#line 473 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1825 "parse.c" - break; - - case 46: /* systemdvalue_conf: ID '=' ID ';' */ -#line 485 "parse.y" - { - if (!cgroup_alloc_systemd_opts((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_cleanup_systemd_opts(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1838 "parse.c" - break; - - case 47: /* systemdvalue_conf: systemdvalue_conf ID '=' ID ';' */ -#line 494 "parse.y" - { - if (!cgroup_add_systemd_opts((yyvsp[-3].name), (yyvsp[-1].name))) { - cgroup_cleanup_systemd_opts(); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - (yyval.val) = 1; - } -#line 1851 "parse.c" - break; - - case 48: /* systemd: SYSTEMD '{' systemdvalue_conf '}' */ -#line 505 "parse.y" - { - (yyval.val) = (yyvsp[-1].val); - if (!(yyval.val)) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - (yyval.val) = ECGCONFIGPARSEFAIL; - return (yyval.val); - } - } -#line 1864 "parse.c" - break; - - -#line 1868 "parse.c" - - default: break; - } - /* User semantic actions sometimes alter yychar, and that requires - that yytoken be updated with the new translation. We take the - approach of translating immediately before every use of yytoken. - One alternative is translating here after every semantic action, - but that translation would be missed if the semantic action invokes - YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or - if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an - incorrect destructor might then be invoked immediately. In the - case of YYERROR or YYBACKUP, subsequent parser actions might lead - to an incorrect destructor call or verbose syntax error message - before the lookahead is translated. */ - YY_SYMBOL_PRINT ("-> $$ =", YY_CAST (yysymbol_kind_t, yyr1[yyn]), &yyval, &yyloc); - - YYPOPSTACK (yylen); - yylen = 0; - - *++yyvsp = yyval; - - /* Now 'shift' the result of the reduction. Determine what state - that goes to, based on the state we popped back to and the rule - number reduced by. */ - { - const int yylhs = yyr1[yyn] - YYNTOKENS; - const int yyi = yypgoto[yylhs] + *yyssp; - yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp - ? yytable[yyi] - : yydefgoto[yylhs]); - } - - goto yynewstate; - - -/*--------------------------------------. -| yyerrlab -- here on detecting error. | -`--------------------------------------*/ -yyerrlab: - /* Make sure we have latest lookahead translation. See comments at - user semantic actions for why this is necessary. */ - yytoken = yychar == YYEMPTY ? YYSYMBOL_YYEMPTY : YYTRANSLATE (yychar); - /* If not already recovering from an error, report this error. */ - if (!yyerrstatus) - { - ++yynerrs; - yyerror (YY_("syntax error")); - } - - if (yyerrstatus == 3) - { - /* If just tried and failed to reuse lookahead token after an - error, discard it. */ - - if (yychar <= YYEOF) - { - /* Return failure if at end of input. */ - if (yychar == YYEOF) - YYABORT; - } - else - { - yydestruct ("Error: discarding", - yytoken, &yylval); - yychar = YYEMPTY; - } - } - - /* Else will try to reuse lookahead token after shifting the error - token. */ - goto yyerrlab1; - - -/*---------------------------------------------------. -| yyerrorlab -- error raised explicitly by YYERROR. | -`---------------------------------------------------*/ -yyerrorlab: - /* Pacify compilers when the user code never invokes YYERROR and the - label yyerrorlab therefore never appears in user code. */ - if (0) - YYERROR; - ++yynerrs; - - /* Do not reclaim the symbols of the rule whose action triggered - this YYERROR. */ - YYPOPSTACK (yylen); - yylen = 0; - YY_STACK_PRINT (yyss, yyssp); - yystate = *yyssp; - goto yyerrlab1; - - -/*-------------------------------------------------------------. -| yyerrlab1 -- common code for both syntax error and YYERROR. | -`-------------------------------------------------------------*/ -yyerrlab1: - yyerrstatus = 3; /* Each real token shifted decrements this. */ - - /* Pop stack until we find a state that shifts the error token. */ - for (;;) - { - yyn = yypact[yystate]; - if (!yypact_value_is_default (yyn)) - { - yyn += YYSYMBOL_YYerror; - if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYSYMBOL_YYerror) - { - yyn = yytable[yyn]; - if (0 < yyn) - break; - } - } - - /* Pop the current state because it cannot handle the error token. */ - if (yyssp == yyss) - YYABORT; - - - yydestruct ("Error: popping", - YY_ACCESSING_SYMBOL (yystate), yyvsp); - YYPOPSTACK (1); - yystate = *yyssp; - YY_STACK_PRINT (yyss, yyssp); - } - - YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN - *++yyvsp = yylval; - YY_IGNORE_MAYBE_UNINITIALIZED_END - - - /* Shift the error token. */ - YY_SYMBOL_PRINT ("Shifting", YY_ACCESSING_SYMBOL (yyn), yyvsp, yylsp); - - yystate = yyn; - goto yynewstate; - - -/*-------------------------------------. -| yyacceptlab -- YYACCEPT comes here. | -`-------------------------------------*/ -yyacceptlab: - yyresult = 0; - goto yyreturnlab; - - -/*-----------------------------------. -| yyabortlab -- YYABORT comes here. | -`-----------------------------------*/ -yyabortlab: - yyresult = 1; - goto yyreturnlab; - - -/*-----------------------------------------------------------. -| yyexhaustedlab -- YYNOMEM (memory exhaustion) comes here. | -`-----------------------------------------------------------*/ -yyexhaustedlab: - yyerror (YY_("memory exhausted")); - yyresult = 2; - goto yyreturnlab; - - -/*----------------------------------------------------------. -| yyreturnlab -- parsing is finished, clean up and return. | -`----------------------------------------------------------*/ -yyreturnlab: - if (yychar != YYEMPTY) - { - /* Make sure we have latest lookahead translation. See comments at - user semantic actions for why this is necessary. */ - yytoken = YYTRANSLATE (yychar); - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); - } - /* Do not reclaim the symbols of the rule whose action triggered - this YYABORT or YYACCEPT. */ - YYPOPSTACK (yylen); - YY_STACK_PRINT (yyss, yyssp); - while (yyssp != yyss) - { - yydestruct ("Cleanup: popping", - YY_ACCESSING_SYMBOL (+*yyssp), yyvsp); - YYPOPSTACK (1); - } -#ifndef yyoverflow - if (yyss != yyssa) - YYSTACK_FREE (yyss); -#endif - - return yyresult; -} - -#line 514 "parse.y" - diff --git a/lib/libcgroup-3.1.0/src/parse.h b/lib/libcgroup-3.1.0/src/parse.h deleted file mode 100644 index 8ca26d6aedc..00000000000 --- a/lib/libcgroup-3.1.0/src/parse.h +++ /dev/null @@ -1,112 +0,0 @@ -/* A Bison parser, made by GNU Bison 3.8.2. */ - -/* Bison interface for Yacc-like parsers in C - - Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2021 Free Software Foundation, - Inc. - - 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 3 of the License, or - (at your option) any later version. - - 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, see . */ - -/* As a special exception, you may create a larger work that contains - part or all of the Bison parser skeleton and distribute that work - under terms of your choice, so long as that work isn't itself a - parser generator using the skeleton or a modified version thereof - as a parser skeleton. Alternatively, if you modify or redistribute - the parser skeleton itself, you may (at your option) remove this - special exception, which will cause the skeleton and the resulting - Bison output files to be licensed under the GNU General Public - License without this special exception. - - This special exception was added by the Free Software Foundation in - version 2.2 of Bison. */ - -/* DO NOT RELY ON FEATURES THAT ARE NOT DOCUMENTED in the manual, - especially those whose name start with YY_ or yy_. They are - private implementation details that can be changed or removed. */ - -#ifndef YY_YY_PARSE_H_INCLUDED -# define YY_YY_PARSE_H_INCLUDED -/* Debug traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif -#if YYDEBUG -extern int yydebug; -#endif - -/* Token kinds. */ -#ifndef YYTOKENTYPE -# define YYTOKENTYPE - enum yytokentype - { - YYEMPTY = -2, - YYEOF = 0, /* "end of file" */ - YYerror = 256, /* error */ - YYUNDEF = 257, /* "invalid token" */ - ID = 258, /* ID */ - MOUNT = 259, /* MOUNT */ - GROUP = 260, /* GROUP */ - PERM = 261, /* PERM */ - TASK = 262, /* TASK */ - ADMIN = 263, /* ADMIN */ - NAMESPACE = 264, /* NAMESPACE */ - DEFAULT = 265, /* DEFAULT */ - TEMPLATE = 266, /* TEMPLATE */ - SYSTEMD = 267 /* SYSTEMD */ - }; - typedef enum yytokentype yytoken_kind_t; -#endif -/* Token kinds. */ -#define YYEMPTY -2 -#define YYEOF 0 -#define YYerror 256 -#define YYUNDEF 257 -#define ID 258 -#define MOUNT 259 -#define GROUP 260 -#define PERM 261 -#define TASK 262 -#define ADMIN 263 -#define NAMESPACE 264 -#define DEFAULT 265 -#define TEMPLATE 266 -#define SYSTEMD 267 - -/* Value type. */ -#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED -union YYSTYPE -{ -#line 36 "parse.y" - - char *name; - char chr; - int val; - struct cgroup_dictionary *values; - -#line 98 "parse.h" - -}; -typedef union YYSTYPE YYSTYPE; -# define YYSTYPE_IS_TRIVIAL 1 -# define YYSTYPE_IS_DECLARED 1 -#endif - - -extern YYSTYPE yylval; - - -int yyparse (void); - - -#endif /* !YY_YY_PARSE_H_INCLUDED */ diff --git a/lib/libcgroup-3.1.0/src/parse.y b/lib/libcgroup-3.1.0/src/parse.y deleted file mode 100644 index 01752857dc8..00000000000 --- a/lib/libcgroup-3.1.0/src/parse.y +++ /dev/null @@ -1,514 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright IBM Corporation. 2007 - * - * Authors: Balbir Singh - * - * NOTE: The grammar has been modified, not to be the most efficient, but - * to allow easy updation of internal data structures. - */ - -%{ -#include -#include -#include -#include -#include - -int yylex(void); -extern int line_no; -extern char *yytext; - -static void yyerror(const char *s) -{ - fprintf(stderr, "error at line number %d at %s:%s\n", line_no, yytext, s); -} - -int yywrap(void) -{ - return 1; -} - -%} - -%token ID MOUNT GROUP PERM TASK ADMIN NAMESPACE DEFAULT TEMPLATE SYSTEMD - -%union { - char *name; - char chr; - int val; - struct cgroup_dictionary *values; -} -%type group_name -%type mountvalue_conf mount task_namevalue_conf admin_namevalue_conf -%type admin_conf task_conf task_or_admin group_conf group start -%type namespace namespace_conf default default_conf -%type namevalue_conf -%type template template_conf -%type template_task_or_admin template_task_namevalue_conf -%type template_admin_namevalue_conf template_task_conf -%type template_admin_conf -%type systemdvalue_conf systemd -%start start -%% - -start : start group - { - $$ = $1; - } - | start mount - { - $$ = $1; - } - | start default - { - $$ = $1; - } - | start namespace - { - $$ = $1; - } - | start template - { - $$ = $1; - } - | start systemd - { - $$ = $1; - } - | - { - $$ = 1; - } - ; - -default : DEFAULT '{' default_conf '}' - { - $$ = $3; - if ($$) { - cgroup_config_define_default(); - } - } - ; - -default_conf - : PERM '{' task_or_admin '}' - { - $$ = $3; - } - ; - -group : GROUP group_name '{' group_conf '}' - { - $$ = $4; - if ($$) { - $$ = cgroup_config_insert_cgroup($2); - if (!$$) { - fprintf(stderr, "failed to insert group check size and memory"); - $$ = ECGOTHER; - return $$; - } - } else { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -group_name - : ID - { - $$ = $1; - } - | DEFAULT - { - $$ = $1; - } - -group_conf - : ID '{' namevalue_conf '}' - { - $$ = cgroup_config_parse_controller_options($1, $3); - cgroup_dictionary_free($3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | group_conf ID '{' namevalue_conf '}' - { - $$ = cgroup_config_parse_controller_options($2, $4); - cgroup_dictionary_free($4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | PERM '{' task_or_admin '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template : TEMPLATE ID '{' template_conf '}' - { - $$ = $4; - if ($$) { - $$ = template_config_insert_cgroup($2); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGOTHER; - return $$; - } - } else { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - - -template_conf - : ID '{' namevalue_conf '}' - { - $$ = template_config_parse_controller_options($1, $3); - cgroup_dictionary_free($3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | template_conf ID '{' namevalue_conf '}' - { - $$ = template_config_parse_controller_options($2, $4); - cgroup_dictionary_free($4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | PERM '{' template_task_or_admin '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template_task_or_admin - : TASK '{' template_task_namevalue_conf '}' template_admin_conf - { - $$ = $3 && $5; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | ADMIN '{' template_admin_namevalue_conf '}' template_task_conf - { - $$ = $3 && $5; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - - -namevalue_conf - : ID '=' ID ';' - { - struct cgroup_dictionary *dict; - int ret; - ret = cgroup_dictionary_create(&dict, 0); - if (ret == 0) - ret = cgroup_dictionary_add(dict, $1, $3); - if (ret) { - fprintf(stderr, "parsing failed at line number %d:%s\n", line_no, - cgroup_strerror(ret)); - $$ = NULL; - cgroup_dictionary_free(dict); - return ECGCONFIGPARSEFAIL; - } - $$ = dict; - } - | namevalue_conf ID '=' ID ';' - { - int ret = 0; - ret = cgroup_dictionary_add($1, $2, $4); - if (ret != 0) { - fprintf(stderr, "parsing failed at line number %d: %s\n", line_no, - cgroup_strerror(ret)); - $$ = NULL; - return ECGCONFIGPARSEFAIL; - } - $$ = $1; - } - | - { - $$ = NULL; - } - ; - -task_namevalue_conf - : ID '=' ID ';' - { - $$ = cgroup_config_group_task_perm($1, $3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | task_namevalue_conf ID '=' ID ';' - { - $$ = $1 && cgroup_config_group_task_perm($2, $4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -admin_namevalue_conf - : ID '=' ID ';' - { - $$ = cgroup_config_group_admin_perm($1, $3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | admin_namevalue_conf ID '=' ID ';' - { - $$ = $1 && cgroup_config_group_admin_perm($2, $4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template_task_namevalue_conf - : ID '=' ID ';' - { - $$ = template_config_group_task_perm($1, $3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | template_task_namevalue_conf ID '=' ID ';' - { - $$ = $1 && template_config_group_task_perm($2, $4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template_admin_namevalue_conf - : ID '=' ID ';' - { - $$ = template_config_group_admin_perm($1, $3); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | template_admin_namevalue_conf ID '=' ID ';' - { - $$ = $1 && template_config_group_admin_perm($2, $4); - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - - -task_or_admin - : TASK '{' task_namevalue_conf '}' admin_conf - { - $$ = $3 && $5; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - | ADMIN '{' admin_namevalue_conf '}' task_conf - { - $$ = $3 && $5; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -admin_conf: ADMIN '{' admin_namevalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -task_conf: TASK '{' task_namevalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template_admin_conf: ADMIN '{' template_admin_namevalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -template_task_conf: TASK '{' template_task_namevalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -mountvalue_conf - : ID '=' ID ';' - { - if (!cgroup_config_insert_into_mount_table($1, $3)) { - cgroup_config_cleanup_mount_table(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - | mountvalue_conf ID '=' ID ';' - { - if (!cgroup_config_insert_into_mount_table($2, $4)) { - cgroup_config_cleanup_mount_table(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - ; - -mount : MOUNT '{' mountvalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -namespace_conf - : ID '=' ID ';' - { - if (!cgroup_config_insert_into_namespace_table($1, $3)) { - cgroup_config_cleanup_namespace_table(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - | namespace_conf ID '=' ID ';' - { - if (!cgroup_config_insert_into_namespace_table($2, $4)) { - cgroup_config_cleanup_namespace_table(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - ; - -namespace : NAMESPACE '{' namespace_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; - -systemdvalue_conf - : ID '=' ID ';' - { - if (!cgroup_alloc_systemd_opts($1, $3)) { - cgroup_cleanup_systemd_opts(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - | systemdvalue_conf ID '=' ID ';' - { - if (!cgroup_add_systemd_opts($2, $4)) { - cgroup_cleanup_systemd_opts(); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - $$ = 1; - } - ; - -systemd : SYSTEMD '{' systemdvalue_conf '}' - { - $$ = $3; - if (!$$) { - fprintf(stderr, "parsing failed at line number %d\n", line_no); - $$ = ECGCONFIGPARSEFAIL; - return $$; - } - } - ; -%% diff --git a/lib/libcgroup-3.1.0/src/python/Makefile.am b/lib/libcgroup-3.1.0/src/python/Makefile.am deleted file mode 100644 index 71092d5cb57..00000000000 --- a/lib/libcgroup-3.1.0/src/python/Makefile.am +++ /dev/null @@ -1,43 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Libcgroup Python Bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# -@CODE_COVERAGE_RULES@ - -PY_DISTUTILS = \ - VERSION_RELEASE="@PACKAGE_VERSION@" \ - CPPFLAGS="-I\${top_srcdir}/include -I\${top_builddir}/include ${AM_CPPFLAGS} ${CPPLAGS} -O2" \ - CFLAGS="$(CODE_COVERAGE_CFLAGS) ${AM_CFLAGS} ${CFLAGS}" \ - LDFLAGS="$(CODE_COVERAGE_LIBS) ${AM_LDFLAGS} ${LDFLAGS}" \ - ${PYTHON} ${srcdir}/setup.py - -# support silent builds -PY_BUILD_0 = @echo " PYTHON " $@; ${PY_DISTUTILS} -q build -PY_BUILD_1 = ${PY_DISTUTILS} build -PY_BUILD_ = ${PY_BUILD_0} -PY_BUILD = ${PY_BUILD_@AM_V@} - -PY_INSTALL = ${PY_DISTUTILS} install - -EXTRA_DIST = cgroup.pxd libcgroup.pyx setup.py - -all-local: build - -build: ../libcgroup.la cgroup.pxd libcgroup.pyx setup.py - [ ${srcdir} == ${builddir} ] || cp ${srcdir}/libcgroup.pyx ${builddir} - ${PY_BUILD} && touch build - -install-exec-local: build - ${PY_INSTALL} --install-lib=${DESTDIR}/${pyexecdir} \ - --record=${DESTDIR}/${pyexecdir}/install_files.txt - -uninstall-local: - cat ${DESTDIR}/${pyexecdir}/install_files.txt | xargs ${RM} -f - ${RM} -f ${DESTDIR}/${pyexecdir}/install_files.txt - -clean-local: - [ ${srcdir} == ${builddir} ] || ${RM} -f ${builddir}/libcgroup.pyx - ${RM} -rf libcgroup.c build libcgroup.egg-info dist diff --git a/lib/libcgroup-3.1.0/src/python/Makefile.in b/lib/libcgroup-3.1.0/src/python/Makefile.in deleted file mode 100644 index 12a4831ea2a..00000000000 --- a/lib/libcgroup-3.1.0/src/python/Makefile.in +++ /dev/null @@ -1,517 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = src/python -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -PY_DISTUTILS = \ - VERSION_RELEASE="@PACKAGE_VERSION@" \ - CPPFLAGS="-I\${top_srcdir}/include -I\${top_builddir}/include ${AM_CPPFLAGS} ${CPPLAGS} -O2" \ - CFLAGS="$(CODE_COVERAGE_CFLAGS) ${AM_CFLAGS} ${CFLAGS}" \ - LDFLAGS="$(CODE_COVERAGE_LIBS) ${AM_LDFLAGS} ${LDFLAGS}" \ - ${PYTHON} ${srcdir}/setup.py - - -# support silent builds -PY_BUILD_0 = @echo " PYTHON " $@; ${PY_DISTUTILS} -q build -PY_BUILD_1 = ${PY_DISTUTILS} build -PY_BUILD_ = ${PY_BUILD_0} -PY_BUILD = ${PY_BUILD_@AM_V@} -PY_INSTALL = ${PY_DISTUTILS} install -EXTRA_DIST = cgroup.pxd libcgroup.pyx setup.py -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/python/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/python/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile all-local -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-local mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: install-exec-local - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-local - -.MAKE: install-am install-strip - -.PHONY: all all-am all-local check check-am clean clean-generic \ - clean-libtool clean-local cscopelist-am ctags-am distclean \ - distclean-generic distclean-libtool distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-exec-local install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am uninstall-local - -.PRECIOUS: Makefile - - -# SPDX-License-Identifier: LGPL-2.1-only -# -# Libcgroup Python Bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# -@CODE_COVERAGE_RULES@ - -all-local: build - -build: ../libcgroup.la cgroup.pxd libcgroup.pyx setup.py - [ ${srcdir} == ${builddir} ] || cp ${srcdir}/libcgroup.pyx ${builddir} - ${PY_BUILD} && touch build - -install-exec-local: build - ${PY_INSTALL} --install-lib=${DESTDIR}/${pyexecdir} \ - --record=${DESTDIR}/${pyexecdir}/install_files.txt - -uninstall-local: - cat ${DESTDIR}/${pyexecdir}/install_files.txt | xargs ${RM} -f - ${RM} -f ${DESTDIR}/${pyexecdir}/install_files.txt - -clean-local: - [ ${srcdir} == ${builddir} ] || ${RM} -f ${builddir}/libcgroup.pyx - ${RM} -rf libcgroup.c build libcgroup.egg-info dist - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/src/python/cgroup.pxd b/lib/libcgroup-3.1.0/src/python/cgroup.pxd deleted file mode 100644 index e591876a94a..00000000000 --- a/lib/libcgroup-3.1.0/src/python/cgroup.pxd +++ /dev/null @@ -1,133 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Libcgroup Python Bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -# cython: language_level = 3str - -from posix.types cimport pid_t, uid_t, gid_t, mode_t -from libcpp cimport bool - -cdef extern from "libcgroup.h": - cdef struct cgroup: - pass - - cdef struct cgroup_controller: - pass - - cdef enum cg_version_t: - CGROUP_UNK - CGROUP_V1 - CGROUP_V2 - CGROUP_DISK - - cdef enum cg_setup_mode_t: - CGROUP_MODE_UNK - CGROUP_MODE_LEGACY - CGROUP_MODE_HYBRID - CGROUP_MODE_UNIFIED - - cdef struct cgroup_library_version: - unsigned int major - unsigned int minor - unsigned int release - - cdef enum cgroup_systemd_mode_t: - CGROUP_SYSTEMD_MODE_FAIL - CGROUP_SYSTEMD_MODE_REPLACE - CGROUP_SYSTEMD_MODE_ISOLATE - CGROUP_SYSTEMD_MODE_IGNORE_DEPS - CGROUP_SYSTEMD_MODE_IGNORE_REQS - - cdef struct cgroup_systemd_scope_opts: - int delegated - cgroup_systemd_mode_t mode - pid_t pid - - cdef enum cgroup_log_level: - CGROUP_LOG_CONT - CGROUP_LOG_ERROR - CGROUP_LOG_WARNING - CGROUP_LOG_INFO - CGROUP_LOG_DEBUG - - int cgroup_init() - const cgroup_library_version * cgroup_version() - - cgroup *cgroup_new_cgroup(const char *name) - int cgroup_create_cgroup(cgroup *cg, int ignore_ownership) - int cgroup_convert_cgroup(cgroup *out_cg, cg_version_t out_version, - cgroup *in_cg, cg_version_t in_version) - void cgroup_free(cgroup **cg) - - cgroup_controller *cgroup_add_controller(cgroup *cg, const char *name) - int cgroup_add_all_controllers(cgroup *cg) - cgroup_controller *cgroup_get_controller(cgroup *cg, const char *name) - - int cgroup_add_value_string(cgroup_controller *cgc, const char *name, - const char *value) - int cgroup_get_value_string(cgroup_controller *cgc, const char *name, - char **value) - char *cgroup_get_value_name(cgroup_controller *cgc, int index) - int cgroup_get_value_name_count(cgroup_controller *cgc) - - int cgroup_cgxget(cgroup ** cg, cg_version_t version, - bint ignore_unmappable) - - int cgroup_cgxset(const cgroup * const cg, cg_version_t version, - bint ignore_unmappable) - - int cgroup_list_mount_points(const cg_version_t cgrp_version, - char ***mount_paths) - - cg_setup_mode_t cgroup_setup_mode() - - int cgroup_create_scope(const char * const scope_name, const char * const slice_name, - const cgroup_systemd_scope_opts * const opts) - - int cgroup_get_cgroup(cgroup *cg) - - int cgroup_delete_cgroup(cgroup *cg, int ignore_migration) - - int cgroup_get_controller_count(cgroup *cgroup) - - cgroup_controller *cgroup_get_controller_by_index(cgroup *cgroup, int index) - - char *cgroup_get_controller_name(cgroup_controller *controller) - - int cgroup_attach_task(cgroup * cgroup) - int cgroup_attach_task_pid(cgroup * cgroup, pid_t pid) - - int cgroup_set_uid_gid(cgroup *cgroup, uid_t tasks_uid, gid_t tasks_gid, uid_t control_uid, - gid_t control_gid) - - void cgroup_set_permissions(cgroup *cgroup, mode_t control_dperm, mode_t control_fperm, - mode_t task_fperm) - - int cgroup_create_scope2(cgroup *cgroup, int ignore_ownership, - const cgroup_systemd_scope_opts * const opts) - - int cgroup_set_default_systemd_cgroup() - int cgroup_write_systemd_default_cgroup(const char * const slice_name, - const char * const scope_name) - - int cgroup_compare_cgroup(cgroup *cgroup_a, cgroup *cgroup_b) - - int cgroup_get_procs(char *name, char *controller, pid_t **pids, int *size) - - bool is_cgroup_mode_legacy() - - bool is_cgroup_mode_hybrid() - - bool is_cgroup_mode_unified() - - int cgroup_get_current_controller_path(pid_t pid, const char *controller, - char **current_path) - - int cgroup_change_cgroup_path(const char *dest, pid_t pid, const char * const controllers[]) - - void cgroup_set_default_logger(int log_level) -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/src/python/libcgroup.pyx b/lib/libcgroup-3.1.0/src/python/libcgroup.pyx deleted file mode 100644 index 407963ab86d..00000000000 --- a/lib/libcgroup-3.1.0/src/python/libcgroup.pyx +++ /dev/null @@ -1,821 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Libcgroup Python Bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -# cython: language_level = 3str - -""" Python bindings for the libcgroup library -""" - -__author__ = 'Tom Hromatka ' -__date__ = "25 October 2021" - -from posix.types cimport pid_t, mode_t -from libc.stdlib cimport malloc, free -from libc.string cimport strcpy -cimport cgroup - -CONTROL_NAMELEN_MAX = 32 - -cdef class Version: - CGROUP_UNK = cgroup.CGROUP_UNK - CGROUP_V1 = cgroup.CGROUP_V1 - CGROUP_V2 = cgroup.CGROUP_V2 - CGROUP_DISK = cgroup.CGROUP_DISK - -cdef class Mode: - CGROUP_MODE_UNK = cgroup.CGROUP_MODE_UNK - CGROUP_MODE_LEGACY = cgroup.CGROUP_MODE_LEGACY - CGROUP_MODE_HYBRID = cgroup.CGROUP_MODE_HYBRID - CGROUP_MODE_UNIFIED = cgroup.CGROUP_MODE_UNIFIED - -cdef class SystemdMode: - CGROUP_SYSTEMD_MODE_FAIL = cgroup.CGROUP_SYSTEMD_MODE_FAIL - CGROUP_SYSTEMD_MODE_REPLACE = cgroup.CGROUP_SYSTEMD_MODE_REPLACE - CGROUP_SYSTEMD_MODE_ISOLATE = cgroup.CGROUP_SYSTEMD_MODE_ISOLATE - CGROUP_SYSTEMD_MODE_IGNORE_DEPS = cgroup.CGROUP_SYSTEMD_MODE_IGNORE_DEPS - CGROUP_SYSTEMD_MODE_IGNORE_REQS = cgroup.CGROUP_SYSTEMD_MODE_IGNORE_REQS - -cdef class LogLevel: - CGROUP_LOG_CONT = cgroup.CGROUP_LOG_CONT - CGROUP_LOG_ERROR = cgroup.CGROUP_LOG_ERROR - CGROUP_LOG_WARNING = cgroup.CGROUP_LOG_WARNING - CGROUP_LOG_INFO = cgroup.CGROUP_LOG_INFO - CGROUP_LOG_DEBUG = cgroup.CGROUP_LOG_DEBUG - - -def c_str(string): - return bytes(string, "ascii") - - -def indent(in_str, cnt): - leading_indent = cnt * ' ' - return ''.join(leading_indent + line for line in in_str.splitlines(True)) - - -class Controller: - def __init__(self, name): - self.name = name - # self.settings maps to - # struct control_value *values[CG_NV_MAX]; - self.settings = dict() - - def __str__(self): - out_str = "Controller {}\n".format(self.name) - - for setting_key in self.settings: - out_str += indent("{} = {}\n".format(setting_key, - self.settings[setting_key]), 4) - - return out_str - - def __eq__(self, other): - if not isinstance(other, Controller): - return False - - if self.name != other.name: - return False - - if self.settings != other.settings: - return False - - return True - - -cdef class Cgroup: - """ Python object representing a libcgroup cgroup """ - cdef cgroup.cgroup * _cgp - cdef public: - object name, controllers, version - - @staticmethod - def cgroup_init(): - ret = cgroup.cgroup_init() - if ret != 0: - raise RuntimeError("Failed to initialize libcgroup: {}".format(ret)) - - def __cinit__(self, name, version): - Cgroup.cgroup_init() - - self._cgp = cgroup.cgroup_new_cgroup(c_str(name)) - if self._cgp == NULL: - raise RuntimeError("Failed to create cgroup {}".format(name)) - - def __init__(self, name, version): - """Initialize this cgroup instance - - Arguments: - name - Name of this cgroup - version - Version of this cgroup - - Note: - Does not modify the cgroup sysfs. Does not read from the cgroup sysfs - """ - self.name = name - self.controllers = dict() - self.version = version - - def __str__(self): - out_str = "Cgroup {}\n".format(self.name) - for ctrl_key in self.controllers: - out_str += indent(str(self.controllers[ctrl_key]), 4) - - return out_str - - def __eq__(self, other): - if not isinstance(other, Cgroup): - return False - - if self.name != other.name: - return False - - if self.version != other.version: - return False - - if self.controllers != other.controllers: - return False - - if not self.compare(other): - return False - - return True - - @staticmethod - def library_version(): - cdef const cgroup.cgroup_library_version * version - - version = cgroup.cgroup_version() - return [version.major, version.minor, version.release] - - def add_controller(self, ctrl_name): - """Add a controller to the Cgroup instance - - Arguments: - ctrl_name - name of the controller - - Description: - Adds a controller to the Cgroup instance - - Note: - Does not modify the cgroup sysfs - """ - cdef cgroup.cgroup_controller * cgcp - - cgcp = cgroup.cgroup_add_controller(self._cgp, - c_str(ctrl_name)) - if cgcp == NULL: - raise RuntimeError("Failed to add controller {} to cgroup".format( - ctrl_name)) - - self.controllers[ctrl_name] = Controller(ctrl_name) - - def add_all_controllers(self): - """Add all enabled controllers to the Cgroup instance - - Description: - Adds all enabled controllers (i.e. all controllers in the cgroup's cgroup.controllers - file) to the Cgroup instance - - Note: - Reads from the cgroup sysfs - """ - ret = cgroup.cgroup_add_all_controllers(self._cgp) - if ret != 0: - raise RuntimeError("Failed to add all controllers to cgroup") - - ctrl_cnt = cgroup.cgroup_get_controller_count(self._cgp) - for i in range(0, ctrl_cnt): - ctrl_ptr = cgroup.cgroup_get_controller_by_index(self._cgp, i) - ctrl_name = cgroup.cgroup_get_controller_name(ctrl_ptr).decode('ascii') - self.controllers[ctrl_name] = Controller(ctrl_name) - - self._pythonize_cgroup() - - def add_setting(self, setting_name, setting_value=None): - """Add a setting to the Cgroup/Controller instance - - Arguments: - setting_name - name of the cgroup setting, e.g. 'cpu.shares' - setting_value (optional) - value - - Description: - Adds a setting/value pair to the Cgroup/Controller instance - - Note: - Does not modify the cgroup sysfs - """ - cdef cgroup.cgroup_controller *cgcp - - ctrl_name = setting_name.split('.')[0] - - cgcp = cgroup.cgroup_get_controller(self._cgp, - c_str(ctrl_name)) - if cgcp == NULL: - self.add_controller(ctrl_name) - - cgcp = cgroup.cgroup_get_controller(self._cgp, - c_str(ctrl_name)) - if cgcp == NULL: - raise RuntimeError("Failed to get controller {}".format( - ctrl_name)) - - if setting_value is None: - ret = cgroup.cgroup_add_value_string(cgcp, - c_str(setting_name), NULL) - else: - ret = cgroup.cgroup_add_value_string(cgcp, - c_str(setting_name), c_str(setting_value)) - if ret != 0: - raise RuntimeError("Failed to add setting {}: {}".format( - setting_name, ret)) - - def _pythonize_cgroup(self): - """ - Given a populated self._cgp, populate the equivalent Python fields - """ - cdef char *setting_name - cdef char *setting_value - - for ctrlr_key in self.controllers: - cgcp = cgroup.cgroup_get_controller(self._cgp, - c_str(self.controllers[ctrlr_key].name)) - if cgcp == NULL: - raise RuntimeError("Failed to get controller {}".format( - ctrlr_key)) - - self.controllers[ctrlr_key] = Controller(ctrlr_key) - setting_cnt = cgroup.cgroup_get_value_name_count(cgcp) - - for i in range(0, setting_cnt): - setting_name = cgroup.cgroup_get_value_name(cgcp, i) - - ret = cgroup.cgroup_get_value_string(cgcp, - setting_name, &setting_value) - if ret != 0: - raise RuntimeError("Failed to get value {}: {}".format( - setting_name, ret)) - - name = setting_name.decode("ascii") - value = setting_value.decode("ascii").strip() - self.controllers[ctrlr_key].settings[name] = value - - def convert(self, out_version): - """Convert this cgroup to another cgroup version - - Arguments: - out_version - Version to convert to - - Return: - Returns the converted cgroup instance - - Description: - Convert this cgroup instance to a cgroup instance of a different - cgroup version - - Note: - Does not modify the cgroup sysfs. Does not read from the cgroup sysfs - """ - out_cgp = Cgroup(self.name, out_version) - ret = cgroup.cgroup_convert_cgroup(out_cgp._cgp, - out_version, self._cgp, self.version) - if ret != 0: - raise RuntimeError("Failed to convert cgroup: {}".format(ret)) - - for ctrlr_key in self.controllers: - out_cgp.controllers[ctrlr_key] = Controller(ctrlr_key) - - out_cgp._pythonize_cgroup() - - return out_cgp - - def cgxget(self, ignore_unmappable=False): - """Read the requested settings from the cgroup sysfs - - Arguments: - ignore_unmappable - Ignore cgroup settings that can't be converted - from one version to another - - Return: - Returns the cgroup instance that represents the settings read from - sysfs - - Description: - Given this cgroup instance, read the settings/values from the - cgroup sysfs. If the read was successful, the settings are - returned in the return value - - Note: - Reads from the cgroup sysfs - """ - cdef bint ignore - - if ignore_unmappable: - ignore = 1 - else: - ignore = 0 - - ret = cgroup.cgroup_cgxget(&self._cgp, self.version, ignore) - if ret != 0: - raise RuntimeError("cgxget failed: {}".format(ret)) - - self._pythonize_cgroup() - - def cgxset(self, ignore_unmappable=False): - """Write this cgroup to the cgroup sysfs - - Arguments: - ignore_unmappable - Ignore cgroup settings that can't be converted - from one version to another - - Description: - Write the settings/values in this cgroup instance to the cgroup sysfs - - Note: - Writes to the cgroup sysfs - """ - if ignore_unmappable: - ignore = 1 - else: - ignore = 0 - - ret = cgroup.cgroup_cgxset(self._cgp, self.version, ignore) - if ret != 0: - raise RuntimeError("cgxset failed: {}".format(ret)) - - def create(self, ignore_ownership=True): - """Write this cgroup to the cgroup sysfs - - Arguments: - ignore_ownership - if true, all errors are ignored when setting ownership - of the group and its tasks file - - Return: - None - """ - ret = cgroup.cgroup_create_cgroup(self._cgp, ignore_ownership) - if ret != 0: - raise RuntimeError("Failed to create cgroup: {}".format(ret)) - - @staticmethod - def mount_points(version): - """List cgroup mount points of the specified version - - Arguments: - version - It specifies the cgroup version - - Return: - The cgroup mount points in a list - - Description: - Parse the /proc/mounts and list the cgroup mount points matching the - version - """ - cdef char **a - - Cgroup.cgroup_init() - - mount_points = [] - ret = cgroup.cgroup_list_mount_points(version, &a) - if ret is not 0: - raise RuntimeError("cgroup_list_mount_points failed: {}".format(ret)) - - i = 0 - while a[i]: - mount_points.append((a[i]).decode("utf-8")) - i = i + 1 - return mount_points - - @staticmethod - def cgroup_mode(): - """Get the cgroup mode (legacy, hybrid, or unified) - - Return: - The cgroup mode enumeration - """ - Cgroup.cgroup_init() - return cgroup.cgroup_setup_mode() - - @staticmethod - def create_scope(scope_name='libcgroup.scope', slice_name='libcgroup.slice', delegated=True, - systemd_mode=SystemdMode.CGROUP_SYSTEMD_MODE_FAIL, pid=None): - """Create a systemd scope - - Arguments: - scope_name - name of the scope to be created - slice_name - name of the slice where the scope should reside - delegated - if true, then systemd will not manage the cgroup aspects of the scope. It - is up to the user to manage the cgroup settings - systemd_mode - setting to tell systemd how to handle creation of this scope and - resolve conflicts if the scope and/or slice exist - pid - pid of the process to place in the scope. If None is provided, libcgroup will - place a dummy process in the scope - - Description: - Create a systemd scope under slice_name. If delegated is true, then systemd will - not manage the cgroup aspects of the scope. - """ - cdef cgroup.cgroup_systemd_scope_opts opts - - Cgroup.cgroup_init() - - if delegated: - opts.delegated = 1 - else: - opts.delegated = 0 - - opts.mode = systemd_mode - if pid: - opts.pid = pid - else: - opts.pid = -1 - - ret = cgroup.cgroup_create_scope(c_str(scope_name), c_str(slice_name), &opts) - if ret is not 0: - raise RuntimeError("cgroup_create_scope failed: {}".format(ret)) - - def get(self): - """Get the cgroup information from the cgroup sysfs - - Description: - Read the cgroup data from the cgroup sysfs filesystem - """ - cdef cgroup.cgroup_controller *ctrl_ptr - - ret = cgroup.cgroup_get_cgroup(self._cgp) - if ret is not 0: - raise RuntimeError("cgroup_get_cgroup failed: {}".format(ret)) - - ctrl_cnt = cgroup.cgroup_get_controller_count(self._cgp) - for i in range(0, ctrl_cnt): - ctrl_ptr = cgroup.cgroup_get_controller_by_index(self._cgp, i) - ctrl_name = cgroup.cgroup_get_controller_name(ctrl_ptr).decode('ascii') - self.controllers[ctrl_name] = Controller(ctrl_name) - - self._pythonize_cgroup() - - def delete(self, ignore_migration=True): - """Delete the cgroup from the cgroup sysfs - - Arguments: - ignore_migration - ignore errors caused by migration of tasks to parent cgroup - - Description: - Delete the cgroup from the cgroup sysfs filesystem - """ - ret = cgroup.cgroup_delete_cgroup(self._cgp, ignore_migration) - if ret is not 0: - raise RuntimeError("cgroup_delete_cgroup failed: {}".format(ret)) - - def attach(self, pid=None, root_cgroup=False): - """Attach a process to a cgroup - - Arguments: - pid - pid to be attached. If none, then the current pid is attached - root_cgroup - if True, then the pid will be attached to the root cgroup - - Description: - Attach a process to a cgroup - """ - if pid is None: - if root_cgroup: - ret = cgroup.cgroup_attach_task(NULL) - else: - ret = cgroup.cgroup_attach_task(self._cgp) - else: - if root_cgroup: - ret = cgroup.cgroup_attach_task_pid(NULL, pid) - else: - ret = cgroup.cgroup_attach_task_pid(self._cgp, pid) - - if ret is not 0: - raise RuntimeError("cgroup_attach_task failed: {}".format(ret)) - - def set_uid_gid(self, tasks_uid, tasks_gid, ctrl_uid, ctrl_gid): - """Set the desired owning uid/gid for the tasks file and the entire cgroup hierarchy - - Arguments: - tasks_uid - uid that should own the tasks file - tasks_gid - gid that should own the tasks file - ctrl_uid - uid to recursively apply to the entire cgroup hierarchy - ctrl_gid - gid to recursively apply to the entire cgroup hierarchy - - Note: - Does not modify the cgroup sysfs. Does not read from the cgroup sysfs. Applies the - provided uids and gids to the appropriate uid/gid fields in the cgroup struct. - """ - ret = cgroup.cgroup_set_uid_gid(self._cgp, tasks_uid, tasks_gid, ctrl_uid, ctrl_gid) - if ret is not 0: - raise RuntimeError("cgroup_set_uid_gid failed: {}".format(ret)) - - def set_permissions(self, dir_mode, ctrl_mode, task_mode): - """Set the permission bits on the cgroup - - Arguments: - dir_mode - permissions to set on the cgroup directory - ctrl_mode - permissions to set on the files in the directory, except tasks - task_mode - permissions to set on the tasks file - - Note: - Does not modify the cgroup sysfs. Does not read from the cgroup sysfs. Only the - in-memory cgroup structure is updated. - - The mode parameters are expected to be of a form defined in the Python stat module [1], - e.g. stat.S_IWUSR. - - [1] https://docs.python.org/3/library/stat.html - """ - cdef mode_t dmode = dir_mode - cdef mode_t cmode = ctrl_mode - cdef mode_t tmode = task_mode - - cgroup.cgroup_set_permissions(self._cgp, dmode, cmode, tmode) - - def create_scope2(self, ignore_ownership=True, delegated=True, - systemd_mode=SystemdMode.CGROUP_SYSTEMD_MODE_FAIL, pid=None): - """Create a systemd scope using the cgroup instance - - Arguments: - ignore_ownership - if true, do not modify the owning user/group for the cgroup directory - and control files - delegated - if true, then systemd will not manage the cgroup aspects of the scope. It - is up to the user to manage the cgroup settings - systemd_mode - setting to tell systemd how to handle creation of this scope and - resolve conflicts if the scope and/or slice exist - pid - pid of the process to place in the scope. If None is provided, libcgroup will - place a dummy process in the scope - - Description: - Create a systemd scope using the cgroup instance in this class. If delegated is true, - then systemd will not manage the cgroup aspects of the scope. - """ - cdef cgroup.cgroup_systemd_scope_opts opts - - if delegated: - opts.delegated = 1 - else: - opts.delegated = 0 - - opts.mode = systemd_mode - if pid: - opts.pid = pid - else: - opts.pid = -1 - - ret = cgroup.cgroup_create_scope2(self._cgp, ignore_ownership, &opts) - if ret is not 0: - raise RuntimeError("cgroup_create_scope2 failed: {}".format(ret)) - - @staticmethod - def _set_default_systemd_cgroup(): - """Set systemd_default_cgroup - - Arguments: - None - - Description: - Reads /run/libcgroup/systemd and if the file exists, sets the - systemd_default_cgroup. Then on all the paths constructed, has - the systemd_default_cgroup appended to it. This is used when - cgroup sub-tree is constructed for systemd delegation. - """ - Cgroup.cgroup_init() - ret = cgroup.cgroup_set_default_systemd_cgroup() - - if ret != 1: - raise RuntimeError('Failed to set the default systemd cgroup') - - @staticmethod - def write_default_systemd_scope(slice_name, scope_name, set_default=True): - """Write the provided slice and scope to the libcgroup /var/run file - - Arguments: - slice_name - Slice name, e.g. libcgroup.slice - scope_name - Scope name, e.g. database.scope - set_default - If true, set this as the default path for libcgroup APIs - and tools - - Description: - Write the provided slice and scope to the libcgroup var/run file. This - convenience function provides a mechanism for setting a slice/scope as - the default path within libcgroup. Any API or cmdline operation will - utilize this path as the "root" cgroup, but it can be overridden on a - case-by-case basis. - - So if the default slice/scope is set to "libcgroup.slice/database.scope", - and the user wants to access "libcgroup.slice/database.scope/foo", then - they can use the following: - - # Within libcgroup, this will expand to - # libcgroup.slice/database.scope/foo - cg = Cgroup('foo') - """ - ret = cgroup.cgroup_write_systemd_default_cgroup(c_str(slice_name), - c_str(scope_name)) - if ret != 1: - raise RuntimeError("Failed to write the default slice/scope") - - if set_default: - Cgroup._set_default_systemd_cgroup() - - @staticmethod - def clear_default_systemd_scope(): - """Clear/Remove the default slice/scope from libcgroup - - Description: - Delete the default slice/scope from the libcgroup var/run file. - Also delete the internal global variable within libcgroup so that - the default path is restored back to the root cgroup - """ - try: - Cgroup.write_default_systemd_scope('', '', set_default=False) - except RuntimeError: - pass - - try: - Cgroup._set_default_systemd_cgroup() - except RuntimeError: - pass - - cdef compare(self, Cgroup other): - """Compare this cgroup instance with another cgroup instance - - Arguments: - other - other cgroup instance to be compared - - Return: - Returns true if the cgroups are equal. False otherwise - - Description: - Invokes the libcgroup C function, cgroup_compare_cgroup(). - cgroup_compare_cgroup() walks through the cgroup and compares the - cgroup, its controllers, and the values/settings within the - controller. - """ - ret = cgroup.cgroup_compare_cgroup(self._cgp, other._cgp) - if ret == 0: - return True - else: - return False - - def get_processes(self): - """Get the processes in this cgroup - - Return: - Returns an integer list of PIDs - - Description: - Invokes the libcgroup C function, cgroup_get_procs(). - cgroup_get_procs() reads each controller's cgroup.procs file - in the cgroup sysfs. The results are then combined together - into a standard Python list of integers. - - Note: - Reads from the cgroup sysfs - """ - pid_list = list() - cdef pid_t *pids - cdef int size - - if len(self.controllers) == 0: - ret = cgroup.cgroup_get_procs(c_str(self.name), NULL, &pids, &size) - if ret is not 0: - raise RuntimeError("cgroup_get_procs failed: {}".format(ret)) - - for i in range(0, size): - pid_list.append(int(pids[i])) - - for ctrl_key in self.controllers: - ret = cgroup.cgroup_get_procs(c_str(self.name), - c_str(self.controllers[ctrl_key].name), &pids, &size) - if ret is not 0: - raise RuntimeError("cgroup_get_procs failed: {}".format(ret)) - - for i in range(0, size): - pid_list.append(int(pids[i])) - - # Remove duplicates - pid_list = [*set(pid_list)] - - return pid_list - - @staticmethod - def is_cgroup_mode_legacy(): - """Check if the current setup mode is legacy (v1) - - Return: - True if the mode is legacy, else false - """ - return cgroup.is_cgroup_mode_legacy() - - @staticmethod - def is_cgroup_mode_hybrid(): - """Check if the current setup mode is hybrid (v1/v2) - - Return: - True if the mode is hybrid, else false - """ - return cgroup.is_cgroup_mode_hybrid() - - @staticmethod - def is_cgroup_mode_unified(): - """Check if the current setup mode is unified (v2) - - Return: - True if the mode is unified, else false - """ - return cgroup.is_cgroup_mode_unified() - - @staticmethod - def get_current_controller_path(pid, controller=None): - """Get the cgroup path of pid, under controller hierarchy - - Return: - Return cgroup path relative to mount point - - Description: - Invokes the libcgroup C function, cgroup_get_current_controller_path(). - It parses the /proc//cgroup file and returns the cgroup path, if - the controller matches in the output for cgroup v1 controllers and for - the cgroup v2 controllers, checks if the cgroup.controllers file has - the controller enabled. - """ - cdef char *current_path - - Cgroup.cgroup_init() - - if controller is None: - ret = cgroup.cgroup_get_current_controller_path(pid, NULL, - ¤t_path) - elif isinstance(controller, str): - ret = cgroup.cgroup_get_current_controller_path(pid, - c_str(controller), ¤t_path) - else: - raise TypeError("cgroup_get_current_controller_path failed: " - "expected controller type string, but passed " - "{}".format(type(controller))) - - if ret is not 0: - raise RuntimeError("cgroup_get_current_controller_path failed :" - "{}".format(ret)) - - return current_path.decode('ascii') - - @staticmethod - def move_process(pid, dest_cgname, controller=None): - """Move a process to the specified cgroup - - Return: - None - - Description: - Invokes the libcgroup C function, cgroup_change_cgroup_path(). - It moves a process to the specified cgroup dest_cgname. - - To move the process to a cgroup v1 cgroup, the controller must be - provided. For cgroup v2, the controller is optional - - Note: - * Writes to the cgroup sysfs - """ - cdef char *controllers[2] - - if not controller: - ret = cgroup.cgroup_change_cgroup_path(c_str(dest_cgname), pid, NULL) - elif isinstance(controller, str): - controllers[0] = malloc(CONTROL_NAMELEN_MAX) - strcpy(controllers[0], c_str(controller)) - controllers[1] = NULL - - ret = cgroup.cgroup_change_cgroup_path(c_str(dest_cgname), pid, - controllers) - free(controllers[0]) - else: - # - # In the future we could add support for a list of controllers - # - raise TypeError("Unsupported controller type: {}".format(type(controller))) - - if ret is not 0: - raise RuntimeError("cgroup_change_cgroup_path failed :" - "{}".format(ret)) - - @staticmethod - def log_level(log_level): - """Set the libcgroup log level - - Arguments: - log_level - libcgroup.LogLevel - - Description: - Set the libcgroup logger to stdout at the specified log_level - """ - cgroup.cgroup_set_default_logger(log_level) - - def __dealloc__(self): - cgroup.cgroup_free(&self._cgp) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/src/python/setup.py b/lib/libcgroup-3.1.0/src/python/setup.py deleted file mode 100755 index 753ad874bd8..00000000000 --- a/lib/libcgroup-3.1.0/src/python/setup.py +++ /dev/null @@ -1,35 +0,0 @@ -#!/usr/bin/env python -# SPDX-License-Identifier: LGPL-2.1-only -# -# Libcgroup Python Module Build Script -# - -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from setuptools import Extension, setup -from Cython.Build import cythonize -import os - -setup( - name='libcgroup', - version=os.environ['VERSION_RELEASE'], - description='Python bindings for libcgroup', - url='https://github.com/libcgroup/libcgroup', - maintainer='Tom Hromatka', - maintainer_email='tom.hromatka@oracle.com', - license='LGPLv2.1', - platforms='Linux', - ext_modules=cythonize([ - Extension( - 'libcgroup', ['libcgroup.pyx'], - # unable to handle libtool libraries directly - extra_objects=['../.libs/libcgroup.a'], - libraries=['systemd'] - ), - ]) -) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/src/systemd.c b/lib/libcgroup-3.1.0/src/systemd.c deleted file mode 100644 index 47e19d31e0b..00000000000 --- a/lib/libcgroup-3.1.0/src/systemd.c +++ /dev/null @@ -1,348 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright (c) 2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - * Author: Silvia Chapa - */ - -#include -#include -#include -#include -#include -#include -#include -#include - -#define USEC_PER_SEC 1000000 - -static const char * const modes[] = { - "fail", /* CGROUP_SYSTEMD_MODE_FAIL */ - "replace", /* CGROUP_SYSTEMD_MODE_REPLACE */ - "isolate", /* CGROUP_SYSTEMD_MODE_ISOLATE */ - "ignore-dependencies", /* CGROUP_SYSTEMD_MODE_IGNORE_DEPS */ - "ignore-requirements", /* CGROUP_SYSTEMD_MODE_IGNORE_REQS */ -}; -static_assert((sizeof(modes) / sizeof(modes[0])) == CGROUP_SYSTEMD_MODE_CNT, - "modes[] array must be same length as CGROUP_SYSTEMD_MODE_CNT"); - -static const char * const sender = "org.freedesktop.systemd1"; -static const char * const path = "/org/freedesktop/systemd1"; -static const char * const interface = "org.freedesktop.systemd1.Manager"; - -int cgroup_set_default_scope_opts(struct cgroup_systemd_scope_opts * const opts) -{ - if (!opts) - return ECGINVAL; - - opts->delegated = 1; - opts->mode = CGROUP_SYSTEMD_MODE_FAIL; - opts->pid = -1; - - return 0; -} - -/* - * Returns time elapsed in usec - * - * Inspired-by: https://github.com/cockpit-project/cockpit/blob/main/src/tls/socket-io.c#L39 - */ -static int64_t elapsed_time(const struct timespec * const start, const struct timespec * const end) -{ - int64_t elapsed = (end->tv_sec - start->tv_sec) * 1000000 + - (end->tv_nsec - start->tv_nsec) / 1000; - - assert(elapsed >= 0); - - return elapsed; -} - -static int job_removed_callback(sd_bus_message *message, void *user_data, sd_bus_error *error) -{ - const char *result, *msg_path, *scope_name; - const char **job_path = user_data; - int ret; - - ret = sd_bus_message_read(message, "uoss", NULL, &msg_path, &scope_name, &result); - if (ret < 0) { - cgroup_err("callback message read failed: %d\n", errno); - return 0; - } - - if (*job_path == NULL || strcmp(msg_path, *job_path) != 0) { - cgroup_dbg("Received a systemd signal, but it was not our message\n"); - return 0; - } - - cgroup_dbg("Received JobRemoved signal for scope %s. Result: %s\n", scope_name, result); - - /* - * Use the job_path pointer as a way to inform the original thread that the job has - * completed. - */ - *job_path = NULL; - return 0; -} - -int cgroup_create_scope(const char * const scope_name, const char * const slice_name, - const struct cgroup_systemd_scope_opts * const opts) -{ - sd_bus_message *msg = NULL, *reply = NULL; - int ret = 0, sdret = 0, cgret = ECGFAIL; - sd_bus_error error = SD_BUS_ERROR_NULL; - const char *job_path = NULL; - struct timespec start, now; - sd_bus *bus = NULL; - pid_t child_pid; - - if (!scope_name || !slice_name || !opts) - return ECGINVAL; - - if (strcmp(&scope_name[strlen(scope_name) - strlen(".scope")], ".scope") != 0) - cgroup_warn("scope doesn't have expected suffix\n"); - if (strcmp(&slice_name[strlen(slice_name) - strlen(".slice")], ".slice") != 0) - cgroup_warn("slice doesn't have expected suffix\n"); - - if (opts->mode >= CGROUP_SYSTEMD_MODE_CNT) { - cgroup_err("invalid systemd mode: %d\n", opts->mode); - return ECGINVAL; - } - - if (opts->mode == CGROUP_SYSTEMD_MODE_ISOLATE || - opts->mode == CGROUP_SYSTEMD_MODE_IGNORE_DEPS || - opts->mode == CGROUP_SYSTEMD_MODE_IGNORE_REQS) { - cgroup_err("unsupported systemd mode: %d\n", opts->mode); - return ECGINVAL; - } - - if (opts->pid < 0) { - child_pid = fork(); - if (child_pid < 0) { - last_errno = errno; - cgroup_err("fork failed: %d\n", errno); - return ECGOTHER; - } - - if (child_pid == 0) { - char *args[] = {"libcgroup_systemd_idle_thread", NULL}; - - /* - * Have the child sleep forever. Systemd will delete the scope if - * there isn't a running process in it. - */ - execvp("libcgroup_systemd_idle_thread", args); - - /* The child process should never get here */ - last_errno = errno; - cgroup_err("failed to create system idle thread.\n"); - return ECGOTHER; - } - - cgroup_dbg("created libcgroup_system_idle thread pid %d\n", child_pid); - } else { - child_pid = opts->pid; - } - cgroup_dbg("pid %d will be placed in scope %s\n", child_pid, scope_name); - - sdret = sd_bus_default_system(&bus); - if (sdret < 0) { - cgroup_err("failed to open the system bus: %d\n", errno); - goto out; - } - - sdret = sd_bus_match_signal(bus, NULL, sender, path, interface, - "JobRemoved", job_removed_callback, &job_path); - if (sdret < 0) { - cgroup_err("failed to install match callback: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_new_method_call(bus, &msg, sender, path, interface, - "StartTransientUnit"); - if (sdret < 0) { - cgroup_err("failed to create the systemd msg: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_append(msg, "ss", scope_name, modes[opts->mode]); - if (sdret < 0) { - cgroup_err("failed to append the scope name: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_open_container(msg, 'a', "(sv)"); - if (sdret < 0) { - cgroup_err("failed to open container: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_append(msg, "(sv)", "Description", "s", - "scope created by libcgroup"); - if (sdret < 0) { - cgroup_err("failed to append the description: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_append(msg, "(sv)", "PIDs", "au", 1, child_pid); - if (sdret < 0) { - cgroup_err("failed to append the PID: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_append(msg, "(sv)", "Slice", "s", slice_name); - if (sdret < 0) { - cgroup_err("failed to append the slice: %d\n", errno); - goto out; - } - - if (opts->delegated == 1) { - sdret = sd_bus_message_append(msg, "(sv)", "Delegate", "b", 1); - if (sdret < 0) { - cgroup_err("failed to append delegate: %d\n", errno); - goto out; - } - } - - sdret = sd_bus_message_close_container(msg); - if (sdret < 0) { - cgroup_err("failed to close the container: %d\n", errno); - goto out; - } - - sdret = sd_bus_message_append(msg, "a(sa(sv))", 0); - if (sdret < 0) { - cgroup_err("failed to append aux structure: %d\n", errno); - goto out; - } - - sdret = sd_bus_call(bus, msg, 0, &error, &reply); - if (sdret < 0) { - cgroup_err("sd_bus_call() failed: %d\n", - sd_bus_message_get_errno(msg)); - cgroup_err("error message: %s\n", error.message); - goto out; - } - - /* Receive the job_path from systemd */ - sdret = sd_bus_message_read(reply, "o", &job_path); - if (sdret < 0) { - cgroup_err("failed to read reply: %d\n", errno); - goto out; - } - - cgroup_dbg("job_path = %s\n", job_path); - - ret = clock_gettime(CLOCK_MONOTONIC, &start); - if (ret < 0) { - last_errno = errno; - cgroup_err("Failed to get time: %d\n", errno); - cgret = ECGOTHER; - goto out; - } - - /* The callback will null out the job_path pointer on completion */ - while(job_path) { - sdret = sd_bus_process(bus, NULL); - if (sdret < 0) { - cgroup_err("failed to process the sd bus: %d\n", errno); - goto out; - } - - if (sdret == 0) { - /* - * Per the sd_bus_wait() man page, call this function after sd_bus_process - * returns zero. The wait time (usec) was somewhat arbitrarily chosen - */ - sdret = sd_bus_wait(bus, 10); - if (sdret < 0) { - cgroup_err("failed to wait for sd bus: %d\n", errno); - goto out; - } - } - - ret = clock_gettime(CLOCK_MONOTONIC, &now); - if (ret < 0) { - last_errno = errno; - cgroup_err("Failed to get time: %d\n", errno); - cgret = ECGOTHER; - goto out; - } - - if (elapsed_time(&start, &now) > USEC_PER_SEC) { - cgroup_err("The create scope command timed out\n"); - goto out; - } - } - - cgret = 0; - -out: - if (cgret && opts->pid < 0) - kill(child_pid, SIGTERM); - - sd_bus_error_free(&error); - sd_bus_message_unref(msg); - sd_bus_message_unref(reply); - sd_bus_unref(bus); - - return cgret; -} - -int cgroup_create_scope2(struct cgroup *cgroup, int ignore_ownership, - const struct cgroup_systemd_scope_opts * const opts) -{ - char *copy1 = NULL, *copy2 = NULL, *slash, *slice_name, *scope_name; - int ret = 0; - - if (!cgroup) - return ECGROUPNOTALLOWED; - - slash = strstr(cgroup->name, "/"); - if (!slash) { - cgroup_err("cgroup name does not contain a slash: %s\n", cgroup->name); - return ECGINVAL; - } - - slash = strstr(slash + 1, "/"); - if (slash) { - cgroup_err("cgroup name contains more than one slash: %s\n", cgroup->name); - return ECGINVAL; - } - - copy1 = strdup(cgroup->name); - if (!copy1) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - scope_name = basename(copy1); - - copy2 = strdup(cgroup->name); - if (!copy2) { - last_errno = errno; - ret = ECGOTHER; - goto err; - } - - slice_name = dirname(copy2); - - ret = cgroup_create_scope(scope_name, slice_name, opts); - if (ret) - goto err; - - /* - * Utilize cgroup_create_cgroup() to assign the requested owner/group and permissions. - * cgroup_create_cgroup() can gracefully handle EEXIST if the cgroup already exists, so - * we can reuse its ownership logic without penalty. - */ - ret = cgroup_create_cgroup(cgroup, ignore_ownership); - -err: - if (copy1) - free(copy1); - if (copy2) - free(copy2); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/Makefile.am b/lib/libcgroup-3.1.0/src/tools/Makefile.am deleted file mode 100644 index 2e51e3d1455..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/Makefile.am +++ /dev/null @@ -1,75 +0,0 @@ -@CODE_COVERAGE_RULES@ - -AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include -I$(top_builddir)/include -LDADD = $(top_builddir)/src/libcgroup.la -lpthread - -if WITH_TOOLS - -if WITH_SYSTEMD -EXTRA_CFLAGS = -DWITH_SYSTEMD -endif - -bin_PROGRAMS = cgexec cgclassify cgcreate cgset cgxset cgget cgxget cgdelete \ - lssubsys lscgroup cgsnapshot - -sbin_PROGRAMS = cgconfigparser - -noinst_LTLIBRARIES = libcgset.la - -cgexec_SOURCES = cgexec.c tools-common.c tools-common.h -cgexec_LIBS = $(CODE_COVERAGE_LIBS) -cgexec_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgclassify_SOURCES = cgclassify.c tools-common.c tools-common.h -cgclassify_LIBS = $(CODE_COVERAGE_LIBS) -cgclassify_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgcreate_SOURCES = cgcreate.c tools-common.c tools-common.h -cgcreate_LIBS = $(CODE_COVERAGE_LIBS) -cgcreate_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -libcgset_la_SOURCES = cgset.c tools-common.c tools-common.h -libcgset_la_LIBADD = $(CODE_COVERAGE_LIBS) -libcgset_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC= -DUNIT_TEST -libcgset_la_LDFLAGS = -Wl,--no-undefined $(LDADD) - -cgset_SOURCES = cgset.c tools-common.c tools-common.h -cgset_LIBS = $(CODE_COVERAGE_LIBS) -cgset_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC=static - -cgxset_SOURCES = cgxset.c tools-common.c tools-common.h -cgxset_LIBS = $(CODE_COVERAGE_LIBS) -cgxset_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC=static - -cgget_SOURCES = cgget.c tools-common.c tools-common.h -cgget_LIBS = $(CODE_COVERAGE_LIBS) -cgget_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgxget_SOURCES = cgxget.c tools-common.c tools-common.h -cgxget_LIBS = $(CODE_COVERAGE_LIBS) -cgxget_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgconfigparser_SOURCES = cgconfig.c tools-common.c tools-common.h -cgconfigparser_LIBS = $(CODE_COVERAGE_LIBS) -cgconfigparser_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgdelete_SOURCES = cgdelete.c tools-common.c tools-common.h -cgdelete_LIBS = $(CODE_COVERAGE_LIBS) -cgdelete_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -lssubsys_SOURCES = lssubsys.c -lssubsys_LIBS = $(CODE_COVERAGE_LIBS) -lssubsys_CFLAGS = $(CODE_COVERAGE_CFLAGS) - -lscgroup_SOURCES = tools-common.c lscgroup.c -lscgroup_LIBS = $(CODE_COVERAGE_LIBS) -lscgroup_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -cgsnapshot_SOURCES = cgsnapshot.c -cgsnapshot_LIBS = $(CODE_COVERAGE_LIBS) -cgsnapshot_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) - -install-exec-hook: - chmod u+s $(DESTDIR)$(bindir)/cgexec - -endif diff --git a/lib/libcgroup-3.1.0/src/tools/Makefile.in b/lib/libcgroup-3.1.0/src/tools/Makefile.in deleted file mode 100644 index 84c994d7b40..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/Makefile.in +++ /dev/null @@ -1,1384 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -@WITH_TOOLS_TRUE@bin_PROGRAMS = cgexec$(EXEEXT) cgclassify$(EXEEXT) \ -@WITH_TOOLS_TRUE@ cgcreate$(EXEEXT) cgset$(EXEEXT) \ -@WITH_TOOLS_TRUE@ cgxset$(EXEEXT) cgget$(EXEEXT) \ -@WITH_TOOLS_TRUE@ cgxget$(EXEEXT) cgdelete$(EXEEXT) \ -@WITH_TOOLS_TRUE@ lssubsys$(EXEEXT) lscgroup$(EXEEXT) \ -@WITH_TOOLS_TRUE@ cgsnapshot$(EXEEXT) -@WITH_TOOLS_TRUE@sbin_PROGRAMS = cgconfigparser$(EXEEXT) -subdir = src/tools -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)" -PROGRAMS = $(bin_PROGRAMS) $(sbin_PROGRAMS) -LTLIBRARIES = $(noinst_LTLIBRARIES) -am__DEPENDENCIES_1 = -@WITH_TOOLS_TRUE@libcgset_la_DEPENDENCIES = $(am__DEPENDENCIES_1) -am__libcgset_la_SOURCES_DIST = cgset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_libcgset_la_OBJECTS = libcgset_la-cgset.lo \ -@WITH_TOOLS_TRUE@ libcgset_la-tools-common.lo -libcgset_la_OBJECTS = $(am_libcgset_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libcgset_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(libcgset_la_CFLAGS) \ - $(CFLAGS) $(libcgset_la_LDFLAGS) $(LDFLAGS) -o $@ -@WITH_TOOLS_TRUE@am_libcgset_la_rpath = -am__cgclassify_SOURCES_DIST = cgclassify.c tools-common.c \ - tools-common.h -@WITH_TOOLS_TRUE@am_cgclassify_OBJECTS = \ -@WITH_TOOLS_TRUE@ cgclassify-cgclassify.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgclassify-tools-common.$(OBJEXT) -cgclassify_OBJECTS = $(am_cgclassify_OBJECTS) -cgclassify_LDADD = $(LDADD) -cgclassify_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgclassify_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgclassify_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgconfigparser_SOURCES_DIST = cgconfig.c tools-common.c \ - tools-common.h -@WITH_TOOLS_TRUE@am_cgconfigparser_OBJECTS = \ -@WITH_TOOLS_TRUE@ cgconfigparser-cgconfig.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgconfigparser-tools-common.$(OBJEXT) -cgconfigparser_OBJECTS = $(am_cgconfigparser_OBJECTS) -cgconfigparser_LDADD = $(LDADD) -cgconfigparser_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgconfigparser_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ - $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ - $(cgconfigparser_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o \ - $@ -am__cgcreate_SOURCES_DIST = cgcreate.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgcreate_OBJECTS = cgcreate-cgcreate.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgcreate-tools-common.$(OBJEXT) -cgcreate_OBJECTS = $(am_cgcreate_OBJECTS) -cgcreate_LDADD = $(LDADD) -cgcreate_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgcreate_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgcreate_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgdelete_SOURCES_DIST = cgdelete.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgdelete_OBJECTS = cgdelete-cgdelete.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgdelete-tools-common.$(OBJEXT) -cgdelete_OBJECTS = $(am_cgdelete_OBJECTS) -cgdelete_LDADD = $(LDADD) -cgdelete_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgdelete_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgdelete_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgexec_SOURCES_DIST = cgexec.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgexec_OBJECTS = cgexec-cgexec.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgexec-tools-common.$(OBJEXT) -cgexec_OBJECTS = $(am_cgexec_OBJECTS) -cgexec_LDADD = $(LDADD) -cgexec_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgexec_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgexec_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgget_SOURCES_DIST = cgget.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgget_OBJECTS = cgget-cgget.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgget-tools-common.$(OBJEXT) -cgget_OBJECTS = $(am_cgget_OBJECTS) -cgget_LDADD = $(LDADD) -cgget_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgget_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgget_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgset_SOURCES_DIST = cgset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgset_OBJECTS = cgset-cgset.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgset-tools-common.$(OBJEXT) -cgset_OBJECTS = $(am_cgset_OBJECTS) -cgset_LDADD = $(LDADD) -cgset_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgset_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgset_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgsnapshot_SOURCES_DIST = cgsnapshot.c -@WITH_TOOLS_TRUE@am_cgsnapshot_OBJECTS = \ -@WITH_TOOLS_TRUE@ cgsnapshot-cgsnapshot.$(OBJEXT) -cgsnapshot_OBJECTS = $(am_cgsnapshot_OBJECTS) -cgsnapshot_LDADD = $(LDADD) -cgsnapshot_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgsnapshot_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgsnapshot_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgxget_SOURCES_DIST = cgxget.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgxget_OBJECTS = cgxget-cgxget.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgxget-tools-common.$(OBJEXT) -cgxget_OBJECTS = $(am_cgxget_OBJECTS) -cgxget_LDADD = $(LDADD) -cgxget_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgxget_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgxget_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__cgxset_SOURCES_DIST = cgxset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@am_cgxset_OBJECTS = cgxset-cgxset.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ cgxset-tools-common.$(OBJEXT) -cgxset_OBJECTS = $(am_cgxset_OBJECTS) -cgxset_LDADD = $(LDADD) -cgxset_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -cgxset_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(cgxset_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__lscgroup_SOURCES_DIST = tools-common.c lscgroup.c -@WITH_TOOLS_TRUE@am_lscgroup_OBJECTS = \ -@WITH_TOOLS_TRUE@ lscgroup-tools-common.$(OBJEXT) \ -@WITH_TOOLS_TRUE@ lscgroup-lscgroup.$(OBJEXT) -lscgroup_OBJECTS = $(am_lscgroup_OBJECTS) -lscgroup_LDADD = $(LDADD) -lscgroup_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -lscgroup_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(lscgroup_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -am__lssubsys_SOURCES_DIST = lssubsys.c -@WITH_TOOLS_TRUE@am_lssubsys_OBJECTS = lssubsys-lssubsys.$(OBJEXT) -lssubsys_OBJECTS = $(am_lssubsys_OBJECTS) -lssubsys_LDADD = $(LDADD) -lssubsys_DEPENDENCIES = $(top_builddir)/src/libcgroup.la -lssubsys_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(lssubsys_CFLAGS) \ - $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/cgclassify-cgclassify.Po \ - ./$(DEPDIR)/cgclassify-tools-common.Po \ - ./$(DEPDIR)/cgconfigparser-cgconfig.Po \ - ./$(DEPDIR)/cgconfigparser-tools-common.Po \ - ./$(DEPDIR)/cgcreate-cgcreate.Po \ - ./$(DEPDIR)/cgcreate-tools-common.Po \ - ./$(DEPDIR)/cgdelete-cgdelete.Po \ - ./$(DEPDIR)/cgdelete-tools-common.Po \ - ./$(DEPDIR)/cgexec-cgexec.Po \ - ./$(DEPDIR)/cgexec-tools-common.Po ./$(DEPDIR)/cgget-cgget.Po \ - ./$(DEPDIR)/cgget-tools-common.Po ./$(DEPDIR)/cgset-cgset.Po \ - ./$(DEPDIR)/cgset-tools-common.Po \ - ./$(DEPDIR)/cgsnapshot-cgsnapshot.Po \ - ./$(DEPDIR)/cgxget-cgxget.Po \ - ./$(DEPDIR)/cgxget-tools-common.Po \ - ./$(DEPDIR)/cgxset-cgxset.Po \ - ./$(DEPDIR)/cgxset-tools-common.Po \ - ./$(DEPDIR)/libcgset_la-cgset.Plo \ - ./$(DEPDIR)/libcgset_la-tools-common.Plo \ - ./$(DEPDIR)/lscgroup-lscgroup.Po \ - ./$(DEPDIR)/lscgroup-tools-common.Po \ - ./$(DEPDIR)/lssubsys-lssubsys.Po -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -SOURCES = $(libcgset_la_SOURCES) $(cgclassify_SOURCES) \ - $(cgconfigparser_SOURCES) $(cgcreate_SOURCES) \ - $(cgdelete_SOURCES) $(cgexec_SOURCES) $(cgget_SOURCES) \ - $(cgset_SOURCES) $(cgsnapshot_SOURCES) $(cgxget_SOURCES) \ - $(cgxset_SOURCES) $(lscgroup_SOURCES) $(lssubsys_SOURCES) -DIST_SOURCES = $(am__libcgset_la_SOURCES_DIST) \ - $(am__cgclassify_SOURCES_DIST) \ - $(am__cgconfigparser_SOURCES_DIST) \ - $(am__cgcreate_SOURCES_DIST) $(am__cgdelete_SOURCES_DIST) \ - $(am__cgexec_SOURCES_DIST) $(am__cgget_SOURCES_DIST) \ - $(am__cgset_SOURCES_DIST) $(am__cgsnapshot_SOURCES_DIST) \ - $(am__cgxget_SOURCES_DIST) $(am__cgxset_SOURCES_DIST) \ - $(am__lscgroup_SOURCES_DIST) $(am__lssubsys_SOURCES_DIST) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AM_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include -I$(top_builddir)/include -LDADD = $(top_builddir)/src/libcgroup.la -lpthread -@WITH_SYSTEMD_TRUE@@WITH_TOOLS_TRUE@EXTRA_CFLAGS = -DWITH_SYSTEMD -@WITH_TOOLS_TRUE@noinst_LTLIBRARIES = libcgset.la -@WITH_TOOLS_TRUE@cgexec_SOURCES = cgexec.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgexec_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgexec_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgclassify_SOURCES = cgclassify.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgclassify_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgclassify_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgcreate_SOURCES = cgcreate.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgcreate_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgcreate_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@libcgset_la_SOURCES = cgset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@libcgset_la_LIBADD = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@libcgset_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC= -DUNIT_TEST -@WITH_TOOLS_TRUE@libcgset_la_LDFLAGS = -Wl,--no-undefined $(LDADD) -@WITH_TOOLS_TRUE@cgset_SOURCES = cgset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgset_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgset_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC=static -@WITH_TOOLS_TRUE@cgxset_SOURCES = cgxset.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgxset_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgxset_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -DSTATIC=static -@WITH_TOOLS_TRUE@cgget_SOURCES = cgget.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgget_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgget_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgxget_SOURCES = cgxget.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgxget_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgxget_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgconfigparser_SOURCES = cgconfig.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgconfigparser_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgconfigparser_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgdelete_SOURCES = cgdelete.c tools-common.c tools-common.h -@WITH_TOOLS_TRUE@cgdelete_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgdelete_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@lssubsys_SOURCES = lssubsys.c -@WITH_TOOLS_TRUE@lssubsys_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@lssubsys_CFLAGS = $(CODE_COVERAGE_CFLAGS) -@WITH_TOOLS_TRUE@lscgroup_SOURCES = tools-common.c lscgroup.c -@WITH_TOOLS_TRUE@lscgroup_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@lscgroup_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -@WITH_TOOLS_TRUE@cgsnapshot_SOURCES = cgsnapshot.c -@WITH_TOOLS_TRUE@cgsnapshot_LIBS = $(CODE_COVERAGE_LIBS) -@WITH_TOOLS_TRUE@cgsnapshot_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(EXTRA_CFLAGS) -all: all-am - -.SUFFIXES: -.SUFFIXES: .c .lo .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/tools/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign src/tools/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ - fi; \ - for p in $$list; do echo "$$p $$p"; done | \ - sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p \ - || test -f $$p1 \ - ; then echo "$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n;h' \ - -e 's|.*|.|' \ - -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ - sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) files[d] = files[d] " " $$1; \ - else { print "f", $$3 "/" $$4, $$1; } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' \ - `; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(bindir)" && rm -f $$files - -clean-binPROGRAMS: - @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list -install-sbinPROGRAMS: $(sbin_PROGRAMS) - @$(NORMAL_INSTALL) - @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ - if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(sbindir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(sbindir)" || exit 1; \ - fi; \ - for p in $$list; do echo "$$p $$p"; done | \ - sed 's/$(EXEEXT)$$//' | \ - while read p p1; do if test -f $$p \ - || test -f $$p1 \ - ; then echo "$$p"; echo "$$p"; else :; fi; \ - done | \ - sed -e 'p;s,.*/,,;n;h' \ - -e 's|.*|.|' \ - -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ - sed 'N;N;N;s,\n, ,g' | \ - $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ - { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ - if ($$2 == $$4) files[d] = files[d] " " $$1; \ - else { print "f", $$3 "/" $$4, $$1; } } \ - END { for (d in files) print "f", d, files[d] }' | \ - while read type dir files; do \ - if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ - test -z "$$files" || { \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(sbindir)$$dir'"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(sbindir)$$dir" || exit $$?; \ - } \ - ; done - -uninstall-sbinPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(sbin_PROGRAMS)'; test -n "$(sbindir)" || list=; \ - files=`for p in $$list; do echo "$$p"; done | \ - sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ - -e 's/$$/$(EXEEXT)/' \ - `; \ - test -n "$$list" || exit 0; \ - echo " ( cd '$(DESTDIR)$(sbindir)' && rm -f" $$files ")"; \ - cd "$(DESTDIR)$(sbindir)" && rm -f $$files - -clean-sbinPROGRAMS: - @list='$(sbin_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list - -clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) - @list='$(noinst_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libcgset.la: $(libcgset_la_OBJECTS) $(libcgset_la_DEPENDENCIES) $(EXTRA_libcgset_la_DEPENDENCIES) - $(AM_V_CCLD)$(libcgset_la_LINK) $(am_libcgset_la_rpath) $(libcgset_la_OBJECTS) $(libcgset_la_LIBADD) $(LIBS) - -cgclassify$(EXEEXT): $(cgclassify_OBJECTS) $(cgclassify_DEPENDENCIES) $(EXTRA_cgclassify_DEPENDENCIES) - @rm -f cgclassify$(EXEEXT) - $(AM_V_CCLD)$(cgclassify_LINK) $(cgclassify_OBJECTS) $(cgclassify_LDADD) $(LIBS) - -cgconfigparser$(EXEEXT): $(cgconfigparser_OBJECTS) $(cgconfigparser_DEPENDENCIES) $(EXTRA_cgconfigparser_DEPENDENCIES) - @rm -f cgconfigparser$(EXEEXT) - $(AM_V_CCLD)$(cgconfigparser_LINK) $(cgconfigparser_OBJECTS) $(cgconfigparser_LDADD) $(LIBS) - -cgcreate$(EXEEXT): $(cgcreate_OBJECTS) $(cgcreate_DEPENDENCIES) $(EXTRA_cgcreate_DEPENDENCIES) - @rm -f cgcreate$(EXEEXT) - $(AM_V_CCLD)$(cgcreate_LINK) $(cgcreate_OBJECTS) $(cgcreate_LDADD) $(LIBS) - -cgdelete$(EXEEXT): $(cgdelete_OBJECTS) $(cgdelete_DEPENDENCIES) $(EXTRA_cgdelete_DEPENDENCIES) - @rm -f cgdelete$(EXEEXT) - $(AM_V_CCLD)$(cgdelete_LINK) $(cgdelete_OBJECTS) $(cgdelete_LDADD) $(LIBS) - -cgexec$(EXEEXT): $(cgexec_OBJECTS) $(cgexec_DEPENDENCIES) $(EXTRA_cgexec_DEPENDENCIES) - @rm -f cgexec$(EXEEXT) - $(AM_V_CCLD)$(cgexec_LINK) $(cgexec_OBJECTS) $(cgexec_LDADD) $(LIBS) - -cgget$(EXEEXT): $(cgget_OBJECTS) $(cgget_DEPENDENCIES) $(EXTRA_cgget_DEPENDENCIES) - @rm -f cgget$(EXEEXT) - $(AM_V_CCLD)$(cgget_LINK) $(cgget_OBJECTS) $(cgget_LDADD) $(LIBS) - -cgset$(EXEEXT): $(cgset_OBJECTS) $(cgset_DEPENDENCIES) $(EXTRA_cgset_DEPENDENCIES) - @rm -f cgset$(EXEEXT) - $(AM_V_CCLD)$(cgset_LINK) $(cgset_OBJECTS) $(cgset_LDADD) $(LIBS) - -cgsnapshot$(EXEEXT): $(cgsnapshot_OBJECTS) $(cgsnapshot_DEPENDENCIES) $(EXTRA_cgsnapshot_DEPENDENCIES) - @rm -f cgsnapshot$(EXEEXT) - $(AM_V_CCLD)$(cgsnapshot_LINK) $(cgsnapshot_OBJECTS) $(cgsnapshot_LDADD) $(LIBS) - -cgxget$(EXEEXT): $(cgxget_OBJECTS) $(cgxget_DEPENDENCIES) $(EXTRA_cgxget_DEPENDENCIES) - @rm -f cgxget$(EXEEXT) - $(AM_V_CCLD)$(cgxget_LINK) $(cgxget_OBJECTS) $(cgxget_LDADD) $(LIBS) - -cgxset$(EXEEXT): $(cgxset_OBJECTS) $(cgxset_DEPENDENCIES) $(EXTRA_cgxset_DEPENDENCIES) - @rm -f cgxset$(EXEEXT) - $(AM_V_CCLD)$(cgxset_LINK) $(cgxset_OBJECTS) $(cgxset_LDADD) $(LIBS) - -lscgroup$(EXEEXT): $(lscgroup_OBJECTS) $(lscgroup_DEPENDENCIES) $(EXTRA_lscgroup_DEPENDENCIES) - @rm -f lscgroup$(EXEEXT) - $(AM_V_CCLD)$(lscgroup_LINK) $(lscgroup_OBJECTS) $(lscgroup_LDADD) $(LIBS) - -lssubsys$(EXEEXT): $(lssubsys_OBJECTS) $(lssubsys_DEPENDENCIES) $(EXTRA_lssubsys_DEPENDENCIES) - @rm -f lssubsys$(EXEEXT) - $(AM_V_CCLD)$(lssubsys_LINK) $(lssubsys_OBJECTS) $(lssubsys_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgclassify-cgclassify.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgclassify-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgconfigparser-cgconfig.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgconfigparser-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgcreate-cgcreate.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgcreate-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgdelete-cgdelete.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgdelete-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgexec-cgexec.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgexec-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgget-cgget.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgget-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgset-cgset.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgset-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgsnapshot-cgsnapshot.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgxget-cgxget.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgxget-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgxset-cgxset.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cgxset-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgset_la-cgset.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcgset_la-tools-common.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lscgroup-lscgroup.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lscgroup-tools-common.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lssubsys-lssubsys.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCC_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -libcgset_la-cgset.lo: cgset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgset_la_CFLAGS) $(CFLAGS) -MT libcgset_la-cgset.lo -MD -MP -MF $(DEPDIR)/libcgset_la-cgset.Tpo -c -o libcgset_la-cgset.lo `test -f 'cgset.c' || echo '$(srcdir)/'`cgset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgset_la-cgset.Tpo $(DEPDIR)/libcgset_la-cgset.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgset.c' object='libcgset_la-cgset.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgset_la_CFLAGS) $(CFLAGS) -c -o libcgset_la-cgset.lo `test -f 'cgset.c' || echo '$(srcdir)/'`cgset.c - -libcgset_la-tools-common.lo: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgset_la_CFLAGS) $(CFLAGS) -MT libcgset_la-tools-common.lo -MD -MP -MF $(DEPDIR)/libcgset_la-tools-common.Tpo -c -o libcgset_la-tools-common.lo `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcgset_la-tools-common.Tpo $(DEPDIR)/libcgset_la-tools-common.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='libcgset_la-tools-common.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libcgset_la_CFLAGS) $(CFLAGS) -c -o libcgset_la-tools-common.lo `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgclassify-cgclassify.o: cgclassify.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -MT cgclassify-cgclassify.o -MD -MP -MF $(DEPDIR)/cgclassify-cgclassify.Tpo -c -o cgclassify-cgclassify.o `test -f 'cgclassify.c' || echo '$(srcdir)/'`cgclassify.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgclassify-cgclassify.Tpo $(DEPDIR)/cgclassify-cgclassify.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgclassify.c' object='cgclassify-cgclassify.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -c -o cgclassify-cgclassify.o `test -f 'cgclassify.c' || echo '$(srcdir)/'`cgclassify.c - -cgclassify-cgclassify.obj: cgclassify.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -MT cgclassify-cgclassify.obj -MD -MP -MF $(DEPDIR)/cgclassify-cgclassify.Tpo -c -o cgclassify-cgclassify.obj `if test -f 'cgclassify.c'; then $(CYGPATH_W) 'cgclassify.c'; else $(CYGPATH_W) '$(srcdir)/cgclassify.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgclassify-cgclassify.Tpo $(DEPDIR)/cgclassify-cgclassify.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgclassify.c' object='cgclassify-cgclassify.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -c -o cgclassify-cgclassify.obj `if test -f 'cgclassify.c'; then $(CYGPATH_W) 'cgclassify.c'; else $(CYGPATH_W) '$(srcdir)/cgclassify.c'; fi` - -cgclassify-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -MT cgclassify-tools-common.o -MD -MP -MF $(DEPDIR)/cgclassify-tools-common.Tpo -c -o cgclassify-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgclassify-tools-common.Tpo $(DEPDIR)/cgclassify-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgclassify-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -c -o cgclassify-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgclassify-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -MT cgclassify-tools-common.obj -MD -MP -MF $(DEPDIR)/cgclassify-tools-common.Tpo -c -o cgclassify-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgclassify-tools-common.Tpo $(DEPDIR)/cgclassify-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgclassify-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgclassify_CFLAGS) $(CFLAGS) -c -o cgclassify-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgconfigparser-cgconfig.o: cgconfig.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -MT cgconfigparser-cgconfig.o -MD -MP -MF $(DEPDIR)/cgconfigparser-cgconfig.Tpo -c -o cgconfigparser-cgconfig.o `test -f 'cgconfig.c' || echo '$(srcdir)/'`cgconfig.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgconfigparser-cgconfig.Tpo $(DEPDIR)/cgconfigparser-cgconfig.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgconfig.c' object='cgconfigparser-cgconfig.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -c -o cgconfigparser-cgconfig.o `test -f 'cgconfig.c' || echo '$(srcdir)/'`cgconfig.c - -cgconfigparser-cgconfig.obj: cgconfig.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -MT cgconfigparser-cgconfig.obj -MD -MP -MF $(DEPDIR)/cgconfigparser-cgconfig.Tpo -c -o cgconfigparser-cgconfig.obj `if test -f 'cgconfig.c'; then $(CYGPATH_W) 'cgconfig.c'; else $(CYGPATH_W) '$(srcdir)/cgconfig.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgconfigparser-cgconfig.Tpo $(DEPDIR)/cgconfigparser-cgconfig.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgconfig.c' object='cgconfigparser-cgconfig.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -c -o cgconfigparser-cgconfig.obj `if test -f 'cgconfig.c'; then $(CYGPATH_W) 'cgconfig.c'; else $(CYGPATH_W) '$(srcdir)/cgconfig.c'; fi` - -cgconfigparser-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -MT cgconfigparser-tools-common.o -MD -MP -MF $(DEPDIR)/cgconfigparser-tools-common.Tpo -c -o cgconfigparser-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgconfigparser-tools-common.Tpo $(DEPDIR)/cgconfigparser-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgconfigparser-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -c -o cgconfigparser-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgconfigparser-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -MT cgconfigparser-tools-common.obj -MD -MP -MF $(DEPDIR)/cgconfigparser-tools-common.Tpo -c -o cgconfigparser-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgconfigparser-tools-common.Tpo $(DEPDIR)/cgconfigparser-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgconfigparser-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgconfigparser_CFLAGS) $(CFLAGS) -c -o cgconfigparser-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgcreate-cgcreate.o: cgcreate.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -MT cgcreate-cgcreate.o -MD -MP -MF $(DEPDIR)/cgcreate-cgcreate.Tpo -c -o cgcreate-cgcreate.o `test -f 'cgcreate.c' || echo '$(srcdir)/'`cgcreate.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgcreate-cgcreate.Tpo $(DEPDIR)/cgcreate-cgcreate.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgcreate.c' object='cgcreate-cgcreate.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -c -o cgcreate-cgcreate.o `test -f 'cgcreate.c' || echo '$(srcdir)/'`cgcreate.c - -cgcreate-cgcreate.obj: cgcreate.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -MT cgcreate-cgcreate.obj -MD -MP -MF $(DEPDIR)/cgcreate-cgcreate.Tpo -c -o cgcreate-cgcreate.obj `if test -f 'cgcreate.c'; then $(CYGPATH_W) 'cgcreate.c'; else $(CYGPATH_W) '$(srcdir)/cgcreate.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgcreate-cgcreate.Tpo $(DEPDIR)/cgcreate-cgcreate.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgcreate.c' object='cgcreate-cgcreate.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -c -o cgcreate-cgcreate.obj `if test -f 'cgcreate.c'; then $(CYGPATH_W) 'cgcreate.c'; else $(CYGPATH_W) '$(srcdir)/cgcreate.c'; fi` - -cgcreate-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -MT cgcreate-tools-common.o -MD -MP -MF $(DEPDIR)/cgcreate-tools-common.Tpo -c -o cgcreate-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgcreate-tools-common.Tpo $(DEPDIR)/cgcreate-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgcreate-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -c -o cgcreate-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgcreate-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -MT cgcreate-tools-common.obj -MD -MP -MF $(DEPDIR)/cgcreate-tools-common.Tpo -c -o cgcreate-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgcreate-tools-common.Tpo $(DEPDIR)/cgcreate-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgcreate-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgcreate_CFLAGS) $(CFLAGS) -c -o cgcreate-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgdelete-cgdelete.o: cgdelete.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -MT cgdelete-cgdelete.o -MD -MP -MF $(DEPDIR)/cgdelete-cgdelete.Tpo -c -o cgdelete-cgdelete.o `test -f 'cgdelete.c' || echo '$(srcdir)/'`cgdelete.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgdelete-cgdelete.Tpo $(DEPDIR)/cgdelete-cgdelete.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgdelete.c' object='cgdelete-cgdelete.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -c -o cgdelete-cgdelete.o `test -f 'cgdelete.c' || echo '$(srcdir)/'`cgdelete.c - -cgdelete-cgdelete.obj: cgdelete.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -MT cgdelete-cgdelete.obj -MD -MP -MF $(DEPDIR)/cgdelete-cgdelete.Tpo -c -o cgdelete-cgdelete.obj `if test -f 'cgdelete.c'; then $(CYGPATH_W) 'cgdelete.c'; else $(CYGPATH_W) '$(srcdir)/cgdelete.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgdelete-cgdelete.Tpo $(DEPDIR)/cgdelete-cgdelete.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgdelete.c' object='cgdelete-cgdelete.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -c -o cgdelete-cgdelete.obj `if test -f 'cgdelete.c'; then $(CYGPATH_W) 'cgdelete.c'; else $(CYGPATH_W) '$(srcdir)/cgdelete.c'; fi` - -cgdelete-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -MT cgdelete-tools-common.o -MD -MP -MF $(DEPDIR)/cgdelete-tools-common.Tpo -c -o cgdelete-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgdelete-tools-common.Tpo $(DEPDIR)/cgdelete-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgdelete-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -c -o cgdelete-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgdelete-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -MT cgdelete-tools-common.obj -MD -MP -MF $(DEPDIR)/cgdelete-tools-common.Tpo -c -o cgdelete-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgdelete-tools-common.Tpo $(DEPDIR)/cgdelete-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgdelete-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgdelete_CFLAGS) $(CFLAGS) -c -o cgdelete-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgexec-cgexec.o: cgexec.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -MT cgexec-cgexec.o -MD -MP -MF $(DEPDIR)/cgexec-cgexec.Tpo -c -o cgexec-cgexec.o `test -f 'cgexec.c' || echo '$(srcdir)/'`cgexec.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgexec-cgexec.Tpo $(DEPDIR)/cgexec-cgexec.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgexec.c' object='cgexec-cgexec.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -c -o cgexec-cgexec.o `test -f 'cgexec.c' || echo '$(srcdir)/'`cgexec.c - -cgexec-cgexec.obj: cgexec.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -MT cgexec-cgexec.obj -MD -MP -MF $(DEPDIR)/cgexec-cgexec.Tpo -c -o cgexec-cgexec.obj `if test -f 'cgexec.c'; then $(CYGPATH_W) 'cgexec.c'; else $(CYGPATH_W) '$(srcdir)/cgexec.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgexec-cgexec.Tpo $(DEPDIR)/cgexec-cgexec.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgexec.c' object='cgexec-cgexec.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -c -o cgexec-cgexec.obj `if test -f 'cgexec.c'; then $(CYGPATH_W) 'cgexec.c'; else $(CYGPATH_W) '$(srcdir)/cgexec.c'; fi` - -cgexec-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -MT cgexec-tools-common.o -MD -MP -MF $(DEPDIR)/cgexec-tools-common.Tpo -c -o cgexec-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgexec-tools-common.Tpo $(DEPDIR)/cgexec-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgexec-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -c -o cgexec-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgexec-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -MT cgexec-tools-common.obj -MD -MP -MF $(DEPDIR)/cgexec-tools-common.Tpo -c -o cgexec-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgexec-tools-common.Tpo $(DEPDIR)/cgexec-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgexec-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgexec_CFLAGS) $(CFLAGS) -c -o cgexec-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgget-cgget.o: cgget.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -MT cgget-cgget.o -MD -MP -MF $(DEPDIR)/cgget-cgget.Tpo -c -o cgget-cgget.o `test -f 'cgget.c' || echo '$(srcdir)/'`cgget.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgget-cgget.Tpo $(DEPDIR)/cgget-cgget.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgget.c' object='cgget-cgget.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -c -o cgget-cgget.o `test -f 'cgget.c' || echo '$(srcdir)/'`cgget.c - -cgget-cgget.obj: cgget.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -MT cgget-cgget.obj -MD -MP -MF $(DEPDIR)/cgget-cgget.Tpo -c -o cgget-cgget.obj `if test -f 'cgget.c'; then $(CYGPATH_W) 'cgget.c'; else $(CYGPATH_W) '$(srcdir)/cgget.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgget-cgget.Tpo $(DEPDIR)/cgget-cgget.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgget.c' object='cgget-cgget.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -c -o cgget-cgget.obj `if test -f 'cgget.c'; then $(CYGPATH_W) 'cgget.c'; else $(CYGPATH_W) '$(srcdir)/cgget.c'; fi` - -cgget-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -MT cgget-tools-common.o -MD -MP -MF $(DEPDIR)/cgget-tools-common.Tpo -c -o cgget-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgget-tools-common.Tpo $(DEPDIR)/cgget-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgget-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -c -o cgget-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgget-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -MT cgget-tools-common.obj -MD -MP -MF $(DEPDIR)/cgget-tools-common.Tpo -c -o cgget-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgget-tools-common.Tpo $(DEPDIR)/cgget-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgget-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgget_CFLAGS) $(CFLAGS) -c -o cgget-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgset-cgset.o: cgset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -MT cgset-cgset.o -MD -MP -MF $(DEPDIR)/cgset-cgset.Tpo -c -o cgset-cgset.o `test -f 'cgset.c' || echo '$(srcdir)/'`cgset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgset-cgset.Tpo $(DEPDIR)/cgset-cgset.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgset.c' object='cgset-cgset.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -c -o cgset-cgset.o `test -f 'cgset.c' || echo '$(srcdir)/'`cgset.c - -cgset-cgset.obj: cgset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -MT cgset-cgset.obj -MD -MP -MF $(DEPDIR)/cgset-cgset.Tpo -c -o cgset-cgset.obj `if test -f 'cgset.c'; then $(CYGPATH_W) 'cgset.c'; else $(CYGPATH_W) '$(srcdir)/cgset.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgset-cgset.Tpo $(DEPDIR)/cgset-cgset.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgset.c' object='cgset-cgset.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -c -o cgset-cgset.obj `if test -f 'cgset.c'; then $(CYGPATH_W) 'cgset.c'; else $(CYGPATH_W) '$(srcdir)/cgset.c'; fi` - -cgset-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -MT cgset-tools-common.o -MD -MP -MF $(DEPDIR)/cgset-tools-common.Tpo -c -o cgset-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgset-tools-common.Tpo $(DEPDIR)/cgset-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgset-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -c -o cgset-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgset-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -MT cgset-tools-common.obj -MD -MP -MF $(DEPDIR)/cgset-tools-common.Tpo -c -o cgset-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgset-tools-common.Tpo $(DEPDIR)/cgset-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgset-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgset_CFLAGS) $(CFLAGS) -c -o cgset-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgsnapshot-cgsnapshot.o: cgsnapshot.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgsnapshot_CFLAGS) $(CFLAGS) -MT cgsnapshot-cgsnapshot.o -MD -MP -MF $(DEPDIR)/cgsnapshot-cgsnapshot.Tpo -c -o cgsnapshot-cgsnapshot.o `test -f 'cgsnapshot.c' || echo '$(srcdir)/'`cgsnapshot.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgsnapshot-cgsnapshot.Tpo $(DEPDIR)/cgsnapshot-cgsnapshot.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgsnapshot.c' object='cgsnapshot-cgsnapshot.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgsnapshot_CFLAGS) $(CFLAGS) -c -o cgsnapshot-cgsnapshot.o `test -f 'cgsnapshot.c' || echo '$(srcdir)/'`cgsnapshot.c - -cgsnapshot-cgsnapshot.obj: cgsnapshot.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgsnapshot_CFLAGS) $(CFLAGS) -MT cgsnapshot-cgsnapshot.obj -MD -MP -MF $(DEPDIR)/cgsnapshot-cgsnapshot.Tpo -c -o cgsnapshot-cgsnapshot.obj `if test -f 'cgsnapshot.c'; then $(CYGPATH_W) 'cgsnapshot.c'; else $(CYGPATH_W) '$(srcdir)/cgsnapshot.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgsnapshot-cgsnapshot.Tpo $(DEPDIR)/cgsnapshot-cgsnapshot.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgsnapshot.c' object='cgsnapshot-cgsnapshot.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgsnapshot_CFLAGS) $(CFLAGS) -c -o cgsnapshot-cgsnapshot.obj `if test -f 'cgsnapshot.c'; then $(CYGPATH_W) 'cgsnapshot.c'; else $(CYGPATH_W) '$(srcdir)/cgsnapshot.c'; fi` - -cgxget-cgxget.o: cgxget.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -MT cgxget-cgxget.o -MD -MP -MF $(DEPDIR)/cgxget-cgxget.Tpo -c -o cgxget-cgxget.o `test -f 'cgxget.c' || echo '$(srcdir)/'`cgxget.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxget-cgxget.Tpo $(DEPDIR)/cgxget-cgxget.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgxget.c' object='cgxget-cgxget.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -c -o cgxget-cgxget.o `test -f 'cgxget.c' || echo '$(srcdir)/'`cgxget.c - -cgxget-cgxget.obj: cgxget.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -MT cgxget-cgxget.obj -MD -MP -MF $(DEPDIR)/cgxget-cgxget.Tpo -c -o cgxget-cgxget.obj `if test -f 'cgxget.c'; then $(CYGPATH_W) 'cgxget.c'; else $(CYGPATH_W) '$(srcdir)/cgxget.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxget-cgxget.Tpo $(DEPDIR)/cgxget-cgxget.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgxget.c' object='cgxget-cgxget.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -c -o cgxget-cgxget.obj `if test -f 'cgxget.c'; then $(CYGPATH_W) 'cgxget.c'; else $(CYGPATH_W) '$(srcdir)/cgxget.c'; fi` - -cgxget-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -MT cgxget-tools-common.o -MD -MP -MF $(DEPDIR)/cgxget-tools-common.Tpo -c -o cgxget-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxget-tools-common.Tpo $(DEPDIR)/cgxget-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgxget-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -c -o cgxget-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgxget-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -MT cgxget-tools-common.obj -MD -MP -MF $(DEPDIR)/cgxget-tools-common.Tpo -c -o cgxget-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxget-tools-common.Tpo $(DEPDIR)/cgxget-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgxget-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxget_CFLAGS) $(CFLAGS) -c -o cgxget-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -cgxset-cgxset.o: cgxset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -MT cgxset-cgxset.o -MD -MP -MF $(DEPDIR)/cgxset-cgxset.Tpo -c -o cgxset-cgxset.o `test -f 'cgxset.c' || echo '$(srcdir)/'`cgxset.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxset-cgxset.Tpo $(DEPDIR)/cgxset-cgxset.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgxset.c' object='cgxset-cgxset.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -c -o cgxset-cgxset.o `test -f 'cgxset.c' || echo '$(srcdir)/'`cgxset.c - -cgxset-cgxset.obj: cgxset.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -MT cgxset-cgxset.obj -MD -MP -MF $(DEPDIR)/cgxset-cgxset.Tpo -c -o cgxset-cgxset.obj `if test -f 'cgxset.c'; then $(CYGPATH_W) 'cgxset.c'; else $(CYGPATH_W) '$(srcdir)/cgxset.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxset-cgxset.Tpo $(DEPDIR)/cgxset-cgxset.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='cgxset.c' object='cgxset-cgxset.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -c -o cgxset-cgxset.obj `if test -f 'cgxset.c'; then $(CYGPATH_W) 'cgxset.c'; else $(CYGPATH_W) '$(srcdir)/cgxset.c'; fi` - -cgxset-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -MT cgxset-tools-common.o -MD -MP -MF $(DEPDIR)/cgxset-tools-common.Tpo -c -o cgxset-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxset-tools-common.Tpo $(DEPDIR)/cgxset-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgxset-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -c -o cgxset-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -cgxset-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -MT cgxset-tools-common.obj -MD -MP -MF $(DEPDIR)/cgxset-tools-common.Tpo -c -o cgxset-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cgxset-tools-common.Tpo $(DEPDIR)/cgxset-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='cgxset-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cgxset_CFLAGS) $(CFLAGS) -c -o cgxset-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -lscgroup-tools-common.o: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -MT lscgroup-tools-common.o -MD -MP -MF $(DEPDIR)/lscgroup-tools-common.Tpo -c -o lscgroup-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lscgroup-tools-common.Tpo $(DEPDIR)/lscgroup-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='lscgroup-tools-common.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -c -o lscgroup-tools-common.o `test -f 'tools-common.c' || echo '$(srcdir)/'`tools-common.c - -lscgroup-tools-common.obj: tools-common.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -MT lscgroup-tools-common.obj -MD -MP -MF $(DEPDIR)/lscgroup-tools-common.Tpo -c -o lscgroup-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lscgroup-tools-common.Tpo $(DEPDIR)/lscgroup-tools-common.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='tools-common.c' object='lscgroup-tools-common.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -c -o lscgroup-tools-common.obj `if test -f 'tools-common.c'; then $(CYGPATH_W) 'tools-common.c'; else $(CYGPATH_W) '$(srcdir)/tools-common.c'; fi` - -lscgroup-lscgroup.o: lscgroup.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -MT lscgroup-lscgroup.o -MD -MP -MF $(DEPDIR)/lscgroup-lscgroup.Tpo -c -o lscgroup-lscgroup.o `test -f 'lscgroup.c' || echo '$(srcdir)/'`lscgroup.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lscgroup-lscgroup.Tpo $(DEPDIR)/lscgroup-lscgroup.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lscgroup.c' object='lscgroup-lscgroup.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -c -o lscgroup-lscgroup.o `test -f 'lscgroup.c' || echo '$(srcdir)/'`lscgroup.c - -lscgroup-lscgroup.obj: lscgroup.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -MT lscgroup-lscgroup.obj -MD -MP -MF $(DEPDIR)/lscgroup-lscgroup.Tpo -c -o lscgroup-lscgroup.obj `if test -f 'lscgroup.c'; then $(CYGPATH_W) 'lscgroup.c'; else $(CYGPATH_W) '$(srcdir)/lscgroup.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lscgroup-lscgroup.Tpo $(DEPDIR)/lscgroup-lscgroup.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lscgroup.c' object='lscgroup-lscgroup.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lscgroup_CFLAGS) $(CFLAGS) -c -o lscgroup-lscgroup.obj `if test -f 'lscgroup.c'; then $(CYGPATH_W) 'lscgroup.c'; else $(CYGPATH_W) '$(srcdir)/lscgroup.c'; fi` - -lssubsys-lssubsys.o: lssubsys.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lssubsys_CFLAGS) $(CFLAGS) -MT lssubsys-lssubsys.o -MD -MP -MF $(DEPDIR)/lssubsys-lssubsys.Tpo -c -o lssubsys-lssubsys.o `test -f 'lssubsys.c' || echo '$(srcdir)/'`lssubsys.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lssubsys-lssubsys.Tpo $(DEPDIR)/lssubsys-lssubsys.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lssubsys.c' object='lssubsys-lssubsys.o' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lssubsys_CFLAGS) $(CFLAGS) -c -o lssubsys-lssubsys.o `test -f 'lssubsys.c' || echo '$(srcdir)/'`lssubsys.c - -lssubsys-lssubsys.obj: lssubsys.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lssubsys_CFLAGS) $(CFLAGS) -MT lssubsys-lssubsys.obj -MD -MP -MF $(DEPDIR)/lssubsys-lssubsys.Tpo -c -o lssubsys-lssubsys.obj `if test -f 'lssubsys.c'; then $(CYGPATH_W) 'lssubsys.c'; else $(CYGPATH_W) '$(srcdir)/lssubsys.c'; fi` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/lssubsys-lssubsys.Tpo $(DEPDIR)/lssubsys-lssubsys.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='lssubsys.c' object='lssubsys-lssubsys.obj' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lssubsys_CFLAGS) $(CFLAGS) -c -o lssubsys-lssubsys.obj `if test -f 'lssubsys.c'; then $(CYGPATH_W) 'lssubsys.c'; else $(CYGPATH_W) '$(srcdir)/lssubsys.c'; fi` - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(PROGRAMS) $(LTLIBRARIES) -installdirs: - for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(sbindir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -@WITH_TOOLS_FALSE@install-exec-hook: -clean: clean-am - -clean-am: clean-binPROGRAMS clean-generic clean-libtool \ - clean-noinstLTLIBRARIES clean-sbinPROGRAMS mostlyclean-am - -distclean: distclean-am - -rm -f ./$(DEPDIR)/cgclassify-cgclassify.Po - -rm -f ./$(DEPDIR)/cgclassify-tools-common.Po - -rm -f ./$(DEPDIR)/cgconfigparser-cgconfig.Po - -rm -f ./$(DEPDIR)/cgconfigparser-tools-common.Po - -rm -f ./$(DEPDIR)/cgcreate-cgcreate.Po - -rm -f ./$(DEPDIR)/cgcreate-tools-common.Po - -rm -f ./$(DEPDIR)/cgdelete-cgdelete.Po - -rm -f ./$(DEPDIR)/cgdelete-tools-common.Po - -rm -f ./$(DEPDIR)/cgexec-cgexec.Po - -rm -f ./$(DEPDIR)/cgexec-tools-common.Po - -rm -f ./$(DEPDIR)/cgget-cgget.Po - -rm -f ./$(DEPDIR)/cgget-tools-common.Po - -rm -f ./$(DEPDIR)/cgset-cgset.Po - -rm -f ./$(DEPDIR)/cgset-tools-common.Po - -rm -f ./$(DEPDIR)/cgsnapshot-cgsnapshot.Po - -rm -f ./$(DEPDIR)/cgxget-cgxget.Po - -rm -f ./$(DEPDIR)/cgxget-tools-common.Po - -rm -f ./$(DEPDIR)/cgxset-cgxset.Po - -rm -f ./$(DEPDIR)/cgxset-tools-common.Po - -rm -f ./$(DEPDIR)/libcgset_la-cgset.Plo - -rm -f ./$(DEPDIR)/libcgset_la-tools-common.Plo - -rm -f ./$(DEPDIR)/lscgroup-lscgroup.Po - -rm -f ./$(DEPDIR)/lscgroup-tools-common.Po - -rm -f ./$(DEPDIR)/lssubsys-lssubsys.Po - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: install-binPROGRAMS install-sbinPROGRAMS - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-exec-hook -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/cgclassify-cgclassify.Po - -rm -f ./$(DEPDIR)/cgclassify-tools-common.Po - -rm -f ./$(DEPDIR)/cgconfigparser-cgconfig.Po - -rm -f ./$(DEPDIR)/cgconfigparser-tools-common.Po - -rm -f ./$(DEPDIR)/cgcreate-cgcreate.Po - -rm -f ./$(DEPDIR)/cgcreate-tools-common.Po - -rm -f ./$(DEPDIR)/cgdelete-cgdelete.Po - -rm -f ./$(DEPDIR)/cgdelete-tools-common.Po - -rm -f ./$(DEPDIR)/cgexec-cgexec.Po - -rm -f ./$(DEPDIR)/cgexec-tools-common.Po - -rm -f ./$(DEPDIR)/cgget-cgget.Po - -rm -f ./$(DEPDIR)/cgget-tools-common.Po - -rm -f ./$(DEPDIR)/cgset-cgset.Po - -rm -f ./$(DEPDIR)/cgset-tools-common.Po - -rm -f ./$(DEPDIR)/cgsnapshot-cgsnapshot.Po - -rm -f ./$(DEPDIR)/cgxget-cgxget.Po - -rm -f ./$(DEPDIR)/cgxget-tools-common.Po - -rm -f ./$(DEPDIR)/cgxset-cgxset.Po - -rm -f ./$(DEPDIR)/cgxset-tools-common.Po - -rm -f ./$(DEPDIR)/libcgset_la-cgset.Plo - -rm -f ./$(DEPDIR)/libcgset_la-tools-common.Plo - -rm -f ./$(DEPDIR)/lscgroup-lscgroup.Po - -rm -f ./$(DEPDIR)/lscgroup-tools-common.Po - -rm -f ./$(DEPDIR)/lssubsys-lssubsys.Po - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-binPROGRAMS uninstall-sbinPROGRAMS - -.MAKE: install-am install-exec-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ - clean-binPROGRAMS clean-generic clean-libtool \ - clean-noinstLTLIBRARIES clean-sbinPROGRAMS cscopelist-am ctags \ - ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-binPROGRAMS \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-exec-hook install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-sbinPROGRAMS install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \ - uninstall-sbinPROGRAMS - -.PRECIOUS: Makefile - -@CODE_COVERAGE_RULES@ - -@WITH_TOOLS_TRUE@install-exec-hook: -@WITH_TOOLS_TRUE@ chmod u+s $(DESTDIR)$(bindir)/cgexec - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/src/tools/cgclassify.c b/lib/libcgroup-3.1.0/src/tools/cgclassify.c deleted file mode 100644 index d868fec6e28..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgclassify.c +++ /dev/null @@ -1,700 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright RedHat Inc. 2008 - * - * Authors: Vivek Goyal - * - * Replace systemd idle_thread enhancements by Kamalesh Babulal - * Copyright (c) 2023 Oracle and/or its affiliates. - * Author: Kamalesh Babulal - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - - -#define TEMP_BUF 81 - -#define SYSTEMD_IDLE_THREAD "libcgroup_systemd_idle_thread" - -static pid_t find_scope_pid(pid_t pid, int capture); -static int write_systemd_unified(const char * const cgrp_name, pid_t pid); -static int is_scope_parsed(const char * const path); -static int rollback_pid_cgroups(pid_t pid); - -struct cgroup_info { - char ctrl_name[CONTROL_NAMELEN_MAX]; - char cgrp_path[FILENAME_MAX]; -}info[MAX_MNT_ELEMENTS + 1]; - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s '-h' for more information.\n", program_name); - return; - } - - info("Usage: %s [[-g] :] ", program_name); - info("[--sticky | --cancel-sticky] \n"); - info("Move running task(s) to given cgroups\n"); - info(" -h, --help Display this help\n"); - info(" -g : Control group to be used as target\n"); - info(" --cancel-sticky cgred daemon change pidlist and children tasks\n"); - info(" --sticky cgred daemon does not change "); - info("pidlist and children tasks\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); - info(" -r Replace the default idle_thread spawned "); - info("for the systemd scope\n"); -#endif -} - -/* - * Change process group as specified on command line. - */ -static int change_group_path(pid_t pid, struct cgroup_group_spec *cgroup_list[]) -{ - int ret = 0; - int i; - - for (i = 0; i < CG_HIER_MAX; i++) { - if (!cgroup_list[i]) - break; - - ret = cgroup_change_cgroup_path(cgroup_list[i]->path, pid, - (const char *const*) cgroup_list[i]->controllers); - if (ret) { - err("Error changing group of pid %d: %s\n", pid, cgroup_strerror(ret)); - return -1; - } - } - - return 0; -} - -/* - * Change process group as specified in cgrules.conf. - */ -static int change_group_based_on_rule(pid_t pid) -{ - char *procname = NULL; - int ret = -1; - uid_t euid; - gid_t egid; - - /* Put pid into right cgroup as per rules in /etc/cgrules.conf */ - if (cgroup_get_uid_gid_from_procfs(pid, &euid, &egid)) { - err("Error in determining euid/egid of pid %d\n", pid); - goto out; - } - - ret = cgroup_get_procname_from_procfs(pid, &procname); - if (ret) { - err("Error in determining process name of pid %d\n", pid); - goto out; - } - - /* Change the cgroup by determining the rules */ - ret = cgroup_change_cgroup_flags(euid, egid, procname, pid, 0); - if (ret) { - err("Error: change of cgroup failed for pid %d: %s\n", pid, cgroup_strerror(ret)); - goto out; - } - ret = 0; - -out: - if (procname) - free(procname); - - return ret; -} - -static struct option longopts[] = { - {"sticky", no_argument, NULL, 's'}, - {"cancel-sticky", no_argument, NULL, 'u'}, - {"help", no_argument, NULL, 'h'}, - {0, 0, 0, 0} -}; - -int main(int argc, char *argv[]) -{ - struct cgroup_group_spec *cgroup_list[CG_HIER_MAX]; - int ignore_default_systemd_delegate_slice = 0; - int ret = 0, i, exit_code = 0; - int skip_replace_idle = 0; - pid_t scope_pid = -1; - int replace_idle = 0; - int cg_specified = 0; - int flag = 0; - char *endptr; - pid_t pid; - int c; - - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - memset(cgroup_list, 0, sizeof(cgroup_list)); -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "+g:shbr", longopts, NULL)) > 0) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; - case 'r': - replace_idle = 1; - break; -#else - while ((c = getopt_long(argc, argv, "+g:sh", longopts, NULL)) > 0) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - exit(0); - break; - case 'g': - ret = parse_cgroup_spec(cgroup_list, optarg, CG_HIER_MAX); - if (ret) { - err("cgroup controller and path parsing failed\n"); - exit(EXIT_BADARGS); - } - cg_specified = 1; - break; - case 's': - flag |= CGROUP_DAEMON_UNCHANGE_CHILDREN; - break; - case 'u': - flag |= CGROUP_DAEMON_CANCEL_UNCHANGE_PROCESS; - break; - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - break; - } - } - - /* Initialize libcg */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - return ret; - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - for (i = optind; i < argc; i++) { - pid = (pid_t) strtol(argv[i], &endptr, 10); - if (endptr[0] != '\0') { - /* the input argument was not a number */ - err("Error: %s is not valid pid.\n", argv[i]); - exit_code = 2; - continue; - } - - if (flag) - ret = cgroup_register_unchanged_process(pid, flag); - if (ret) - exit_code = 1; - - if (replace_idle && !skip_replace_idle) { - ret = find_scope_pid(pid, 1); - if (ret) { - err("Failed to read /proc/%u/cgroups\n", pid); - return 1; - } - } - - if (cg_specified) - ret = change_group_path(pid, cgroup_list); - else - ret = change_group_based_on_rule(pid); - - /* if any group change fails */ - if (ret) - exit_code = 1; - - /* skip replacing of idle_thread in systemd slice */ - if (!replace_idle) - continue; - - /* systemd idle_thread is already replaced */ - if (skip_replace_idle) - continue; - - scope_pid = find_scope_pid(pid, 0); - if (scope_pid == -1) - goto err; - - skip_replace_idle = 1; - - ret = kill(scope_pid, SIGTERM); - if (ret) { - err("Failed to kill pid %u:%s\n", scope_pid, strerror(errno)); - goto err; - } - } - - return exit_code; - -err: - exit_code = rollback_pid_cgroups(pid); - return exit_code; -} - -static pid_t search_systemd_idle_thread_task(pid_t pids[], size_t size) -{ - char task_cmd[FILENAME_MAX]; - char buffer[FILENAME_MAX]; - FILE *pid_cmd_fp = NULL; - int scope_pid = -1; - int i; - - for (i = 0; i < size; i++) { - snprintf(buffer, FILENAME_MAX, "/proc/%u/cmdline", pids[i]); - pid_cmd_fp = fopen(buffer, "re"); - /* task might have exited */ - if (!pid_cmd_fp) - continue; - - /* task might have exited, so consider only successful reads. */ - if (fgets(task_cmd, FILENAME_MAX, pid_cmd_fp)) { - if (!strcmp(task_cmd, SYSTEMD_IDLE_THREAD)) { - scope_pid = pids[i]; - fclose(pid_cmd_fp); - break; - } - } - fclose(pid_cmd_fp); - } - - return scope_pid; -} - -static pid_t find_scope_pid(pid_t pid, int capture) -{ - pid_t _scope_pid = -1, scope_pid = -1; - char ctrl_name[CONTROL_NAMELEN_MAX]; - char cgroup_name[FILENAME_MAX]; - char scope_name[FILENAME_MAX]; - int found_systemd_cgrp = 0; - int found_unified_cgrp = 0; - char buffer[FILENAME_MAX]; - FILE *pid_proc_fp = NULL; - char *_ctrl_name = NULL; - int idx, ret, size = 0; - pid_t *pids; - int i=0; - - /* - * Let's parse the cgroup of the pid, to check if its in one or - * more .scopes. - */ - snprintf(buffer, FILENAME_MAX, "/proc/%u/cgroup", pid); - pid_proc_fp = fopen(buffer, "re"); - if (!pid_proc_fp) { - err("Failed to open: %s\n", buffer); - return -1; - } - - while (fgets(buffer, FILENAME_MAX, pid_proc_fp)) { - memset(ctrl_name, '\0', sizeof(ctrl_name)); - - /* check for overflow of controllers */ - if (i >= MAX_MNT_ELEMENTS) { - err("Found more than MAX_MNT_ELEMENTS controllers\n"); - scope_pid = -1; - goto out; - } - - /* read according to the cgroup mode */ - if (strstr(buffer, "::")) { - snprintf(ctrl_name, CONTROL_NAMELEN_MAX, "unified"); - ret = sscanf(buffer, "%d::%4096s\n", &idx, cgroup_name); - } else{ - ret = sscanf(buffer, "%d:%[^:]:%4096s\n", &idx, ctrl_name, cgroup_name); - } - - if (ret != 2 && ret != 3) { - err("Unrecognized cgroup file format: %s\n", buffer); - scope_pid = -1; - goto out; - } - - /* cgroup v1 might have shared mount points cpu,cpuacct */ - _ctrl_name = strchr(ctrl_name, ','); - if (_ctrl_name) { - size = strlen(ctrl_name) - strlen(_ctrl_name); - ctrl_name[size] = '\0'; - } - - /* - * capture is true, while the pid's controller and cgroups - * are populated for rollback case. - */ - if (capture) { - snprintf(info[i].ctrl_name, CONTROL_NAMELEN_MAX, "%s", ctrl_name); - snprintf(info[i].cgrp_path, FILENAME_MAX, "%s", cgroup_name); - } - - if (!is_cgroup_mode_unified()) { - if (ret == 3 && !strncmp(ctrl_name, "name=", 5)) { - if (!strcmp(ctrl_name, "name=systemd")) { - i++; - found_systemd_cgrp = 1; - } - continue; - } else if (ret == 2) { - i++; - found_unified_cgrp = 1; - continue; - } - } - i++; - - /* we are not interested in other functionality */ - if (capture) - continue; - - /* skip if the cgroup path doesn't have systemd scope format */ - if (strstr(cgroup_name, ".scope") == NULL || - strstr(cgroup_name, ".slice") == NULL) - continue; - - /* skip if we have already searched cgroup for idle_thread */ - if (is_scope_parsed(cgroup_name)) - continue; - - - if (ret == 2) - ret = cgroup_get_procs(cgroup_name, NULL, &pids, &size); - else - ret = cgroup_get_procs(cgroup_name, ctrl_name, &pids, &size); - if (ret) { - err("Failed to read cgroup.procs of cgroup: %s\n", cgroup_name + 1); - scope_pid = -1; - goto out; - } - - /* - * .scope created by the non-libcgroup process, will not - * have libcgroup_systemd_idle_thread - */ - _scope_pid = search_systemd_idle_thread_task(pids, size); - free(pids); - - if (_scope_pid == -1) - continue; - - if (scope_pid == -1) { - /* - * cgexec pid needs to written into: - * ../systemd///cgroup.procs (legacy/hybrid) - * ../unified///cgroup.procs (hybrid) - */ - snprintf(scope_name, FILENAME_MAX, "%s", cgroup_name); - scope_pid = _scope_pid; - continue; - } - - if (_scope_pid != scope_pid) { - err("Failed to replace scope idle_thread, found two idle_thread\n"); - err(" %u %u\n", scope_pid, _scope_pid); - scope_pid = -1; - goto out; - } - } - - if (capture) { - scope_pid = 0; - goto out; - } - - if (scope_pid == -1) { - err("Failed to find idle_thread task\n"); - goto out; - } - - if (is_cgroup_mode_legacy() && (found_systemd_cgrp == 0 || found_unified_cgrp == 1)) { - err("cgroup legacy setup incorrect\n"); - scope_pid = -1; - goto out; - } - - if (is_cgroup_mode_hybrid() && (found_systemd_cgrp == 0 || found_unified_cgrp == 0)) { - err("cgroup hybrid setup incorrect\n"); - scope_pid = -1; - goto out; - } - - /* This is true for cgroup v1 (legacy/hybrid) */ - if (found_systemd_cgrp) { - ret = write_systemd_unified(scope_name, pid); - if (ret) - scope_pid = -1; - } - - info[i].ctrl_name[0] = '\0'; -out: - if (pid_proc_fp) - fclose(pid_proc_fp); - - return scope_pid; -} - -/* - * Parse the /proc/mounts file and look for the controller string - * in each line. If found copies the mount point into mnt_point, - * else return NULL mnt_point. - */ -static void find_mnt_point(const char * const controller, char **mnt_point) -{ - char proc_mount[] = "/proc/mounts"; - char cgroup_path[FILENAME_MAX]; - char buffer[FILENAME_MAX * 2]; - FILE *proc_mount_f = NULL; - int ret; - - *mnt_point = NULL; - - proc_mount_f = fopen(proc_mount, "re"); - if (proc_mount_f == NULL) { - err("Failed to read %s:%s\n", proc_mount, strerror(errno)); - goto out; - } - - while (fgets(buffer, (FILENAME_MAX * 2), proc_mount_f) != NULL) { - /* skip line that doesn't have controller */ - if (!strstr(buffer, controller)) - continue; - - if (strcmp(controller, "name=systemd") == 0) { - if (!strstr(buffer, "name=systemd ") && - !strstr(buffer, "name=systemd,")) - continue; - } - - ret = sscanf(buffer, "%*s %4096s\n", cgroup_path); - if (ret != 1) { - err("Failed during read of %s:%s\n", proc_mount, strerror(errno)); - goto out; - } - - *mnt_point = strdup(cgroup_path); - if (!*mnt_point) - err("strdup of %s failed\n", cgroup_path); - break; - } - -out: - if (proc_mount_f) - fclose(proc_mount_f); -} - -static int write_systemd_unified(const char * const scope_name, pid_t pid) -{ - char cgroup_procs_path[FILENAME_MAX + 14]; - FILE *cgroup_systemd_path_f = NULL; - FILE *cgroup_unified_path_f = NULL; - char *cgroup_name = NULL; - - /* construct the systemd cgroup path, by parsing /proc/mounts */ - find_mnt_point("name=systemd", &cgroup_name); - if (!cgroup_name) { - err("Unable find name=systemd cgroup path\n"); - return -1; - } - - snprintf(cgroup_procs_path, sizeof(cgroup_procs_path), "%s/%s/cgroup.procs", - cgroup_name, scope_name); - free(cgroup_name); - - cgroup_systemd_path_f = fopen(cgroup_procs_path, "we"); - if (!cgroup_systemd_path_f) { - err("Failed to open %s\n", cgroup_procs_path); - return -1; - } - - if (is_cgroup_mode_hybrid()) { - /* - * construct the unified cgroup path, by parsing - * /proc/mounts - */ - find_mnt_point("unified", &cgroup_name); - if (!cgroup_name) { - err("Unable find unified cgroup path\n"); - fclose(cgroup_systemd_path_f); - return -1; - } - - snprintf(cgroup_procs_path, sizeof(cgroup_procs_path), "%s/%s/cgroup.procs", - cgroup_name, scope_name); - free(cgroup_name); - - cgroup_unified_path_f = fopen(cgroup_procs_path, "we"); - if (!cgroup_unified_path_f) { - err("Failed to open %s\n", cgroup_procs_path); - fclose(cgroup_systemd_path_f); - return -1; - } - } - - fprintf(cgroup_systemd_path_f, "%d", pid); - fflush(cgroup_systemd_path_f); - fclose(cgroup_systemd_path_f); - - if (!is_cgroup_mode_hybrid()) - return 0; - - fprintf(cgroup_unified_path_f, "%d", pid); - fflush(cgroup_unified_path_f); - fclose(cgroup_unified_path_f); - - return 0; -} - -static int is_scope_parsed(const char * const path) -{ - /* - * As per, /kernel/cgroup/cgroup.c::cgroup_init() - * At the max there can be only 16 controllers and we are - * not accounting for named hierarchies, which can be more - * than 16 themselves. - */ - static char parsed_scope_path[MAX_MNT_ELEMENTS][FILENAME_MAX]; - int i; - - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (!strcmp(parsed_scope_path[i], path)) - return 1; - if (parsed_scope_path[i][0] == '\0') { - snprintf(parsed_scope_path[i], FILENAME_MAX, "%s", path); - break; - } - } - - return 0; -} - -/* Borrowed from src/api.c::__attach_task_pid */ -static int attach_task_pid(char *path, pid_t tid) -{ - FILE *tasks = NULL; - int ret = 0; - - tasks = fopen(path, "we"); - if (!tasks) { - switch (errno) { - case EPERM: - ret = ECGROUPNOTOWNER; - break; - case ENOENT: - ret = ECGROUPNOTEXIST; - break; - default: - ret = ECGROUPNOTALLOWED; - } - goto err; - } - ret = fprintf(tasks, "%d", tid); - if (ret < 0) { - ret = ECGOTHER; - goto err; - } - ret = fflush(tasks); - if (ret) { - ret = ECGOTHER; - goto err; - } - fclose(tasks); - return 0; -err: - err("cannot write tid %d to %s:%s\n", tid, path, strerror(errno)); - if (tasks) - fclose(tasks); - return ret; -} - -static int rollback_pid_cgroups(pid_t pid) -{ - char cgroup_proc_path[FILENAME_MAX + 14]; - char cgroup_path[FILENAME_MAX]; - int err = 0, idx = 0, ret = 0; - char *cgrp_proc_path = NULL; - - /* - * unified cgroup rollback is simple, we need to write into - * single cgroup hierarchy. - */ - if (is_cgroup_mode_unified()) { - pthread_rwlock_rdlock(&cg_mount_table_lock); - cg_build_path_locked(info[idx].cgrp_path, cgroup_path, NULL); - pthread_rwlock_unlock(&cg_mount_table_lock); - - snprintf(cgroup_proc_path, FILENAME_MAX + 14, "%s/cgroup.procs", cgroup_path); - ret = attach_task_pid(cgroup_proc_path, pid); - return ret; - } - - for (idx = 0; info[idx].ctrl_name[0] != '\0'; idx++) { - /* find the systemd cgroup path */ - if (!strcmp(info[idx].ctrl_name, "name=systemd")) { - find_mnt_point("name=systemd", &cgrp_proc_path); - if (!cgrp_proc_path) { - err("Unable find name=systemd cgroup path\n"); - return -1; - } - - snprintf(cgroup_proc_path, FILENAME_MAX + 14, "%s/%s/cgroup.procs", - cgrp_proc_path, info[idx].cgrp_path); - free(cgrp_proc_path); - - /* find the unified cgroup path */ - } else if (is_cgroup_mode_hybrid() && - !strcmp(info[idx].ctrl_name, "unified")) { - find_mnt_point("unified cgroup2", &cgrp_proc_path); - if (!cgrp_proc_path) { - err("Unable find unified cgroup path\n"); - return -1; - } - - snprintf(cgroup_proc_path, FILENAME_MAX + 14, "%s/%s/cgroup.procs", - cgrp_proc_path, info[idx].cgrp_path); - free(cgrp_proc_path); - - /* find other controller hierarchy path */ - } else { - pthread_rwlock_rdlock(&cg_mount_table_lock); - cg_build_path_locked(info[idx].cgrp_path, cgroup_path, info[idx].ctrl_name); - pthread_rwlock_unlock(&cg_mount_table_lock); - - snprintf(cgroup_proc_path, FILENAME_MAX + 14, "%s/cgroup.procs", - cgroup_path); - } - - /* record the error and continue */ - ret = attach_task_pid(cgroup_proc_path, pid); - if (ret) - err = -1; - } - - return err; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgconfig.c b/lib/libcgroup-3.1.0/src/tools/cgconfig.c deleted file mode 100644 index b541d4b1212..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgconfig.c +++ /dev/null @@ -1,196 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright IBM Corporation. 2007 - * - * Authors: Dhaval Giani - * Balbir Singh - * - * Code initiated and designed by Dhaval Giani. All faults are most likely - * his mistake. - */ - -/* For basename() */ -#ifndef _GNU_SOURCE -#define _GNU_SOURCE -#endif - -#include "tools-common.h" - -#include -#include - -#include -#include - -#include -#include -#include -#include - -static struct cgroup_string_list cfg_files; - -static void usage(int status, char *progname) -{ - if (status != 0) { - err("Wrong input parameters, try %s '-h' for more information.\n", progname); - return; - } - - info("Usage: %s [-h] [-f mode] [-d mode] [-s mode] ", progname); - info("[-t :] [-a :] [-l FILE] [-L DIR] ...\n"); - info("Parse and load the specified cgroups configuration file\n"); - info(" -a : Default owner of groups "); - info("files and directories\n"); - info(" -d, --dperm=mode Default group directory permissions\n"); - info(" -f, --fperm=mode Default group file permissions\n"); - info(" -h, --help Display this help\n"); - info(" -l, --load=FILE Parse and load the cgroups configuration file\n"); - info(" -L, --load-directory=DIR Parse and load the cgroups "); - info("configuration files from a directory\n"); - info(" -s, --tperm=mode Default tasks file permissions\n"); - info(" -t : Default owner of the tasks file\n"); -} - -int main(int argc, char *argv[]) -{ - static struct option options[] = { - {"help", 0, 0, 'h'}, - {"load", 1, 0, 'l'}, - {"load-directory", 1, 0, 'L'}, - {"task", required_argument, NULL, 't'}, - {"admin", required_argument, NULL, 'a'}, - {"dperm", required_argument, NULL, 'd'}, - {"fperm", required_argument, NULL, 'f' }, - {"tperm", required_argument, NULL, 's' }, - {0, 0, 0, 0} - }; - - uid_t tuid = NO_UID_GID, auid = NO_UID_GID; - gid_t tgid = NO_UID_GID, agid = NO_UID_GID; - mode_t tasks_mode = NO_PERMS; - mode_t file_mode = NO_PERMS; - mode_t dir_mode = NO_PERMS; - - struct cgroup *default_group = NULL; - int filem_change = 0; - int dirm_change = 0; - int ret, error = 0; - int c, i; - - cgroup_set_default_logger(-1); - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - error = cgroup_string_list_init(&cfg_files, argc/2); - if (error) - goto err; - - while ((c = getopt_long(argc, argv, "hl:L:t:a:d:f:s:", options, NULL)) > 0) { - switch (c) { - case 'h': - usage(0, argv[0]); - error = 0; - goto err; - case 'l': - error = cgroup_string_list_add_item(&cfg_files, optarg); - if (error) { - err("%s: cannot add file to list, out of memory?\n", argv[0]); - goto err; - } - break; - case 'L': - cgroup_string_list_add_directory(&cfg_files, optarg, argv[0]); - break; - case 'a': - /* set admin uid/gid */ - error = parse_uid_gid(optarg, &auid, &agid, argv[0]); - if (error) - goto err; - break; - case 't': - /* set task uid/gid */ - error = parse_uid_gid(optarg, &tuid, &tgid, argv[0]); - if (error) - goto err; - break; - case 'd': - dirm_change = 1; - error = parse_mode(optarg, &dir_mode, argv[0]); - if (error) - goto err; - break; - case 'f': - filem_change = 1; - error = parse_mode(optarg, &file_mode, argv[0]); - if (error) - goto err; - break; - case 's': - filem_change = 1; - error = parse_mode(optarg, &tasks_mode, argv[0]); - if (error) - goto err; - break; - default: - usage(1, argv[0]); - error = EXIT_BADARGS; - goto err; - } - } - - if (argv[optind]) { - usage(1, argv[0]); - error = EXIT_BADARGS; - goto err; - } - - /* set default permissions */ - default_group = cgroup_new_cgroup("default"); - if (!default_group) { - error = -1; - err("%s: cannot create default cgroup\n", argv[0]); - goto err; - } - - error = cgroup_set_uid_gid(default_group, tuid, tgid, auid, agid); - if (error) { - err("%s: cannot set default UID and GID: %s\n", argv[0], cgroup_strerror(error)); - goto free_cgroup; - } - - if (dirm_change | filem_change) { - cgroup_set_permissions(default_group, dir_mode, file_mode, tasks_mode); - } - - error = cgroup_config_set_default(default_group); - if (error) { - err("%s: cannot set config parser defaults: %s\n", argv[0], - cgroup_strerror(error)); - goto free_cgroup; - } - - for (i = 0; i < cfg_files.count; i++) { - ret = cgroup_config_load_config(cfg_files.items[i]); - if (ret) { - err("%s; error loading %s: %s\n", argv[0], cfg_files.items[i], - cgroup_strerror(ret)); - if (!error) - error = ret; - } - } - -free_cgroup: - cgroup_free(&default_group); -err: - cgroup_string_list_free(&cfg_files); - - return error; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgcreate.c b/lib/libcgroup-3.1.0/src/tools/cgcreate.c deleted file mode 100644 index 82a6c97c7c8..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgcreate.c +++ /dev/null @@ -1,355 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright Red Hat, Inc. 2009 - * - * Authors: Ivana Hutarova Varekova - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -/* - * Display the usage - */ -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h for more information.\n", program_name); - return; - } - - info("Usage: %s [-h] [-f mode] [-d mode] [-s mode] ", program_name); - info("[-t :] [-a :] -g : [-g ...]\n"); - info("Create control group(s)\n"); - info(" -a : Owner of the group and all its files\n"); - info(" -d, --dperm=mode Group directory permissions\n"); - info(" -f, --fperm=mode Group file permissions\n"); - info(" -g : Control group which should be added\n"); - info(" -h, --help Display this help\n"); - info(" -s, --tperm=mode Tasks file permissions\n"); - info(" -t : Owner of the tasks file\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd"); - info("delegate hierarchy\n"); - info(" -c, --scope Create a delegated systemd scope\n"); - info(" -p, --pid=pid Task pid to use to create systemd "); - info("scope\n"); - info(" -S, --setdefault Set this scope as the default scope "); - info("delegate hierarchy\n"); -#endif -} - -#ifdef WITH_SYSTEMD -static int create_systemd_scope(struct cgroup * const cg, const char * const prog_name, - int set_default, pid_t pid) -{ - struct cgroup_systemd_scope_opts opts; - char slice[FILENAME_MAX]; - char *scope; - int ret; - int len; - - ret = cgroup_set_default_scope_opts(&opts); - if (ret) - return ret; - - opts.pid = pid; - - ret = cgroup_create_scope2(cg, 0, &opts); - if (!ret && set_default) { - scope = strstr(cg->name, "/"); - if (!scope) { - err("%s: Invalid scope name %s, expected /\n", - prog_name, cg->name); - ret = ECGINVAL; - goto err; - } - len = strlen(cg->name) - strlen(scope); - strncpy(slice, cg->name, FILENAME_MAX - 1); - slice[len] = '\0'; - scope++; - - ret = cgroup_write_systemd_default_cgroup(slice, scope); - /* - * cgroup_write_systemd_default_cgroup() returns 0 on failure - */ - if (ret == 0) { - err("%s: failed to write default %s/%s to ", - prog_name, slice, scope); - err("/var/run/libcgroup/systemd\n"); - ret = ECGINVAL; - goto err; - } - - /* - * the default was successfully set. override the return of "1" back to - * the usual "0" on success. - */ - ret = 0; - } - -err: - return ret; -} -#else -static int create_systemd_scope(struct cgroup * const cg, const char * const prog_name, - int set_default, pid_t pid) -{ - return ECGINVAL; -} -#endif /* WITH_SYSTEMD */ - -int main(int argc, char *argv[]) -{ - static struct option long_opts[] = { - {"help", no_argument, NULL, 'h'}, - {"task", required_argument, NULL, 't'}, - {"admin", required_argument, NULL, 'a'}, - {"", required_argument, NULL, 'g'}, - {"dperm", required_argument, NULL, 'd'}, - {"fperm", required_argument, NULL, 'f'}, - {"tperm", required_argument, NULL, 's'}, -#ifdef WITH_SYSTEMD - {"scope", no_argument, NULL, 'c'}, - {"setdefault", no_argument, NULL, 'S'}, - {"pid", required_argument, NULL, 'p'}, -#endif /* WITH_SYSTEMD */ - {0, 0, 0, 0}, - }; - - uid_t tuid = CGRULE_INVALID, auid = CGRULE_INVALID; - gid_t tgid = CGRULE_INVALID, agid = CGRULE_INVALID; - - int ignore_default_systemd_delegate_slice = 0; - int set_default_scope = 0; - int create_scope = 0; - pid_t scope_pid = -1; - - struct cgroup_group_spec **cgroup_list; - struct cgroup_controller *cgc; - struct cgroup *cgroup; - - /* approximation of max. numbers of groups that will be created */ - int capacity = argc; - - /* permission variables */ - mode_t tasks_mode = NO_PERMS; - mode_t file_mode = NO_PERMS; - mode_t dir_mode = NO_PERMS; - int filem_change = 0; - int dirm_change = 0; - - int ret = 0; - int i, j; - int c; - - /* no parametr on input */ - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - cgroup_list = calloc(capacity, sizeof(struct cgroup_group_spec *)); - if (cgroup_list == NULL) { - err("%s: out of memory\n", argv[0]); - ret = -1; - goto err; - } - -#ifdef WITH_SYSTEMD - /* parse arguments */ - while ((c = getopt_long(argc, argv, "a:t:g:hd:f:s:bcp:S", long_opts, NULL)) > 0) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; - case 'c': - create_scope = 1; - break; - case 'p': - scope_pid = atoi(optarg); - if (scope_pid <= 1) { - err("%s: Invalid pid %s\n", argv[0], optarg); - ret = EXIT_BADARGS; - goto err; - } - break; - case 'S': - set_default_scope = 1; - break; -#else - while ((c = getopt_long(argc, argv, "a:t:g:hd:f:s:", long_opts, NULL)) > 0) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - ret = 0; - goto err; - case 'a': - /* set admin uid/gid */ - if (parse_uid_gid(optarg, &auid, &agid, argv[0])) - goto err; - break; - case 't': - /* set task uid/gid */ - if (parse_uid_gid(optarg, &tuid, &tgid, argv[0])) - goto err; - break; - case 'g': - ret = parse_cgroup_spec(cgroup_list, optarg, capacity); - if (ret) { - err("%s: cgroup controller and path parsing failed (%s)\n", - argv[0], argv[optind]); - ret = EXIT_BADARGS; - goto err; - } - break; - case 'd': - dirm_change = 1; - ret = parse_mode(optarg, &dir_mode, argv[0]); - if (ret) - goto err; - break; - case 'f': - filem_change = 1; - ret = parse_mode(optarg, &file_mode, argv[0]); - if (ret) - goto err; - break; - case 's': - filem_change = 1; - ret = parse_mode(optarg, &tasks_mode, argv[0]); - if (ret) - goto err; - break; - default: - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - } - -#ifdef WITH_SYSTEMD - if (ignore_default_systemd_delegate_slice && create_scope) { - err("%s: \"-b\" and \"-c\" are mutually exclusive\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - if (set_default_scope && !create_scope) { - err("%s: \"-S\" requires \"-c\" to be provided\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - if (!create_scope && scope_pid != -1) { - err("%s: \"-p\" requires \"-c\" to be provided\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } -#endif - - /* no cgroup name */ - if (argv[optind]) { - err("%s: wrong arguments (%s)\n", argv[0], argv[optind]); - ret = EXIT_BADARGS; - goto err; - } - - /* initialize libcg */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* this will always be false if WITH_SYSTEMD is not defined */ - if (!create_scope && !ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* for each new cgroup */ - for (i = 0; i < capacity; i++) { - if (!cgroup_list[i]) - break; - - /* create the new cgroup structure */ - cgroup = cgroup_new_cgroup(cgroup_list[i]->path); - if (!cgroup) { - ret = ECGFAIL; - err("%s: can't add new cgroup: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* set uid and gid for the new cgroup based on input options */ - ret = cgroup_set_uid_gid(cgroup, tuid, tgid, auid, agid); - if (ret) - goto err; - - /* add controllers to the new cgroup */ - j = 0; - while (cgroup_list[i]->controllers[j]) { - if (strcmp(cgroup_list[i]->controllers[j], "*") == 0) { - /* it is meta character, add all controllers */ - ret = cgroup_add_all_controllers(cgroup); - if (ret != 0) { - ret = ECGINVAL; - err("%s: can't add all controllers\n", argv[0]); - cgroup_free(&cgroup); - goto err; - } - } else { - cgc = cgroup_add_controller(cgroup, - cgroup_list[i]->controllers[j]); - if (!cgc) { - ret = ECGINVAL; - err("%s: controller %s can't be add\n", argv[0], - cgroup_list[i]->controllers[j]); - cgroup_free(&cgroup); - goto err; - } - } - j++; - } - - /* all variables set so create cgroup */ - if (dirm_change | filem_change) - cgroup_set_permissions(cgroup, dir_mode, file_mode, tasks_mode); - - if (create_scope) { - ret = create_systemd_scope(cgroup, argv[0], set_default_scope, scope_pid); - } else { - ret = cgroup_create_cgroup(cgroup, 0); - } - if (ret) { - err("%s: can't create cgroup %s: %s\n", argv[0], cgroup->name, - cgroup_strerror(ret)); - cgroup_free(&cgroup); - goto err; - } - cgroup_free(&cgroup); - } - -err: - if (cgroup_list) { - for (i = 0; i < capacity; i++) { - if (cgroup_list[i]) - cgroup_free_group_spec(cgroup_list[i]); - } - free(cgroup_list); - } - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgdelete.c b/lib/libcgroup-3.1.0/src/tools/cgdelete.c deleted file mode 100644 index 5e85a9316c6..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgdelete.c +++ /dev/null @@ -1,295 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright RedHat Inc. 2009 - * - * Authors: Jan Safranek - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include - -static const struct option long_options[] = { - {"recursive", no_argument, NULL, 'r'}, - {"help", no_argument, NULL, 'h'}, - {"group", required_argument, NULL, 'g'}, - {NULL, 0, NULL, 0} -}; - -struct ext_cgroup_record { - char name[FILENAME_MAX]; /* controller name */ - char controller[FILENAME_MAX]; /* cgroup name */ - int h_number; /* hierarchy number */ -}; - - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters,"); - err(" try %s --help' for more information.\n", program_name); - return; - } - - info("Usage: %s [-h] [-r] [[-g] :] ...\n", program_name); - info("Remove control group(s)\n"); - info(" -g : Control group to be removed (-g is optional)\n"); - info(" -h, --help Display this help\n"); - info(" -r, --recursive Recursively remove all subgroups\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); -#endif -} - -/* - * Skip adding controller which points to the same cgroup when delete - * cgroup with specifying multi controllers. Just skip controller which - * cgroup and hierarchy number is same - */ -static int skip_add_controller(int counter, int *skip, struct ext_cgroup_record *ecg_list) -{ - struct controller_data info; - void *handle; - int ret = 0; - int k; - - /* find out hierarchy number of added cgroup */ - ecg_list[counter].h_number = 0; - - ret = cgroup_get_all_controller_begin(&handle, &info); - while (ret == 0) { - if (!strcmp(info.name, ecg_list[counter].name)) { - /* hierarchy number found out, set it */ - ecg_list[counter].h_number = info.hierarchy; - break; - } - ret = cgroup_get_all_controller_next(&handle, &info); - } - cgroup_get_all_controller_end(&handle); - - /* deal with cgroup_get_controller_begin/next ret values */ - if (ret == ECGEOF) - ret = 0; - if (ret) { - err("cgroup_get_controller_begin/next failed(%s)\n", cgroup_strerror(ret)); - return ret; - } - - /* found out whether the hierarchy should be skipped */ - *skip = 0; - for (k = 0; k < counter; k++) { - if ((!strcmp(ecg_list[k].name, ecg_list[counter].name)) && - (ecg_list[k].h_number == ecg_list[counter].h_number)) { - /* we found a control group in the same hierarchy */ - if (strcmp(ecg_list[k].controller, ecg_list[counter].controller)) { - /* - * it is a different controller -> if there - * is not one cgroup for the same controller, - * skip it - */ - *skip = 1; - } else { - /* - * there is the identical group,controller - * pair don't skip it - */ - *skip = 0; - return ret; - } - } - } - - return ret; -} - - -int main(int argc, char *argv[]) -{ - int ignore_default_systemd_delegate_slice = 0; - struct cgroup_group_spec **cgroup_list = NULL; - struct ext_cgroup_record *ecg_list = NULL; - struct cgroup_controller *cgc; - struct cgroup *cgroup; - - int final_ret = 0; - int counter = 0; - int flags = 0; - int max = 0; - int ret = 0; - int i, j, c; - int skip; - - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - /* initialize libcg */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - cgroup_list = calloc(argc, sizeof(struct cgroup_group_spec *)); - if (cgroup_list == NULL) { - err("%s: out of memory\n", argv[0]); - ret = -1; - goto err; - } - - ecg_list = calloc(argc, sizeof(struct ext_cgroup_record)); - if (ecg_list == NULL) { - err("%s: out of memory\n", argv[0]); - ret = -1; - goto err; - } - - /* Parse arguments */ -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "rhg:b", long_options, NULL)) > 0) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; -#else - while ((c = getopt_long(argc, argv, "rhg:", long_options, NULL)) > 0) { - switch (c) { -#endif - case 'r': - flags |= CGFLAG_DELETE_RECURSIVE; - break; - case 'g': - ret = parse_cgroup_spec(cgroup_list, optarg, argc); - if (ret != 0) { - err("%s: error parsing cgroup '%s'", argv[0], optarg); - ret = EXIT_BADARGS; - goto err; - } - break; - case 'h': - usage(0, argv[0]); - ret = 0; - goto err; - default: - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* parse groups on command line */ - for (i = optind; i < argc; i++) { - ret = parse_cgroup_spec(cgroup_list, argv[i], argc); - if (ret != 0) { - err("%s: error parsing cgroup '%s'\n", argv[0], argv[i]); - ret = EXIT_BADARGS; - goto err; - } - } - - /* for each cgroup to be deleted */ - for (i = 0; i < argc; i++) { - if (!cgroup_list[i]) - break; - - /* create the new cgroup structure */ - cgroup = cgroup_new_cgroup(cgroup_list[i]->path); - if (!cgroup) { - ret = ECGFAIL; - err("%s: can't create new cgroup: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* add controllers to the cgroup */ - j = 0; - while (cgroup_list[i]->controllers[j]) { - skip = 0; - /* - * save controller name, cg name and hierarchy - * number to determine whether we should skip - * adding controller - */ - if (counter == max) { - /* - * there is not enough space to store - * them, create it - */ - max = max + argc; - ecg_list = (struct ext_cgroup_record *) - realloc(ecg_list, max * sizeof(struct ext_cgroup_record)); - if (!ecg_list) { - err("%s: not enough memory\n", argv[0]); - final_ret = -1; - goto err; - } - } - - strncpy(ecg_list[counter].controller, - cgroup_list[i]->controllers[j], FILENAME_MAX); - ecg_list[counter].controller[FILENAME_MAX - 1] = '\0'; - - strncpy(ecg_list[counter].name, - cgroup_list[i]->path, FILENAME_MAX); - ecg_list[counter].name[FILENAME_MAX - 1] = '\0'; - - ret = skip_add_controller(counter, &skip, ecg_list); - if (ret) - goto err; - - if (skip) { - /* don't add the controller, goto next one */ - goto next; - } - - cgc = cgroup_add_controller(cgroup, cgroup_list[i]->controllers[j]); - if (!cgc) { - ret = ECGFAIL; - err("%s: controller %s can't be added\n", argv[0], - cgroup_list[i]->controllers[j]); - cgroup_free(&cgroup); - goto err; - } -next: - counter++; - j++; - } - - ret = cgroup_delete_cgroup_ext(cgroup, flags); - /* Remember the errors and continue, try to remove all groups. */ - if (ret != 0) { - err("%s: cannot remove group '%s': %s\n", argv[0], cgroup->name, - cgroup_strerror(ret)); - final_ret = ret; - } - cgroup_free(&cgroup); - } - - ret = final_ret; - -err: - if (ecg_list) - free(ecg_list); - - if (cgroup_list) { - for (i = 0; i < argc; i++) { - if (cgroup_list[i]) - cgroup_free_group_spec(cgroup_list[i]); - } - free(cgroup_list); - } - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgexec.c b/lib/libcgroup-3.1.0/src/tools/cgexec.c deleted file mode 100644 index 863d4fb58d4..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgexec.c +++ /dev/null @@ -1,524 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright RedHat Inc. 2008 - * - * Authors: Vivek Goyal - * - * Replace systemd idle_thread enhancements by Kamalesh Babulal - * Copyright (c) 2023 Oracle and/or its affiliates. - * Author: Kamalesh Babulal - */ - -#ifndef _GNU_SOURCE -#define _GNU_SOURCE -#endif - -#include "tools-common.h" - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -#define SYSTEMD_IDLE_THREAD "libcgroup_systemd_idle_thread" - -static pid_t find_scope_pid(pid_t pid); -static int write_systemd_unified(const char * const scope_name); -static int is_scope_parsed(const char * const path); - -static struct option longopts[] = { - {"sticky", no_argument, NULL, 's'}, - {"help", no_argument, NULL, 'h'}, - {0, 0, 0, 0} -}; - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s --help for more information.\n", program_name); - return; - } - - info("Usage: %s [-h] [-g :] [--sticky] ", program_name); - info("command [arguments] ...\n"); - info("Run the task in given control group(s)\n"); - info(" -g : Control group which should be added\n"); - info(" -h, --help Display this help\n"); - info(" --sticky cgred daemon does not "); - info("change pidlist and children tasks\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); - info(" -r Replace the default idle_thread spawned "); - info("for the systemd scope\n"); -#endif -} - -int main(int argc, char *argv[]) -{ - struct cgroup_group_spec *cgroup_list[CG_HIER_MAX]; - int ignore_default_systemd_delegate_slice = 0; - pid_t scope_pid = -1; - int child_status = 0; - int replace_idle = 0; - int cg_specified = 0; - int flag_child = 0; - int i, ret = 0; - uid_t uid; - gid_t gid; - pid_t pid; - int c; - - memset(cgroup_list, 0, sizeof(cgroup_list)); -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "+g:shbr", longopts, NULL)) > 0) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; - case 'r': - replace_idle = 1; - break; -#else - while ((c = getopt_long(argc, argv, "+g:sh", longopts, NULL)) > 0) { - switch (c) { -#endif - case 'g': - ret = parse_cgroup_spec(cgroup_list, optarg, CG_HIER_MAX); - if (ret) { - err("cgroup controller and path parsing failed\n"); - exit(EXIT_BADARGS); - } - cg_specified = 1; - break; - case 's': - flag_child |= CGROUP_DAEMON_UNCHANGE_CHILDREN; - break; - case 'h': - usage(0, argv[0]); - exit(0); - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - } - - /* Executable name */ - if (!argv[optind]) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - /* Initialize libcg */ - ret = cgroup_init(); - if (ret) { - err("libcgroup initialization failed: %s\n", cgroup_strerror(ret)); - return ret; - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* Just for debugging purposes. */ - uid = geteuid(); - gid = getegid(); - cgroup_dbg("My euid and egid is: %d,%d\n", (int) uid, (int) gid); - - uid = getuid(); - gid = getgid(); - pid = getpid(); - - ret = cgroup_register_unchanged_process(pid, flag_child); - if (ret) { - err("registration of process failed\n"); - return ret; - } - - /* - * 'cgexec' command file needs the root privilege for executing a - * cgroup_register_unchanged_process() by using unix domain socket, - * and an euid/egid should be changed to the executing user from a - * root user. - */ - if (setresuid(uid, uid, uid)) { - err("%s", strerror(errno)); - return -1; - } - - if (setresgid(gid, gid, gid)) { - err("%s", strerror(errno)); - return -1; - } - - if (cg_specified) { - /* - * User has specified the list of control group - * and controllers - */ - for (i = 0; i < CG_HIER_MAX; i++) { - if (!cgroup_list[i]) - break; - - ret = cgroup_change_cgroup_path(cgroup_list[i]->path, pid, - (const char *const*) cgroup_list[i]->controllers); - if (ret) { - err("cgroup change of group failed\n"); - return ret; - } - } - } else { - - /* Change the cgroup by determining the rules based on uid */ - ret = cgroup_change_cgroup_flags(uid, gid, argv[optind], pid, 0); - if (ret) { - err("cgroup change of group failed\n"); - return ret; - } - } - - if (!replace_idle) { - /* Now exec the new process */ - execvp(argv[optind], &argv[optind]); - err("exec failed:%s", strerror(errno)); - return -1; - } - - scope_pid = find_scope_pid(pid); - if (scope_pid == -1) - return -1; - - pid = fork(); - if (pid == -1) { - err("Fork failed for pid %u:%s\n", pid, strerror(errno)); - return -1; - } - - /* child process kills the spawned idle_thread */ - if (pid == 0) { - ret = kill(scope_pid, SIGTERM); - if (ret) { - err("Failed to kill pid %u:%s\n", scope_pid, strerror(errno)); - exit(1); - } - - exit(0); - } - - wait(&child_status); - if (WEXITSTATUS(child_status)) - return -1; - - /* Now exec the new process */ - execvp(argv[optind], &argv[optind]); - err("exec failed:%s", strerror(errno)); - - return -1; -} - -static pid_t search_systemd_idle_thread_task(pid_t pids[], size_t size) -{ - char task_cmd[FILENAME_MAX]; - char buffer[FILENAME_MAX]; - FILE *pid_cmd_fp = NULL; - int scope_pid = -1; - int i; - - for (i = 0; i < size; i++) { - snprintf(buffer, FILENAME_MAX, "/proc/%u/cmdline", pids[i]); - pid_cmd_fp = fopen(buffer, "re"); - /* task might have exited */ - if (!pid_cmd_fp) - continue; - - /* task might have exited, so consider only successful reads. */ - if (fgets(task_cmd, FILENAME_MAX, pid_cmd_fp)) { - if (!strcmp(task_cmd, SYSTEMD_IDLE_THREAD)) { - scope_pid = pids[i]; - fclose(pid_cmd_fp); - break; - } - } - fclose(pid_cmd_fp); - } - return scope_pid; - -} - -static pid_t find_scope_pid(pid_t pid) -{ - pid_t _scope_pid = -1, scope_pid = -1; - char ctrl_name[CONTROL_NAMELEN_MAX]; - char cgroup_name[FILENAME_MAX]; - char scope_name[FILENAME_MAX]; - int found_systemd_cgrp = 0; - int found_unified_cgrp = 0; - char buffer[FILENAME_MAX]; - FILE *pid_proc_fp = NULL; - char *_ctrl_name = NULL; - int idx, ret, size = 0; - pid_t *pids; - - - /* Let's parse the cgroup of the pid, to check if its in one or - * more .scopes. - */ - snprintf(buffer, FILENAME_MAX, "/proc/%u/cgroup", pid); - pid_proc_fp = fopen(buffer, "re"); - if (!pid_proc_fp) { - err("Failed to open: %s\n", buffer); - return -1; - } - - while (fgets(buffer, FILENAME_MAX, pid_proc_fp)) { - memset(ctrl_name, '\0', sizeof(CONTROL_NAMELEN_MAX)); - - /* read according to the cgroup mode */ - if (strstr(buffer, "::")) - ret = sscanf(buffer, "%d::%4096s\n", &idx, cgroup_name); - else - ret = sscanf(buffer, "%d:%[^:]:%4096s\n", &idx, ctrl_name, cgroup_name); - - if (ret != 2 && ret != 3) { - err("Unrecognized cgroup file format: %s\n", buffer); - goto out; - } - - if (!is_cgroup_mode_unified()) { - if (ret == 3 && !strncmp(ctrl_name, "name=systemd", 12)) { - found_systemd_cgrp = 1; - continue; - } else if (ret == 2) { - found_unified_cgrp = 1; - continue; - } - } - - /* skip if the cgroup path doesn't have systemd scope format */ - if (strstr(cgroup_name, ".scope") == NULL || - strstr(cgroup_name, ".slice") == NULL) - continue; - - /* skip if we have already searched cgroup for idle_thread */ - if (is_scope_parsed(cgroup_name)) - continue; - - /* cgroup v1 might have shared mount points cpu,cpuacct */ - _ctrl_name = strchr(ctrl_name, ','); - if (_ctrl_name) { - size = strlen(ctrl_name) - strlen(_ctrl_name); - ctrl_name[size] = '\0'; - } - - if (ret == 2) - ret = cgroup_get_procs(cgroup_name, NULL, &pids, &size); - else - ret = cgroup_get_procs(cgroup_name, ctrl_name, &pids, &size); - if (ret) { - err("Failed to read cgroup.procs of cgroup: %s\n", cgroup_name + 1); - goto out; - } - - /* - * .scope created by the non-libcgroup process, will not - * have libcgroup_systemd_idle_thread - */ - _scope_pid = search_systemd_idle_thread_task(pids, size); - free(pids); - - if (_scope_pid == -1) - continue; - - if (scope_pid == -1) { - /* - * cgexec pid needs to written into: - * ../systemd///cgroup.procs (legacy/hybrid) - * ../unified///cgroup.procs (hybrid) - */ - snprintf(scope_name, FILENAME_MAX, "%s", cgroup_name); - scope_pid = _scope_pid; - continue; - } - - if (_scope_pid != scope_pid) { - err("Failed to replace scope idle_thread, found two idle_thread\n"); - err(" %u %u\n", scope_pid, _scope_pid); - goto out; - } - } - - if (scope_pid == -1) { - err("Failed to find idle_thread task\n"); - goto out; - } - - if (is_cgroup_mode_legacy() && (found_systemd_cgrp == 0 || found_unified_cgrp == 1)) { - err("cgroup legacy setup incorrect\n"); - scope_pid = -1; - goto out; - } - - if (is_cgroup_mode_hybrid() && (found_systemd_cgrp == 0 || found_unified_cgrp == 0)) { - err("cgroup hybrid setup incorrect\n"); - scope_pid = -1; - goto out; - } - - /* This is true for cgroup v1 (legacy/hybrid) */ - if (found_systemd_cgrp) { - ret = write_systemd_unified(scope_name); - if (ret) - scope_pid = -1; - } - -out: - if (pid_proc_fp) - fclose(pid_proc_fp); - - return scope_pid; -} - -/* - * Parse the /proc/mounts file and look for the controller string - * in each line. If found copies the mount point into mnt_point, - * else return NULL mnt_point. - */ -static void find_mnt_point(const char * const controller, char **mnt_point) -{ - char proc_mount[] = "/proc/mounts"; - char cgroup_path[FILENAME_MAX]; - char buffer[FILENAME_MAX * 2]; - FILE *proc_mount_f = NULL; - int ret; - - *mnt_point = NULL; - - proc_mount_f = fopen(proc_mount, "re"); - if (proc_mount_f == NULL) { - err("Failed to read %s:%s\n", proc_mount, strerror(errno)); - goto out; - } - - while (fgets(buffer, (FILENAME_MAX * 2), proc_mount_f) != NULL) { - /* skip line that doesn't have controller */ - if (!strstr(buffer, controller)) - continue; - - ret = sscanf(buffer, "%*s %4096s\n", cgroup_path); - if (ret != 1) { - err("Failed during read of %s:%s\n", proc_mount, strerror(errno)); - goto out; - } - - *mnt_point = strdup(cgroup_path); - if (!*mnt_point) - err("strdup of %s failed\n", cgroup_path); - break; - } - -out: - if (proc_mount_f) - fclose(proc_mount_f); -} - -static int write_systemd_unified(const char * const scope_name) -{ - char cgroup_procs_path[FILENAME_MAX * 2 + 25]; - FILE *cgroup_systemd_path_f = NULL; - FILE *cgroup_unified_path_f = NULL; - char *cgroup_name = NULL; - pid_t pid; - - /* construct the systemd cgroup path, by parsing /proc/mounts */ - find_mnt_point("name=systemd ", &cgroup_name); - if (!cgroup_name) { - err("Unable find name=systemd cgroup path\n"); - return -1; - } - - snprintf(cgroup_procs_path, sizeof(cgroup_procs_path), "%s/%s/cgroup.procs", - cgroup_name, scope_name); - free(cgroup_name); - - cgroup_systemd_path_f = fopen(cgroup_procs_path, "we"); - if (!cgroup_systemd_path_f) { - err("Failed to open %s\n", cgroup_procs_path); - return -1; - } - - if (is_cgroup_mode_hybrid()) { - /* - * construct the unified cgroup path, by parsing - * /proc/mounts - */ - find_mnt_point("unified cgroup2", &cgroup_name); - if (!cgroup_name) { - err("Unable find unified cgroup path\n"); - fclose(cgroup_systemd_path_f); - return -1; - } - - snprintf(cgroup_procs_path, sizeof(cgroup_procs_path), "%s/%s/cgroup.procs", - cgroup_name, scope_name); - free(cgroup_name); - - cgroup_unified_path_f = fopen(cgroup_procs_path, "we"); - if (!cgroup_unified_path_f) { - err("Failed to open %s\n", cgroup_procs_path); - fclose(cgroup_systemd_path_f); - return -1; - } - } - - pid = getpid(); - - fprintf(cgroup_systemd_path_f, "%d", pid); - fflush(cgroup_systemd_path_f); - fclose(cgroup_systemd_path_f); - - if (!is_cgroup_mode_hybrid()) - return 0; - - fprintf(cgroup_unified_path_f, "%d", pid); - fflush(cgroup_unified_path_f); - fclose(cgroup_unified_path_f); - - return 0; -} - -static int is_scope_parsed(const char * const path) -{ - /* - * As per, /kernel/cgroup/cgroup.c::cgroup_init() - * At the max there can be only 16 controllers and we are - * not accounting for named hierarchies, which can be more - * than 16 themselves. - */ - static char parsed_scope_path[MAX_MNT_ELEMENTS][FILENAME_MAX]; - int i; - - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - if (!strcmp(parsed_scope_path[i], path)) - return 1; - - if (parsed_scope_path[i][0] == '\0') { - snprintf(parsed_scope_path[i], FILENAME_MAX, "%s", path); - break; - } - } - - return 0; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgget.c b/lib/libcgroup-3.1.0/src/tools/cgget.c deleted file mode 100644 index 07f1fb2d8ff..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgget.c +++ /dev/null @@ -1,883 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -#define MODE_SHOW_HEADERS 1 -#define MODE_SHOW_NAMES 2 -#define MODE_SYSTEMD_DELEGATE 4 - -#define LL_MAX 100 - -static int find_cgroup_mount_type(void); -static int print_controller_version(void); - -static const struct option long_options[] = { - {"variable", required_argument, NULL, 'r'}, - {"help", no_argument, NULL, 'h'}, - {"all", no_argument, NULL, 'a'}, - {"values-only", no_argument, NULL, 'v'}, - {NULL, 0, NULL, 0} -}; - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h' for more information.\n", program_name); - return; - } - info("Usage: %s [-nv] [-r ] [-g ] [-a] ...\n", program_name); - info("Print parameter(s) of given group(s).\n"); - info(" -a, --all Print info about all relevant controllers\n"); - info(" -g Controller which info should be displayed\n"); - info(" -g : Control group which info should be displayed\n"); - info(" -h, --help Display this help\n"); - info(" -n Do not print headers\n"); - info(" -r, --variable Define parameter to display\n"); - info(" -v, --values-only Print only values, not "); - info("parameter names\n"); - info(" -m Display the cgroup mode\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); -#endif - info(" -c Display controller version\n"); -} - -static int get_controller_from_name(const char * const name, char **controller) -{ - char *dot; - - *controller = strdup(name); - if (*controller == NULL) - return ECGOTHER; - - dot = strchr(*controller, '.'); - if (dot == NULL) { - err("cgget: error parsing parameter name '%s'", name); - return ECGINVAL; - } - *dot = '\0'; - - return 0; -} - -static int create_cg(struct cgroup **cg_list[], int * const cg_list_len) -{ - *cg_list = realloc(*cg_list, ((*cg_list_len) + 1) * sizeof(struct cgroup *)); - if ((*cg_list) == NULL) - return ECGCONTROLLERCREATEFAILED; - - memset(&(*cg_list)[*cg_list_len], 0, sizeof(struct cgroup *)); - - (*cg_list)[*cg_list_len] = cgroup_new_cgroup(""); - if ((*cg_list)[*cg_list_len] == NULL) - return ECGCONTROLLERCREATEFAILED; - - (*cg_list_len)++; - - return 0; -} - -static int parse_a_flag(struct cgroup **cg_list[], int * const cg_list_len) -{ - struct cgroup_mount_point controller; - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - void *handle; - int ret = 0; - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-r" was provided, then we know that the cgroup(s) will be - * an optarg at the end with no flag. Let's temporarily populate - * the first cgroup with the requested control values. - */ - cg = (*cg_list)[0]; - - ret = cgroup_get_controller_begin(&handle, &controller); - while (ret == 0) { - cgc = cgroup_get_controller(cg, controller.name); - if (!cgc) { - cgc = cgroup_add_controller(cg, controller.name); - if (!cgc) { - err("cgget: cannot find controller '%s'\n", controller.name); - ret = ECGOTHER; - goto out; - } - } - ret = cgroup_get_controller_next(&handle, &controller); - } - if (ret == ECGEOF) - /* - * we successfully reached the end of the controller list; - * this is not an error - */ - ret = 0; - - cgroup_get_controller_end(&handle); - - return ret; - -out: - cgroup_get_controller_end(&handle); - - return ret; -} - -static int parse_r_flag(struct cgroup **cg_list[], int * const cg_list_len, - const char * const cntl_value) -{ - char *cntl_value_controller = NULL; - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - int ret = 0; - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-r" was provided, then we know that the cgroup(s) will be - * an optarg at the end with no flag. Let's temporarily populate - * the first cgroup with the requested control values. - */ - cg = (*cg_list)[0]; - - ret = get_controller_from_name(cntl_value, &cntl_value_controller); - if (ret) - goto out; - - cgc = cgroup_get_controller(cg, cntl_value_controller); - if (!cgc) { - cgc = cgroup_add_controller(cg, cntl_value_controller); - if (!cgc) { - err("cgget: cannot find controller '%s'\n", cntl_value_controller); - ret = ECGOTHER; - goto out; - } - } - - ret = cgroup_add_value_string(cgc, cntl_value, NULL); - -out: - if (cntl_value_controller) - free(cntl_value_controller); - - return ret; -} - -static int parse_g_flag_no_colon(struct cgroup **cg_list[], int * const cg_list_len, - const char * const ctrl_str) -{ - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - int ret = 0; - - if ((*cg_list_len) > 1) { - ret = ECGMAXVALUESEXCEEDED; - goto out; - } - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-g " was provided, then we know that the cgroup(s) - * will be an optarg at the end with no flag. Let's temporarily - * populate the first cgroup with the requested control values. - */ - cg = *cg_list[0]; - - cgc = cgroup_get_controller(cg, ctrl_str); - if (!cgc) { - cgc = cgroup_add_controller(cg, ctrl_str); - if (!cgc) { - err("cgget: cannot find controller '%s'\n", ctrl_str); - ret = ECGOTHER; - goto out; - } - } - -out: - return ret; -} - -static int split_cgroup_name(const char * const ctrl_str, char *cg_name) -{ - char *colon; - - colon = strchr(ctrl_str, ':'); - if (colon == NULL) { - /* ctrl_str doesn't contain a ":" */ - cg_name[0] = '\0'; - return ECGINVAL; - } - - strncpy(cg_name, &colon[1], FILENAME_MAX - 1); - - return 0; -} - -static int split_controllers(const char * const in, char **ctrl[], int * const ctrl_len) -{ - char *copy, *tok, *colon, *saveptr = NULL; - int ret = 0; - char **tmp; - - copy = strdup(in); - if (!copy) - goto out; - saveptr = copy; - - colon = strchr(copy, ':'); - if (colon) - colon[0] = '\0'; - - while ((tok = strtok_r(copy, ",", ©))) { - tmp = realloc(*ctrl, sizeof(char *) * ((*ctrl_len) + 1)); - if (!tmp) { - ret = ECGOTHER; - goto out; - } - - *ctrl = tmp; - (*ctrl)[*ctrl_len] = strdup(tok); - if ((*ctrl)[*ctrl_len] == NULL) { - ret = ECGOTHER; - goto out; - } - - (*ctrl_len)++; - } - -out: - if (saveptr) - free(saveptr); - - return ret; -} - -static int parse_g_flag_with_colon(struct cgroup **cg_list[], int * const cg_list_len, - const char * const ctrl_str) -{ - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - char **controllers = NULL; - int controllers_len = 0; - int i, ret = 0; - - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - - cg = (*cg_list)[(*cg_list_len) - 1]; - - ret = split_cgroup_name(ctrl_str, cg->name); - if (ret) - goto out; - - ret = split_controllers(ctrl_str, &controllers, &controllers_len); - if (ret) - goto out; - - for (i = 0; i < controllers_len; i++) { - cgc = cgroup_get_controller(cg, controllers[i]); - if (!cgc) { - cgc = cgroup_add_controller(cg, controllers[i]); - if (!cgc) { - err("cgget: cannot find controller '%s'\n", controllers[i]); - ret = ECGOTHER; - goto out; - } - } - } - -out: - for (i = 0; i < controllers_len; i++) - free(controllers[i]); - - return ret; -} - -static int parse_opt_args(int argc, char *argv[], struct cgroup **cg_list[], - int * const cg_list_len, bool first_cg_is_dummy) -{ - struct cgroup *cg = NULL; - int ret = 0; - - /* - * The first cgroup was temporarily populated and requires the - * user to provide a cgroup name as an opt - */ - if (argv[optind] == NULL && first_cg_is_dummy) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - /* - * The user has provided a cgroup and controller via the - * -g : flag and has also provided a cgroup - * via the optind. This was not supported by the previous cgget - * implementation. Continue that approach. - * - * Example of a command that will hit this code: - * $ cgget -g cpu:mycgroup mycgroup - */ - if (argv[optind] != NULL && (*cg_list_len) > 0 && - strcmp((*cg_list)[0]->name, "") != 0) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - while (argv[optind] != NULL) { - if ((*cg_list_len) > 0) - cg = (*cg_list)[(*cg_list_len) - 1]; - else - cg = NULL; - - if ((*cg_list_len) == 0) { - /* - * The user didn't provide a '-r' or '-g' flag. - * The parse_a_flag() function can be reused here - * because we both have the same use case - gather - * all the data about this particular cgroup. - */ - ret = parse_a_flag(cg_list, cg_list_len); - if (ret) - goto out; - - strncpy((*cg_list)[(*cg_list_len) - 1]->name, argv[optind], - sizeof((*cg_list)[(*cg_list_len) - 1]->name) - 1); - } else if (cg != NULL && strlen(cg->name) == 0) { - /* - * this cgroup was created based upon control/value - * pairs or with a -g option. we'll - * populate it with the parameter provided by the user - */ - strncpy(cg->name, argv[optind], sizeof(cg->name) - 1); - } else { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - - ret = cgroup_copy_cgroup((*cg_list)[(*cg_list_len) - 1], - (*cg_list)[(*cg_list_len) - 2]); - if (ret) - goto out; - - strncpy((*cg_list)[(*cg_list_len) - 1]->name, argv[optind], - sizeof((*cg_list)[(*cg_list_len) - 1]->name) - 1); - } - optind++; - } - -out: - return ret; -} - -static int parse_opts(int argc, char *argv[], struct cgroup **cg_list[], int * const cg_list_len, - int * const mode) -{ - bool do_not_fill_controller = false; - bool first_cgroup_is_dummy = false; - bool cgroup_mount_type = false; - bool fill_controller = false; - bool print_ctrl_ver = false; - int ret = 0; - int c; - - /* Parse arguments. */ -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "r:hnvg:ambc", long_options, NULL)) > 0) { - switch (c) { - case 'b': - *mode = (*mode) & (INT_MAX ^ MODE_SYSTEMD_DELEGATE); - break; -#else - while ((c = getopt_long(argc, argv, "r:hnvg:amc", long_options, NULL)) > 0) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - exit(0); - case 'n': - /* Do not show headers. */ - *mode = (*mode) & (INT_MAX ^ MODE_SHOW_HEADERS); - break; - case 'v': - /* Do not show parameter names. */ - *mode = (*mode) & (INT_MAX ^ MODE_SHOW_NAMES); - break; - case 'r': - do_not_fill_controller = true; - first_cgroup_is_dummy = true; - ret = parse_r_flag(cg_list, cg_list_len, optarg); - if (ret) - goto err; - break; - case 'g': - fill_controller = true; - if (strchr(optarg, ':') == NULL) { - first_cgroup_is_dummy = true; - ret = parse_g_flag_no_colon(cg_list, cg_list_len, optarg); - if (ret) - goto err; - } else { - ret = parse_g_flag_with_colon(cg_list, cg_list_len, optarg); - if (ret) - goto err; - } - break; - case 'a': - fill_controller = true; - ret = parse_a_flag(cg_list, cg_list_len); - if (ret) - goto err; - break; - case 'm': - cgroup_mount_type = true; - break; - case 'c': - print_ctrl_ver = true; - break; - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - } - - /* Don't allow '-r' and ('-g' or '-a') */ - if (fill_controller && do_not_fill_controller) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - /* '-m' and '-c' should not used with other options */ - if ((cgroup_mount_type || print_ctrl_ver) && - (fill_controller || do_not_fill_controller)) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - if (cgroup_mount_type) { - ret = find_cgroup_mount_type(); - if (ret) - goto err; - } - - if (print_ctrl_ver) { - ret = print_controller_version(); - if (ret) - goto err; - } - - ret = parse_opt_args(argc, argv, cg_list, cg_list_len, first_cgroup_is_dummy); - if (ret) - goto err; - -err: - return ret; -} - -static int get_cv_value(struct control_value * const cv, const char * const cg_name, - const char * const controller_name) -{ - bool is_multiline = false; - void *tmp, *handle = NULL; - char tmp_line[LL_MAX]; - int ret; - - ret = cgroup_read_value_begin(controller_name, cg_name, cv->name, &handle, tmp_line, - LL_MAX); - if (ret == ECGEOF) - goto read_end; - if (ret != 0) { - if (ret == ECGOTHER) { - int tmp_ret; - - /* - * to maintain compatibility with an earlier version - * of cgget, try to determine if the failure was due - * to an invalid controller - */ - tmp_ret = cgroup_test_subsys_mounted(controller_name); - if (tmp_ret == 0) { - err("cgget: cannot find controller '%s' in group '%s'\n", - controller_name, cg_name); - } else { - err("variable file read failed %s\n", cgroup_strerror(ret)); - } - } - - goto end; - } - - /* remove the newline character */ - tmp_line[strcspn(tmp_line, "\n")] = '\0'; - - strncpy(cv->value, tmp_line, CG_CONTROL_VALUE_MAX - 1); - cv->multiline_value = strdup(cv->value); - if (cv->multiline_value == NULL) - goto read_end; - - while ((ret = cgroup_read_value_next(&handle, tmp_line, LL_MAX)) == 0) { - if (ret == 0) { - is_multiline = true; - cv->value[0] = '\0'; - - /* remove the newline character */ - tmp_line[strcspn(tmp_line, "\n")] = '\0'; - - tmp = realloc(cv->multiline_value, sizeof(char) * - (strlen(cv->multiline_value) + strlen(tmp_line) + 3)); - if (tmp == NULL) - goto read_end; - - cv->multiline_value = tmp; - strcat(cv->multiline_value, "\n\t"); - strcat(cv->multiline_value, tmp_line); - } - } - -read_end: - cgroup_read_value_end(&handle); - if (ret == ECGEOF) - ret = 0; -end: - if (is_multiline == false && cv->multiline_value) { - free(cv->multiline_value); - cv->multiline_value = NULL; - } - - if ((FILE *)handle) - fclose((FILE *)handle); - - return ret; -} - -static int indent_multiline_value(struct control_value * const cv) -{ - char tmp_val[CG_CONTROL_VALUE_MAX] = {0}; - char *tok, *saveptr = NULL; - - tok = strtok_r(cv->value, "\n", &saveptr); - strncat(tmp_val, tok, CG_CONTROL_VALUE_MAX - 1); - /* don't indent the first value */ - while ((tok = strtok_r(NULL, "\n", &saveptr))) { - strncat(tmp_val, "\n\t", (CG_CONTROL_VALUE_MAX - (strlen(tmp_val) + 1))); - strncat(tmp_val, tok, (CG_CONTROL_VALUE_MAX - (strlen(tmp_val) + 1))); - } - - cv->multiline_value = strdup(tmp_val); - if (!cv->multiline_value) - return ECGOTHER; - - return 0; -} - -static int fill_empty_controller(struct cgroup * const cg, struct cgroup_controller * const cgc) -{ - char cgrp_ctrl_path[FILENAME_MAX] = { '\0' }; - char mnt_path[FILENAME_MAX] = { '\0' }; -#ifdef WITH_SYSTEMD - char tmp[FILENAME_MAX] = { '\0' }; -#endif - struct dirent *ctrl_dir = NULL; - int i, mnt_path_len, ret = 0; - bool found_mount = false; - DIR *dir = NULL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (i = 0; i < CG_CONTROLLER_MAX && cg_mount_table[i].name[0] != '\0'; i++) { - if (strlen(cgc->name) == strlen(cg_mount_table[i].name) && - strncmp(cgc->name, cg_mount_table[i].name, strlen(cgc->name)) == 0) { - found_mount = true; - break; - } - } - - if (found_mount == false) - goto out; - - if (!cg_build_path_locked(NULL, mnt_path, cg_mount_table[i].name)) - goto out; - - mnt_path_len = strlen(mnt_path); -#ifdef WITH_SYSTEMD - /* - * If the user has set a slice/scope as setdefault in the - * cgconfig.conf file, every path constructed will have the - * systemd_default_cgroup slice/scope suffixed to it. - * - * We need to trim the slice/scope from the path, incase of - * user providing / as the cgroup name in the command - * line: - * cgget -g cpu:/foo - */ - if (cg->name[0] == '/' && cg->name[1] != '\0' && - strncmp(mnt_path + (mnt_path_len - 7), ".scope/", 7) == 0) { - snprintf(tmp, FILENAME_MAX, "%s", dirname(mnt_path)); - strncpy(mnt_path, tmp, FILENAME_MAX - 1); - mnt_path[FILENAME_MAX - 1] = '\0'; - - mnt_path_len = strlen(mnt_path); - if (strncmp(mnt_path + (mnt_path_len - 6), ".slice", 6) == 0) { - snprintf(tmp, FILENAME_MAX, "%s", dirname(mnt_path)); - strncpy(mnt_path, tmp, FILENAME_MAX - 1); - mnt_path[FILENAME_MAX - 1] = '\0'; - } else { - cgroup_dbg("Malformed path %s (expected slice name)\n", mnt_path); - ret = ECGOTHER; - goto out; - } - } -#endif - strncat(mnt_path, cg->name, FILENAME_MAX - mnt_path_len - 1); - mnt_path[sizeof(mnt_path) - 1] = '\0'; - - if (access(mnt_path, F_OK)) - goto out; - - if (!cg_build_path_locked(cg->name, cgrp_ctrl_path, cg_mount_table[i].name)) - goto out; - - dir = opendir(cgrp_ctrl_path); - if (!dir) { - ret = ECGOTHER; - goto out; - } - - while ((ctrl_dir = readdir(dir)) != NULL) { - /* Skip over non regular files */ - if (ctrl_dir->d_type != DT_REG) - continue; - - ret = cgroup_fill_cgc(ctrl_dir, cg, cgc, i); - if (ret == ECGFAIL) - goto out; - - if (cgc->index > 0) { - cgc->values[cgc->index - 1]->dirty = false; - - /* - * previous versions of cgget indented the second - * and all subsequent lines. Continue that behavior - */ - if (strchr(cgc->values[cgc->index - 1]->value, '\n')) { - ret = indent_multiline_value( - cgc->values[cgc->index - 1]); - if (ret) - goto out; - } - } - } - -out: - if (dir) - closedir(dir); - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} - -static int get_controller_values(struct cgroup * const cg, struct cgroup_controller * const cgc) -{ - int ret = 0; - int i; - - for (i = 0; i < cgc->index; i++) { - ret = get_cv_value(cgc->values[i], cg->name, cgc->name); - if (ret) - goto out; - } - - if (cgc->index == 0) { - /* fill the entire controller since no values were provided */ - ret = fill_empty_controller(cg, cgc); - if (ret) - goto out; - } - -out: - return ret; -} - -static int get_cgroup_values(struct cgroup * const cg) -{ - int ret = 0; - int i; - - for (i = 0; i < cg->index; i++) { - ret = get_controller_values(cg, cg->controller[i]); - if (ret) - break; - } - - return ret; -} - -static int get_values(struct cgroup *cg_list[], int cg_list_len) -{ - int ret = 0; - int i; - - for (i = 0; i < cg_list_len; i++) { - ret = get_cgroup_values(cg_list[i]); - if (ret) - break; - } - - return ret; -} - -void print_control_values(const struct control_value * const cv, int mode) -{ - if (mode & MODE_SHOW_NAMES) - info("%s: ", cv->name); - - if (cv->multiline_value) - info("%s\n", cv->multiline_value); - else - info("%s\n", cv->value); -} - -void print_controller(const struct cgroup_controller * const cgc, int mode) -{ - int i; - - for (i = 0; i < cgc->index; i++) - print_control_values(cgc->values[i], mode); -} - -static void print_cgroup(const struct cgroup * const cg, int mode) -{ - int i; - - if (mode & MODE_SHOW_HEADERS) - info("%s:\n", cg->name); - - for (i = 0; i < cg->index; i++) - print_controller(cg->controller[i], mode); - - if (mode & MODE_SHOW_HEADERS) - info("\n"); -} - -static void print_cgroups(struct cgroup *cg_list[], int cg_list_len, int mode) -{ - int i; - - for (i = 0; i < cg_list_len; i++) - print_cgroup(cg_list[i], mode); -} - -int main(int argc, char *argv[]) -{ - int mode = MODE_SHOW_NAMES | MODE_SHOW_HEADERS | MODE_SYSTEMD_DELEGATE; - struct cgroup **cg_list = NULL; - int cg_list_len = 0; - int ret = 0, i; - - /* No parameter on input? */ - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - ret = parse_opts(argc, argv, &cg_list, &cg_list_len, &mode); - if (ret) - goto err; - - /* this is false always for disable-systemd */ - if (mode & MODE_SYSTEMD_DELEGATE) - cgroup_set_default_systemd_cgroup(); - - ret = get_values(cg_list, cg_list_len); - if (ret) - goto err; - - print_cgroups(cg_list, cg_list_len, mode); - -err: - for (i = 0; i < cg_list_len; i++) - cgroup_free(&(cg_list[i])); - - return ret; -} - -static int find_cgroup_mount_type(void) -{ - enum cg_setup_mode_t setup_mode; - int ret = 0; - - setup_mode = cgroup_setup_mode(); - switch(setup_mode) { - case CGROUP_MODE_LEGACY: - info("Legacy Mode (Cgroup v1 only).\n"); - break; - case CGROUP_MODE_HYBRID: - info("Hybrid mode (Cgroup v1/v2).\n"); - break; - case CGROUP_MODE_UNIFIED: - info("Unified Mode (Cgroup v2 only).\n"); - break; - default: - err("Unable to determine the Cgroup setup mode.\n"); - ret = 1; - break; - } - - return ret; -} - -static int print_controller_version(void) -{ - struct cgroup_mount_point controller; - enum cg_version_t version; - void *handle; - int ret = 0; - - /* perf_event controller is the one with the lengthiest name */ - info("%-11s\t%-7s\n", "#Controller","Version"); - ret = cgroup_get_controller_begin(&handle, &controller); - while (ret == 0) { - ret = cgroup_get_controller_version(controller.name, &version); - if (!ret) - info("%-11s\t%d\n", controller.name, version); - else - info("%-11s\t%-7s\n", controller.name, "unknown"); - - ret = cgroup_get_controller_next(&handle, &controller); - } - cgroup_get_controller_end(&handle); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgset.c b/lib/libcgroup-3.1.0/src/tools/cgset.c deleted file mode 100644 index 82f698f8360..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgset.c +++ /dev/null @@ -1,288 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include - -#define FL_RULES 1 -#define FL_COPY 2 - -enum { - COPY_FROM_OPTION = CHAR_MAX + 1 -}; - -#ifndef UNIT_TEST -static const struct option long_options[] = { - {"rule", required_argument, NULL, 'r'}, - {"help", no_argument, NULL, 'h'}, - {"copy-from", required_argument, NULL, COPY_FROM_OPTION}, - {NULL, 0, NULL, 0} -}; - -int flags; /* used input method */ - -static struct cgroup *copy_name_value_from_cgroup(char src_cg_path[FILENAME_MAX]) -{ - struct cgroup *src_cgroup; - int ret = 0; - - /* create source cgroup */ - src_cgroup = cgroup_new_cgroup(src_cg_path); - if (!src_cgroup) { - err("can't create cgroup: %s\n", cgroup_strerror(ECGFAIL)); - goto scgroup_err; - } - - /* copy the name-version values to the cgroup structure */ - ret = cgroup_get_cgroup(src_cgroup); - if (ret != 0) { - err("cgroup %s error: %s\n", src_cg_path, cgroup_strerror(ret)); - goto scgroup_err; - } - - return src_cgroup; - -scgroup_err: - cgroup_free(&src_cgroup); - - return NULL; -} - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, "); - err("try %s --help' for more information.\n", program_name); - return; - } - - info("Usage: %s [-r ] ...\n", program_name); - info(" or: %s --copy-from ...\n", program_name); - info("Set the parameters of given cgroup(s)\n"); - info(" -r, --variable Define parameter to set\n"); - info(" --copy-from Control group whose "); - info("parameters will be copied\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd "); - info("delegate hierarchy\n"); -#endif -} -#endif /* !UNIT_TEST */ - -STATIC int parse_r_flag(const char * const program_name, const char * const name_value_str, - struct control_value * const name_value) -{ - char *copy = NULL, *buf = NULL; - int ret = 0; - - buf = strchr(name_value_str, '='); - if (buf == NULL) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - copy = strdup(name_value_str); - if (copy == NULL) { - err("%s: not enough memory\n", program_name); - ret = -1; - goto err; - } - - /* parse optarg value */ - buf = strtok(copy, "="); - if (buf == NULL) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - strncpy(name_value->name, buf, FILENAME_MAX); - name_value->name[FILENAME_MAX-1] = '\0'; - - buf = strchr(name_value_str, '='); - /* - * we don't need to check the return value of strchr because we - * know there's already an '=' character in the string. - */ - buf++; - - if (strlen(buf) == 0) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - strncpy(name_value->value, buf, CG_CONTROL_VALUE_MAX); - name_value->value[CG_CONTROL_VALUE_MAX-1] = '\0'; - -err: - if (copy) - free(copy); - - return ret; -} - -#ifndef UNIT_TEST -int main(int argc, char *argv[]) -{ - int ignore_default_systemd_delegate_slice = 0; - struct control_value *name_value = NULL; - int nv_number = 0; - int nv_max = 0; - - char src_cg_path[FILENAME_MAX] = "\0"; - struct cgroup *src_cgroup = NULL; - struct cgroup *cgroup = NULL; - - int ret = 0; - int c; - - /* no parameter on input */ - if (argc < 2) { - err("Usage is %s -r relative path to cgroup>\n", argv[0]); - exit(EXIT_BADARGS); - } - - /* parse arguments */ -#ifdef WITH_SYSTEMD - while ((c = getopt_long (argc, argv, "r:hb", long_options, NULL)) != -1) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; -#else - while ((c = getopt_long (argc, argv, "r:h", long_options, NULL)) != -1) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - ret = 0; - goto err; - - case 'r': - if ((flags & FL_COPY) != 0) { - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - flags |= FL_RULES; - - /* add name-value pair to buffer (= name_value variable) */ - if (nv_number >= nv_max) { - nv_max += CG_NV_MAX; - name_value = (struct control_value *) - realloc(name_value, nv_max * sizeof(struct control_value)); - if (!name_value) { - err("%s: not enough memory\n", argv[0]); - ret = -1; - goto err; - } - } - - ret = parse_r_flag(argv[0], optarg, &name_value[nv_number]); - if (ret) - goto err; - - nv_number++; - break; - case COPY_FROM_OPTION: - if (flags != 0) { - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - flags |= FL_COPY; - strncpy(src_cg_path, optarg, FILENAME_MAX); - src_cg_path[FILENAME_MAX-1] = '\0'; - break; - default: - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - } - - /* no cgroup name */ - if (!argv[optind]) { - err("%s: no cgroup specified\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - if (flags == 0) { - err("%s: no name-value pair was set\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - /* initialize libcgroup */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* copy the name-value pairs from -r options */ - if ((flags & FL_RULES) != 0) { - src_cgroup = create_cgroup_from_name_value_pairs("tmp", name_value, nv_number); - if (src_cgroup == NULL) - goto err; - } - - /* copy the name-value from the given group */ - if ((flags & FL_COPY) != 0) { - src_cgroup = copy_name_value_from_cgroup(src_cg_path); - if (src_cgroup == NULL) - goto err; - } - - while (optind < argc) { - /* create new cgroup */ - cgroup = cgroup_new_cgroup(argv[optind]); - if (!cgroup) { - ret = ECGFAIL; - err("%s: can't add new cgroup: %s\n", argv[0], cgroup_strerror(ret)); - goto cgroup_free_err; - } - - /* copy the values from the source cgroup to new one */ - ret = cgroup_copy_cgroup(cgroup, src_cgroup); - if (ret != 0) { - err("%s: cgroup %s error: %s\n", argv[0], src_cg_path, - cgroup_strerror(ret)); - goto cgroup_free_err; - } - - /* modify cgroup based on values of the new one */ - ret = cgroup_modify_cgroup(cgroup); - if (ret) { - err("%s: cgroup modify error: %s\n", argv[0], cgroup_strerror(ret)); - goto cgroup_free_err; - } - - optind++; - cgroup_free(&cgroup); - } - -cgroup_free_err: - if (cgroup) - cgroup_free(&cgroup); - if (src_cgroup) - cgroup_free(&src_cgroup); -err: - free(name_value); - - return ret; -} -#endif /* !UNIT_TEST */ diff --git a/lib/libcgroup-3.1.0/src/tools/cgsnapshot.c b/lib/libcgroup-3.1.0/src/tools/cgsnapshot.c deleted file mode 100644 index 58de4fa2675..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgsnapshot.c +++ /dev/null @@ -1,853 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright (C) 2010 Red Hat, Inc. All Rights Reserved. - * Written by Ivana Hutarova Varekova - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -enum flag { - FL_LIST = 1, - FL_SILENT = 2, /* do-not show any warning/error output */ - FL_STRICT = 4, /* don show the variables which are not on allowlist */ - FL_OUTPUT = 8, /* output should be redirect to the given file */ - FL_DENY = 16, /* denylist set */ - FL_ALLOW = 32, /* allowlist set */ -}; - -#define DENYLIST_CONF "/etc/cgsnapshot_denylist.conf" -#define ALLOWLIST_CONF "/etc/cgsnapshot_allowlist.conf" - -struct deny_list_type { - char *name; /* variable name */ - struct deny_list_type *next; /* pointer to the next record */ -}; - -struct deny_list_type *deny_list; -struct deny_list_type *allow_list; - -typedef char cont_name_t[FILENAME_MAX]; - -int flags; -FILE *output_f; - -/* - * Display the usage - */ -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h' for more information.\n", program_name); - return; - } - - info("Usage: %s [-h] [-s] [-b FILE] [-w FILE] [-f FILE] [controller] [...]\n", - program_name); - info("Generate the configuration file for given controllers\n"); - info(" -b, --denylist=FILE Set the denylist"); - info(" configuration file (default %s)\n", DENYLIST_CONF); - info(" -f, --file=FILE Redirect the output to output_file\n"); - info(" -h, --help Display this help\n"); - info(" -s, --silent Ignore all warnings\n"); - info(" -t, --strict Don't show variables "); - info("which are not on the allowlist\n"); - info(" -w, --allowlist=FILE Set the allowlist "); - info("configuration file (don't used by default)\n"); -} - -/* cache values from denylist file to the list structure */ -int load_list(char *filename, struct deny_list_type **p_list) -{ - struct deny_list_type *start = NULL; - struct deny_list_type *end = NULL; - struct deny_list_type *new; - - char buf[FILENAME_MAX]; - char name[FILENAME_MAX]; - int i = 0; - FILE *fw; - int ret; - - fw = fopen(filename, "r"); - if (fw == NULL) { - err("ERROR: Failed to open file %s: %s\n", filename, strerror(errno)); - *p_list = NULL; - return 1; - } - - /* go through the configuration file and search the line */ - while (fgets(buf, FILENAME_MAX, fw) != NULL) { - buf[FILENAME_MAX-1] = '\0'; - i = 0; - - /* if the record start with # then skip it */ - while ((buf[i] == ' ') || (buf[i] == '\n')) - i++; - - if ((buf[i] == '#') || (buf[i] == '\0')) - continue; - - ret = sscanf(buf, "%s", name); - if (ret == 0) - continue; - - new = (struct deny_list_type *) malloc(sizeof(struct deny_list_type)); - if (new == NULL) { - err("ERROR: Memory allocation problem (%s)\n", strerror(errno)); - ret = 1; - goto err; - } - - new->name = strdup(name); - if (new->name == NULL) { - err("ERROR: Memory allocation problem (%s)\n", strerror(errno)); - ret = 1; - free(new); - goto err; - } - new->next = NULL; - - /* update the variables list */ - if (start == NULL) { - start = new; - end = new; - } else { - end->next = new; - end = new; - } - } - fclose(fw); - - *p_list = start; - - return 0; - -err: - fclose(fw); - new = start; - while (new != NULL) { - end = new->next; - free(new->name); - free(new); - new = end; - } - *p_list = NULL; - - return ret; -} - -/* free list structure */ -void free_list(struct deny_list_type *list) -{ - struct deny_list_type *now; - struct deny_list_type *next; - - now = list; - while (now != NULL) { - next = now->next; - free(now->name); - free(now); - now = next; - } -} - -/* - * Test whether the variable is on the list return values are: - * 1 ... was found - * 0 ... no record was found - */ -int is_on_list(char *name, struct deny_list_type *list) -{ - struct deny_list_type *record; - - record = list; - /* go through the list of all values */ - while (record != NULL) { - /* if the variable name is found */ - if (strcmp(record->name, name) == 0) { - return 1; /* return its value */ - } - record = record->next; - } - - return 0; /* the variable was not found */ -} - -/* - * Display permissions record for the given group defined by path - */ -static int display_permissions(const char *path, const char * const cg_name, - const char * const ctrl_name) -{ - char tasks_path[FILENAME_MAX]; - struct passwd *pw; - struct group *gr; - struct stat sba; - struct stat sbt; - int ret; - - /* admin permissions record */ - /* get the directory statistic */ - ret = stat(path, &sba); - if (ret) { - err("ERROR: can't read statistics about %s\n", path); - return -1; - } - - /* tasks permissions record */ - /* get tasks file statistic */ - ret = cgroup_build_tasks_procs_path(tasks_path, sizeof(tasks_path), cg_name, ctrl_name); - if (ret) { - err("ERROR: can't build tasks/procs path: %d\n", ret); - return -1; - } - - ret = stat(tasks_path, &sbt); - if (ret) { - err("ERROR: can't read statistics about %s\n", tasks_path); - return -1; - } - - if ((sba.st_uid) || (sba.st_gid) || (sbt.st_uid) || (sbt.st_gid)) { - /* - * some uid or gid is nonroot, admin permission - * tag is necessary - */ - - /* print the header */ - fprintf(output_f, "\tperm {\n"); - - /* find out the user and group name */ - pw = getpwuid(sba.st_uid); - if (pw == NULL) { - err("ERROR: can't get %d user name\n", sba.st_uid); - fprintf(output_f, "}\n}\n"); - return -1; - } - - gr = getgrgid(sba.st_gid); - if (gr == NULL) { - err("ERROR: can't get %d group name\n", sba.st_gid); - fprintf(output_f, "}\n}\n"); - return -1; - } - - /* print the admin record */ - fprintf(output_f, "\t\tadmin {\n"); - fprintf(output_f, "\t\t\tuid = %s;\n", pw->pw_name); - fprintf(output_f, "\t\t\tgid = %s;\n", gr->gr_name); - fprintf(output_f, "\t\t}\n"); - - /* find out the user and group name */ - pw = getpwuid(sbt.st_uid); - if (pw == NULL) { - err("ERROR: can't get %d user name\n", sbt.st_uid); - fprintf(output_f, "}\n}\n"); - return -1; - } - - gr = getgrgid(sbt.st_gid); - if (gr == NULL) { - err("ERROR: can't get %d group name\n", sbt.st_gid); - fprintf(output_f, "}\n}\n"); - return -1; - } - - /* print the task record */ - fprintf(output_f, "\t\ttask {\n"); - fprintf(output_f, "\t\t\ttuid = %s;\n", pw->pw_name); - fprintf(output_f, "\t\t\ttgid = %s;\n", gr->gr_name); - fprintf(output_f, "\t\t}\n"); - - fprintf(output_f, "\t}\n"); - } - - return 0; -} - -/* - * Display the control group record: - * header - * permission record - * controllers records - * tail - */ -static int display_cgroup_data(struct cgroup *group, - char controller[CG_CONTROLLER_MAX][FILENAME_MAX], - const char *group_path, int root_path_len, int first, - const char *program_name) -{ - struct cgroup_controller *group_controller = NULL; - char var_path[FILENAME_MAX]; - char *value = NULL; - char *output_name; - struct stat sb; - int bl, wl = 0; /* is on the denylist/allowlist flag */ - int nr_var = 0; - int i = 0, j; - int ret = 0; - char *name; - - /* print the group definition header */ - fprintf(output_f, "group %s {\n", group->name); - - /* for all wanted controllers display controllers tag */ - while (controller[i][0] != '\0') { - /* display the permission tags */ - ret = display_permissions(group_path, group->name, controller[i]); - if (ret) - return ret; - - group_controller = cgroup_get_controller(group, controller[i]); - if (group_controller == NULL) { - info("cannot find controller '%s' in group '%s'\n", controller[i], - group->name); - i++; - ret = -1; - continue; - } - - /* print the controller header */ - if (strncmp(controller[i], "name=", 5) == 0) - fprintf(output_f, "\t\"%s\" {\n", controller[i]); - else - fprintf(output_f, "\t%s {\n", controller[i]); - i++; - nr_var = cgroup_get_value_name_count(group_controller); - - for (j = 0; j < nr_var; j++) { - name = cgroup_get_value_name(group_controller, j); - - /* - * For the non-root groups cgconfigparser set - * permissions of variable files to 777. Thus it - * is necessary to test the permissions of variable - * files in the root group to find out whether the - * variable is writable. - */ - if (root_path_len >= FILENAME_MAX) - root_path_len = FILENAME_MAX - 1; - - strncpy(var_path, group_path, root_path_len); - var_path[root_path_len] = '\0'; - - strncat(var_path, "/", FILENAME_MAX - strlen(var_path) - 1); - var_path[FILENAME_MAX-1] = '\0'; - - strncat(var_path, name, FILENAME_MAX - strlen(var_path) - 1); - var_path[FILENAME_MAX-1] = '\0'; - - /* test whether the write permissions */ - ret = stat(var_path, &sb); - /* - * freezer.state is not in root group so ret != 0, - * but it should be listed device.list should be - * read to create device.allow input - */ - /* 0200 == S_IWUSR */ - if ((ret == 0) && ((sb.st_mode & 0200) == 0) && - (strcmp("devices.list", name) != 0)) { - /* variable is not writable */ - continue; - } - - /* - * find whether the variable is denylisted - * or allowlisted - */ - bl = is_on_list(name, deny_list); - wl = is_on_list(name, allow_list); - - /* if it is denylisted skip it and continue */ - if (bl) - continue; - - /* - * if it is not allowlisted and strict tag is used - * skip it and continue too - */ - if ((!wl) && (flags & FL_STRICT)) - continue; - - /* - * if it is not allowlisted and silent tag is not - * used write an warning - */ - if ((!wl) && !(flags & FL_SILENT) && (first)) { - err("WARNING: variable %s is neither ", name); - err("deny nor allow list\n"); - } - - output_name = name; - - /* - * deal with devices variables: - * - omit devices.deny and device.allow, - * - generate devices.{deny,allow} from - * device.list variable (deny all and then - * all device.list devices - */ - if ((strcmp("devices.deny", name) == 0) || - (strcmp("devices.allow", name) == 0)) - continue; - - if (strcmp("devices.list", name) == 0) { - output_name = "devices.allow"; - fprintf(output_f, "\t\tdevices.deny=\"a *:* rwm\";\n"); - } - - ret = cgroup_get_value_string(group_controller, name, &value); - - /* variable can not be read */ - if (ret != 0) { - ret = 0; - err("ERROR: Value of variable %s can be read\n", name); - goto err; - } - fprintf(output_f, "\t\t%s=\"%s\";\n", output_name, value); - free(value); - } - fprintf(output_f, "\t}\n"); - } - - /* tail of the record */ - fprintf(output_f, "}\n\n"); - -err: - return ret; -} - -/* - * creates the record about the hierarchies which contains - * "controller" subsystem - */ -static int display_controller_data(char controller[CG_CONTROLLER_MAX][FILENAME_MAX], - const char *program_name) -{ - char cgroup_name[FILENAME_MAX]; - struct cgroup_file_info info; - struct cgroup *group = NULL; - int prefix_len; - void *handle; - int first = 1; - int lvl; - int ret; - - /* - * start to parse the structure for the first controller - - * controller[0] attached to hierarchy - */ - ret = cgroup_walk_tree_begin(controller[0], "/", 0, &handle, &info, &lvl); - if (ret != 0) - return ret; - - prefix_len = strlen(info.full_path); - - /* go through all files and directories */ - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) == 0) { - /* some group starts here */ - if (info.type == CGROUP_FILE_TYPE_DIR) { - /* parse the group name from full_path*/ - strncpy(cgroup_name, &info.full_path[prefix_len], FILENAME_MAX); - cgroup_name[FILENAME_MAX-1] = '\0'; - - /* start to grab data about the new group */ - group = cgroup_new_cgroup(cgroup_name); - if (group == NULL) { - info("cannot create group '%s'\n", cgroup_name); - ret = ECGFAIL; - goto err; - } - - ret = cgroup_get_cgroup(group); - if (ret != 0) { - /* - * We know for sure that the cgroup exists - * but just that the cgroup v2 controller - * is not enabled in the cgroup.subtree_control - * file. - */ - if (ret != ECGROUPNOTEXIST) { - info("cannot read group '%s': %s %d\n", cgroup_name, - cgroup_strerror(ret), ret); - goto err; - } - } - - if (ret == 0) - display_cgroup_data(group, controller, info.full_path, prefix_len, - first, program_name); - first = 0; - cgroup_free(&group); - } - } - -err: - cgroup_walk_tree_end(&handle); - if (ret == ECGEOF) - ret = 0; - - return ret; -} - -static int is_ctlr_on_list(char controllers[CG_CONTROLLER_MAX][FILENAME_MAX], - cont_name_t wanted_conts[CG_CONTROLLER_MAX]) -{ - char tmp_controllers[CG_CONTROLLER_MAX][FILENAME_MAX]; - int i = 0, j = 0, k = 0; - int ret = 0; - - while (controllers[i][0] != '\0') { - while (wanted_conts[j][0] != '\0') { - if (strcmp(controllers[i], wanted_conts[j]) == 0) { - strncpy(tmp_controllers[k], wanted_conts[j], FILENAME_MAX - 1); - (tmp_controllers[k])[FILENAME_MAX - 1] = '\0'; - k++; - } - j++; - } - j = 0; - i++; - } - - (tmp_controllers[k])[0] = '\0'; - - /* Lets reset the controllers to intersection of controller ∩ wanted_conts */ - for (i = 0; tmp_controllers[i][0] != '\0'; i++) { - /* - * gcc complains about truncation when using snprintf() and - * and coverity complains about truncation when using strncpy(). - * Avoid both these warnings by directly invoking memcpy() - */ - memcpy(controllers[i], tmp_controllers[i], sizeof(controllers[i])); - ret = 1; - } - (controllers[i])[0] = '\0'; - - return ret; -} - - -/* print data about input cont_name controller */ -static int parse_controllers(cont_name_t cont_names[CG_CONTROLLER_MAX], const char *program_name) -{ - char controllers[CG_CONTROLLER_MAX][FILENAME_MAX] = {"\0"}; - struct cgroup_mount_point controller; - char path[FILENAME_MAX]; - void *handle; - int ret = 0; - int max = 0; - - path[0] = '\0'; - - ret = cgroup_get_controller_begin(&handle, &controller); - - /* go through the list of controllers/mount point pairs */ - while (ret == 0) { - if (strcmp(path, controller.path) == 0) { - /* - * if it is still the same mount point - * - * note that the last entry in controllers[][] must be '\0', so - * we need to stop populating the array at CG_CONTROLLER_MAX - 1 - */ - if (max < CG_CONTROLLER_MAX - 1) { - strncpy(controllers[max], controller.name, FILENAME_MAX); - (controllers[max])[FILENAME_MAX-1] = '\0'; - max++; - } - } else { - /* we got new mount point, print it if needed */ - if ((!(flags & FL_LIST) || (is_ctlr_on_list(controllers, cont_names))) && - (max != 0 && max < CG_CONTROLLER_MAX)) { - (controllers[max])[0] = '\0'; - ret = display_controller_data(controllers, program_name); - if (ret) - goto err; - } - - strncpy(controllers[0], controller.name, FILENAME_MAX); - (controllers[0])[FILENAME_MAX-1] = '\0'; - - strncpy(path, controller.path, FILENAME_MAX); - path[FILENAME_MAX-1] = '\0'; - max = 1; - } - - /* the actual controller should not be printed */ - ret = cgroup_get_controller_next(&handle, &controller); - } - - if ((!(flags & FL_LIST) || (is_ctlr_on_list(controllers, cont_names))) && - (max != 0 && max < CG_CONTROLLER_MAX)) { - (controllers[max])[0] = '\0'; - ret = display_controller_data(controllers, program_name); - } - -err: - cgroup_get_controller_end(&handle); - if (ret != ECGEOF) - return ret; - - return 0; -} - -static int show_mountpoints(const char *controller) -{ - char path[FILENAME_MAX]; - int quote = 0; - void *handle; - int ret; - - if (strncmp(controller, "name=", 5) == 0) - quote = 1; - - ret = cgroup_get_subsys_mount_point_begin(controller, &handle, path); - if (ret) - return ret; - - while (ret == 0) { - if (quote) - fprintf(output_f, "\t\"%s\" = %s;\n", controller, path); - else - fprintf(output_f, "\t%s = %s;\n", controller, path); - ret = cgroup_get_subsys_mount_point_next(&handle, path); - } - cgroup_get_subsys_mount_point_end(&handle); - - if (ret != ECGEOF) - return ret; - - return 0; -} - -/* - * parse whether data about given controller "name" should be displayed. - * If yes then the data are printed. "cont_names" is list of controllers - * which should be shown. - */ -static void parse_mountpoint(cont_name_t cont_names[CG_CONTROLLER_MAX], char *name) -{ - int i; - - /* if there is no controller list show all mounted controllers */ - if (!(flags & FL_LIST)) { - if (show_mountpoints(name)) { - /* the controller is not mounted */ - if ((flags & FL_SILENT) == 0) - err("ERROR: %s hierarchy not mounted\n", name); - } - return; - } - - /* there is controller list - show wanted mounted controllers only */ - for (i = 0; i <= CG_CONTROLLER_MAX-1; i++) { - if (!strncmp(cont_names[i], name, strlen(name)+1)) { - /* controller is on the list */ - if (show_mountpoints(name)) { - /* the controller is not mounted */ - if ((flags & FL_SILENT) == 0) { - err("ERROR: %s hierarchy not mounted\n", name); - } - break; - } - break; - } - } -} - -/* print data about input mount points */ -static int parse_mountpoints(cont_name_t cont_names[CG_CONTROLLER_MAX], const char *program_name) -{ - struct cgroup_mount_point mount; - struct controller_data info; - int ret, final_ret = 0; - void *handle; - - /* start mount section */ - fprintf(output_f, "mount {\n"); - - /* go through the controller list */ - ret = cgroup_get_all_controller_begin(&handle, &info); - while (ret == 0) { - - /* the controller attached to some hierarchy */ - if (info.hierarchy != 0) - parse_mountpoint(cont_names, info.name); - - /* next controller */ - ret = cgroup_get_all_controller_next(&handle, &info); - } - - if (ret != ECGEOF) { - if ((flags & FL_SILENT) != 0) { - err("E: in get next controller %s\n", cgroup_strerror(ret)); - } - final_ret = ret; - } - - cgroup_get_all_controller_end(&handle); - - /* process also named hierarchies */ - ret = cgroup_get_controller_begin(&handle, &mount); - while (ret == 0) { - if (strncmp(mount.name, "name=", 5) == 0) - parse_mountpoint(cont_names, mount.name); - ret = cgroup_get_controller_next(&handle, &mount); - } - - if (ret != ECGEOF) { - if ((flags & FL_SILENT) != 0) { - err("E: in get next controller %s\n", cgroup_strerror(ret)); - } - final_ret = ret; - } - - cgroup_get_controller_end(&handle); - - /* finish mount section */ - fprintf(output_f, "}\n\n"); - - return final_ret; -} - -int main(int argc, char *argv[]) -{ - static struct option long_opts[] = { - {"help", no_argument, NULL, 'h'}, - {"silent", no_argument, NULL, 's'}, - {"denylist", required_argument, NULL, 'b'}, - {"allowlist", required_argument, NULL, 'w'}, - {"strict", no_argument, NULL, 't'}, - {"file", required_argument, NULL, 'f'}, - {0, 0, 0, 0} - }; - - cont_name_t wanted_cont[CG_CONTROLLER_MAX]; - char bl_file[FILENAME_MAX]; /* denylist file name */ - char wl_file[FILENAME_MAX]; /* allowlist file name */ - int ret = 0, err; - int c_number = 0; - int c, i; - - for (i = 0; i < CG_CONTROLLER_MAX; i++) - wanted_cont[i][0] = '\0'; - - flags = 0; - - /* parse arguments */ - while ((c = getopt_long(argc, argv, "hsb:w:tf:", long_opts, NULL)) > 0) { - switch (c) { - case 'h': - usage(0, argv[0]); - return 0; - case 's': - flags |= FL_SILENT; - break; - case 'b': - flags |= FL_DENY; - strncpy(bl_file, optarg, FILENAME_MAX); - bl_file[FILENAME_MAX-1] = '\0'; - break; - case 'w': - flags |= FL_ALLOW; - strncpy(wl_file, optarg, FILENAME_MAX); - wl_file[FILENAME_MAX-1] = '\0'; - break; - case 't': - flags |= FL_STRICT; - break; - case 'f': - flags |= FL_OUTPUT; - output_f = fopen(optarg, "w"); - if (output_f == NULL) { - err("%s: Failed to open file %s\n", argv[0], optarg); - return ECGOTHER; - } - break; - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - } - - /* read the list of controllers */ - while (optind < argc) { - flags |= FL_LIST; - strncpy(wanted_cont[c_number], argv[optind], FILENAME_MAX); - (wanted_cont[c_number])[FILENAME_MAX-1] = '\0'; - c_number++; - optind++; - if (optind == CG_CONTROLLER_MAX-1) { - err("too many parameters\n"); - break; - } - } - - if ((flags & FL_OUTPUT) == 0) - output_f = stdout; - - /* denylist */ - if (flags & FL_DENY) { - ret = load_list(bl_file, &deny_list); - } else { - /* load the denylist from the default location */ - ret = load_list(DENYLIST_CONF, &deny_list); - } - if (ret != 0) { - ret = EXIT_BADARGS; - goto finish; - } - - /* allowlist */ - if (flags & FL_ALLOW) - ret = load_list(wl_file, &allow_list); - if (ret != 0) { - ret = EXIT_BADARGS; - goto finish; - } - - /* print the header */ - fprintf(output_f, "# Configuration file generated by cgsnapshot\n"); - - /* initialize libcgroup */ - ret = cgroup_init(); - if (ret) - /* empty configuration file */ - goto finish; - - /* print mount points section */ - ret = parse_mountpoints(wanted_cont, argv[0]); - ret = ret ? EXIT_BADARGS : 0; - /* continue with processing on error*/ - - /* print hierarchies section */ - /* replace error from parse_mountpoints() only with another error */ - err = parse_controllers(wanted_cont, argv[0]); - if (err) - ret = err; - -finish: - free_list(deny_list); - free_list(allow_list); - - if (output_f != stdout) - fclose(output_f); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/cgxget.c b/lib/libcgroup-3.1.0/src/tools/cgxget.c deleted file mode 100644 index cc84abcd244..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgxget.c +++ /dev/null @@ -1,939 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup extended cgxget. Works with both cgroup v1 and v2 - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ -#include "tools-common.h" -#include "abstraction-common.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - - -#define MODE_SHOW_HEADERS 1 -#define MODE_SHOW_NAMES 2 -#define MODE_SYSTEMD_DELEGATE 4 - -#define LL_MAX 100 - -#ifndef LIBCG_LIB -static const struct option long_options[] = { - {"v1", no_argument, NULL, '1'}, - {"v2", no_argument, NULL, '2'}, - {"ignore-unmappable", no_argument, NULL, 'i'}, - {"variable", required_argument, NULL, 'r'}, - {"help", no_argument, NULL, 'h'}, - {"all", no_argument, NULL, 'a'}, - {"values-only", no_argument, NULL, 'v'}, - {NULL, 0, NULL, 0} -}; - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h' for more information.\n", program_name); - return; - } - - info("Usage: %s [-nv] [-r ] [-g ] [-a] ...\n", program_name); - info(" or: %s [-nv] [-r ] -g : ...\n", program_name); - info("Print parameter(s) of given group(s).\n"); - info(" -1, --v1 Provided parameters are in v1 format\n"); - info(" -2, --v2 Provided parameters are in v2 format\n"); - info(" -i, --ignore-unmappable Do not return an error for "); - info("settings that cannot be converted\n"); - info(" -a, --all Print info about all relevant controllers\n"); - info(" -g Controller which info should be displayed\n"); - info(" -g : Control group which info should be displayed\n"); - info(" -h, --help Display this help\n"); - info(" -n Do not print headers\n"); - info(" -r, --variable Define parameter to display\n"); - info(" -v, --values-only Print only values, not parameter names\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); -#endif -} - -static int get_controller_from_name(const char * const name, char **controller) -{ - char *dot; - - *controller = strdup(name); - if (*controller == NULL) - return ECGOTHER; - - dot = strchr(*controller, '.'); - if (dot == NULL) { - err("cgxget: error parsing parameter name\n '%s'", name); - return ECGINVAL; - } - *dot = '\0'; - - return 0; -} - -static int create_cg(struct cgroup **cg_list[], int * const cg_list_len) -{ - *cg_list = realloc(*cg_list, ((*cg_list_len) + 1) * sizeof(struct cgroup *)); - if ((*cg_list) == NULL) - return ECGCONTROLLERCREATEFAILED; - - memset(&(*cg_list)[*cg_list_len], 0, sizeof(struct cgroup *)); - - (*cg_list)[*cg_list_len] = cgroup_new_cgroup(""); - if ((*cg_list)[*cg_list_len] == NULL) - return ECGCONTROLLERCREATEFAILED; - - (*cg_list_len)++; - - return 0; -} - -static int parse_a_flag(struct cgroup **cg_list[], int * const cg_list_len) -{ - struct cgroup_mount_point controller; - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - void *handle; - int ret = 0; - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-r" was provided, then we know that the cgroup(s) will be - * an optarg at the end with no flag. Let's temporarily populate - * the first cgroup with the requested control values. - */ - cg = (*cg_list)[0]; - - ret = cgroup_get_controller_begin(&handle, &controller); - while (ret == 0) { - cgc = cgroup_get_controller(cg, controller.name); - if (!cgc) { - cgc = cgroup_add_controller(cg, controller.name); - if (!cgc) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - } - - ret = cgroup_get_controller_next(&handle, &controller); - } - if (ret == ECGEOF) - /* - * we successfully reached the end of the controller list; - * this is not an error - */ - ret = 0; - - cgroup_get_controller_end(&handle); - - return ret; - -out: - cgroup_get_controller_end(&handle); - - return ret; -} - -static int parse_r_flag(struct cgroup **cg_list[], int * const cg_list_len, - const char * const cntl_value) -{ - char *cntl_value_controller = NULL; - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - int ret = 0; - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-r" was provided, then we know that the cgroup(s) will be - * an optarg at the end with no flag. Let's temporarily populate - * the first cgroup with the requested control values. - */ - cg = (*cg_list)[0]; - - ret = get_controller_from_name(cntl_value, &cntl_value_controller); - if (ret) - goto out; - - cgc = cgroup_get_controller(cg, cntl_value_controller); - if (!cgc) { - cgc = cgroup_add_controller(cg, cntl_value_controller); - if (!cgc) { - err("cgxget: cannot find controller '%s'\n", cntl_value_controller); - ret = ECGOTHER; - goto out; - } - } - - ret = cgroup_add_value_string(cgc, cntl_value, NULL); - -out: - if (cntl_value_controller) - free(cntl_value_controller); - - return ret; -} - -static int parse_g_flag_no_colon(struct cgroup **cg_list[], int * const cg_list_len, - const char * const ctrl_str) -{ - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - int ret = 0; - - if ((*cg_list_len) > 1) { - ret = ECGMAXVALUESEXCEEDED; - goto out; - } - - if ((*cg_list_len) == 0) { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - } - - /* - * if "-g " was provided, then we know that the - * cgroup(s) will be an optarg at the end with no flag. - * Let's temporarily populate the first cgroup with the requested - * control values. - */ - cg = *cg_list[0]; - - cgc = cgroup_get_controller(cg, ctrl_str); - if (!cgc) { - cgc = cgroup_add_controller(cg, ctrl_str); - if (!cgc) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - } - -out: - return ret; -} - -static int split_cgroup_name(const char * const ctrl_str, char *cg_name) -{ - char *colon; - - colon = strchr(ctrl_str, ':'); - if (colon == NULL) { - /* ctrl_str doesn't contain a ":" */ - cg_name[0] = '\0'; - return ECGINVAL; - } - - strncpy(cg_name, &colon[1], FILENAME_MAX - 1); - - return 0; -} - -static int split_controllers(const char * const in, char **ctrl[], int * const ctrl_len) -{ - char *copy, *tok, *colon, *saveptr = NULL; - int ret = 0; - char **tmp; - - copy = strdup(in); - if (!copy) - goto out; - saveptr = copy; - - colon = strchr(copy, ':'); - if (colon) - colon[0] = '\0'; - - while ((tok = strtok_r(copy, ",", ©))) { - tmp = realloc(*ctrl, sizeof(char *) * ((*ctrl_len) + 1)); - if (!tmp) { - ret = ECGOTHER; - goto out; - } - - *ctrl = tmp; - (*ctrl)[*ctrl_len] = strdup(tok); - if ((*ctrl)[*ctrl_len] == NULL) { - ret = ECGOTHER; - goto out; - } - - (*ctrl_len)++; - } - -out: - if (saveptr) - free(saveptr); - - return ret; -} - -static int parse_g_flag_with_colon(struct cgroup **cg_list[], int * const cg_list_len, - const char * const ctrl_str) -{ - struct cgroup_controller *cgc; - struct cgroup *cg = NULL; - char **controllers = NULL; - int controllers_len = 0; - int i, ret = 0; - - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - - cg = (*cg_list)[(*cg_list_len) - 1]; - - ret = split_cgroup_name(ctrl_str, cg->name); - if (ret) - goto out; - - ret = split_controllers(ctrl_str, &controllers, &controllers_len); - if (ret) - goto out; - - for (i = 0; i < controllers_len; i++) { - cgc = cgroup_get_controller(cg, controllers[i]); - if (!cgc) { - cgc = cgroup_add_controller(cg, controllers[i]); - if (!cgc) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - } - } - -out: - for (i = 0; i < controllers_len; i++) - free(controllers[i]); - - return ret; -} - -static int parse_opt_args(int argc, char *argv[], struct cgroup **cg_list[], - int * const cg_list_len, bool first_cg_is_dummy) -{ - struct cgroup *cg = NULL; - int ret = 0; - - /* - * The first cgroup was temporarily populated and requires the - * user to provide a cgroup name as an opt - */ - if (argv[optind] == NULL && first_cg_is_dummy) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - /* - * The user has provided a cgroup and controller via the - * -g : flag and has also provided a cgroup - * via the optind. This was not supported by the previous - * cgget implementation. Continue that approach. - * - * Example of a command that will hit this code: - * $ cgxget -g cpu:mycgroup mycgroup - */ - if (argv[optind] != NULL && (*cg_list_len) > 0 && strcmp((*cg_list)[0]->name, "") != 0) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - while (argv[optind] != NULL) { - if ((*cg_list_len) > 0) - cg = (*cg_list)[(*cg_list_len) - 1]; - else - cg = NULL; - - if ((*cg_list_len) == 0) { - /* - * The user didn't provide a '-r' or '-g' flag. - * The parse_a_flag() function can be reused here - * because we both have the same use case - gather - * all the data about this particular cgroup. - */ - ret = parse_a_flag(cg_list, cg_list_len); - if (ret) - goto out; - - strncpy((*cg_list)[(*cg_list_len) - 1]->name, argv[optind], - sizeof((*cg_list)[(*cg_list_len) - 1]->name) - 1); - } else if (cg != NULL && strlen(cg->name) == 0) { - /* - * this cgroup was created based upon control/value - * pairs or with a -g option. we'll - * populate it with the parameter provided by the user - */ - strncpy(cg->name, argv[optind], sizeof(cg->name) - 1); - } else { - ret = create_cg(cg_list, cg_list_len); - if (ret) - goto out; - - ret = cgroup_copy_cgroup((*cg_list)[(*cg_list_len) - 1], - (*cg_list)[(*cg_list_len) - 2]); - if (ret) - goto out; - - strncpy((*cg_list)[(*cg_list_len) - 1]->name, argv[optind], - sizeof((*cg_list)[(*cg_list_len) - 1]->name) - 1); - } - - optind++; - } - -out: - return ret; -} - -static int parse_opts(int argc, char *argv[], struct cgroup **cg_list[], int * const cg_list_len, - int * const mode, enum cg_version_t * const version, - bool * const ignore_unmappable) -{ - bool do_not_fill_controller = false; - bool first_cgroup_is_dummy = false; - bool fill_controller = false; - int ret = 0; - int c; - - /* Parse arguments. */ -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "r:hnvg:a12ib", long_options, NULL)) > 0) { - switch (c) { - case 'b': - *mode = (*mode) & (INT_MAX ^ MODE_SYSTEMD_DELEGATE); - break; -#else - while ((c = getopt_long(argc, argv, "r:hnvg:a12i", long_options, NULL)) > 0) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - exit(0); - case 'n': - /* Do not show headers. */ - *mode = (*mode) & (INT_MAX ^ MODE_SHOW_HEADERS); - break; - case 'v': - /* Do not show parameter names. */ - *mode = (*mode) & (INT_MAX ^ MODE_SHOW_NAMES); - break; - case 'r': - do_not_fill_controller = true; - first_cgroup_is_dummy = true; - ret = parse_r_flag(cg_list, cg_list_len, optarg); - if (ret) - goto err; - break; - case 'g': - fill_controller = true; - if (strchr(optarg, ':') == NULL) { - first_cgroup_is_dummy = true; - ret = parse_g_flag_no_colon(cg_list, cg_list_len, optarg); - if (ret) - goto err; - } else { - ret = parse_g_flag_with_colon(cg_list, cg_list_len, optarg); - if (ret) - goto err; - } - break; - case 'a': - fill_controller = true; - ret = parse_a_flag(cg_list, cg_list_len); - if (ret) - goto err; - break; - case '1': - *version = CGROUP_V1; - break; - case '2': - *version = CGROUP_V2; - break; - case 'i': - *ignore_unmappable = true; - break; - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - } - - /* Don't allow '-r' and ('-g' or '-a') */ - if (fill_controller && do_not_fill_controller) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - ret = parse_opt_args(argc, argv, cg_list, cg_list_len, first_cgroup_is_dummy); - if (ret) - goto err; - -err: - return ret; -} -#endif /* !LIBCG_LIB */ - -static int get_cv_value(struct control_value * const cv, const char * const cg_name, - const char * const controller_name) -{ - bool is_multiline = false; - char tmp_line[LL_MAX]; - void *handle, *tmp; - int ret; - - ret = cgroup_read_value_begin(controller_name, cg_name, cv->name, &handle, tmp_line, - LL_MAX); - if (ret == ECGEOF) - goto read_end; - if (ret != 0) { - if (ret == ECGOTHER) { - int tmp_ret; - - /* - * to maintain compatibility with an earlier - * version of cgget, try to determine if the - * failure was due to an invalid controller - */ - tmp_ret = cgroup_test_subsys_mounted(controller_name); - if (tmp_ret == 0) { - err("cgxget: cannot find controller '%s' in group '%s'\n", - controller_name, cg_name); - } else { - err("variable file read failed %s\n", cgroup_strerror(ret)); - } - } - - goto end; - } - - /* remove the newline character */ - tmp_line[strcspn(tmp_line, "\n")] = '\0'; - - strncpy(cv->value, tmp_line, CG_CONTROL_VALUE_MAX - 1); - cv->multiline_value = strdup(cv->value); - if (cv->multiline_value == NULL) - goto read_end; - - while ((ret = cgroup_read_value_next(&handle, tmp_line, LL_MAX)) == 0) { - if (ret == 0) { - is_multiline = true; - cv->value[0] = '\0'; - - /* remove the newline character */ - tmp_line[strcspn(tmp_line, "\n")] = '\0'; - - tmp = realloc(cv->multiline_value, sizeof(char) * - (strlen(cv->multiline_value) + strlen(tmp_line) + 3)); - if (tmp == NULL) - goto read_end; - - cv->multiline_value = tmp; - strcat(cv->multiline_value, "\n\t"); - strcat(cv->multiline_value, tmp_line); - } - } - -read_end: - cgroup_read_value_end(&handle); - if (ret == ECGEOF) - ret = 0; -end: - if (is_multiline == false && cv->multiline_value) { - free(cv->multiline_value); - cv->multiline_value = NULL; - } - - return ret; -} - -static int indent_multiline_value(struct control_value * const cv) -{ - char tmp_val[CG_CONTROL_VALUE_MAX] = {0}; - char *tok, *saveptr = NULL; - - tok = strtok_r(cv->value, "\n", &saveptr); - strncat(tmp_val, tok, CG_CONTROL_VALUE_MAX - 1); - /* don't indent the first value */ - while ((tok = strtok_r(NULL, "\n", &saveptr))) { - strncat(tmp_val, "\n\t", (CG_CONTROL_VALUE_MAX - (strlen(tmp_val) + 1))); - strncat(tmp_val, tok, (CG_CONTROL_VALUE_MAX - (strlen(tmp_val) + 1))); - } - - cv->multiline_value = strdup(tmp_val); - if (!cv->multiline_value) - return ECGOTHER; - - return 0; -} - -static int fill_empty_controller(struct cgroup * const cg, struct cgroup_controller * const cgc) -{ - char cgrp_ctrl_path[FILENAME_MAX] = { '\0' }; - char mnt_path[FILENAME_MAX] = { '\0' }; -#ifdef WITH_SYSTEMD - char tmp[FILENAME_MAX] = { '\0' }; -#endif - struct dirent *ctrl_dir = NULL; - int i, mnt_path_len, ret = 0; - bool found_mount = false; - DIR *dir = NULL; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - - for (i = 0; i < CG_CONTROLLER_MAX && - cg_mount_table[i].name[0] != '\0'; i++) { - - if (strlen(cgc->name) == strlen(cg_mount_table[i].name) && - strncmp(cgc->name, cg_mount_table[i].name, strlen(cgc->name)) == 0) { - found_mount = true; - break; - } - } - - if (found_mount == false) - goto out; - - if (!cg_build_path_locked(NULL, mnt_path, cg_mount_table[i].name)) - goto out; - - mnt_path_len = strlen(mnt_path); -#ifdef WITH_SYSTEMD - /* - * If the user has set a slice/scope as setdefault in the - * cgconfig.conf file, every path constructed will have the - * systemd_default_cgroup slice/scope suffixed to it. - * - * We need to trim the slice/scope from the path, incase of - * user providing / as the cgroup name in the command - * line: - * cgxget -1 -r cpu.shares /a - */ - - if (cg->name[0] == '/' && cg->name[1] != '\0' && - strncmp(mnt_path + (mnt_path_len - 7), ".scope/", 7) == 0) { - snprintf(tmp, FILENAME_MAX, "%s", dirname(mnt_path)); - strncpy(mnt_path, tmp, FILENAME_MAX - 1); - mnt_path[FILENAME_MAX - 1] = '\0'; - - mnt_path_len = strlen(mnt_path); - if (strncmp(mnt_path + (mnt_path_len - 6), ".slice", 6) == 0) { - snprintf(tmp, FILENAME_MAX, "%s", dirname(mnt_path)); - strncpy(mnt_path, tmp, FILENAME_MAX - 1); - mnt_path[FILENAME_MAX - 1] = '\0'; - } else { - cgroup_dbg("Malformed path %s (expected slice name)\n", mnt_path); - ret = ECGOTHER; - goto out; - } - } -#endif - strncat(mnt_path, cg->name, FILENAME_MAX - mnt_path_len - 1); - mnt_path[sizeof(mnt_path) - 1] = '\0'; - - if (access(mnt_path, F_OK)) - goto out; - - if (!cg_build_path_locked(cg->name, cgrp_ctrl_path, cg_mount_table[i].name)) - goto out; - - dir = opendir(cgrp_ctrl_path); - if (!dir) { - ret = ECGOTHER; - goto out; - } - - while ((ctrl_dir = readdir(dir)) != NULL) { - /* Skip over non regular files */ - if (ctrl_dir->d_type != DT_REG) - continue; - - ret = cgroup_fill_cgc(ctrl_dir, cg, cgc, i); - if (ret == ECGFAIL) - goto out; - - if (cgc->index > 0) { - cgc->values[cgc->index - 1]->dirty = false; - - /* - * previous versions of cgget indented the second - * and all subsequent lines. Continue that behavior - */ - if (strchr(cgc->values[cgc->index - 1]->value, '\n')) { - ret = indent_multiline_value(cgc->values[cgc->index - 1]); - if (ret) - goto out; - } - } - } - -out: - if (dir) - closedir(dir); - - pthread_rwlock_unlock(&cg_mount_table_lock); - - return ret; -} - -static int get_controller_values(struct cgroup * const cg, struct cgroup_controller * const cgc) -{ - int ret = 0; - int i; - - for (i = 0; i < cgc->index; i++) { - ret = get_cv_value(cgc->values[i], cg->name, cgc->name); - if (ret) - goto out; - } - - if (cgc->index == 0) { - /* fill the entire controller since no values were provided */ - ret = fill_empty_controller(cg, cgc); - if (ret) - goto out; - } - -out: - return ret; -} - -static int get_cgroup_values(struct cgroup * const cg) -{ - int ret = 0; - int i; - - for (i = 0; i < cg->index; i++) { - ret = get_controller_values(cg, cg->controller[i]); - if (ret) - break; - } - - return ret; -} - -#ifndef LIBCG_LIB -static int get_values(struct cgroup *cg_list[], int cg_list_len) -{ - int ret = 0; - int i; - - for (i = 0; i < cg_list_len; i++) { - ret = get_cgroup_values(cg_list[i]); - if (ret) - break; - } - - return ret; -} - -static void print_control_values(const struct control_value * const cv, int mode) -{ - if (mode & MODE_SHOW_NAMES) - info("%s: ", cv->name); - - if (cv->multiline_value) - info("%s\n", cv->multiline_value); - else - info("%s\n", cv->value); -} - -static void print_controller(const struct cgroup_controller * const cgc, int mode) -{ - int i; - - for (i = 0; i < cgc->index; i++) - print_control_values(cgc->values[i], mode); -} - -static void print_cgroup(const struct cgroup * const cg, int mode) -{ - int i; - - if (mode & MODE_SHOW_HEADERS) - info("%s:\n", cg->name); - - for (i = 0; i < cg->index; i++) - print_controller(cg->controller[i], mode); - - if (mode & MODE_SHOW_HEADERS) - info("\n"); -} - -static void print_cgroups(struct cgroup *cg_list[], int cg_list_len, int mode) -{ - int i; - - for (i = 0; i < cg_list_len; i++) - print_cgroup(cg_list[i], mode); -} - -static int convert_cgroups(struct cgroup **cg_list[], int cg_list_len, - enum cg_version_t in_version, enum cg_version_t out_version) -{ - struct cgroup **cg_converted_list; - int i = 0, j, ret = 0; - - cg_converted_list = malloc(cg_list_len * sizeof(struct cgroup *)); - if (cg_converted_list == NULL) - goto out; - - for (i = 0; i < cg_list_len; i++) { - cg_converted_list[i] = cgroup_new_cgroup((*cg_list)[i]->name); - if (cg_converted_list[i] == NULL) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - - ret = cgroup_convert_cgroup(cg_converted_list[i], out_version, (*cg_list)[i], - in_version); - if (ret) - goto out; - } - -out: - if (ret != 0 && ret != ECGNOVERSIONCONVERT) { - /* The conversion failed */ - for (j = 0; j < i; j++) - cgroup_free(&(cg_converted_list[j])); - free(cg_converted_list); - } else { - /* - * The conversion succeeded or was unmappable. - * Free the old list. - */ - for (i = 0; i < cg_list_len; i++) - cgroup_free(&(*cg_list)[i]); - - *cg_list = cg_converted_list; - } - - return ret; -} - -int main(int argc, char *argv[]) -{ - int mode = MODE_SHOW_NAMES | MODE_SHOW_HEADERS | MODE_SYSTEMD_DELEGATE; - enum cg_version_t version = CGROUP_UNK; - struct cgroup **cg_list = NULL; - bool ignore_unmappable = false; - int cg_list_len = 0; - int ret = 0, i; - - /* No parameter on input? */ - if (argc < 2) { - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - ret = parse_opts(argc, argv, &cg_list, &cg_list_len, &mode, &version, &ignore_unmappable); - if (ret) - goto err; - - /* this is false always for disable-systemd */ - if (mode & MODE_SYSTEMD_DELEGATE) - cgroup_set_default_systemd_cgroup(); - - ret = convert_cgroups(&cg_list, cg_list_len, version, CGROUP_DISK); - if ((ret && ret != ECGNOVERSIONCONVERT) || - (ret == ECGNOVERSIONCONVERT && !ignore_unmappable)) - /* - * If the user not has specified that we ignore any errors - * due to being unable to map from v1 to v2 or vice versa, - * return error, else ignore the error and continue. - */ - goto err; - - ret = get_values(cg_list, cg_list_len); - if (ret) - goto err; - - ret = convert_cgroups(&cg_list, cg_list_len, CGROUP_DISK, version); - if (ret) - goto err; - - print_cgroups(cg_list, cg_list_len, mode); - -err: - for (i = 0; i < cg_list_len; i++) - cgroup_free(&(cg_list[i])); - - return ret; -} -#endif /* !LIBCG_LIB */ - -#ifdef LIBCG_LIB -int cgroup_cgxget(struct cgroup **cg, enum cg_version_t version, bool ignore_unmappable) -{ - struct cgroup *disk_cg, *out_cg; - int ret; - - if (!cg || !(*cg)) { - ret = ECGINVAL; - goto out; - } - - disk_cg = cgroup_new_cgroup((*cg)->name); - if (!disk_cg) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - - ret = cgroup_convert_cgroup(disk_cg, CGROUP_DISK, *cg, version); - if (ret == ECGNOVERSIONCONVERT && ignore_unmappable) - ret = 0; - else if (ret) - goto out; - - ret = get_cgroup_values(disk_cg); - if (ret) - goto out; - - out_cg = cgroup_new_cgroup((*cg)->name); - if (!out_cg) { - ret = ECGCONTROLLERCREATEFAILED; - goto out; - } - - ret = cgroup_convert_cgroup(out_cg, version, disk_cg, CGROUP_DISK); - if (ret) { - cgroup_free(&out_cg); - goto out; - } - - cgroup_free(cg); - *cg = out_cg; - -out: - if (disk_cg) - cgroup_free(&disk_cg); - - return ret; -} -#endif /* LIBCG_LIB */ diff --git a/lib/libcgroup-3.1.0/src/tools/cgxset.c b/lib/libcgroup-3.1.0/src/tools/cgxset.c deleted file mode 100644 index e5eba5284c4..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/cgxset.c +++ /dev/null @@ -1,380 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Libcgroup extended cgxset. Works with both cgroup v1 and v2 - * - * Copyright (c) 2021-2022 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ -#include "tools-common.h" -#include "abstraction-common.h" - -#include -#include - -#include -#include -#include -#include -#include - -#define FL_RULES 1 -#define FL_COPY 2 - -enum { - COPY_FROM_OPTION = CHAR_MAX + 1 -}; - -#ifndef UNIT_TEST -static const struct option long_options[] = { - {"v1", no_argument, NULL, '1'}, - {"v2", no_argument, NULL, '2'}, - {"ignore-unmappable", no_argument, NULL, 'i'}, - {"rule", required_argument, NULL, 'r'}, - {"help", no_argument, NULL, 'h'}, - {"copy-from", required_argument, NULL, COPY_FROM_OPTION}, - {NULL, 0, NULL, 0} -}; - -int flags; /* used input method */ - -static struct cgroup *copy_name_value_from_cgroup(char src_cg_path[FILENAME_MAX]) -{ - struct cgroup *src_cgroup; - int ret = 0; - - /* create source cgroup */ - src_cgroup = cgroup_new_cgroup(src_cg_path); - if (!src_cgroup) { - err("can't create cgroup: %s\n", cgroup_strerror(ECGFAIL)); - goto scgroup_err; - } - - /* copy the name-version values to the cgroup structure */ - ret = cgroup_get_cgroup(src_cgroup); - if (ret != 0) { - err("cgroup %s error: %s\n", src_cg_path, cgroup_strerror(ret)); - goto scgroup_err; - } - - return src_cgroup; - -scgroup_err: - cgroup_free(&src_cgroup); - - return NULL; -} - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, "); - err("try %s --help' for more information.\n", program_name); - return; - } - - info("Usage: %s [-r ] ...\n", program_name); - info(" or: %s --copy-from ...\n", program_name); - info("Set the parameters of given cgroup(s)\n"); - info(" -1, --v1 Provided parameters are in v1 format\n"); - info(" -2, --v2 Provided parameters are in v2 format\n"); - info(" -i, --ignore-unmappable Do not return an error for "); - info("settings that cannot be converted\n"); - info(" -r, --variable Define parameter to set\n"); - info(" --copy-from Control group whose "); - info("parameters will be copied\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd "); - info("delegate hierarchy\n"); -#endif -} -#endif /* !UNIT_TEST */ - -STATIC int parse_r_flag(const char * const program_name, const char * const name_value_str, - struct control_value * const name_value) -{ - char *copy = NULL, *buf = NULL; - int ret = 0; - - buf = strchr(name_value_str, '='); - if (buf == NULL) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - copy = strdup(name_value_str); - if (copy == NULL) { - err("%s: not enough memory\n", program_name); - ret = -1; - goto err; - } - - /* parse optarg value */ - buf = strtok(copy, "="); - if (buf == NULL) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - strncpy(name_value->name, buf, FILENAME_MAX); - name_value->name[FILENAME_MAX-1] = '\0'; - - buf = strchr(name_value_str, '='); - /* - * we don't need to check the return value of strchr because we - * know there's already an '=' character in the string. - */ - buf++; - - if (strlen(buf) == 0) { - err("%s: wrong parameter of option -r: %s\n", program_name, optarg); - ret = EXIT_BADARGS; - goto err; - } - - strncpy(name_value->value, buf, CG_CONTROL_VALUE_MAX); - name_value->value[CG_CONTROL_VALUE_MAX-1] = '\0'; - -err: - if (copy) - free(copy); - - return ret; -} - -#ifndef UNIT_TEST -int main(int argc, char *argv[]) -{ - int ignore_default_systemd_delegate_slice = 0; - struct control_value *name_value = NULL; - int nv_number = 0; - int nv_max = 0; - - struct cgroup *converted_src_cgroup = NULL; - char src_cg_path[FILENAME_MAX] = "\0"; - struct cgroup *src_cgroup = NULL; - struct cgroup *cgroup = NULL; - - enum cg_version_t src_version = CGROUP_UNK; - bool ignore_unmappable = false; - int ret = 0; - int c; - - /* no parametr on input */ - if (argc < 2) { - err("Usage is %s -r \n", argv[0]); - return -1; - } - -#ifdef WITH_SYSTEMD - /* parse arguments */ - while ((c = getopt_long (argc, argv, "r:h12ib", long_options, NULL)) != -1) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; -#else - while ((c = getopt_long (argc, argv, "r:h12i", long_options, NULL)) != -1) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - ret = 0; - goto err; - case 'r': - if ((flags & FL_COPY) != 0) { - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - flags |= FL_RULES; - - /* add name-value pair to buffer (= name_value variable) */ - if (nv_number >= nv_max) { - nv_max += CG_NV_MAX; - name_value = (struct control_value *) - realloc(name_value, nv_max * sizeof(struct control_value)); - if (!name_value) { - err("%s: not enough memory\n", argv[0]); - ret = -1; - goto err; - } - } - - ret = parse_r_flag(argv[0], optarg, &name_value[nv_number]); - if (ret) - goto err; - - nv_number++; - break; - case COPY_FROM_OPTION: - if (flags != 0) { - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - flags |= FL_COPY; - strncpy(src_cg_path, optarg, FILENAME_MAX); - src_cg_path[FILENAME_MAX-1] = '\0'; - break; - case '1': - src_version = CGROUP_V1; - break; - case '2': - src_version = CGROUP_V2; - break; - case 'i': - ignore_unmappable = true; - break; - default: - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - } - - /* no cgroup name */ - if (!argv[optind]) { - err("%s: no cgroup specified\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - if (flags == 0) { - err("%s: no name-value pair was set\n", argv[0]); - ret = EXIT_BADARGS; - goto err; - } - - /* initialize libcgroup */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], - cgroup_strerror(ret)); - goto err; - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* copy the name-value pairs from -r options */ - if ((flags & FL_RULES) != 0) { - src_cgroup = create_cgroup_from_name_value_pairs("tmp", name_value, nv_number); - if (src_cgroup == NULL) - goto err; - } - - /* copy the name-value from the given group */ - if ((flags & FL_COPY) != 0) { - src_cgroup = copy_name_value_from_cgroup(src_cg_path); - if (src_cgroup == NULL) - goto err; - } - - while (optind < argc) { - /* create new cgroup */ - cgroup = cgroup_new_cgroup(argv[optind]); - if (!cgroup) { - ret = ECGFAIL; - err("%s: can't add new cgroup: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* copy the values from the source cgroup to new one */ - ret = cgroup_copy_cgroup(cgroup, src_cgroup); - if (ret != 0) { - err("%s: cgroup %s error: %s\n", argv[0], src_cg_path, - cgroup_strerror(ret)); - goto err; - } - - converted_src_cgroup = cgroup_new_cgroup(cgroup->name); - if (converted_src_cgroup == NULL) { - ret = ECGCONTROLLERCREATEFAILED; - goto err; - } - - /* - * If a failure occurs between this comment and the "End of above comment" - * below, then we need to manually free converted_src_cgroup. - */ - - ret = cgroup_convert_cgroup(converted_src_cgroup, CGROUP_DISK, src_cgroup, - src_version); - if ((ret && ret != ECGNOVERSIONCONVERT) || - (ret == ECGNOVERSIONCONVERT && !ignore_unmappable)) { - /* - * If the user not has specified that we ignore any errors - * due to being unable to map from v1 to v2 or vice versa, - * return error, else ignore the error and continue. - */ - free(converted_src_cgroup); - goto err; - } - - /* - * End of above comment about converted_src_cgroup needing to be manually freed. - */ - - cgroup_free(&cgroup); - cgroup = converted_src_cgroup; - - /* modify cgroup based on values of the new one */ - ret = cgroup_modify_cgroup(cgroup); - if (ret) { - err("%s: cgroup modify error: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - optind++; - cgroup_free(&cgroup); - } - -err: - if (cgroup) - cgroup_free(&cgroup); - if (src_cgroup) - cgroup_free(&src_cgroup); - free(name_value); - - return ret; -} -#endif /* !UNIT_TEST */ - -#ifdef LIBCG_LIB -int cgroup_cgxset(const struct cgroup * const cgroup, enum cg_version_t version, - bool ignore_unmappable) -{ - struct cgroup *converted_cgroup; - int ret; - - converted_cgroup = cgroup_new_cgroup(cgroup->name); - if (converted_cgroup == NULL) { - ret = ECGCONTROLLERCREATEFAILED; - goto err; - } - - ret = cgroup_convert_cgroup(converted_cgroup, CGROUP_DISK, cgroup, version); - if (ret == ECGNOVERSIONCONVERT && ignore_unmappable) - /* - * The user has specified that we should ignore any errors - * due to being unable to map from v1 to v2 or vice versa - */ - ret = 0; - else if (ret) - goto err; - - /* modify cgroup based on values of the new one */ - ret = cgroup_modify_cgroup(converted_cgroup); - if (ret) - goto err; - -err: - if (converted_cgroup) - cgroup_free(&converted_cgroup); - - return ret; -} -#endif /* LIBCG_LIB */ diff --git a/lib/libcgroup-3.1.0/src/tools/lscgroup.c b/lib/libcgroup-3.1.0/src/tools/lscgroup.c deleted file mode 100644 index 280f1d6818d..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/lscgroup.c +++ /dev/null @@ -1,326 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. - * Written by Ivana Hutarova Varekova - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include - -enum flag { - /* - * the flag set if there is a cgroup on - * output if there is no one we want to - * display all cgroups - */ - FL_LIST = 1 -}; - -static inline void trim_filepath(char *path) -{ - int len; - - len = strlen(path) - 1; - while (path[len] == '/') - len--; - - path[len + 1] = '\0'; -} - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h' for more information.\n", program_name); - return; - } - - info("Usage: %s [-h] [[-g] :] [...]\n", program_name); - info("List all cgroups\n"); - info(" -g : Control group to be "); - info("displayed (-g is optional)\n"); - info(" -h, --help Display this help\n"); -#ifdef WITH_SYSTEMD - info(" -b Ignore default systemd delegate hierarchy\n"); -#endif - info("(Note: currently supported on cgroups v1 only)\n"); -} - -/* - * if the info about controller "name" should be printed, then the function - * returns nonzero value - */ -static int is_ctlr_on_list(struct cgroup_group_spec *cgroup_list, const char *name) -{ - int j; - - for (j = 0; cgroup_list->controllers[j] != NULL; j++) - if (strcmp(cgroup_list->controllers[j], name) == 0) - return 1; - - return 0; -} - -static void print_info(struct cgroup_file_info *info, char *name, int pref) -{ - if (info->type == CGROUP_FILE_TYPE_DIR) { - if (info->full_path[pref] == '/') - info("%s:%s\n", name, &info->full_path[pref]); - else - info("%s:/%s\n", name, &info->full_path[pref]); - } -} - -/* display controller:/input_path cgroups */ -static int display_controller_data(char *input_path, char *controller, char *name) -{ - char cgroup_dir_path[FILENAME_MAX]; - char input_dir_path[FILENAME_MAX]; - struct cgroup_file_info info; - int lvl, len, ret; - void *handle; - - ret = cgroup_walk_tree_begin(controller, input_path, 0, &handle, &info, &lvl); - if (ret != 0) - return ret; - - strncpy(cgroup_dir_path, info.full_path, FILENAME_MAX); - cgroup_dir_path[sizeof(cgroup_dir_path) - 1] = '\0'; - /* remove problematic '/' characters from cgroup directory path */ - trim_filepath(cgroup_dir_path); - - strncpy(input_dir_path, input_path, FILENAME_MAX); - input_dir_path[sizeof(input_dir_path) - 1] = '\0'; - - /* remove problematic '/' characters from input directory path */ - trim_filepath(input_dir_path); - len = strlen(cgroup_dir_path) - strlen(input_dir_path); - print_info(&info, name, len); - - while ((ret = cgroup_walk_tree_next(0, &handle, &info, lvl)) == 0) - print_info(&info, name, len); - - cgroup_walk_tree_end(&handle); - if (ret == ECGEOF) - ret = 0; - - return ret; -} - -/* - * print data about input cgroup_list cgroups if FL_LIST flag is set then - * if the function does not find the cgroup it returns ECGEOF - */ -static int print_cgroup(struct cgroup_group_spec *cgroup_spec, int flags) -{ - struct cgroup_mount_point controller; - char all_conts[FILENAME_MAX]; - char con_name[FILENAME_MAX]; - char path[FILENAME_MAX]; - int output = 0; - void *handle; - int ret = 0; - - path[0] = '\0'; - con_name[0] = '\0'; - all_conts[0] = '\0'; - - ret = cgroup_get_controller_begin(&handle, &controller); - - /* go through the list of controllers/mount point pairs */ - while (ret == 0) { - if (strcmp(path, controller.path) == 0) { - /* if it is still the same mount point */ - strncat(all_conts, ",", FILENAME_MAX-strlen(all_conts)-1); - strncat(all_conts, controller.name, FILENAME_MAX-strlen(all_conts)-1); - all_conts[sizeof(all_conts) - 1] = '\0'; - } else { - /* we got new mount point, print it if needed */ - if (output) { - ret = display_controller_data(cgroup_spec->path, con_name, - all_conts); - if (ret) - return ret; - if ((flags & FL_LIST) != 0) { - /* we succesfully finish printing */ - output = 0; - break; - } - } - - output = 0; - strncpy(all_conts, controller.name, FILENAME_MAX); - all_conts[FILENAME_MAX-1] = '\0'; - - strncpy(con_name, controller.name, FILENAME_MAX); - con_name[FILENAME_MAX-1] = '\0'; - - strncpy(path, controller.path, FILENAME_MAX); - path[FILENAME_MAX-1] = '\0'; - } - - /* set output flag */ - if ((output == 0) && (!(flags & FL_LIST) || - (is_ctlr_on_list(cgroup_spec, controller.name)))) - output = 1; - - /* the actual controller should not be printed */ - ret = cgroup_get_controller_next(&handle, &controller); - } - - cgroup_get_controller_end(&handle); - if (ret != ECGEOF) - return ret; - - if (output) - ret = display_controller_data(cgroup_spec->path, con_name, all_conts); - - return ret; -} - - -static int cgroup_list_cgroups(char *tname, struct cgroup_group_spec *cgroup_list[], int flags) -{ - int final_ret = 0; - int ret = 0; - int i = 0; - - /* initialize libcgroup */ - ret = cgroup_init(); - if (ret) { - err("cgroups can't be listed: %s\n", cgroup_strerror(ret)); - return ret; - } - - if ((flags & FL_LIST) == 0) { - struct cgroup_group_spec *cgroup_spec; - - cgroup_spec = calloc(1, sizeof(struct cgroup_group_spec)); - /* we have to print all cgroups */ - ret = print_cgroup(cgroup_spec, flags); - free(cgroup_spec); - if (ret == 0) { - final_ret = 0; - } else { - final_ret = ret; - err("cgroups can't be listed: %s\n", cgroup_strerror(ret)); - } - } else { - /* we have he list of controllers which should be print */ - while ((cgroup_list[i] != NULL) && ((ret == ECGEOF) || (ret == 0))) { - - ret = print_cgroup(cgroup_list[i], flags); - if (ret != 0) { - if (ret == ECGEOF) { - /* controller was not found */ - final_ret = ECGFAIL; - } else { - /* other problem */ - final_ret = ret; - } - - err("%s: cannot find group %s..:%s: %s\n", tname, - cgroup_list[i]->controllers[0], cgroup_list[i]->path, - cgroup_strerror(final_ret)); - } - i++; - } - } - - return final_ret; -} - -int main(int argc, char *argv[]) -{ - static struct option options[] = { - {"help", 0, 0, 'h'}, - {"group", required_argument, NULL, 'g'}, - {0, 0, 0, 0} - }; - - struct cgroup_group_spec *cgroup_list[CG_HIER_MAX]; - int ignore_default_systemd_delegate_slice = 0; - int flags = 0; - int ret = 0; - int c; - int i; - - memset(cgroup_list, 0, sizeof(cgroup_list)); - - /* parse arguments */ -#ifdef WITH_SYSTEMD - while ((c = getopt_long(argc, argv, "hg:b", options, NULL)) > 0) { - switch (c) { - case 'b': - ignore_default_systemd_delegate_slice = 1; - break; -#else - while ((c = getopt_long(argc, argv, "hg:", options, NULL)) > 0) { - switch (c) { -#endif - case 'h': - usage(0, argv[0]); - ret = 0; - goto err; - case 'g': - ret = parse_cgroup_spec(cgroup_list, optarg, CG_HIER_MAX); - if (ret) { - err("%s: cgroup controller and path parsing failed (%s)\n", - argv[0], optarg); - return ret; - } - break; - default: - usage(1, argv[0]); - ret = EXIT_BADARGS; - goto err; - } - } - - /* initialize libcg */ - ret = cgroup_init(); - if (ret) { - err("%s: libcgroup initialization failed: %s\n", argv[0], cgroup_strerror(ret)); - goto err; - } - - /* this is false always for disable-systemd */ - if (!ignore_default_systemd_delegate_slice) - cgroup_set_default_systemd_cgroup(); - - /* read the list of controllers */ - while (optind < argc) { - ret = parse_cgroup_spec(cgroup_list, argv[optind], CG_HIER_MAX); - if (ret) { - err("%s: cgroup controller an path parsing failed (%s)\n", argv[0], - argv[optind]); - return -1; - } - optind++; - } - - if (cgroup_list[0] != NULL) { - /* cgroups on input */ - flags |= FL_LIST; - } - - /* print the information based on list of input cgroups and flags */ - ret = cgroup_list_cgroups(argv[0], cgroup_list, flags); - -err: - if (cgroup_list[0]) { - for (i = 0; i < CG_HIER_MAX; i++) { - if (cgroup_list[i]) - cgroup_free_group_spec(cgroup_list[i]); - } - } - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/lssubsys.c b/lib/libcgroup-3.1.0/src/tools/lssubsys.c deleted file mode 100644 index c143d175ef6..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/lssubsys.c +++ /dev/null @@ -1,282 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright (C) 2009 Red Hat, Inc. All Rights Reserved. - * Written by Ivana Hutarova Varekova - */ - -#include "tools-common.h" - -#include -#include - -#include -#include -#include -#include -#include - - -enum flag { - FL_MOUNT = 1, /* show the mount points */ - FL_LIST = 2, - FL_ALL = 4, /* show all subsystems - not mounted too */ - FL_HIERARCHY = 8, /* show info about hierarchies */ - FL_MOUNT_ALL = 16 /* show all mount points of hierarchies */ -}; - -typedef char cont_name_t[FILENAME_MAX]; - -static void usage(int status, const char *program_name) -{ - if (status != 0) { - err("Wrong input parameters, try %s -h' for more information.\n", program_name); - return; - } - - info("Usage: %s [-i] [-m] [-M] [controller] [...]\n", program_name); - info(" or: %s [-a] [-i] [-m] [-M]\n", program_name); - info("List information about given controller(s) If no controller "); - info("is set list information about all mounted controllers.\n"); - info(" -a, --all Display information "); - info("about all controllers (including not mounted ones)\n"); - info(" -h, --help Display this help\n"); - info(" -i, --hierarchies Display information about hierarchies\n"); - info(" -m, --mount-points Display mount points\n"); - info(" -M, --all-mount-points Display all mount points\n"); - info("(Note: currently supported on cgroups v1 only)\n"); -} - -static int print_controller_mount(const char *controller, int flags, cont_name_t cont_names, - int hierarchy) -{ - char path[FILENAME_MAX]; - void *handle; - int ret = 0; - - /* print only hierarchy name */ - if (!(flags & FL_MOUNT) && !(flags & FL_HIERARCHY)) - info("%s\n", cont_names); - - /* print only hierarchy name and number*/ - if (!(flags & FL_MOUNT) && (flags & FL_HIERARCHY)) - info("%s %d\n", cont_names, hierarchy); - - if (flags & FL_MOUNT) { - /* print hierarchy name and mount point(s) */ - ret = cgroup_get_subsys_mount_point_begin(controller, &handle, path); - /* intentionally ignore error from above call */ - while (ret == 0) { - info("%s %s\n", cont_names, path); - /* first mount record is enough */ - if (!(flags & FL_MOUNT_ALL)) - goto stop; - ret = cgroup_get_subsys_mount_point_next(&handle, path); - } - if (ret == ECGEOF) - ret = 0; -stop: - cgroup_get_subsys_mount_point_end(&handle); - } - return ret; -} - -/* display all controllers attached to the given hierarchy */ -static int print_all_controllers_in_hierarchy(const char *tname, int hierarchy, int flags) -{ - struct controller_data info; - enum cg_version_t version; - cont_name_t cont_names = "\0"; - cont_name_t cont_name; - int first = 1; - void *handle; - int ret = 0; - - /* - * Initialize libcgroup and intentionally ignore its result, no - * mounted controller is valid use case. - */ - (void) cgroup_init(); - - ret = cgroup_get_all_controller_begin(&handle, &info); - if ((ret != 0) && (ret != ECGEOF)) { - err("cannot read controller data: %s\n", cgroup_strerror(ret)); - return ret; - } - - while (ret != ECGEOF) { - ret = cgroup_get_controller_version(info.name, &version); - if (ret) - goto end; - - /* - * v1 controllers should be in the hierachy. - * v2 controllers will have a hierarchy value of zero - */ - if (version == CGROUP_V1 && info.hierarchy != hierarchy) - goto next; - - if (first) { - /* the first controller in the hierarchy */ - strncpy(cont_name, info.name, FILENAME_MAX-1); - cont_name[sizeof(cont_name) - 1] = '\0'; - - strncpy(cont_names, info.name, FILENAME_MAX-1); - cont_names[sizeof(cont_names) - 1] = '\0'; - first = 0; - } else { - /* the next controller in the hierarchy */ - strncat(cont_names, ",", FILENAME_MAX-1); - strncat(cont_names, info.name, FILENAME_MAX-1); - cont_names[sizeof(cont_names) - 1] = '\0'; - } - -next: - ret = cgroup_get_all_controller_next(&handle, &info); - if (ret && ret != ECGEOF) - goto end; - } - - ret = print_controller_mount(cont_name, flags, cont_names, hierarchy); -end: - cgroup_get_all_controller_end(&handle); - - if (ret == ECGEOF) - ret = 0; - - return ret; -} - - -/* - * go through the list of all controllers gather them based on hierarchy - * number and print them - */ -static int cgroup_list_all_controllers(const char *tname, cont_name_t cont_name[CG_CONTROLLER_MAX], - int c_number, int flags) -{ - struct controller_data info; - int h_list[CG_CONTROLLER_MAX]; /* list of hierarchies */ - int is_on_list = 0; - int counter = 0; - void *handle; - int ret; - int j; - - ret = cgroup_get_all_controller_begin(&handle, &info); - while (ret == 0) { - if (info.hierarchy == 0) { - /* the controller is not attached to any hierachy */ - if (flags & FL_ALL) { - /* display only if -a flag is set */ - info("%s\n", info.name); - } - } - is_on_list = 0; - j = 0; - while ((is_on_list == 0) && (j < c_number)) { - if (strcmp(info.name, cont_name[j]) == 0) { - is_on_list = 1; - break; - } - j++; - } - - if ((info.hierarchy != 0) && ((flags & FL_ALL) || - (!(flags & FL_LIST) || (is_on_list == 1)))) { - /* - * the controller is attached to some hierarchy - * and either should be output all controllers, - * or the controller is on the output list - */ - h_list[counter] = info.hierarchy; - counter++; - for (j = 0; j < counter-1; j++) { - /* - * the hierarchy already was on the list - * so remove the new record - */ - if (h_list[j] == info.hierarchy) { - counter--; - break; - } - } - } - - ret = cgroup_get_all_controller_next(&handle, &info); - } - cgroup_get_all_controller_end(&handle); - if (ret == ECGEOF) - ret = 0; - if (ret) { - err("cgroup_get_controller_begin/next failed (%s)\n", cgroup_strerror(ret)); - return ret; - } - - for (j = 0; j < counter; j++) - ret = print_all_controllers_in_hierarchy(tname, h_list[j], flags); - - return ret; -} - -int main(int argc, char *argv[]) -{ - static struct option options[] = { - {"help", 0, 0, 'h'}, - {"mount-points", 0, 0, 'm'}, - {"all-mount-points", 0, 0, 'M'}, - {"all", 0, 0, 'a'}, - {"hierarchies", 0, 0, 'i'}, - {0, 0, 0, 0} - }; - - cont_name_t cont_name[CG_CONTROLLER_MAX]; - int c_number = 0; - int flags = 0; - int ret = 0; - int c; - int i; - - for (i = 0; i < CG_CONTROLLER_MAX; i++) - cont_name[i][0] = '\0'; - - /* parse arguments */ - while ((c = getopt_long(argc, argv, "mMhai", options, NULL)) > 0) { - switch (c) { - case 'h': - usage(0, argv[0]); - return 0; - case 'm': - flags |= FL_MOUNT; - break; - case 'M': - flags |= FL_MOUNT | FL_MOUNT_ALL; - break; - case 'a': - flags |= FL_ALL; - break; - case 'i': - flags |= FL_HIERARCHY; - break; - default: - usage(1, argv[0]); - exit(EXIT_BADARGS); - } - } - - /* read the list of controllers */ - while (optind < argc) { - flags |= FL_LIST; - strncpy(cont_name[c_number], argv[optind], FILENAME_MAX); - cont_name[c_number][FILENAME_MAX-1] = '\0'; - c_number++; - optind++; - if (optind == CG_CONTROLLER_MAX) { - err("Warning: too many parameters\n"); - break; - } - } - - ret = cgroup_list_all_controllers(argv[0], cont_name, c_number, flags); - - return ret; -} diff --git a/lib/libcgroup-3.1.0/src/tools/tools-common.c b/lib/libcgroup-3.1.0/src/tools/tools-common.c deleted file mode 100644 index e79023b2b1f..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/tools-common.c +++ /dev/null @@ -1,312 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright Red Hat, Inc. 2009 - * - * Author: Vivek Goyal - * Jan Safranek - */ - -/* for asprintf */ -#define _GNU_SOURCE - -#include "tools-common.h" - -#include - -#include -#include -#include -#include -#include -#include -#include - -#include - -int parse_cgroup_spec(struct cgroup_group_spec **cdptr, char *optarg, int capacity) -{ - char *cptr = NULL, *pathptr = NULL, *temp; - struct cgroup_group_spec *ptr; - int i, j; - - ptr = *cdptr; - - /* Find first free entry inside the cgroup data array */ - for (i = 0; i < capacity; i++, ptr++) { - if (!cdptr[i]) - break; - } - - if (i == capacity) { - /* No free slot found */ - fprintf(stderr, "Max allowed hierarchies %d reached\n", capacity); - return -1; - } - - /* Extract list of controllers */ - if (optarg[0] == ':') { - /* No controller was passed in */ - cptr = NULL; - pathptr = strtok(optarg, ":"); - } else { - /* Extract the list of controllers from the user */ - cptr = strtok(optarg, ":"); - cgroup_dbg("list of controllers is %s\n", cptr); - if (!cptr) - return -1; - - pathptr = strtok(NULL, ":"); - } - - cgroup_dbg("cgroup path is %s\n", pathptr); - if (!pathptr) - return -1; - - /* instanciate cgroup_data. */ - cdptr[i] = calloc(1, sizeof(struct cgroup_group_spec)); - if (!cdptr[i]) { - fprintf(stderr, "%s\n", strerror(errno)); - return -1; - } - - if (cptr != NULL) { - /* Convert list of controllers into an array of strings. */ - j = 0; - do { - if (j == 0) - temp = strtok(cptr, ","); - else - temp = strtok(NULL, ","); - - if (temp) { - cdptr[i]->controllers[j] = strdup(temp); - if (!cdptr[i]->controllers[j]) { - free(cdptr[i]); - fprintf(stderr, "%s\n", strerror(errno)); - return -1; - } - } - j++; - } while (temp && j < CG_CONTROLLER_MAX-1); - } - - /* Store path to the cgroup */ - strncpy(cdptr[i]->path, pathptr, FILENAME_MAX - 1); - cdptr[i]->path[sizeof(cdptr[i]->path) - 1] = '\0'; - - return 0; -} - - -/** - * Free a single cgroup_group_spec structure - * <--->@param cl The structure to free from memory. - */ -void cgroup_free_group_spec(struct cgroup_group_spec *cl) -{ - /* Loop variable */ - int i = 0; - - /* Make sure our structure is not NULL, first. */ - if (!cl) { - cgroup_dbg("Warning: Attempted to free NULL rule.\n"); - return; - } - - /* We must free any used controller strings, too. */ - for (i = 0; i < CG_CONTROLLER_MAX; i++) { - if (cl->controllers[i]) - free(cl->controllers[i]); - } - - free(cl); -} - - -int cgroup_string_list_init(struct cgroup_string_list *list, int initial_size) -{ - if (list == NULL) - return ECGINVAL; - - list->items = calloc(initial_size, sizeof(char *)); - if (!list->items) - return ECGFAIL; - - list->count = 0; - list->size = initial_size; - - return 0; -} - -void cgroup_string_list_free(struct cgroup_string_list *list) -{ - int i; - - if (list == NULL) - return; - - if (list->items == NULL) - return; - - for (i = 0; i < list->count; i++) - free(list->items[i]); - - free(list->items); -} - -int cgroup_string_list_add_item(struct cgroup_string_list *list, const char *item) -{ - if (list == NULL) - return ECGINVAL; - - if (list->size <= list->count) { - char **tmp = realloc(list->items, sizeof(char *) * list->size*2); - if (tmp == NULL) - return ECGFAIL; - list->items = tmp; - list->size = list->size * 2; - } - - list->items[list->count] = strdup(item); - if (list->items[list->count] == NULL) - return ECGFAIL; - list->count++; - - return 0; -} - -static int _compare_string(const void *a, const void *b) -{ - const char *sa = * (char * const *) a; - const char *sb = * (char * const *) b; - - return strcmp(sa, sb); -} - - -int cgroup_string_list_add_directory(struct cgroup_string_list *list, char *dirname, - char *program_name) -{ - int start, ret, count = 0; - struct dirent *item; - DIR *d; - - if (list == NULL) - return ECGINVAL; - - start = list->count; - - d = opendir(dirname); - if (!d) { - fprintf(stderr, "%s: cannot open %s: %s\n", program_name, dirname, - strerror(errno)); - exit(1); - } - - do { - errno = 0; - item = readdir(d); - if (item && (item->d_type == DT_REG || item->d_type == DT_LNK)) { - char *tmp, *file_ext; - - /* we are interested in .conf files, skip others */ - file_ext = strstr(item->d_name, ".conf"); - if (!file_ext) - continue; - - if (strcmp(file_ext, ".conf") || strlen(item->d_name) == 5) - continue; - - ret = asprintf(&tmp, "%s/%s", dirname, item->d_name); - if (ret < 0) { - fprintf(stderr, "%s: out of memory\n", program_name); - exit(1); - } - ret = cgroup_string_list_add_item(list, tmp); - free(tmp); - count++; - if (ret) { - fprintf(stderr, "%s: %s\n", program_name, cgroup_strerror(ret)); - exit(1); - } - } - if (!item && errno) { - fprintf(stderr, "%s: cannot read %s: %s\n", program_name, dirname, - strerror(errno)); - exit(1); - } - } while (item != NULL); - closedir(d); - - /* sort the names found in the directory */ - if (count > 0) - qsort(&list->items[start], count, sizeof(char *), _compare_string); - - return 0; -} - -/* allowed mode strings are octal version: "755" */ -int parse_mode(char *string, mode_t *pmode, const char *program_name) -{ - size_t len; - char *end; - long mode; - - len = strlen(string); - if (len < 3 || len > 4) - goto err; - - errno = 0; - mode = strtol(string, &end, 8); - if (errno != 0 || *end != '\0') - goto err; - *pmode = mode; - return 0; - -err: - *pmode = 0; - fprintf(stdout, "%s wrong mode format %s\n", program_name, string); - - return -1; -} - -int parse_uid_gid(char *string, uid_t *uid, gid_t *gid, const char *program_name) -{ - char *grp_string = NULL; - char *pwd_string = NULL; - struct passwd *pwd; - struct group *grp; - - *uid = *gid = NO_UID_GID; - - if (string[0] == ':') - grp_string = strtok(string, ":"); - else { - pwd_string = strtok(string, ":"); - if (pwd_string != NULL) - grp_string = strtok(NULL, ":"); - } - - if (pwd_string != NULL) { - pwd = getpwnam(pwd_string); - if (pwd != NULL) { - *uid = pwd->pw_uid; - } else { - fprintf(stderr, "%s: can't find uid of user %s.\n", program_name, - pwd_string); - return -1; - } - } - if (grp_string != NULL) { - grp = getgrnam(grp_string); - if (grp != NULL) { - *gid = grp->gr_gid; - } else { - fprintf(stderr, "%s: can't find gid of group %s.\n", program_name, - grp_string); - return -1; - } - } - - return 0; -} diff --git a/lib/libcgroup-3.1.0/src/tools/tools-common.h b/lib/libcgroup-3.1.0/src/tools/tools-common.h deleted file mode 100644 index 04888434a22..00000000000 --- a/lib/libcgroup-3.1.0/src/tools/tools-common.h +++ /dev/null @@ -1,137 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * Copyright Red Hat, Inc. 2009 - * - * Author: Vivek Goyal - * Jan Safranek - */ - -#ifndef __TOOLS_COMMON - -#define __TOOLS_COMMON - -#ifdef __cplusplus -extern "C" { -#endif - -#include "config.h" -#include "../libcgroup-internal.h" - -#include - -#define cgroup_err(x...) cgroup_log(CGROUP_LOG_ERROR, "Error: " x) -#define cgroup_warn(x...) cgroup_log(CGROUP_LOG_WARNING, "Warning: " x) -#define cgroup_info(x...) cgroup_log(CGROUP_LOG_INFO, "Info: " x) -#define cgroup_dbg(x...) cgroup_log(CGROUP_LOG_DEBUG, x) -#define cgroup_cont(x...) cgroup_log(CGROUP_LOG_CONT, x) - -#define err(x...) fprintf(stderr, x) -#define info(x...) fprintf(stdout, x) - -#define EXIT_BADARGS 129 - -/** - * Auxiliary specifier of group, used to store parsed command line options. - */ -struct cgroup_group_spec { - char path[FILENAME_MAX]; - char *controllers[CG_CONTROLLER_MAX]; -}; - -/** - * Simple dynamic array of strings. - */ -struct cgroup_string_list { - char **items; - int size; - int count; -}; - -/** - * Parse command line option with group specifier into provided data structure. - * The option must have form of 'controller1,controller2,..:group_name'. - * - * The parsed list of controllers and group name is added at the end of - * provided cdptr, - * i.e. on place of first NULL cgroup_group_spec*. - * - * @param cdptr Target data structure to fill. New item is allocated and - * added at the end. - * @param optarg Argument to parse. - * @param capacity The capacity of the cdptr array. - * @return 0 on success, != 0 on error. - */ -int parse_cgroup_spec(struct cgroup_group_spec **cdptr, char *optarg, int capacity); - -/** - * Free a single cgroup_group_spec structure. - * @param cl The structure to free from memory - */ -void cgroup_free_group_spec(struct cgroup_group_spec *cl); - -/** - * Initialize a new list. - * @param list The list to initialize. - * @param initial_size The initial size of the list to pre-allocate. - */ -int cgroup_string_list_init(struct cgroup_string_list *list, int initial_size); - -/** - * Destroy a list, automatically freeing all its items. - * @param list The list to destroy. - */ -void cgroup_string_list_free(struct cgroup_string_list *list); - -/** - * Adds new item to the list. It automatically resizes underlying array if needed. - * @param list The list to modify. - * @param item The item to add. The item is automatically copied to new buffer. - */ -int cgroup_string_list_add_item(struct cgroup_string_list *list, const char *item); - -/** - * Add alphabetically sorted files present in given directory - * (without subdirs) to list of strings. - * The function exits on error. - * @param list The list to add files to. - * @param dirname Full path to directory to examime. - * @param program_name Name of the executable, it will be used for - * printing errors to stderr. - */ -int cgroup_string_list_add_directory(struct cgroup_string_list *list, char *dirname, - char *program_name); - -/** - * Parse file permissions as octal number. - * @param string A string to parse, must contain 3-4 characters '0'-'7'. - * @param pmode Parsed mode. - * @oaram program_name Argv[0] to show error messages. - */ -int parse_mode(char *string, mode_t *pmode, const char *program_name); - -/** - * Parse UID and GID from string in form "user:group". - * @param string A string to parse. - * @param uid Parsed UID (-1 if 'user' is missing in the string). - * @param gid Parsed GID (-1 if 'group' is missing in the string). - * @param program_name Argv[0] to show error messages. - */ -int parse_uid_gid(char *string, uid_t *uid, gid_t *gid, const char *program_name); - -/** - * Functions that are defined as STATIC can be placed within the - * UNIT_TEST ifdef. This will allow them to be included in the unit tests - * while remaining static in a normal libcgroup build. - */ -#ifdef UNIT_TEST - -int parse_r_flag(const char * const program_name, const char * const name_value_str, - struct control_value * const name_value); - -#endif /* UNIT_TEST */ - -#ifdef __cplusplus -} /* extern "C" */ -#endif - -#endif /* TOOLS_COMMON */ diff --git a/lib/libcgroup-3.1.0/src/wrapper.c b/lib/libcgroup-3.1.0/src/wrapper.c deleted file mode 100644 index 547d5054d0c..00000000000 --- a/lib/libcgroup-3.1.0/src/wrapper.c +++ /dev/null @@ -1,833 +0,0 @@ -// SPDX-License-Identifier: LGPL-2.1-only -/** - * Copyright IBM Corporation. 2008 - * - * Author: Dhaval Giani - * - * Code initiated and designed by Dhaval Giani. All faults are most likely - * his mistake. - */ - -#define _GNU_SOURCE - -#include -#include - -#include -#include -#include -#include -#include -#include - -static void init_cgroup(struct cgroup *cgroup) -{ - cgroup->task_fperm = NO_PERMS; - cgroup->control_fperm = NO_PERMS; - cgroup->control_dperm = NO_PERMS; - - cgroup->control_gid = NO_UID_GID; - cgroup->control_uid = NO_UID_GID; - cgroup->tasks_gid = NO_UID_GID; - cgroup->tasks_uid = NO_UID_GID; -} - -void init_cgroup_table(struct cgroup *cgroups, size_t count) -{ - size_t i; - - for (i = 0; i < count; ++i) - init_cgroup(&cgroups[i]); -} - -struct cgroup *cgroup_new_cgroup(const char *name) -{ - struct cgroup *cgroup; - - if (!name) - return NULL; - - cgroup = calloc(1, sizeof(struct cgroup)); - if (!cgroup) - return NULL; - - init_cgroup(cgroup); - strncpy(cgroup->name, name, FILENAME_MAX - 1); - cgroup->name[FILENAME_MAX - 1] = '\0'; - - return cgroup; -} - -struct cgroup_controller *cgroup_add_controller(struct cgroup *cgroup, const char *name) -{ - struct cgroup_controller *controller; - int i, ret; - - if (!cgroup || !name) - return NULL; - - /* Still not sure how to handle the failure here. */ - if (cgroup->index >= CG_CONTROLLER_MAX) - return NULL; - - /* Still not sure how to handle the failure here. */ - for (i = 0; i < cgroup->index; i++) { - if (strncmp(name, cgroup->controller[i]->name, CONTROL_NAMELEN_MAX) == 0) - return NULL; - } - - controller = calloc(1, sizeof(struct cgroup_controller)); - if (!controller) - return NULL; - - strncpy(controller->name, name, CONTROL_NAMELEN_MAX - 1); - controller->name[CONTROL_NAMELEN_MAX - 1] = '\0'; - - controller->cgroup = cgroup; - controller->index = 0; - - if (strcmp(controller->name, CGROUP_FILE_PREFIX) == 0) { - /* - * Operating on the "cgroup" controller is only allowed - * on cgroup v2 systems - */ - controller->version = CGROUP_V2; - } else { - ret = cgroup_get_controller_version(controller->name, &controller->version); - if (ret) { - cgroup_dbg("failed to get cgroup version for controller %s\n", - controller->name); - free(controller); - return NULL; - } - } - - cgroup->controller[cgroup->index] = controller; - cgroup->index++; - - return controller; -} - -int cgroup_add_all_controllers(struct cgroup *cgroup) -{ - struct cgroup_controller *cgc; - struct controller_data info; - enum cg_setup_mode_t mode; - void *handle; - int ret = 0; - - if (!cgroup) - return ECGINVAL; - - mode = cgroup_setup_mode(); - - /* - * Per kernel documentation, cgroup-v2.rst, /proc/cgroups is "meaningless" for cgroup v2. - * Use the cgroup's cgroup.controllers file instead - */ - if (mode == CGROUP_MODE_UNIFIED) { - char *ret_c, *controller, *stok_buff = NULL, line[CGV2_CONTROLLERS_LL_MAX]; - /* - * cg_cgroup_v2_mount_path (FILENAME_MAX) + cgroup->name (FILENAME_MAX) + - * strlen("cgroup.controllers") (18) + 2 forward slashes + 1 NULL terminator - */ - char cgroup_controllers_path[FILENAME_MAX * 2 + 18 + 2 + 1]; - FILE *fp; - - pthread_rwlock_rdlock(&cg_mount_table_lock); - if (strlen(cg_cgroup_v2_mount_path) == 0) { - pthread_rwlock_unlock(&cg_mount_table_lock); - ret = ECGOTHER; - goto out; - } - - snprintf(cgroup_controllers_path, sizeof(cgroup_controllers_path), "%s/%s/%s", - cg_cgroup_v2_mount_path, cgroup->name, CGV2_CONTROLLERS_FILE); - pthread_rwlock_unlock(&cg_mount_table_lock); - - fp = fopen(cgroup_controllers_path, "re"); - if (!fp) { - ret = ECGOTHER; - goto out; - } - - ret_c = fgets(line, CGV2_CONTROLLERS_LL_MAX, fp); - fclose(fp); - if (ret_c == NULL) { - /* no controllers are enabled */ - goto out; - } - - /* Remove the trailing newline */ - ret_c[strlen(ret_c) - 1] = '\0'; - - /* - * cgroup.controllers returns a list of available controllers in - * the following format: - * cpuset cpu io memory pids rdma - */ - controller = strtok_r(ret_c, " ", &stok_buff); - do { - cgc = cgroup_add_controller(cgroup, controller); - if (!cgc) { - ret = ECGINVAL; - fprintf(stderr, "controller %s can't be added\n", controller); - goto end; - } - } while ((controller = strtok_r(NULL, " ", &stok_buff))); - } else { - /* go through the controller list */ - ret = cgroup_get_all_controller_begin(&handle, &info); - if ((ret != 0) && (ret != ECGEOF)) { - fprintf(stderr, "cannot read controller data: %s\n", cgroup_strerror(ret)); - return ret; - } - - while (ret == 0) { - if (info.hierarchy == 0) { - /* - * the controller is not attached to any - * hierarchy skip it. - */ - goto next; - } - - /* add mounted controller to cgroup structure */ - cgc = cgroup_add_controller(cgroup, info.name); - if (!cgc) { - ret = ECGINVAL; - fprintf(stderr, "controller %s can't be added\n", info.name); - goto end; - } - -next: - ret = cgroup_get_all_controller_next(&handle, &info); - if (ret && ret != ECGEOF) - goto end; - } - -end: - cgroup_get_all_controller_end(&handle); - if (ret == ECGEOF) - ret = 0; - if (ret) - fprintf(stderr, "cgroup_get_controller_begin/next failed (%s)\n", - cgroup_strerror(ret)); - } - -out: - return ret; -} - -static void cgroup_free_value(struct control_value *value) -{ - if (value->multiline_value) - free(value->multiline_value); - if (value->prev_name) - free(value->prev_name); - - free(value); -} - -void cgroup_free_controller(struct cgroup_controller *ctrl) -{ - int i; - - for (i = 0; i < ctrl->index; i++) - cgroup_free_value(ctrl->values[i]); - ctrl->index = 0; - - free(ctrl); -} - -void cgroup_free_controllers(struct cgroup *cgroup) -{ - int i; - - if (!cgroup) - return; - - for (i = 0; i < cgroup->index; i++) - cgroup_free_controller(cgroup->controller[i]); - - cgroup->index = 0; -} - -void cgroup_free(struct cgroup **cgroup) -{ - struct cgroup *cg = *cgroup; - - /* Passing NULL pointers is OK. We just return. */ - if (!cg) - return; - - cgroup_free_controllers(cg); - free(cg); - *cgroup = NULL; -} - -int cgroup_add_value_string(struct cgroup_controller *controller, const char *name, - const char *value) -{ - int i; - struct control_value *cntl_value; - - if (!controller || !name) - return ECGINVAL; - - if (controller->index >= CG_NV_MAX) - return ECGMAXVALUESEXCEEDED; - - for (i = 0; i < controller->index && i < CG_NV_MAX; i++) { - if (!strcmp(controller->values[i]->name, name)) - return ECGVALUEEXISTS; - } - - cntl_value = calloc(1, sizeof(struct control_value)); - if (!cntl_value) - return ECGCONTROLLERCREATEFAILED; - - strncpy(cntl_value->name, name, sizeof(cntl_value->name)); - cntl_value->name[sizeof(cntl_value->name)-1] = '\0'; - - if (value) { - if (strlen(value) >= sizeof(cntl_value->value)) { - fprintf(stderr, "value exceeds the maximum of %ld characters\n", - sizeof(cntl_value->value) - 1); - free(cntl_value); - return ECGCONFIGPARSEFAIL; - } - - strncpy(cntl_value->value, value, sizeof(cntl_value->value)); - cntl_value->value[sizeof(cntl_value->value)-1] = '\0'; - cntl_value->dirty = true; - } - - controller->values[controller->index] = cntl_value; - controller->index++; - - return 0; -} - -int cgroup_add_value_int64(struct cgroup_controller *controller, const char *name, int64_t value) -{ - char *val; - int ret; - - ret = asprintf(&val, "%"PRId64, value); - if (ret < 0) { - last_errno = errno; - return ECGOTHER; - } - - ret = cgroup_add_value_string(controller, name, val); - free(val); - - return ret; -} - -int cgroup_add_value_uint64(struct cgroup_controller *controller, const char *name, - u_int64_t value) -{ - char *val; - int ret; - - ret = asprintf(&val, "%" PRIu64, value); - if (ret < 0) { - last_errno = errno; - return ECGOTHER; - } - - ret = cgroup_add_value_string(controller, name, val); - free(val); - - return ret; -} - -int cgroup_add_value_bool(struct cgroup_controller *controller, const char *name, bool value) -{ - char *val; - int ret; - - if (value) - val = strdup("1"); - else - val = strdup("0"); - if (!val) { - last_errno = errno; - return ECGOTHER; - } - - ret = cgroup_add_value_string(controller, name, val); - free(val); - - return ret; -} - -int cgroup_remove_value(struct cgroup_controller * const controller, const char * const name) -{ - int i; - - for (i = 0; i < controller->index; i++) { - if (strcmp(controller->values[i]->name, name) == 0) { - cgroup_free_value(controller->values[i]); - - if (i == (controller->index - 1)) { - /* This is the last entry in the table. There's nothing to move */ - controller->index--; - } else { - memmove(&controller->values[i], &controller->values[i + 1], - sizeof(struct control_value *) * (controller->index - i - 1)); - controller->index--; - } - return 0; - } - } - - return ECGROUPNOTEXIST; -} - -int cgroup_compare_controllers(struct cgroup_controller *cgca, struct cgroup_controller *cgcb) -{ - int i; - - if (!cgca || !cgcb) - return ECGINVAL; - - if (strcmp(cgca->name, cgcb->name)) - return ECGCONTROLLERNOTEQUAL; - - if (cgca->index != cgcb->index) - return ECGCONTROLLERNOTEQUAL; - - for (i = 0; i < cgca->index; i++) { - struct control_value *cva = cgca->values[i]; - struct control_value *cvb = cgcb->values[i]; - - if (strcmp(cva->name, cvb->name)) - return ECGCONTROLLERNOTEQUAL; - - if (strcmp(cva->value, cvb->value)) - return ECGCONTROLLERNOTEQUAL; - } - - return 0; -} - -int cgroup_compare_cgroup(struct cgroup *cgroup_a, struct cgroup *cgroup_b) -{ - int i, j; - - if (!cgroup_a || !cgroup_b) - return ECGINVAL; - - if (strcmp(cgroup_a->name, cgroup_b->name)) - return ECGROUPNOTEQUAL; - - if (cgroup_a->tasks_uid != cgroup_b->tasks_uid) - return ECGROUPNOTEQUAL; - - if (cgroup_a->tasks_gid != cgroup_b->tasks_gid) - return ECGROUPNOTEQUAL; - - if (cgroup_a->control_uid != cgroup_b->control_uid) - return ECGROUPNOTEQUAL; - - if (cgroup_a->control_gid != cgroup_b->control_gid) - return ECGROUPNOTEQUAL; - - if (cgroup_a->index != cgroup_b->index) - return ECGROUPNOTEQUAL; - - for (i = 0; i < cgroup_a->index; i++) { - struct cgroup_controller *cgca = cgroup_a->controller[i]; - bool found_match = false; - - /* - * Don't penalize the user if the controllers are in different order - * from cgroup_a to cgroup_b - */ - for (j = 0; j < cgroup_b->index; j++) { - struct cgroup_controller *cgcb = cgroup_b->controller[j]; - - if (cgroup_compare_controllers(cgca, cgcb) == 0) { - found_match = true; - break; - } - } - - if (!found_match) - return ECGCONTROLLERNOTEQUAL; - } - - return 0; -} - -int cgroup_set_uid_gid(struct cgroup *cgroup, uid_t tasks_uid, gid_t tasks_gid, uid_t control_uid, - gid_t control_gid) -{ - if (!cgroup) - return ECGINVAL; - - cgroup->tasks_uid = tasks_uid; - cgroup->tasks_gid = tasks_gid; - cgroup->control_uid = control_uid; - cgroup->control_gid = control_gid; - - return 0; -} - -int cgroup_get_uid_gid(struct cgroup *cgroup, uid_t *tasks_uid, gid_t *tasks_gid, - uid_t *control_uid, gid_t *control_gid) -{ - if (!cgroup || !tasks_uid || !tasks_gid || !control_uid || !control_gid) - return ECGINVAL; - - *tasks_uid = cgroup->tasks_uid; - *tasks_gid = cgroup->tasks_gid; - *control_uid = cgroup->control_uid; - *control_gid = cgroup->control_gid; - - return 0; -} - -struct cgroup_controller *cgroup_get_controller(struct cgroup *cgroup, const char *name) -{ - int i; - struct cgroup_controller *cgc; - - if (!cgroup) - return NULL; - - for (i = 0; i < cgroup->index; i++) { - cgc = cgroup->controller[i]; - - if (!strcmp(cgc->name, name)) - return cgc; - } - - return NULL; -} - -int cgroup_get_value_string(struct cgroup_controller *controller, const char *name, char **value) -{ - int i; - - if (!controller || !name || !value) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - *value = strdup(val->value); - - if (!*value) - return ECGOTHER; - - return 0; - } - } - - return ECGROUPVALUENOTEXIST; - -} - -int cgroup_set_value_string(struct cgroup_controller *controller, const char *name, - const char *value) -{ - int i; - - if (!controller || !name || !value) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - strncpy(val->value, value, CG_CONTROL_VALUE_MAX); - val->value[sizeof(val->value)-1] = '\0'; - val->dirty = true; - return 0; - } - } - - return cgroup_add_value_string(controller, name, value); -} - -int cgroup_get_value_int64(struct cgroup_controller *controller, const char *name, int64_t *value) -{ - int i; - - if (!controller || !name || !value) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - if (sscanf(val->value, "%" SCNd64, value) != 1) - return ECGINVAL; - - return 0; - } - } - - return ECGROUPVALUENOTEXIST; -} - -int cgroup_set_value_int64(struct cgroup_controller *controller, const char *name, int64_t value) -{ - int ret; - int i; - - if (!controller || !name) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - ret = snprintf(val->value, sizeof(val->value), "%" PRId64, value); - if (ret >= sizeof(val->value)) - return ECGINVAL; - - val->dirty = true; - return 0; - } - } - - return cgroup_add_value_int64(controller, name, value); -} - -int cgroup_get_value_uint64(struct cgroup_controller *controller, const char *name, - u_int64_t *value) -{ - int i; - - if (!controller || !name || !value) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - if (sscanf(val->value, "%" SCNu64, value) != 1) - return ECGINVAL; - - return 0; - } - } - - return ECGROUPVALUENOTEXIST; -} - -int cgroup_set_value_uint64(struct cgroup_controller *controller, const char *name, - u_int64_t value) -{ - int ret; - int i; - - if (!controller || !name) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - ret = snprintf(val->value, sizeof(val->value), "%" PRIu64, value); - if (ret >= sizeof(val->value)) - return ECGINVAL; - - val->dirty = true; - return 0; - } - } - - return cgroup_add_value_uint64(controller, name, value); -} - -int cgroup_get_value_bool(struct cgroup_controller *controller, const char *name, bool *value) -{ - int i; - - if (!controller || !name || !value) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - int cgc_val; - - if (sscanf(val->value, "%d", &cgc_val) != 1) - return ECGINVAL; - - if (cgc_val) - *value = true; - else - *value = false; - - return 0; - } - } - - return ECGROUPVALUENOTEXIST; -} - -int cgroup_set_value_bool(struct cgroup_controller *controller, const char *name, bool value) -{ - int ret; - int i; - - if (!controller || !name) - return ECGINVAL; - - for (i = 0; i < controller->index; i++) { - struct control_value *val = controller->values[i]; - - if (!strcmp(val->name, name)) { - if (value) - ret = snprintf(val->value, sizeof(val->value), "1"); - else - ret = snprintf(val->value, sizeof(val->value), "0"); - - if (ret >= sizeof(val->value)) - return ECGINVAL; - - val->dirty = true; - return 0; - - } - } - - return cgroup_add_value_bool(controller, name, value); -} - -struct cgroup *create_cgroup_from_name_value_pairs(const char *name, - struct control_value *name_value, int nv_number) -{ - struct cgroup_controller *cgc; - struct cgroup *src_cgroup; - char con[FILENAME_MAX]; - - int ret; - int i; - - /* create source cgroup */ - src_cgroup = cgroup_new_cgroup(name); - if (!src_cgroup) { - fprintf(stderr, "can't create cgroup: %s\n", cgroup_strerror(ECGFAIL)); - goto scgroup_err; - } - - /* Add pairs name-value to relevant controllers of this cgroup. */ - for (i = 0; i < nv_number; i++) { - - if ((strchr(name_value[i].name, '.')) == NULL) { - fprintf(stderr, "wrong -r parameter (%s=%s)\n", name_value[i].name, - name_value[i].value); - goto scgroup_err; - } - - strncpy(con, name_value[i].name, FILENAME_MAX - 1); - con[FILENAME_MAX - 1] = '\0'; - - strtok(con, "."); - - /* - * find out whether we have to add the controller or - * cgroup already contains it. - */ - cgc = cgroup_get_controller(src_cgroup, con); - if (!cgc) { - /* add relevant controller */ - cgc = cgroup_add_controller(src_cgroup, con); - if (!cgc) { - fprintf(stderr, "controller %s can't be add\n", con); - goto scgroup_err; - } - } - - /* add name-value pair to this controller */ - ret = cgroup_add_value_string(cgc, name_value[i].name, name_value[i].value); - if (ret) { - fprintf(stderr, "name-value pair %s=%s can't be set\n", name_value[i].name, - name_value[i].value); - goto scgroup_err; - } - } - - return src_cgroup; - -scgroup_err: - cgroup_free(&src_cgroup); - - return NULL; -} - -int cgroup_get_value_name_count(struct cgroup_controller *controller) -{ - if (!controller) - return -1; - - return controller->index; -} - - -char *cgroup_get_value_name(struct cgroup_controller *controller, int index) -{ - - if (!controller) - return NULL; - - if (index < controller->index) - return (controller->values[index])->name; - else - return NULL; -} - -char *cgroup_get_cgroup_name(struct cgroup *cgroup) -{ - if (!cgroup) - return NULL; - - return cgroup->name; -} - - -/* - * Return true if cgroup setup mode is cgroup v1 (legacy), else - * returns false. - */ -bool is_cgroup_mode_legacy(void) -{ - enum cg_setup_mode_t setup_mode; - - setup_mode = cgroup_setup_mode(); - return (setup_mode == CGROUP_MODE_LEGACY); -} - -/* - * Return true if cgroup setup mode is cgroup v1/v2 (hybrid), else - * returns false. - */ -bool is_cgroup_mode_hybrid(void) -{ - enum cg_setup_mode_t setup_mode; - - setup_mode = cgroup_setup_mode(); - return (setup_mode == CGROUP_MODE_HYBRID); -} - -/* - * Return true if cgroup setup mode is cgroup v2 (unified), else - * returns false. - */ -bool is_cgroup_mode_unified(void) -{ - enum cg_setup_mode_t setup_mode; - - setup_mode = cgroup_setup_mode(); - return (setup_mode == CGROUP_MODE_UNIFIED); -} diff --git a/lib/libcgroup-3.1.0/tests/Makefile.am b/lib/libcgroup-3.1.0/tests/Makefile.am deleted file mode 100644 index fd4b335425f..00000000000 --- a/lib/libcgroup-3.1.0/tests/Makefile.am +++ /dev/null @@ -1,4 +0,0 @@ -DIST_SUBDIRS = ftests gunit -if WITH_TESTS -SUBDIRS = $(DIST_SUBDIRS) -endif diff --git a/lib/libcgroup-3.1.0/tests/Makefile.in b/lib/libcgroup-3.1.0/tests/Makefile.in deleted file mode 100644 index 17d2256c154..00000000000 --- a/lib/libcgroup-3.1.0/tests/Makefile.in +++ /dev/null @@ -1,653 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = tests -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir distdir-am -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__DIST_COMMON = $(srcdir)/Makefile.in README.md -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -DIST_SUBDIRS = ftests gunit -@WITH_TESTS_TRUE@SUBDIRS = $(DIST_SUBDIRS) -all: all-recursive - -.SUFFIXES: -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign tests/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign tests/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-recursive -all-am: Makefile -installdirs: installdirs-recursive -installdirs-am: -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-recursive - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-recursive - -rm -f Makefile -distclean-am: clean-am distclean-generic distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: - -.MAKE: $(am__recursive_targets) install-am install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - installdirs-am maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ - ps ps-am tags tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/tests/README.md b/lib/libcgroup-3.1.0/tests/README.md deleted file mode 100644 index 05449ee7bcc..00000000000 --- a/lib/libcgroup-3.1.0/tests/README.md +++ /dev/null @@ -1,5 +0,0 @@ -[![Build Status](https://github.com/libcgroup/libcgroup-tests/workflows/Continuous%20Integration/badge.svg?branch=main)](https://github.com/libcgroup/libcgroup-tests/actions) -[![Language grade: Python](https://img.shields.io/lgtm/grade/python/g/libcgroup/libcgroup-tests.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/libcgroup/libcgroup-tests/alerts/?mode=list) - -The libcgroup-tests repository contains the automated tests for the -[libcgroup](https://github.com/libcgroup/libcgroup) project. diff --git a/lib/libcgroup-3.1.0/tests/ftests/001-cgget-basic_cgget_v1.py b/lib/libcgroup-3.1.0/tests/ftests/001-cgget-basic_cgget_v1.py deleted file mode 100755 index c7b3a34f56e..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/001-cgget-basic_cgget_v1.py +++ /dev/null @@ -1,66 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgget functionality test -# -# Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '001cgget' -SETTING = 'cpu.shares' -VALUE = '512' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - Cgroup.set(config, CGNAME, SETTING, VALUE) - - -def test(config): - Cgroup.get_and_validate(config, CGNAME, SETTING, VALUE) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/002-cgdelete-recursive_delete.py b/lib/libcgroup-3.1.0/tests/ftests/002-cgdelete-recursive_delete.py deleted file mode 100755 index d999ca6b9fe..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/002-cgdelete-recursive_delete.py +++ /dev/null @@ -1,83 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup recursive cgdelete functionality test -# -# Copyright (c) 2020-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from libcgroup import Mode -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -PARENT = '002cgdelete' -CHILD = 'childcg' -GRANDCHILD = 'grandchildcg' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - # This test has shown inconsistent failures on underpowered legacy - # machines when run within a container. Skip that configuration - if Cgroup.get_cgroup_mode(config) == Mode.CGROUP_MODE_LEGACY and \ - config.args.container: - result = consts.TEST_SKIPPED - cause = 'Skip this test in containerized legacy hierarchies' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENT) - Cgroup.create(config, CONTROLLER, os.path.join(PARENT, CHILD)) - Cgroup.create(config, CONTROLLER, os.path.join(PARENT, CHILD, GRANDCHILD)) - - version = CgroupVersion.get_version(CONTROLLER) - if version == CgroupVersion.CGROUP_V1: - # cgdelete in a cgroup v1 controller should be able to move a process - # from a child cgroup to its parent. - # - # Moving a process from a child cgroup to its parent isn't (easily) - # supported in cgroup v2 because of cgroup v2's restriction that - # processes only be located in leaf cgroups - grandchild_cgrp_path = os.path.join(PARENT, CHILD, GRANDCHILD) - config.process.create_process_in_cgroup(config, CONTROLLER, - grandchild_cgrp_path) - - -def test(config): - Cgroup.delete(config, CONTROLLER, PARENT, recursive=True) - - return consts.TEST_PASSED, None - - -def teardown(config): - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/003-cgget-basic_cgget_v2.py b/lib/libcgroup-3.1.0/tests/ftests/003-cgget-basic_cgget_v2.py deleted file mode 100755 index f5fe7666df7..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/003-cgget-basic_cgget_v2.py +++ /dev/null @@ -1,67 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgget functionality test -# -# Copyright (c) 2020 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '003cgget' - -SETTING = 'cpuset.mems' -VALUE = '0' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpuset') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpuset controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - Cgroup.set(config, CGNAME, SETTING, VALUE) - - -def test(config): - Cgroup.get_and_validate(config, CGNAME, SETTING, VALUE) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/004-cgsnapshot-basic_snapshot_v1.py b/lib/libcgroup-3.1.0/tests/ftests/004-cgsnapshot-basic_snapshot_v1.py deleted file mode 100755 index 6b6f32c1139..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/004-cgsnapshot-basic_snapshot_v1.py +++ /dev/null @@ -1,116 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgsnapshot functionality test -# -# Copyright (c) 2020-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME = '004cgsnapshot' -CGSNAPSHOT = """group 004cgsnapshot { - memory { - memory.use_hierarchy="1"; - memory.soft_limit_in_bytes="9223372036854771712"; - memory.force_empty=""; - memory.move_charge_at_immigrate="0"; - memory.kmem.tcp.max_usage_in_bytes="0"; - memory.max_usage_in_bytes="0"; - memory.oom_control="oom_kill_disable 0 - under_oom 0 - oom_kill 0"; - memory.limit_in_bytes="9223372036854771712"; - memory.swappiness="60"; - memory.kmem.failcnt="0"; - memory.kmem.max_usage_in_bytes="0"; - memory.failcnt="0"; - memory.kmem.tcp.failcnt="0"; - memory.kmem.limit_in_bytes="9223372036854771712"; - memory.use_hierarchy="1"; - memory.kmem.tcp.limit_in_bytes="9223372036854771712"; -""" - -CGSNAPSHOT_SWAP = """ memory.memsw.failcnt="0"; - memory.memsw.limit_in_bytes="9223372036854771712"; - memory.memsw.max_usage_in_bytes="0"; - } - }""" - -CGSNAPSHOT_NOSWAP = """ } - }""" - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - return result, cause - - if not config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test must be run within a container' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - try: - # check if the memsw.failcnt file exists. if so, add it to the - # expected snapshot - Cgroup.get(config, setting='memory.memsw.failcnt', cgname=CGNAME) - expected_str = CGSNAPSHOT + CGSNAPSHOT_SWAP - except RunError: - # memsw files don't exist. exclude them from the snapshot - expected_str = CGSNAPSHOT + CGSNAPSHOT_NOSWAP - - expected = Cgroup.snapshot_to_dict(expected_str) - actual = Cgroup.snapshot(config, controller=CONTROLLER) - - if expected[CGNAME] != actual[CGNAME]: - result = consts.TEST_FAILED - cause = 'Expected cgsnapshot result did not equal actual cgsnapshot' - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/005-cgsnapshot-basic_snapshot_v2.py b/lib/libcgroup-3.1.0/tests/ftests/005-cgsnapshot-basic_snapshot_v2.py deleted file mode 100755 index 006a4b709a8..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/005-cgsnapshot-basic_snapshot_v2.py +++ /dev/null @@ -1,79 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgsnapshot functionality test -# -# Copyright (c) 2020 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '005cgsnapshot' -CGSNAPSHOT = """group 005cgsnapshot { - cpuset { - cpuset.cpus.partition="member"; - cpuset.mems=""; - cpuset.cpus=""; - } - }""" - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpuset') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpuset controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - expected = Cgroup.snapshot_to_dict(CGSNAPSHOT) - actual = Cgroup.snapshot(config, controller=CONTROLLER) - - if expected[CGNAME].controllers[CONTROLLER] != \ - actual[CGNAME].controllers[CONTROLLER]: - result = consts.TEST_FAILED - cause = 'Expected cgsnapshot result did not equal actual cgsnapshot' - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/006-cgrules-basic_cgrules_v1.py b/lib/libcgroup-3.1.0/tests/ftests/006-cgrules-basic_cgrules_v1.py deleted file mode 100755 index b7a9b586732..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/006-cgrules-basic_cgrules_v1.py +++ /dev/null @@ -1,104 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgrules functionality test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from process import Process -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -PARENT_CGNAME = '006cgrules' -CHILD_CGNAME = 'childcg' - -# move all perl processes to the 006cgrules/childcg cgroup in the -# cpu controller -CGRULE = ( - '*:/usr/bin/perl cpu {}' - ''.format(os.path.join(PARENT_CGNAME, CHILD_CGNAME)) - ) - -cg = Cgroup(os.path.join(PARENT_CGNAME, CHILD_CGNAME)) - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENT_CGNAME) - Cgroup.create(config, CONTROLLER, - os.path.join(PARENT_CGNAME, CHILD_CGNAME)) - - Cgroup.set_cgrules_conf(config, CGRULE, append=False) - cg.start_cgrules(config) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - pid = config.process.create_process(config) - proc_cgroup = Process.get_cgroup(config, pid, CONTROLLER) - - # proc/{pid}/cgroup alsways prepends a '/' to the cgroup path - if proc_cgroup != os.path.join('/', PARENT_CGNAME, CHILD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'PID {} was expected to be in cgroup {} but is in ' - 'cgroup {}' - ''.format(pid, - os.path.join('/', PARENT_CGNAME, CHILD_CGNAME), - proc_cgroup) - ) - - return result, cause - - -def teardown(config): - # destroy the child processes - config.process.join_children(config) - cg.join_children(config) - Cgroup.delete(config, CONTROLLER, PARENT_CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/007-cgrules-basic_cgrules_v2.py b/lib/libcgroup-3.1.0/tests/ftests/007-cgrules-basic_cgrules_v2.py deleted file mode 100755 index 4216a1b66a0..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/007-cgrules-basic_cgrules_v2.py +++ /dev/null @@ -1,96 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic cgrules functionality test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from process import Process -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '007cgrules' - -# move all perl processes to the 007cgrules cgroup in the -# cpuset controller -CGRULE = '*:/usr/bin/perl cpuset {}'.format(CGNAME) - -cg = Cgroup(CGNAME) - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version('cpuset') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpuset controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - Cgroup.set_cgrules_conf(config, CGRULE, append=False) - cg.start_cgrules(config) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - pid = config.process.create_process(config) - proc_cgroup = Process.get_cgroup(config, pid, CONTROLLER) - - # proc/{pid}/cgroup alsways prepends a '/' to the cgroup path - if proc_cgroup != os.path.join('/', CGNAME): - result = consts.TEST_FAILED - cause = ( - 'PID {} was expected to be in cgroup {} but is in ' - 'cgroup {}' - ''.format(pid, os.path.join('/', CGNAME), proc_cgroup) - ) - - return result, cause - - -def teardown(config): - # destroy the child processes - config.process.join_children(config) - cg.join_children(config) - Cgroup.delete(config, CONTROLLER, CGNAME, recursive=False) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/008-cgget-multiple_r_flags.py b/lib/libcgroup-3.1.0/tests/ftests/008-cgget-multiple_r_flags.py deleted file mode 100755 index e4120824f6d..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/008-cgget-multiple_r_flags.py +++ /dev/null @@ -1,104 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - multiple '-r' flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME = '008cgget' - -SETTING1_V1 = 'memory.limit_in_bytes' -SETTING1_V2 = 'memory.max' -VALUE1 = '1048576' - -SETTING2_V1 = 'memory.soft_limit_in_bytes' -SETTING2_V2 = 'memory.high' -VALUE2 = '1024000' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - Cgroup.set(config, CGNAME, SETTING1_V1, VALUE1) - Cgroup.set(config, CGNAME, SETTING2_V1, VALUE2) - elif version == CgroupVersion.CGROUP_V2: - Cgroup.set(config, CGNAME, SETTING1_V2, VALUE1) - Cgroup.set(config, CGNAME, SETTING2_V2, VALUE2) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - settings = [SETTING1_V1, SETTING2_V1] - elif version == CgroupVersion.CGROUP_V2: - settings = [SETTING1_V2, SETTING2_V2] - - out = Cgroup.get(config, controller=None, cgname=CGNAME, setting=settings) - - if out.splitlines()[0] != '{}:'.format(CGNAME): - result = consts.TEST_FAILED - cause = ( - 'cgget expected the cgroup name {} in the first line.\n' - 'Instead it received {}' - ''.format(CGNAME, out.splitlines()[0]) - ) - - if out.splitlines()[1] != '{}: {}'.format(settings[0], VALUE1): - result = consts.TEST_FAILED - cause = ( - 'cgget expected the following:\n\t{}: {}\n' - 'but received:\n\t{}' - ''.format(settings[0], VALUE1, out.splitlines()[1]) - ) - - if out.splitlines()[2] != '{}: {}'.format(settings[1], VALUE2): - result = consts.TEST_FAILED - cause = ( - 'cgget expected the following:\n\t{}: {}\n' - 'but received:\n\t{}' - ''.format(settings[1], VALUE2, out.splitlines()[2]) - ) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/009-cgget-g_flag_controller_only.py b/lib/libcgroup-3.1.0/tests/ftests/009-cgget-g_flag_controller_only.py deleted file mode 100755 index 5997307e965..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/009-cgget-g_flag_controller_only.py +++ /dev/null @@ -1,191 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - '-g' -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '009cgget' - -EXPECTED_OUT_V1 = [ - '''009cgget: - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # cfs_bandwidth without cpu.stat nr_busts, burst_time - '''009cgget: - cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # cfs_bandwidth with cpu.stat nr_busts, burst_time - '''009cgget: - cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - nr_bursts 0 - burst_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''' -] - -EXPECTED_OUT_V2 = [ - '''009cgget: - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI - '''009cgget: - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth without cpu.stat nr_busts, burst_time - '''009cgget: - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth with cpu.stat nr_busts, burst_time - '''009cgget: - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - nr_bursts 0 - burst_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''' -] - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=CONTROLLER, cgname=CGNAME) - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - for expected_out in EXPECTED_OUT_V1: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - elif version == CgroupVersion.CGROUP_V2: - for expected_out in EXPECTED_OUT_V2: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - - if len(out.splitlines()) != len(expected_out.splitlines()): - result = consts.TEST_FAILED - cause = ( - 'Expected {} lines but received {} lines' - ''.format(len(expected_out.splitlines()), - len(out.splitlines())) - ) - return result, cause - - for line_num, line in enumerate(out.splitlines()): - if line.strip() != expected_out.splitlines()[line_num].strip(): - result = consts.TEST_FAILED - cause = ( - 'Expected line:\n\t{}\nbut received line:\n\t{}' - ''.format(expected_out.splitlines()[line_num].strip(), - line.strip()) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/010-cgget-g_flag_controller_and_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/010-cgget-g_flag_controller_and_cgroup.py deleted file mode 100755 index 469e3c64c59..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/010-cgget-g_flag_controller_and_cgroup.py +++ /dev/null @@ -1,194 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - '-g' : -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '010cgget' - -EXPECTED_OUT_V1 = [ - '''cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # cfs_bandwidth without cpu.stat nr_busts, burst_time - '''cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # cfs_bandwidth with cpu.stat nr_busts, burst_time - '''cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - nr_bursts 0 - burst_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''' -] - -EXPECTED_OUT_V2 = [ - '''cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI - '''cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth without cpu.stat nr_busts, burst_time - '''cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth with cpu.stat nr_busts, burst_time - '''cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - nr_bursts 0 - burst_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', -] - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller='{}:{}'.format(CONTROLLER, CGNAME), - print_headers=False) - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - for expected_out in EXPECTED_OUT_V1: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - elif version == CgroupVersion.CGROUP_V2: - for expected_out in EXPECTED_OUT_V2: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - - if len(out.splitlines()) != len(expected_out.splitlines()): - result = consts.TEST_FAILED - cause = ( - 'Expected line count: {}, but received line count: {}' - ''.format(len(expected_out.splitlines()), - len(out.splitlines())) - ) - return result, cause - - if len(out.splitlines()) != len(expected_out.splitlines()): - result = consts.TEST_FAILED - cause = ( - 'Expected {} lines but received {} lines' - ''.format(len(expected_out.splitlines()), - len(out.splitlines())) - ) - return result, cause - - for line_num, line in enumerate(out.splitlines()): - if line.strip() != expected_out.splitlines()[line_num].strip(): - result = consts.TEST_FAILED - cause = ( - 'Expected line:\n\t{}\nbut received line:\n\t{}' - ''.format(expected_out.splitlines()[line_num].strip(), - line.strip()) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/011-cgget-r_flag_two_cgroups.py b/lib/libcgroup-3.1.0/tests/ftests/011-cgget-r_flag_two_cgroups.py deleted file mode 100755 index e6a02defeb3..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/011-cgget-r_flag_two_cgroups.py +++ /dev/null @@ -1,106 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - '-r' -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME1 = '011cgget1' -CGNAME2 = '011cgget2' - -SETTING_V1 = 'memory.limit_in_bytes' -SETTING_V2 = 'memory.max' -VALUE = '2048000' - -EXPECTED_OUT_V1 = '''011cgget1: -memory.limit_in_bytes: 2048000 - -011cgget2: -memory.limit_in_bytes: 2048000 -''' - -EXPECTED_OUT_V2 = '''011cgget1: -memory.max: 2048000 - -011cgget2: -memory.max: 2048000 -''' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME1) - Cgroup.create(config, CONTROLLER, CGNAME2) - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - Cgroup.set(config, CGNAME1, SETTING_V1, VALUE) - Cgroup.set(config, CGNAME2, SETTING_V1, VALUE) - elif version == CgroupVersion.CGROUP_V2: - Cgroup.set(config, CGNAME1, SETTING_V2, VALUE) - Cgroup.set(config, CGNAME2, SETTING_V2, VALUE) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - setting = SETTING_V1 - expected_out = EXPECTED_OUT_V1 - elif version == CgroupVersion.CGROUP_V2: - setting = SETTING_V2 - expected_out = EXPECTED_OUT_V2 - - out = Cgroup.get(config, controller=None, cgname=[CGNAME1, CGNAME2], - setting=setting) - - for line_num, line in enumerate(out.splitlines()): - if line.strip() != expected_out.splitlines()[line_num].strip(): - result = consts.TEST_FAILED - cause = ( - 'Expected line:\n\t{}\nbut received line:\n\t{}' - ''.format(expected_out.splitlines()[line_num].strip(), - line.strip()) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME1) - Cgroup.delete(config, CONTROLLER, CGNAME2) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/012-cgget-multiple_r_flags2.py b/lib/libcgroup-3.1.0/tests/ftests/012-cgget-multiple_r_flags2.py deleted file mode 100755 index d0bd7eda97e..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/012-cgget-multiple_r_flags2.py +++ /dev/null @@ -1,107 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - multiple '-r' flags and multiple cgroups -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME1 = '012cgget1' -CGNAME2 = '012cgget2' - -SETTING1_V1 = 'memory.limit_in_bytes' -SETTING1_V2 = 'memory.max' -VALUE1 = '4194304' - -SETTING2_V1 = 'memory.soft_limit_in_bytes' -SETTING2_V2 = 'memory.high' -VALUE2 = '4096000' - -EXPECTED_OUT = '''{}: -{} -{} - -{}: -{} -{} -'''.format(CGNAME1, VALUE1, VALUE2, CGNAME2, VALUE1, VALUE2) - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME1) - Cgroup.create(config, CONTROLLER, CGNAME2) - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - Cgroup.set(config, CGNAME1, SETTING1_V1, VALUE1) - Cgroup.set(config, CGNAME1, SETTING2_V1, VALUE2) - Cgroup.set(config, CGNAME2, SETTING1_V1, VALUE1) - Cgroup.set(config, CGNAME2, SETTING2_V1, VALUE2) - elif version == CgroupVersion.CGROUP_V2: - Cgroup.set(config, CGNAME1, SETTING1_V2, VALUE1) - Cgroup.set(config, CGNAME1, SETTING2_V2, VALUE2) - Cgroup.set(config, CGNAME2, SETTING1_V2, VALUE1) - Cgroup.set(config, CGNAME2, SETTING2_V2, VALUE2) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - version = CgroupVersion.get_version(CONTROLLER) - - if version == CgroupVersion.CGROUP_V1: - settings = [SETTING1_V1, SETTING2_V1] - elif version == CgroupVersion.CGROUP_V2: - settings = [SETTING1_V2, SETTING2_V2] - - out = Cgroup.get(config, controller=None, cgname=[CGNAME1, CGNAME2], - setting=settings, values_only=True) - - for line_num, line in enumerate(out.splitlines()): - if line.strip() != EXPECTED_OUT.splitlines()[line_num].strip(): - result = consts.TEST_FAILED - cause = ( - 'Expected line:\n\t{}\nbut received line:\n\t{}' - ''.format(EXPECTED_OUT.splitlines()[line_num].strip(), - line.strip()) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME1) - Cgroup.delete(config, CONTROLLER, CGNAME2) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/013-cgget-multiple_g_flags.py b/lib/libcgroup-3.1.0/tests/ftests/013-cgget-multiple_g_flags.py deleted file mode 100755 index da0d2697181..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/013-cgget-multiple_g_flags.py +++ /dev/null @@ -1,225 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - multiple '-g' flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER1 = 'pids' -CONTROLLER2 = 'cpu' -CGNAME = '013cgget' - -EXPECTED_OUT_V1 = [ - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with cfs_bandwidth without cpu.stat nr_busts, burst_time - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with cfs_bandwidth with cpu.stat nr_busts, burst_time - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.cfs_burst_us: 0 - cpu.cfs_period_us: 100000 - cpu.stat: nr_periods 0 - nr_throttled 0 - throttled_time 0 - nr_bursts 0 - burst_time 0 - cpu.shares: 1024 - cpu.idle: 0 - cpu.cfs_quota_us: -1 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''' -] - -EXPECTED_OUT_V2 = [ - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth without cpu.stat nr_busts, burst_time - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''', - # with PSI, cfs_bandwidth with cpu.stat nr_busts, burst_time - '''013cgget: - pids.current: 0 - pids.events: max 0 - pids.max: max - cpu.weight: 100 - cpu.stat: usage_usec 0 - user_usec 0 - system_usec 0 - nr_periods 0 - nr_throttled 0 - throttled_usec 0 - nr_bursts 0 - burst_usec 0 - cpu.weight.nice: 0 - cpu.pressure: some avg10=0.00 avg60=0.00 avg300=0.00 total=0 - full avg10=0.00 avg60=0.00 avg300=0.00 total=0 - cpu.idle: 0 - cpu.max.burst: 0 - cpu.max: max 100000 - cpu.uclamp.min: 0.00 - cpu.uclamp.max: max''' -] - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER1, CGNAME) - Cgroup.create(config, CONTROLLER2, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=[CONTROLLER1, CONTROLLER2], - cgname=CGNAME) - - version = CgroupVersion.get_version(CONTROLLER1) - - if version == CgroupVersion.CGROUP_V1: - for expected_out in EXPECTED_OUT_V1: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - elif version == CgroupVersion.CGROUP_V2: - for expected_out in EXPECTED_OUT_V2: - if len(out.splitlines()) == len(expected_out.splitlines()): - break - - if len(out.splitlines()) != len(expected_out.splitlines()): - result = consts.TEST_FAILED - cause = ( - 'Expected {} lines but received {} lines' - ''.format(len(expected_out.splitlines()), - len(out.splitlines())) - ) - return result, cause - - for line_num, line in enumerate(out.splitlines()): - if line.strip() != expected_out.splitlines()[line_num].strip(): - result = consts.TEST_FAILED - cause = ( - 'Expected line:\n\t{}\nbut received line:\n\t{}' - ''.format(expected_out.splitlines()[line_num].strip(), - line.strip()) - ) - return result, cause - - return result, cause - - -def teardown(config): - ver1 = CgroupVersion.get_version(CONTROLLER1) - ver2 = CgroupVersion.get_version(CONTROLLER2) - - if ver1 == CgroupVersion.CGROUP_V2 and \ - ver2 == CgroupVersion.CGROUP_V2: - # If both controllers are cgroup v2, then we only need to delete - # one cgroup. The path will be the same for both - Cgroup.delete(config, [CONTROLLER1, CONTROLLER2], CGNAME) - else: - Cgroup.delete(config, CONTROLLER1, CGNAME) - Cgroup.delete(config, CONTROLLER2, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/014-cgget-a_flag.py b/lib/libcgroup-3.1.0/tests/ftests/014-cgget-a_flag.py deleted file mode 100755 index 145135513a5..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/014-cgget-a_flag.py +++ /dev/null @@ -1,98 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - exercise the '-a' flag -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER1 = 'memory' -CONTROLLER2 = 'cpuset' -CGNAME = '014cgget' - - -def prereqs(config): - pass - - -def setup(config): - ver1 = CgroupVersion.get_version(CONTROLLER1) - ver2 = CgroupVersion.get_version(CONTROLLER2) - - if ver1 == CgroupVersion.CGROUP_V2 and \ - ver2 == CgroupVersion.CGROUP_V2: - # If both controllers are cgroup v2, then we only need to make - # one cgroup. The path will be the same for both - Cgroup.create(config, [CONTROLLER1, CONTROLLER2], CGNAME) - else: - Cgroup.create(config, CONTROLLER1, CGNAME) - Cgroup.create(config, CONTROLLER2, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, cgname=CGNAME, all_controllers=True) - - # arbitrary check to ensure we read several lines - if len(out.splitlines()) < 20: - result = consts.TEST_FAILED - cause = ( - 'Expected multiple lines, but only received {}' - ''.format(len(out.splitlines())) - ) - return result, cause - - # arbitrary check for a setting that's in both cgroup v1 and cgroup v2 - # memory.stat - if '\tpgmajfault' not in out: - result = consts.TEST_FAILED - cause = 'Unexpected output\n{}'.format(out) - return result, cause - - # make sure that a cpuset value was in the output: - if 'cpuset.cpus' not in out: - result = consts.TEST_FAILED - cause = 'Failed to find cpuset settings in output\n{}'.format(out) - - return result, cause - - -def teardown(config): - ver1 = CgroupVersion.get_version(CONTROLLER1) - ver2 = CgroupVersion.get_version(CONTROLLER2) - - if ver1 == CgroupVersion.CGROUP_V2 and \ - ver2 == CgroupVersion.CGROUP_V2: - # If both controllers are cgroup v2, then we only need to make - # one cgroup. The path will be the same for both - Cgroup.delete(config, [CONTROLLER1, CONTROLLER2], CGNAME) - else: - Cgroup.delete(config, CONTROLLER1, CGNAME) - Cgroup.delete(config, CONTROLLER2, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/015-cgget-multiline_r_flag.py b/lib/libcgroup-3.1.0/tests/ftests/015-cgget-multiline_r_flag.py deleted file mode 100755 index 388a0e10e1d..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/015-cgget-multiline_r_flag.py +++ /dev/null @@ -1,76 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - get a multiline value via the '-r' flag -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME = '015cgget' - -SETTING = 'memory.stat' -VALUE = '512' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=None, cgname=CGNAME, - setting=SETTING, print_headers=True, - values_only=False) - - # arbitrary check to ensure we read several lines - if len(out.splitlines()) < 10: - result = consts.TEST_FAILED - cause = ( - 'Expected multiple lines, but only received {}' - ''.format(len(out.splitlines())) - ) - return result, cause - - # arbitrary check for a setting that's in both cgroup v1 and cgroup v2 - # memory.stat - if '\tunevictable' not in out: - result = consts.TEST_FAILED - cause = 'Unexpected output\n{}'.format(out) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/016-cgget-invalid_options.py b/lib/libcgroup-3.1.0/tests/ftests/016-cgget-invalid_options.py deleted file mode 100755 index 2fd80f6f181..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/016-cgget-invalid_options.py +++ /dev/null @@ -1,217 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - multiple '-g' flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '016cgget' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - # Github Actions has issues with cgget and the code coverage profiler. - # This causes issues with the error handling of this test - if not config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test must be run within a container' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - try: - # cgget -g cpu - Cgroup.get(config, controller=CONTROLLER) - except RunError as re: - if 'Wrong input parameters,' not in re.stderr: - result = consts.TEST_FAILED - cause = "#1 Expected 'Wrong input parameters' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#1 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #1 erroneously passed' - return result, cause - - try: - # cgget -g cpu:016cgget 016cgget - Cgroup.get(config, controller='{}:{}'.format(CONTROLLER, CGNAME), - cgname=CGNAME) - except RunError as re: - if 'Wrong input parameters,' not in re.stderr: - result = consts.TEST_FAILED - cause = "#2 Expected 'Wrong input parameters' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#2 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #2 erroneously passed' - return result, cause - - try: - # cgget -r invalidsetting 016cgget - Cgroup.get(config, setting='invalidsetting', cgname=CGNAME, - print_headers=False, values_only=True) - except RunError as re: - if 'cgget: error parsing parameter name' not in re.stderr: - result = consts.TEST_FAILED - cause = ( - "#3 Expected 'cgget: error parsing parameter name' to " - "be in stderr" - ) - return result, cause - - # legacy cgget returns 0 but populates stderr for this case. - # This feels wrong, so the updated cgget returns ECGINVAL - if re.ret != 91 and re.ret != 0: - result = consts.TEST_FAILED - cause = ( - '#3 Expected return code of 0 or 91 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #3 erroneously passed' - return result, cause - - try: - # cgget -r invalid.setting 016cgget - Cgroup.get(config, setting='invalid.setting', cgname=CGNAME, - print_headers=False, values_only=True) - except RunError as re: - if 'cgget: cannot find controller' not in re.stderr: - result = consts.TEST_FAILED - cause = ( - "#4 Expected 'cgget: cannot find controller' to be in " - "stderr" - ) - return result, cause - - # legacy cgget returns 0 but populates stderr for this case. - # This feels wrong, so the updated cgget returns ECGOTHER - if re.ret != 96 and re.ret != 0: - result = consts.TEST_FAILED - cause = ( - '#4 Expected return code of 0 or 96 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #4 erroneously passed' - return result, cause - - try: - # cgget -r cpu.invalid 016cgget - Cgroup.get(config, setting='{}.invalid'.format(CONTROLLER), - cgname=CGNAME, print_headers=False, values_only=True) - except RunError as re: - if 'variable file read failed' not in re.stderr: - result = consts.TEST_FAILED - cause = "#5 Expected 'variable file read failed' to be in stderr" - return result, cause - - # legacy cgget returns 0 but populates stderr for this case. - # This feels wrong, so the updated cgget returns ECGOTHER - if re.ret != 96 and re.ret != 0: - result = consts.TEST_FAILED - cause = ( - '#5 Expected return code of 0 or 96 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #5 erroneously passed' - return result, cause - - try: - # cgget with no parameters - Cgroup.get(config, controller=None, cgname=None, setting=None, - print_headers=True, values_only=False, - all_controllers=False, cghelp=False) - except RunError as re: - if 'Wrong input parameters,' not in re.stderr: - result = consts.TEST_FAILED - cause = "#6 Expected 'Wrong input parameters' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#6 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #6 erroneously passed' - return result, cause - - # cgget -h - ret = Cgroup.get(config, cghelp=True) - if 'Print parameter(s)' not in ret: - result = consts.TEST_FAILED - cause = '#7 Failed to print help text' - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/017-cgconfig-load_file.py b/lib/libcgroup-3.1.0/tests/ftests/017-cgconfig-load_file.py deleted file mode 100755 index 8ab58eb1c79..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/017-cgconfig-load_file.py +++ /dev/null @@ -1,86 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser functionality test using a configuration file -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '017cgconfig' -CFS_PERIOD = '500000' -CFS_QUOTA = '100000' -SHARES = '999' - -CONFIG_FILE = '''group -{} {{ - {} {{ - cpu.cfs_period_us = {}; - cpu.cfs_quota_us = {}; - cpu.shares = {}; - }} -}}'''.format(CGNAME, CONTROLLER, CFS_PERIOD, CFS_QUOTA, SHARES) - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '017cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - - return result, cause - - -def setup(config): - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - -def test(config): - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - Cgroup.get_and_validate(config, CGNAME, 'cpu.cfs_period_us', CFS_PERIOD) - Cgroup.get_and_validate(config, CGNAME, 'cpu.cfs_quota_us', CFS_QUOTA) - Cgroup.get_and_validate(config, CGNAME, 'cpu.shares', SHARES) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - os.remove(CONFIG_FILE_NAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/018-cgconfig-load_dir.py b/lib/libcgroup-3.1.0/tests/ftests/018-cgconfig-load_dir.py deleted file mode 100755 index 4f9dfa71e80..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/018-cgconfig-load_dir.py +++ /dev/null @@ -1,109 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser functionality test using a configuration directory -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CPU_CTRL = 'cpu' -MEMORY_CTRL = 'memory' -CGNAME = '018cgconfig' -CFS_PERIOD = '400000' -CFS_QUOTA = '50000' -SHARES = '123' - -LIMIT_IN_BYTES = '409600' -SOFT_LIMIT_IN_BYTES = '376832' - -CONFIG_FILE = '''group -{} {{ - {} {{ - cpu.cfs_period_us = {}; - cpu.cfs_quota_us = {}; - cpu.shares = {}; - }} - {} {{ - memory.limit_in_bytes = {}; - memory.soft_limit_in_bytes = {}; - }} -}}'''.format(CGNAME, CPU_CTRL, CFS_PERIOD, CFS_QUOTA, SHARES, - MEMORY_CTRL, LIMIT_IN_BYTES, SOFT_LIMIT_IN_BYTES) - -CONFIG_FILE_DIR = os.path.join(os.getcwd(), '018cgconfig') -CONFIG_FILE_NAME = os.path.join(CONFIG_FILE_DIR, 'cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - - return result, cause - - -def setup(config): - os.mkdir(CONFIG_FILE_DIR) - - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - -def test(config): - Cgroup.configparser(config, load_dir=CONFIG_FILE_DIR) - - Cgroup.get_and_validate(config, CGNAME, 'cpu.cfs_period_us', CFS_PERIOD) - Cgroup.get_and_validate(config, CGNAME, 'cpu.cfs_quota_us', CFS_QUOTA) - Cgroup.get_and_validate(config, CGNAME, 'cpu.shares', SHARES) - Cgroup.get_and_validate(config, CGNAME, 'memory.limit_in_bytes', - LIMIT_IN_BYTES) - Cgroup.get_and_validate(config, CGNAME, 'memory.soft_limit_in_bytes', - SOFT_LIMIT_IN_BYTES) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CPU_CTRL, CGNAME) - Cgroup.delete(config, MEMORY_CTRL, CGNAME) - os.remove(CONFIG_FILE_NAME) - os.rmdir(CONFIG_FILE_DIR) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/019-cgconfig-uidgid_dperm_fperm.py b/lib/libcgroup-3.1.0/tests/ftests/019-cgconfig-uidgid_dperm_fperm.py deleted file mode 100755 index 2d99777df90..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/019-cgconfig-uidgid_dperm_fperm.py +++ /dev/null @@ -1,136 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser functionality test - '-a', '-d', '-f' flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from container import ContainerError -from run import Run, RunError -from cgroup import Cgroup -import consts -import ftests -import utils -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '019cgconfig' - -CONFIG_FILE = '''group -{} {{ - {} {{ - }} -}}'''.format(CGNAME, CONTROLLER) - -USER = 'cguser019' -GROUP = 'cggroup019' -DPERM = '515' -FPERM = '246' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '019cgconfig.conf') - - -def prereqs(config): - pass - - -def setup(config): - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - if config.args.container: - config.container.run(['useradd', '-p', 'Test019#1', USER]) - config.container.run(['groupadd', GROUP]) - else: - Run.run(['sudo', 'useradd', '-p', 'Test019#1', USER]) - Run.run(['sudo', 'groupadd', '-f', GROUP]) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME, dflt_usr=USER, - dflt_grp=GROUP, dperm=DPERM, fperm=FPERM) - - mnt_path = Cgroup.get_controller_mount_point(CONTROLLER) - cpus_path = os.path.join(mnt_path, CGNAME, 'cpuset.cpus') - - user = utils.get_file_owner_username(config, cpus_path) - group = utils.get_file_owner_group_name(config, cpus_path) - - if user != USER: - result = consts.TEST_FAILED - cause = ( - 'Owner name failed. Expected {}, received {}\n' - ''.format(USER, user) - ) - return result, cause - - if group != GROUP: - result = consts.TEST_FAILED - cause = ( - 'Owner group failed. Expected {}, received {}\n' - ''.format(GROUP, group) - ) - return result, cause - - fperm = utils.get_file_permissions(config, cpus_path) - if fperm != FPERM: - result = consts.TEST_FAILED - cause = ( - 'File permissions failed. Expected {}, received {}\n' - ''.format(FPERM, fperm) - ) - return result, cause - - dperm = utils.get_file_permissions(config, os.path.join(mnt_path, CGNAME)) - if dperm != DPERM: - result = consts.TEST_FAILED - cause = ( - 'Directory permissions failed. Expected {}, received {}\n' - ''.format(DPERM, dperm) - ) - - return result, cause - - -def teardown(config): - os.remove(CONFIG_FILE_NAME) - - try: - if config.args.container: - config.container.run(['userdel', USER]) - config.container.run(['groupdel', GROUP]) - else: - Run.run(['sudo', 'userdel', '-r', USER]) - Run.run(['sudo', 'groupdel', GROUP]) - except (ContainerError, RunError, ValueError): - pass - - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/020-cgconfig-tasks_perms_owner.py b/lib/libcgroup-3.1.0/tests/ftests/020-cgconfig-tasks_perms_owner.py deleted file mode 100755 index 19ed057b19d..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/020-cgconfig-tasks_perms_owner.py +++ /dev/null @@ -1,135 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser functionality test - '-s', '-t', flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from container import ContainerError -from run import Run, RunError -import consts -import ftests -import utils -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '020cgconfig' - -CONFIG_FILE = '''group -{} {{ - {} {{ - }} -}}'''.format(CGNAME, CONTROLLER) - -USER = 'cguser020' -GROUP = 'cggroup020' -TPERM = '642' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '020cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpuset') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpuset controller' - - return result, cause - - -def setup(config): - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - if config.args.container: - config.container.run(['useradd', '-p', 'Test020#1', USER]) - config.container.run(['groupadd', GROUP]) - else: - Run.run(['sudo', 'useradd', '-p', 'Test020#1', USER]) - Run.run(['sudo', 'groupadd', '-f', GROUP]) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME, tperm=TPERM, - tasks_usr=USER, tasks_grp=GROUP) - - mnt_path = Cgroup.get_controller_mount_point(CONTROLLER) - tasks_path = os.path.join(mnt_path, CGNAME, 'tasks') - - user = utils.get_file_owner_username(config, tasks_path) - group = utils.get_file_owner_group_name(config, tasks_path) - - if user != USER: - result = consts.TEST_FAILED - cause = ( - 'Owner name failed. Expected {}, received {}\n' - ''.format(USER, user) - ) - return result, cause - - if group != GROUP: - result = consts.TEST_FAILED - cause = ( - 'Owner group failed. Expected {}, received {}\n' - ''.format(GROUP, group) - ) - return result, cause - - tperm = utils.get_file_permissions(config, tasks_path) - if tperm != TPERM: - result = consts.TEST_FAILED - cause = ( - 'File permissions failed. Expected {}, received {}\n' - ''.format(TPERM, tperm) - ) - - return result, cause - - -def teardown(config): - os.remove(CONFIG_FILE_NAME) - - try: - if config.args.container: - config.container.run(['userdel', USER]) - config.container.run(['groupdel', GROUP]) - else: - Run.run(['sudo', 'userdel', '-r', USER]) - Run.run(['sudo', 'groupdel', GROUP]) - except (ContainerError, RunError, ValueError): - pass - - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/021-cgconfig-invalid_options.py b/lib/libcgroup-3.1.0/tests/ftests/021-cgconfig-invalid_options.py deleted file mode 100755 index bac84ebc9ae..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/021-cgconfig-invalid_options.py +++ /dev/null @@ -1,93 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser functionality test - invalid and help options -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '021cgconfig' - -CONFIG_FILE = '''group -{} {{ - {} {{ - cpuset.cpus = abc123; - }} -}}'''.format(CGNAME, CONTROLLER) - -USER = 'cguser021' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '021cgconfig.conf') - - -def prereqs(config): - pass - - -def setup(config): - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - -def test(config): - result = consts.TEST_PASSED - cause = None - - ret = Cgroup.configparser(config, cghelp=True) - if 'Parse and load the specified cgroups' not in ret: - result = consts.TEST_FAILED - cause = 'Failed to print cgconfigparser help text' - return result, cause - - try: - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - except RunError as re: - if 'Invalid argument' not in re.stderr: - result = consts.TEST_FAILED - cause = "Expected 'Invalid argument' to be in stderr" - return result, cause - - if re.ret != 96: - result = consts.TEST_FAILED - cause = 'Expected return code of 96 but received {}'.format(re.ret) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case erroneously passed' - - return result, cause - - -def teardown(config): - os.remove(CONFIG_FILE_NAME) - - -def main(config): - prereqs(config) - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/022-cgset-multiple_r_flag.py b/lib/libcgroup-3.1.0/tests/ftests/022-cgset-multiple_r_flag.py deleted file mode 100755 index 6d139307902..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/022-cgset-multiple_r_flag.py +++ /dev/null @@ -1,71 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - set multiple values via the '-r' flag -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME = '022cgset' - -SETTINGS = ['memory.limit_in_bytes', - 'memory.soft_limit_in_bytes', - 'memory.swappiness'] -VALUES = ['1024000', '512000', '55'] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - Cgroup.set(config, cgname=CGNAME, setting=SETTINGS, value=VALUES) - - for i, setting in enumerate(SETTINGS): - Cgroup.get_and_validate(config, CGNAME, setting, VALUES[i]) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/023-cgset-copy_from.py b/lib/libcgroup-3.1.0/tests/ftests/023-cgset-copy_from.py deleted file mode 100755 index 6fa2ff282a3..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/023-cgset-copy_from.py +++ /dev/null @@ -1,75 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - test the '--copy-from' option -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -SRC_CGNAME = '023cgsetsrc' -DST_CGNAME = '023cgsetdst' - -SETTINGS = ['memory.limit_in_bytes', - 'memory.soft_limit_in_bytes', - 'memory.swappiness'] -VALUES = ['122880', '40960', '42'] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, SRC_CGNAME) - Cgroup.create(config, CONTROLLER, DST_CGNAME) - Cgroup.set(config, cgname=SRC_CGNAME, setting=SETTINGS, value=VALUES) - - -def test(config): - Cgroup.set(config, cgname=DST_CGNAME, copy_from=SRC_CGNAME) - - for i, setting in enumerate(SETTINGS): - Cgroup.get_and_validate(config, DST_CGNAME, setting, VALUES[i]) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, SRC_CGNAME) - Cgroup.delete(config, CONTROLLER, DST_CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/025-cgset-multiple_cgroups.py b/lib/libcgroup-3.1.0/tests/ftests/025-cgset-multiple_cgroups.py deleted file mode 100755 index dab2f72ecc1..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/025-cgset-multiple_cgroups.py +++ /dev/null @@ -1,72 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - set multiple cgroups' values -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAME1 = '025cgset1' -CGNAME2 = '025cgset2' - -SETTING = 'memory.swappiness' -VALUE = '42' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME1) - Cgroup.create(config, CONTROLLER, CGNAME2) - - -def test(config): - Cgroup.set(config, cgname=[CGNAME1, CGNAME2], setting=SETTING, value=VALUE) - - Cgroup.get_and_validate(config, CGNAME1, SETTING, VALUE) - Cgroup.get_and_validate(config, CGNAME2, SETTING, VALUE) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME1) - Cgroup.delete(config, CONTROLLER, CGNAME2) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/026-cgset-multiple_r_multiple_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/026-cgset-multiple_r_multiple_cgroup.py deleted file mode 100755 index 1d60bb27df4..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/026-cgset-multiple_r_multiple_cgroup.py +++ /dev/null @@ -1,75 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - set multiple values in multiple cgroups -# via the '-r' flag -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'memory' -CGNAMES = ['026cgset1', '026cgset2'] - -SETTINGS = ['memory.limit_in_bytes', - 'memory.soft_limit_in_bytes', - 'memory.swappiness'] -VALUES = ['2048000', '1024000', '89'] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('memory') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 memory controller' - - return result, cause - - -def setup(config): - for cg in CGNAMES: - Cgroup.create(config, CONTROLLER, cg) - - -def test(config): - Cgroup.set(config, cgname=CGNAMES, setting=SETTINGS, value=VALUES) - - for i, setting in enumerate(SETTINGS): - for cg in CGNAMES: - Cgroup.get_and_validate(config, cg, setting, VALUES[i]) - - return consts.TEST_PASSED, None - - -def teardown(config): - for cg in CGNAMES: - Cgroup.delete(config, CONTROLLER, cg) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/027-cgset-invalid_options.py b/lib/libcgroup-3.1.0/tests/ftests/027-cgset-invalid_options.py deleted file mode 100755 index c284ab927eb..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/027-cgset-invalid_options.py +++ /dev/null @@ -1,170 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - invalid options -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME1 = '027cgset1' -CGNAME2 = '027cgset2' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME1) - Cgroup.create(config, CONTROLLER, CGNAME2) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - try: - # cgset -r cpu.shares=100 --copy-from 027cgset2 027cgset1 - Cgroup.set(config, cgname=CGNAME1, setting='cpu.shares', value='100', - copy_from=CGNAME2) - except RunError as re: - if 'Wrong input parameters,' not in re.stderr: - result = consts.TEST_FAILED - cause = "#1 Expected 'Wrong input parameters' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#1 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #1 erroneously passed' - return result, cause - - try: - # cgset -r cpu.shares=100 - Cgroup.set(config, cgname=None, setting='cpu.shares', value='100') - except RunError as re: - if 'cgset: no cgroup specified' not in re.stderr: - result = consts.TEST_FAILED - cause = "#2 Expected 'no cgroup specified' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#2 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #2 erroneously passed' - return result, cause - - try: - # cgset 027cgset1 - Cgroup.set(config, cgname=CGNAME1) - except RunError as re: - if 'cgset: no name-value pair was set' not in re.stderr: - result = consts.TEST_FAILED - cause = "#3 Expected 'no name-value pair' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#3 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #3 erroneously passed' - return result, cause - - try: - # cgset - no flags provided - Cgroup.set(config) - except RunError as re: - if 'Usage is' not in re.stderr: - result = consts.TEST_FAILED - cause = "#4 Expected 'Usage is' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#4 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #4 erroneously passed' - return result, cause - - try: - # cgset -r cpu.shares= 027cgset1 - Cgroup.set(config, cgname=CGNAME1, setting='cpu.shares', value='') - except RunError as re: - if 'wrong parameter of option -r' not in re.stderr: - result = consts.TEST_FAILED - cause = "#5 Expected 'Wrong parameter of option' to be in stderr" - return result, cause - - if re.ret != 129: - result = consts.TEST_FAILED - cause = ( - '#5 Expected return code of 129 but received {}' - ''.format(re.ret) - ) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Test case #5 erroneously passed' - return result, cause - - # cgset -h - ret = Cgroup.set(config, cghelp=True) - if 'Usage:' not in ret: - result = consts.TEST_FAILED - cause = '#6 Failed to print help text' - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME1) - Cgroup.delete(config, CONTROLLER, CGNAME2) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/029-lssubsys-basic_lssubsys.py b/lib/libcgroup-3.1.0/tests/ftests/029-lssubsys-basic_lssubsys.py deleted file mode 100755 index 756c64bb239..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/029-lssubsys-basic_lssubsys.py +++ /dev/null @@ -1,86 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Basic lssubsys functionality test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - - -def prereqs(config): - pass - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - mount_list = Cgroup.get_cgroup_mounts(config, expand_v2_mounts=False) - - # cgroup v2 mounts won't show up unless '-a' is specified - lssubsys_list = Cgroup.lssubsys(config, ls_all=False) - - for mount in mount_list: - if mount.version == CgroupVersion.CGROUP_V2: - continue - - if mount.controller == 'name=systemd' or mount.controller == 'systemd': - continue - - found = False - for lsmount in lssubsys_list.splitlines(): - if ',' in lsmount: - for ctrl in lsmount.split(','): - if ctrl == mount.controller: - found = True - break - - if lsmount == mount.controller: - found = True - break - - if not found: - result = consts.TEST_FAILED - cause = ( - 'Failed to find {} in lssubsys list' - ''.format(mount.controller) - ) - return result, cause - - return result, cause - - -def teardown(config): - pass - - -def main(config): - prereqs(config) - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/030-lssubsys-lssubsys_all.py b/lib/libcgroup-3.1.0/tests/ftests/030-lssubsys-lssubsys_all.py deleted file mode 100755 index c83587d83dc..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/030-lssubsys-lssubsys_all.py +++ /dev/null @@ -1,92 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# 'lssubsys -a' test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -import consts -import ftests -import sys -import os - - -def prereqs(config): - pass - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - mount_list = Cgroup.get_cgroup_mounts(config, expand_v2_mounts=True) - - # cgroup v2 mounts won't show up unless '-a' is specified - lssubsys_list = Cgroup.lssubsys(config, ls_all=True) - - for mount in mount_list: - if mount.controller == 'name=systemd' or mount.controller == 'systemd': - continue - - found = False - for lsmount in lssubsys_list.splitlines(): - if ',' in lsmount: - for ctrl in lsmount.split(','): - if ctrl == mount.controller: - found = True - break - - if lsmount == mount.controller: - found = True - break - - if lsmount == 'blkio' and mount.controller == 'io': - found = True - break - - if not found: - result = consts.TEST_FAILED - cause = ( - 'Failed to find {} in lssubsys list' - ''.format(mount.controller) - ) - return result, cause - - ret = Cgroup.lssubsys(config, cghelp=True) - if 'Usage:' not in ret: - result = consts.TEST_FAILED - cause = 'Failed to print help text' - - return result, cause - - -def teardown(config): - pass - - -def main(config): - prereqs(config) - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/031-lscgroup-g_flag.py b/lib/libcgroup-3.1.0/tests/ftests/031-lscgroup-g_flag.py deleted file mode 100755 index 334a3e99636..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/031-lscgroup-g_flag.py +++ /dev/null @@ -1,109 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# lscgroup functionality test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import utils -import sys -import os - -CONTROLLER = 'cpuset' -PARENT_CGNAME = '031lscgroup' -CHILD_CGNAME = 'childlscgroup' -GRANDCHILD_CGNAME = 'grandchildlscgroup' - -# lscgroup is inconsistent in its handling of trailing slashes -# -# When invoking lscgroup with no flags, no trailing slashes are present in -# any of the cgroups. -# -# When invoking lscgroup with the -g flag, a trailing slash is present on -# the first cgroup returned (i.e. the cgroup specified in the -g flag) -# -EXPECTED_OUT1 = '''{}:/{}/ -{}:/{}/{} -{}:/{}/{}/{}'''.format(CONTROLLER, PARENT_CGNAME, - CONTROLLER, PARENT_CGNAME, CHILD_CGNAME, - CONTROLLER, PARENT_CGNAME, CHILD_CGNAME, - GRANDCHILD_CGNAME) - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - v2_cnt = 0 - mount_list = Cgroup.get_cgroup_mounts(config) - - for mount in mount_list: - if mount.version == CgroupVersion.CGROUP_V2: - v2_cnt += 1 - - if v2_cnt > 1: - # There is a bug in lscgroup - see issue #50 - where it doesn't - # properly list the enabled controllers for a cgroup v2 cgroup. - # Skip this test because of this - result = consts.TEST_SKIPPED - cause = 'See Github Issue #50 - lscgroup lists controllers...' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENT_CGNAME) - Cgroup.create( - config, CONTROLLER, os.path.join( - PARENT_CGNAME, CHILD_CGNAME) - ) - Cgroup.create(config, CONTROLLER, - os.path.join(PARENT_CGNAME, CHILD_CGNAME, GRANDCHILD_CGNAME)) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.lscgroup(config, controller=CONTROLLER, path=PARENT_CGNAME) - if out != EXPECTED_OUT1: - result = consts.TEST_FAILED - cause = ( - "Expected lscgroup output doesn't match received output\n'" - "Expected:\n{}\n" - "Received:\n{}\n" - "".format(utils.indent(EXPECTED_OUT1, 4), - utils.indent(out, 4)) - ) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, PARENT_CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/032-lscgroup-multiple_g_flags.py b/lib/libcgroup-3.1.0/tests/ftests/032-lscgroup-multiple_g_flags.py deleted file mode 100755 index 528c43d7918..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/032-lscgroup-multiple_g_flags.py +++ /dev/null @@ -1,124 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# lscgroup functionality test - multiple '-g' flags -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import utils -import sys -import os - -CONTROLLER = 'cpuset' -PARENT_CGNAME = '032lscgroup' -CHILD_CGNAME = 'childlscgroup' -GRANDCHILD_CGNAME = 'grandchildlscgroup' -SIBLING_CGNAME = '032sibling' -SIBLING_CHILD_CGNAME = 'cousinlscgroup' - -# lscgroup is inconsistent in its handling of trailing slashes -# -# When invoking lscgroup with no flags, no trailing slashes are present in -# any of the cgroups. -# -# When invoking lscgroup with the -g flag, a trailing slash is present on -# the first cgroup returned (i.e. the cgroup specified in the -g flag) -# -EXPECTED_OUT1 = '''{}:/{}/ -{}:/{}/{} -{}:/{}/{}/{} -{}:/{}/ -{}:/{}/{}'''.format(CONTROLLER, PARENT_CGNAME, - CONTROLLER, PARENT_CGNAME, CHILD_CGNAME, - CONTROLLER, PARENT_CGNAME, CHILD_CGNAME, GRANDCHILD_CGNAME, - CONTROLLER, SIBLING_CGNAME, - CONTROLLER, SIBLING_CGNAME, SIBLING_CHILD_CGNAME) - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - v2_cnt = 0 - mount_list = Cgroup.get_cgroup_mounts(config) - - for mount in mount_list: - if mount.version == CgroupVersion.CGROUP_V2: - v2_cnt += 1 - - if v2_cnt > 1: - # There is a bug in lscgroup - see issue #50 - where it doesn't - # properly list the enabled controllers for a cgroup v2 cgroup. - # Skip this test because of this - result = consts.TEST_SKIPPED - cause = 'See Github Issue #50 - lscgroup lists controllers...' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENT_CGNAME) - Cgroup.create(config, CONTROLLER, - os.path.join(PARENT_CGNAME, CHILD_CGNAME)) - Cgroup.create(config, CONTROLLER, - os.path.join(PARENT_CGNAME, CHILD_CGNAME, GRANDCHILD_CGNAME)) - - Cgroup.create(config, CONTROLLER, SIBLING_CGNAME) - Cgroup.create(config, CONTROLLER, - os.path.join(SIBLING_CGNAME, SIBLING_CHILD_CGNAME)) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.lscgroup(config, controller=[CONTROLLER, CONTROLLER], - path=[PARENT_CGNAME, SIBLING_CGNAME]) - if out != EXPECTED_OUT1: - result = consts.TEST_FAILED - cause = ( - "Expected lscgroup output doesn't match received output\n" - "Expected:\n{}\n" - "Received:\n{}\n" - "".format(utils.indent(EXPECTED_OUT1, 4), - utils.indent(out, 4)) - ) - return result, cause - - ret = Cgroup.lscgroup(config, cghelp=True) - if 'Usage:' not in ret: - result = consts.TEST_FAILED - cause = 'Failed to print help text' - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, PARENT_CGNAME, recursive=True) - Cgroup.delete(config, CONTROLLER, SIBLING_CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/033-cgget-no_flags.py b/lib/libcgroup-3.1.0/tests/ftests/033-cgget-no_flags.py deleted file mode 100755 index 114cdf3340b..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/033-cgget-no_flags.py +++ /dev/null @@ -1,71 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - no flags, only a cgroup -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '033cgget' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=None, cgname=CGNAME) - - if out.splitlines()[0] != '{}:'.format(CGNAME): - result = consts.TEST_FAILED - cause = ( - 'cgget expected the cgroup name {} in the first line.\n' - 'Instead it received {}' - ''.format(CGNAME, out.splitlines()[0]) - ) - - if len(out.splitlines()) < 5: - result = consts.TEST_FAILED - cause = ( - 'Too few lines output by cgget. Received {} lines' - ''.format(len(out.splitlines())) - ) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/034-cgexec-basic_cgexec.py b/lib/libcgroup-3.1.0/tests/ftests/034-cgexec-basic_cgexec.py deleted file mode 100755 index b3a07471f5b..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/034-cgexec-basic_cgexec.py +++ /dev/null @@ -1,84 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup cgexec test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from process import Process -from cgroup import Cgroup -import consts -import ftests -import sys -import os - - -CONTROLLER = 'cpuset' -CGNAME = '034cgexec' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - if not config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test must be run within a container' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, - cgclassify=False) - - pids = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - if pids is None: - result = consts.TEST_FAILED - cause = 'No processes were found in cgroup {}'.format(CGNAME) - return result, cause - - # run cgexec -h - ret = Cgroup.cgexec(config, controller=CONTROLLER, cgname=CGNAME, - cmdline=None, cghelp=True) - if 'Run the task in given control group(s)' not in ret: - result = consts.TEST_FAILED - cause = 'Failed to print cgexec help text: {}'.format(ret) - - return result, cause - - -def teardown(config): - pids = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - Process.kill(config, pids) - - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/035-cgset-set_cgroup_type.py b/lib/libcgroup-3.1.0/tests/ftests/035-cgset-set_cgroup_type.py deleted file mode 100755 index 42ce71d57fb..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/035-cgset-set_cgroup_type.py +++ /dev/null @@ -1,75 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgget/cgset cgroup.type functionality test -# -# Copyright (c) 2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' -CGNAME = '035cgset' - -SETTING = 'cgroup.type' -BEFORE = 'domain' -AFTER = 'threaded' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - Cgroup.get_and_validate(config, CGNAME, SETTING, BEFORE) - - -def test(config): - Cgroup.set_and_validate(config, CGNAME, SETTING, AFTER) - - return consts.TEST_PASSED, None - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/036-cgset-multi_thread.py b/lib/libcgroup-3.1.0/tests/ftests/036-cgset-multi_thread.py deleted file mode 100755 index a736ff0b517..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/036-cgset-multi_thread.py +++ /dev/null @@ -1,94 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Multithreaded cgroup v2 test -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from process import Process -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -PARENT_CGNAME = '036threaded' -CHILD_CGPATH = os.path.join(PARENT_CGNAME, 'childcg') - -SETTING = 'cgroup.type' -AFTER = 'threaded' -THREADS = 3 - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENT_CGNAME) - Cgroup.create(config, CONTROLLER, CHILD_CGPATH) - - Cgroup.set_and_validate(config, CHILD_CGPATH, SETTING, AFTER) - - -def test(config): - config.process.create_threaded_process_in_cgroup( - config, CONTROLLER, PARENT_CGNAME, THREADS) - - threads = Cgroup.get(config, controller=None, cgname=PARENT_CGNAME, - setting='cgroup.threads', print_headers=False, - values_only=True) - threads = threads.replace('\n', '').split('\t') - -# #pick the first thread - thread_tid = threads[1] - - Cgroup.set_and_validate(config, CHILD_CGPATH, 'cgroup.threads', thread_tid) - - return consts.TEST_PASSED, None - - -def teardown(config): - # destroy the child processes - pids = Cgroup.get_pids_in_cgroup(config, PARENT_CGNAME, CONTROLLER) - Process.kill(config, pids) - - Cgroup.delete(config, CONTROLLER, PARENT_CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/037-cgxget-cpu_settings.py b/lib/libcgroup-3.1.0/tests/ftests/037-cgxget-cpu_settings.py deleted file mode 100755 index 20871e8684b..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/037-cgxget-cpu_settings.py +++ /dev/null @@ -1,106 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgxget functionality test - various cpu settings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '037cgxget' - -CGRP_VER_V1 = CgroupVersion.CGROUP_V1 -CGRP_VER_V2 = CgroupVersion.CGROUP_V2 - -TABLE = [ - # writesetting, writeval, writever, readsetting, readval, readver - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.shares', '512', CGRP_VER_V1], - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.weight', '50', CGRP_VER_V2], - - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.shares', '2048', CGRP_VER_V1], - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.weight', '200', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '10000', CGRP_VER_V1, - 'cpu.cfs_quota_us', '10000', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.cfs_period_us', '100000', CGRP_VER_V1], - ['cpu.cfs_period_us', '50000', CGRP_VER_V1, - 'cpu.max', '10000 50000', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '-1', CGRP_VER_V1, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.max', 'max 100000', CGRP_VER_V2], - - ['cpu.max', '5000 25000', CGRP_VER_V2, - 'cpu.max', '5000 25000', CGRP_VER_V2], - ['cpu.max', '6000 26000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '6000', CGRP_VER_V1], - ['cpu.max', '7000 27000', CGRP_VER_V2, - 'cpu.cfs_period_us', '27000', CGRP_VER_V1], - - ['cpu.max', 'max 40000', CGRP_VER_V2, - 'cpu.max', 'max 40000', CGRP_VER_V2], - ['cpu.max', 'max 41000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], -] - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - for entry in TABLE: - Cgroup.xset(config, cgname=CGNAME, setting=entry[0], value=entry[1], - version=entry[2]) - - out = Cgroup.xget(config, cgname=CGNAME, setting=entry[3], - version=entry[5], values_only=True, - print_headers=False) - if out != entry[4]: - result = consts.TEST_FAILED - cause = ( - 'After setting {}={}, expected {}={}, but received ' - '{}={}'.format(entry[0], entry[1], entry[3], entry[4], - entry[3], out) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/038-cgxget-cpuset_settings.py b/lib/libcgroup-3.1.0/tests/ftests/038-cgxget-cpuset_settings.py deleted file mode 100755 index 8af6d874e54..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/038-cgxget-cpuset_settings.py +++ /dev/null @@ -1,144 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgxget functionality test - various cpuset settings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -from run import Run, RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpuset' -CGNAME = '038cgxget' - -CGRP_VER_V1 = CgroupVersion.CGROUP_V1 -CGRP_VER_V2 = CgroupVersion.CGROUP_V2 - -TABLE = [ - # writesetting, writeval, writever, readsetting, readval, readver - ['cpuset.cpus', '0-1', CGRP_VER_V1, - 'cpuset.cpus', '0-1', CGRP_VER_V1], - ['cpuset.cpus', '0-1', CGRP_VER_V1, - 'cpuset.cpus', '0-1', CGRP_VER_V2], - ['cpuset.cpus', '0-1', CGRP_VER_V1, - 'cpuset.effective_cpus', '0-1', CGRP_VER_V1], - ['cpuset.cpus', '0-1', CGRP_VER_V1, - 'cpuset.cpus.effective', '0-1', CGRP_VER_V2], - ['cpuset.cpus', '1', CGRP_VER_V2, - 'cpuset.cpus', '1', CGRP_VER_V1], - ['cpuset.cpus', '1', CGRP_VER_V2, - 'cpuset.cpus', '1', CGRP_VER_V2], - - ['cpuset.mems', '0', CGRP_VER_V1, - 'cpuset.mems', '0', CGRP_VER_V1], - ['cpuset.mems', '0', CGRP_VER_V1, - 'cpuset.mems', '0', CGRP_VER_V2], - ['cpuset.mems', '0', CGRP_VER_V2, - 'cpuset.mems', '0', CGRP_VER_V1], - ['cpuset.mems', '0', CGRP_VER_V2, - 'cpuset.mems', '0', CGRP_VER_V2], - ['cpuset.mems', '0', CGRP_VER_V1, - 'cpuset.effective_mems', '0', CGRP_VER_V1], - ['cpuset.mems', '0', CGRP_VER_V1, - 'cpuset.mems.effective', '0', CGRP_VER_V2], - - ['cpuset.cpu_exclusive', '1', CGRP_VER_V1, - 'cpuset.cpu_exclusive', '1', CGRP_VER_V1], - ['cpuset.cpu_exclusive', '1', CGRP_VER_V1, - 'cpuset.cpus.partition', 'root', CGRP_VER_V2], - ['cpuset.cpu_exclusive', '0', CGRP_VER_V1, - 'cpuset.cpu_exclusive', '0', CGRP_VER_V1], - ['cpuset.cpu_exclusive', '0', CGRP_VER_V1, - 'cpuset.cpus.partition', 'member', CGRP_VER_V2], - - ['cpuset.cpus.partition', 'root', CGRP_VER_V2, - 'cpuset.cpu_exclusive', '1', CGRP_VER_V1], - ['cpuset.cpus.partition', 'root', CGRP_VER_V2, - 'cpuset.cpus.partition', 'root', CGRP_VER_V2], - ['cpuset.cpus.partition', 'member', CGRP_VER_V2, - 'cpuset.cpu_exclusive', '0', CGRP_VER_V1], - ['cpuset.cpus.partition', 'member', CGRP_VER_V2, - 'cpuset.cpus.partition', 'member', CGRP_VER_V2], -] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - nproc = Run.run('nproc') - if int(nproc) < 2: - result = consts.TEST_SKIPPED - cause = 'This test requires 2 or more processors' - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - for entry in TABLE: - try: - Cgroup.xset(config, cgname=CGNAME, setting=entry[0], - value=entry[1], version=entry[2]) - except RunError as re: - if re.stderr.find('Invalid argument') >= 0: - # The kernel disallowed this setting, likely due to the many - # complexities of exclusive cpusets - continue - raise re - - out = Cgroup.xget(config, cgname=CGNAME, setting=entry[3], - version=entry[5], values_only=True, - print_headers=False) - if out != entry[4]: - result = consts.TEST_FAILED - cause = ( - 'After setting {}={}, expected {}={}, but received ' - '{}={}' - ''.format(entry[0], entry[1], entry[3], entry[4], - entry[3], out) - ) - return result, cause - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/039-pybindings-cgxget.py b/lib/libcgroup-3.1.0/tests/ftests/039-pybindings-cgxget.py deleted file mode 100755 index 9e609e18c5e..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/039-pybindings-cgxget.py +++ /dev/null @@ -1,141 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgxget functionality test using the python bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from cgroup import CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '039bindings' - -SETTING1 = 'cpu.shares' -VALUE1 = '4096' - -SETTING2 = 'cpu.weight' -VALUE2 = '400' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLER, CGNAME) - if CgroupVersion.get_version('cpu') == CgroupVersion.CGROUP_V1: - CgroupCli.set(config, CGNAME, SETTING1, VALUE1) - else: - CgroupCli.set(config, CGNAME, SETTING2, VALUE2) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg1 = Cgroup(CGNAME, Version.CGROUP_V1) - cg1.add_controller(CONTROLLER) - cg1.add_setting(SETTING1) - - cg1.cgxget() - - if len(cg1.controllers) != 1: - result = consts.TEST_FAILED - cause = ( - "Controller length doesn't match, expected 1, but " - "received {}" - "".format(len(cg1.controllers)) - ) - return result, cause - - if len(cg1.controllers[CONTROLLER].settings) != 1: - result = consts.TEST_FAILED - cause = ( - "Settings length doesn't match, expected 1, but " - " received {}" - "".format(len(cg1.controllers[CONTROLLER].settings)) - ) - return result, cause - - if cg1.controllers[CONTROLLER].settings[SETTING1] != VALUE1: - result = consts.TEST_FAILED - cause = ( - 'Expected {} = {} but received {}' - ''.format(SETTING1, VALUE1, - cg1.controllers[CONTROLLER].settings[SETTING1]) - ) - return result, cause - - cg2 = Cgroup(CGNAME, Version.CGROUP_V2) - cg2.add_controller(CONTROLLER) - cg2.add_setting(SETTING2) - - cg2.cgxget() - - if len(cg2.controllers) != 1: - result = consts.TEST_FAILED - cause = ( - "Controller length doesn't match, expected 1, but" - " received {}" - "".format(len(cg2.controllers)) - ) - return result, cause - - if len(cg2.controllers[CONTROLLER].settings) != 1: - result = consts.TEST_FAILED - cause = ( - "Settings length doesn't match, expected 1, but" - "received {}" - "".format(len(cg2.controllers[CONTROLLER].settings)) - ) - return result, cause - - if cg2.controllers[CONTROLLER].settings[SETTING2] != VALUE2: - result = consts.TEST_FAILED - cause = ( - 'Expected {} = {} but received {}' - ''.format(SETTING2, VALUE2, - cg2.controllers[CONTROLLER].settings[SETTING2]) - ) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/040-pybindings-cgxset.py b/lib/libcgroup-3.1.0/tests/ftests/040-pybindings-cgxset.py deleted file mode 100755 index 8e392a45db9..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/040-pybindings-cgxset.py +++ /dev/null @@ -1,117 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgxset functionality test using the python bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import CgroupVersion as CgroupCliVersion -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from run import Run -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '040bindings' - -SETTING1 = 'cpu.shares' -VALUE1 = '512' - -SETTING2 = 'cpu.weight' -VALUE2 = '50' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - user_name = Run.run('whoami', shell_bool=True) - group_name = Run.run('groups', shell_bool=True).split(' ')[0] - - CgroupCli.create(config, controller_list=CONTROLLER, cgname=CGNAME, - user_name=user_name, group_name=group_name) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg1 = Cgroup(CGNAME, Version.CGROUP_V1) - cg1.add_controller(CONTROLLER) - cg1.add_setting(SETTING1, VALUE1) - - cg1.cgxset() - - value_v1 = CgroupCli.xget( - config, setting=SETTING1, print_headers=False, - values_only=True, - version=CgroupCliVersion.CGROUP_V1, - cgname=CGNAME - ) - - if value_v1 != VALUE1: - result = consts.TEST_FAILED - cause = 'Expected {}, but received {}'.format(VALUE1, value_v1) - return result, cause - - # Set the cpu.shares/cpu.weight to an arbitrary value to ensure - # the following v2 cgxset works properly - CgroupCli.xset(config, cgname=CGNAME, setting=SETTING1, value='1234', - version=CgroupCliVersion.CGROUP_V1) - - cg2 = Cgroup(CGNAME, Version.CGROUP_V2) - cg2.add_controller(CONTROLLER) - cg2.add_setting(SETTING2, VALUE2) - - cg2.cgxset() - - value_v2 = CgroupCli.xget( - config, setting=SETTING2, print_headers=False, - values_only=True, - version=CgroupCliVersion.CGROUP_V2, - cgname=CGNAME - ) - - if value_v2 != VALUE2: - result = consts.TEST_FAILED - cause = 'Expected {}, but received {}'.format(VALUE2, value_v2) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/041-pybindings-library_version.py b/lib/libcgroup-3.1.0/tests/ftests/041-pybindings-library_version.py deleted file mode 100755 index 313507884d8..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/041-pybindings-library_version.py +++ /dev/null @@ -1,67 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# get the library version using the python bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from libcgroup import Cgroup -import consts -import ftests -import sys -import os - - -def prereqs(config): - pass - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - [major, minor, release] = Cgroup.library_version() - - if not isinstance(major, int): - result = consts.TEST_FAILED - cause = 'Major version failed. Received {}'.format(major) - return result, cause - - if not isinstance(minor, int): - result = consts.TEST_FAILED - cause = 'Minor version failed. Received {}'.format(minor) - return result, cause - - if not isinstance(release, int): - result = consts.TEST_FAILED - cause = 'Release version failed. Received {}'.format(release) - - return result, cause - - -def teardown(config): - pass - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/042-cgxget-unmappable.py b/lib/libcgroup-3.1.0/tests/ftests/042-cgxget-unmappable.py deleted file mode 100755 index 9b865483fc5..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/042-cgxget-unmappable.py +++ /dev/null @@ -1,70 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgxget test with no mappable settings -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '042cgxget' -SETTING = 'cpu.stat' - - -def prereqs(config): - pass - - -def setup(config): - Cgroup.create(config, CONTROLLER, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) == CgroupVersion.CGROUP_V1: - # request the opposite version of what this system is running - requested_ver = CgroupVersion.CGROUP_V2 - else: - requested_ver = CgroupVersion.CGROUP_V1 - - out = Cgroup.xget( - config, cgname=CGNAME, setting=SETTING, - version=requested_ver, print_headers=False, - ignore_unmappable=True - ) - if len(out): - result = consts.TEST_FAILED - cause = 'Expected cgxget to return nothing. Received {}'.format(out) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME) - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/043-cgcreate-empty_controller.py b/lib/libcgroup-3.1.0/tests/ftests/043-cgcreate-empty_controller.py deleted file mode 100755 index bb0c487ba75..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/043-cgcreate-empty_controller.py +++ /dev/null @@ -1,75 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgcreate with no controller specified functionality test -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' -CGNAME = '043cgcreate' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.create(config, None, CGNAME) - - # verify the cgroup exists by reading cgroup.procs - Cgroup.get( - config, controller=None, cgname=CGNAME, - setting='cgroup.procs', print_headers=True, - values_only=False - ) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, None, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/044-pybindings-cgcreate_empty_controller.py b/lib/libcgroup-3.1.0/tests/ftests/044-pybindings-cgcreate_empty_controller.py deleted file mode 100755 index 1edc95c6d0e..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/044-pybindings-cgcreate_empty_controller.py +++ /dev/null @@ -1,85 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# empty cgcreate functionality test using the python bindings -# -# Copyright (c) 2021-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from cgroup import CgroupVersion -from run import Run -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -PARENT_NAME = '044cgcreate' -CGNAME = os.path.join(PARENT_NAME, 'madeviapython') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - user_name = Run.run('whoami', shell_bool=True) - group_name = Run.run('groups', shell_bool=True).split(' ')[0] - - CgroupCli.create(config, controller_list=CONTROLLER, cgname=PARENT_NAME, - user_name=user_name, group_name=group_name) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.create() - - # Read a valid file within the newly created cgroup. - # This should fail if the cgroup was not created successfully - cg.add_setting(setting_name='cgroup.procs') - cg.cgxget() - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, None, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/045-pybindings-list_mount_points.py b/lib/libcgroup-3.1.0/tests/ftests/045-pybindings-list_mount_points.py deleted file mode 100755 index f8a8b9ebe24..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/045-pybindings-list_mount_points.py +++ /dev/null @@ -1,69 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_list_mount_points functionality test using the python bindings -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from libcgroup import Cgroup, Version -import consts -import ftests -import sys -import os - -CGNAME = '045bindings' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - mount_points_v1 = Cgroup.mount_points(Version.CGROUP_V1) - mount_points_v2 = Cgroup.mount_points(Version.CGROUP_V2) - if not mount_points_v1 and not mount_points_v2: - result = consts.TEST_FAILED - cause = ("No cgroup mount point found") - - return result, cause - - -def teardown(config): - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/046-cgexec-empty_controller.py b/lib/libcgroup-3.1.0/tests/ftests/046-cgexec-empty_controller.py deleted file mode 100755 index 981048a3b83..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/046-cgexec-empty_controller.py +++ /dev/null @@ -1,78 +0,0 @@ -#!/usr/bin/env python3 -# -# cgexec to an empty cgroup functionality test using the python bindings -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from process import Process -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = '046cgexec' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - Cgroup.create(config, None, cgname=CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup(config, '', CGNAME) - output = Cgroup.get( - config, controller=None, cgname=CGNAME, - setting='cgroup.procs', print_headers=False, - values_only=False - ) - - if not len(output): - result = consts.TEST_FAILED - cause = 'No process created in the cgroup' - - return result, cause - - -def teardown(config): - pids = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - Process.kill(config, pids) - - Cgroup.delete(config, None, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/047-cgcreate-delete_cgrp_shared_mnt.py b/lib/libcgroup-3.1.0/tests/ftests/047-cgcreate-delete_cgrp_shared_mnt.py deleted file mode 100755 index 36971d9724f..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/047-cgcreate-delete_cgrp_shared_mnt.py +++ /dev/null @@ -1,90 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test deleting cgroup on mount point shared by cgroup v1 controllers -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER1 = 'cpu' -CONTROLLER2 = 'cpuacct' - -CGNAME = '047shared_mnts' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - - # cpuacct controller is only available on cgroup v1, if an exception - # gets raised, then no cgroup v1 controllers mounted. - try: - CgroupVersion.get_version('cpuacct') - except IndexError: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpuacct controller' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER1, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - try: - Cgroup.delete(config, CONTROLLER2, CGNAME) - except RunError as re: - if 'No such file or directory' in re.stderr: - cause = 'cpu and cpuacct controllers do not share mount points.' - result = consts.TEST_FAILED - else: - raise re - - try: - Cgroup.delete(config, CONTROLLER1, CGNAME) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - return result, cause - - -def teardown(config): - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/048-pybindings-get_cgroup_mode.py b/lib/libcgroup-3.1.0/tests/ftests/048-pybindings-get_cgroup_mode.py deleted file mode 100755 index 1d24e92f6db..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/048-pybindings-get_cgroup_mode.py +++ /dev/null @@ -1,59 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to get the cgroup mode -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup -import consts -import ftests -import sys -import os - - -def prereqs(config): - pass - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - mode1 = Cgroup.cgroup_mode() - mode2 = CgroupCli.get_cgroup_mode(config) - - if mode1 != mode2: - result = consts.TEST_FAILED - cause = 'mode mismatch: libcgroup mode: {}, tests mode: {}'.format(mode1, mode2) - - return result, cause - - -def teardown(config): - pass - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/049-sudo-systemd_create_scope.py b/lib/libcgroup-3.1.0/tests/ftests/049-sudo-systemd_create_scope.py deleted file mode 100755 index df14edc59e0..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/049-sudo-systemd_create_scope.py +++ /dev/null @@ -1,105 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Create a systemd scope -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from cgroup import CgroupVersion -from libcgroup import Cgroup -from systemd import Systemd -from process import Process -from run import RunError -import ftests -import consts -import sys -import os - -SLICE = 'libcgtests.slice' -SCOPE = '049delegated.scope' - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.create_scope(scope_name=SCOPE, slice_name=SLICE) - - if not Systemd.is_delegated(config, SCOPE): - result = consts.TEST_FAILED - cause = 'Cgroup is not delegated' - - return result, cause - - -def teardown(config, result): - pid = CgroupCli.get(config, cgname=os.path.join(SLICE, SCOPE), setting='cgroup.procs', - print_headers=False, values_only=True) - Process.kill(config, pid) - - if result != consts.TEST_PASSED: - # Something went wrong. Let's force the removal of the cgroups just to be safe. - # Note that this should remove the cgroup, but it won't remove it from systemd's - # internal caches, so the system may not return to its 'pristine' prior-to-this-test - # state - try: - CgroupCli.delete(config, None, os.path.join(SLICE, SCOPE)) - except RunError: - pass - else: - # There is no need to remove the scope. systemd should automatically remove it - # once there are no processes inside of it - pass - - return consts.TEST_PASSED, None - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/050-sudo-systemd_create_scope_w_pid.py b/lib/libcgroup-3.1.0/tests/ftests/050-sudo-systemd_create_scope_w_pid.py deleted file mode 100755 index 9759e7440d1..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/050-sudo-systemd_create_scope_w_pid.py +++ /dev/null @@ -1,109 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Create a systemd scope with an existing PID -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from cgroup import CgroupVersion -from libcgroup import Cgroup -from systemd import Systemd -from process import Process -from run import RunError -import ftests -import consts -import sys -import os - -SLICE = 'libcgtests.slice' -SCOPE = '050delegated.scope' -pid = None - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - global pid - - result = consts.TEST_PASSED - cause = None - - pid = int(config.process.create_process(config)) - Cgroup.create_scope(SCOPE, slice_name=SLICE, pid=pid) - - if not Systemd.is_delegated(config, SCOPE): - result = consts.TEST_FAILED - cause = 'Cgroup is not delegated' - - return result, cause - - -def teardown(config, result): - global pid - - Process.kill(config, pid) - - if result != consts.TEST_PASSED: - # Something went wrong. Let's force the removal of the cgroups just to be safe. - # Note that this should remove the cgroup, but it won't remove it from systemd's - # internal caches, so the system may not return to its 'pristine' prior-to-this-test - # state - try: - CgroupCli.delete(config, None, os.path.join(SLICE, SCOPE)) - except RunError: - pass - else: - # There is no need to remove the scope. systemd should automatically remove it - # once there are no processes inside of it - pass - - return consts.TEST_PASSED, None - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/051-sudo-cgroup_get_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/051-sudo-cgroup_get_cgroup.py deleted file mode 100755 index 47fe1deca28..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/051-sudo-cgroup_get_cgroup.py +++ /dev/null @@ -1,91 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Exercise cgroup_create_cgroup() and cgroup_get_cgroup() -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from libcgroup import Cgroup, Version -from cgroup import CgroupVersion -import ftests -import consts -import sys -import os - -CGNAME = '051cgnewcg/childcg' - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.create() - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.get() - - if len(cg.controllers) != 1: - # only one controller, cpu, should be enabled - result = consts.TEST_FAILED - cause = 'Expected one controller to be enabled, but {} were enabled'.format( - len(cg.controllers)) - - return result, cause - - -def teardown(config, result): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - try: - cg.delete() - except RuntimeError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/052-sudo-cgroup_attach_task.py b/lib/libcgroup-3.1.0/tests/ftests/052-sudo-cgroup_attach_task.py deleted file mode 100755 index 112b917ad47..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/052-sudo-cgroup_attach_task.py +++ /dev/null @@ -1,114 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Attach a task to a cgroup via cgroup_attach_task() -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from cgroup import CgroupVersion -import ftests -import consts -import sys -import os - -CGNAME = '052cgattachcg' - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.create() - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.attach() - - found = False - pids = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - for pid in pids: - if pid == os.getpid(): - # our process was successfully added to the cgroup - found = True - - if not found: - result = consts.TEST_FAILED - cause = 'Could not find pid {} in cgroup {}'.format(os.getpid(), CGNAME) - return result, cause - - # now let's attach this process to the root cgroup and ensure we no longer - # are in CGNAME - cg.attach(root_cgroup=True) - - found = False - pids = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - for pid in pids: - if pid == os.getpid(): - # our process was successfully added to the cgroup - found = True - - if found: - result = consts.TEST_FAILED - cause = 'pid {} was erroneously found in cgroup {}'.format(os.getpid(), CGNAME) - - return result, cause - - -def teardown(config, result): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - try: - cg.delete() - except RuntimeError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/053-sudo-cgroup_attach_task_pid.py b/lib/libcgroup-3.1.0/tests/ftests/053-sudo-cgroup_attach_task_pid.py deleted file mode 100755 index c873c39e10a..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/053-sudo-cgroup_attach_task_pid.py +++ /dev/null @@ -1,116 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Attach a task to a cgroup via cgroup_attach_task_pid() -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from cgroup import CgroupVersion -import ftests -import consts -import sys -import os - -CGNAME = '053cgattachcg' - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.create() - - -def test(config): - result = consts.TEST_PASSED - cause = None - - child_pid = config.process.create_process(config) - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.attach(child_pid) - - found = False - pids = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - for pid in pids: - if pid == child_pid: - # our process was successfully added to the cgroup - found = True - - if not found: - result = consts.TEST_FAILED - cause = 'Could not find pid {} in cgroup {}'.format(child_pid, CGNAME) - return result, cause - - # now let's attach the child process to the root cgroup and ensure we no longer - # are in CGNAME - cg.attach(pid=child_pid, root_cgroup=True) - - found = False - pids = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - for pid in pids: - if pid == child_pid: - # our process was successfully added to the cgroup - found = True - - if found: - result = consts.TEST_FAILED - cause = 'pid {} was erroneously found in cgroup {}'.format(child_pid, CGNAME) - - return result, cause - - -def teardown(config, result): - cg = Cgroup(CGNAME, Version.CGROUP_V2) - try: - cg.delete() - except RuntimeError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/054-sudo-set_uid_gid_v2.py b/lib/libcgroup-3.1.0/tests/ftests/054-sudo-set_uid_gid_v2.py deleted file mode 100755 index 05966ce10e7..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/054-sudo-set_uid_gid_v2.py +++ /dev/null @@ -1,89 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to set the uid/gid on a cgroup v2 cgroup using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, CgroupVersion -from libcgroup import Cgroup, Version -import consts -import ftests -import utils -import sys -import os - -CGNAME = '054setuidgid' -CONTROLLER = 'cpu' -TASKS_UID = 1234 -TASKS_GID = 5678 -CTRL_UID = 3456 -CTRL_GID = 7890 - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.set_uid_gid(TASKS_UID, TASKS_GID, CTRL_UID, CTRL_GID) - cg.add_controller(CONTROLLER) - cg.create(ignore_ownership=False) - - ctrl_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'cgroup.procs') - - uid = utils.get_file_owner_uid(config, ctrl_path) - if uid != CTRL_UID: - result = consts.TEST_FAILED - cause = 'Expected cgroup.procs owner to be {} but it\'s {}'.format(CTRL_UID, uid) - - gid = utils.get_file_owner_gid(config, ctrl_path) - if gid != CTRL_GID: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs group to be {} but it\'s {}'.format(CTRL_GID, gid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, None, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/055-sudo-set_uid_gid_v1.py b/lib/libcgroup-3.1.0/tests/ftests/055-sudo-set_uid_gid_v1.py deleted file mode 100755 index 7ca972e452f..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/055-sudo-set_uid_gid_v1.py +++ /dev/null @@ -1,107 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to set the uid/gid on a cgroup v1 cgroup using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, CgroupVersion -from libcgroup import Cgroup, Version -import consts -import ftests -import utils -import sys -import os - -CGNAME = '055setuidgid' -CONTROLLER = 'cpu' -TASKS_UID = 1234 -TASKS_GID = 5678 -CTRL_UID = 3456 -CTRL_GID = 7890 - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v1' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V1) - cg.set_uid_gid(TASKS_UID, TASKS_GID, CTRL_UID, CTRL_GID) - cg.add_controller(CONTROLLER) - cg.create(ignore_ownership=False) - - tasks_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'tasks') - - tasks_uid = utils.get_file_owner_uid(config, tasks_path) - if tasks_uid != TASKS_UID: - result = consts.TEST_FAILED - cause = 'Expected tasks owner to be {} but it\'s {}'.format(TASKS_UID, tasks_uid) - - tasks_gid = utils.get_file_owner_gid(config, tasks_path) - if tasks_gid != TASKS_GID: - result = consts.TEST_FAILED - tmp_cause = 'Expected tasks group to be {} but it\'s {}'.format(TASKS_GID, tasks_gid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - ctrl_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'cgroup.procs') - - ctrl_uid = utils.get_file_owner_uid(config, ctrl_path) - if ctrl_uid != CTRL_UID: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs owner to be {} but it\'s {}'.format(CTRL_UID, ctrl_uid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - ctrl_gid = utils.get_file_owner_gid(config, ctrl_path) - if ctrl_gid != CTRL_GID: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs group to be {} but it\'s {}'.format(CTRL_GID, ctrl_gid) - if not cause: - cause = tmp_cause - else: - cause = '{}\n{}'.format(cause, tmp_cause) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/056-sudo-set_permissions_v2.py b/lib/libcgroup-3.1.0/tests/ftests/056-sudo-set_permissions_v2.py deleted file mode 100755 index 7ac41bac691..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/056-sudo-set_permissions_v2.py +++ /dev/null @@ -1,96 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to set the permissions on a cgroup using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, CgroupVersion -from libcgroup import Cgroup, Version -import consts -import ftests -import utils -import stat -import sys -import os - -CGNAME = '056setperms' -CONTROLLER = 'memory' -# 0711 -DIR_MODE = stat.S_IRWXU | stat.S_IXGRP | stat.S_IXOTH -# 0640 -CTRL_MODE = stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP -# 0771 -TASK_MODE = stat.S_IRWXU | stat.S_IRWXG | stat.S_IXOTH - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.set_permissions(DIR_MODE, CTRL_MODE, TASK_MODE) - cg.add_controller(CONTROLLER) - cg.create(ignore_ownership=False) - - dir_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME) - - dir_mode = utils.get_file_permissions(config, dir_path) - if int(dir_mode, 8) != DIR_MODE: - result = consts.TEST_FAILED - cause = 'Expected directory mode to be {} but it\'s {}'.format( - format(DIR_MODE, '03o'), dir_mode) - - ctrl_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'cgroup.procs') - - ctrl_mode = utils.get_file_permissions(config, ctrl_path) - if int(ctrl_mode, 8) != CTRL_MODE: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs mode to be {} but it\'s {}'.format( - format(CTRL_MODE, '03o'), ctrl_mode) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, None, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/057-sudo-set_permissions_v1.py b/lib/libcgroup-3.1.0/tests/ftests/057-sudo-set_permissions_v1.py deleted file mode 100755 index 566f6a0ad10..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/057-sudo-set_permissions_v1.py +++ /dev/null @@ -1,106 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to set the permissions on a cgroup using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, CgroupVersion -from libcgroup import Cgroup, Version -import consts -import ftests -import utils -import stat -import sys -import os - -CGNAME = '057setperms' -CONTROLLER = 'memory' -# 0711 -DIR_MODE = stat.S_IRWXU | stat.S_IXGRP | stat.S_IXOTH -# 0640 -CTRL_MODE = stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP -# 0660 -TASK_MODE = stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP | stat.S_IWGRP - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version(CONTROLLER) != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v1' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V1) - cg.set_permissions(DIR_MODE, CTRL_MODE, TASK_MODE) - cg.add_controller(CONTROLLER) - cg.create(ignore_ownership=False) - - dir_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME) - - dir_mode = utils.get_file_permissions(config, dir_path) - if int(dir_mode, 8) != DIR_MODE: - result = consts.TEST_FAILED - cause = 'Expected directory mode to be {} but it\'s {}'.format( - format(DIR_MODE, '03o'), dir_mode) - - ctrl_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'cgroup.procs') - - ctrl_mode = utils.get_file_permissions(config, ctrl_path) - if int(ctrl_mode, 8) != CTRL_MODE: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs mode to be {} but it\'s {}'.format( - format(CTRL_MODE, '03o'), ctrl_mode) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - task_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'tasks') - - task_mode = utils.get_file_permissions(config, task_path) - if int(task_mode, 8) != TASK_MODE: - result = consts.TEST_FAILED - tmp_cause = 'Expected tasks mode to be {} but it\'s {}'.format( - format(TASK_MODE, '03o'), task_mode) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/058-sudo-systemd_create_scope2.py b/lib/libcgroup-3.1.0/tests/ftests/058-sudo-systemd_create_scope2.py deleted file mode 100755 index 751a221d612..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/058-sudo-systemd_create_scope2.py +++ /dev/null @@ -1,165 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Create a systemd scope with an existing PID -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import CgroupVersion as CgroupCliVersion -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from systemd import Systemd -from process import Process -from run import RunError -import ftests -import consts -import utils -import stat -import sys -import os - -pid = None -CGNAME = 'libcgtests.slice/058delegated.scope' - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - -# 0751 -DIR_MODE = stat.S_IRWXU | stat.S_IRGRP | stat.S_IXGRP | stat.S_IXOTH -# 0644 -CTRL_MODE = stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP | stat.S_IROTH -# 0775 -TASK_MODE = stat.S_IRWXU | stat.S_IRWXG | stat.S_IXOTH - -TASKS_UID = 2468 -TASKS_GID = 3579 -CTRL_UID = 4680 -CTRL_GID = 5791 - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupCliVersion.get_version(CONTROLLER) != CgroupCliVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - global pid - - result = consts.TEST_PASSED - cause = None - - pid = config.process.create_process(config) - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - - cg.add_controller(CONTROLLER) - cg.set_permissions(DIR_MODE, CTRL_MODE, TASK_MODE) - cg.set_uid_gid(TASKS_UID, TASKS_GID, CTRL_UID, CTRL_GID) - - cg.create_scope2(ignore_ownership=False, pid=pid) - - if not Systemd.is_delegated(config, os.path.basename(CGNAME)): - result = consts.TEST_FAILED - cause = 'Cgroup is not delegated' - - if not CgroupCli.is_controller_enabled(config, CGNAME, CONTROLLER): - result = consts.TEST_FAILED - tmp_cause = 'Controller {} is not enabled in the parent cgroup'.format(CONTROLLER) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - dir_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME) - - dir_mode = utils.get_file_permissions(config, dir_path) - if int(dir_mode, 8) != DIR_MODE: - result = consts.TEST_FAILED - tmp_cause = 'Expected directory mode to be {} but it\'s {}'.format( - format(DIR_MODE, '03o'), dir_mode) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - ctrl_path = os.path.join(CgroupCli.get_controller_mount_point(CONTROLLER), CGNAME, - 'cgroup.procs') - - ctrl_mode = utils.get_file_permissions(config, ctrl_path) - if int(ctrl_mode, 8) != CTRL_MODE: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs mode to be {} but it\'s {}'.format( - format(CTRL_MODE, '03o'), ctrl_mode) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - uid = utils.get_file_owner_uid(config, ctrl_path) - if uid != CTRL_UID: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs owner to be {} but it\'s {}'.format(CTRL_UID, uid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - gid = utils.get_file_owner_gid(config, ctrl_path) - if gid != CTRL_GID: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup.procs group to be {} but it\'s {}'.format(CTRL_GID, gid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config, result): - global pid - - Process.kill(config, pid) - - if result != consts.TEST_PASSED: - # Something went wrong. Let's force the removal of the cgroups just to be safe. - # Note that this should remove the cgroup, but it won't remove it from systemd's - # internal caches, so the system may not return to its 'pristine' prior-to-this-test - # state - try: - CgroupCli.delete(config, None, CGNAME) - except RunError: - pass - else: - # There is no need to remove the scope. systemd should automatically remove it - # once there are no processes inside of it - pass - - return consts.TEST_PASSED, None - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/059-sudo-invalid_systemd_create_scope2.py b/lib/libcgroup-3.1.0/tests/ftests/059-sudo-invalid_systemd_create_scope2.py deleted file mode 100755 index 25d2e39095b..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/059-sudo-invalid_systemd_create_scope2.py +++ /dev/null @@ -1,106 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test invalid parameters for systemd_create_scope2() -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import CgroupVersion as CgroupCliVersion -from libcgroup import Cgroup, Version -import ftests -import consts -import sys -import os - -# Which controller isn't all that important, but it is important that we -# have a cgroup v2 controller -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupCliVersion.get_version(CONTROLLER) != CgroupCliVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires cgroup v2' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cg1 = Cgroup("InvalidNameBecauseNoSlash", Version.CGROUP_V2) - cg1.add_controller(CONTROLLER) - try: - cg1.create_scope2() - except RuntimeError as re: - if '50011' not in str(re): - result = consts.TEST_FAILED - cause = 'Expected ECGINVAL (50011) but received {}'.format(re) - else: - result = consts.TEST_FAILED - cause = 'An invalid cgroup name unexpectedly passed: {}'.format(cg1.name) - - cg2 = Cgroup("Invalid/TooMany/Slashes", Version.CGROUP_V2) - cg2.add_controller(CONTROLLER) - try: - cg2.create_scope2() - except RuntimeError as re: - if '50011' not in str(re): - result = consts.TEST_FAILED - tmp_cause = 'Expected ECGINVAL (50011) but received {}'.format(re) - if not cause: - cause = tmp_cause - else: - cause = '{}\n{}'.format(cause, tmp_cause) - else: - result = consts.TEST_FAILED - cause = 'An invalid cgroup name unexpectedly passed: {}'.format(cg1.name) - if not cause: - cause = tmp_cause - else: - cause = '{}\n{}'.format(cause, tmp_cause) - - return result, cause - - -def teardown(config, result): - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/060-sudo-cgconfigparser-systemd.py b/lib/libcgroup-3.1.0/tests/ftests/060-sudo-cgconfigparser-systemd.py deleted file mode 100755 index 33f32c6a7b6..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/060-sudo-cgconfigparser-systemd.py +++ /dev/null @@ -1,194 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgconfigparser functionality test - systemd configurations -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal - -from systemd import Systemd -from process import Process -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import time -import sys -import os - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '060_cg_in_scope' -OTHER_CGNAME = '060_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test060.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '060cgconfig.conf') - -CONFIGURATIONS = [ - # [ 'systemd configuration file', 'Excepted error substring'] - ['systemd {\n}', 'Error: failed to parse file'], - - ['systemd {\n\tslice = libcgroup;\n}', - 'Error: Invalid systemd configuration slice value libcgroup'], - - ['systemd {\n\tscope = test060;\n}', - 'Error: Invalid systemd configuration scope value test060'], - - ['systemd {\n\tslice = libcgroup.slice;\n}', - 'Error: Invalid systemd setting, missing scope name'], - - ['systemd {\n\tscope = test060.scope;\n}', - 'Error: Invalid systemd setting, missing slice name'], - - ['systemd {\n\tsetdefault = yes;\n}', - 'Error: Invalid systemd setting, missing slice name'], - - ['systemd {\n\tpid = 123;\n}', - 'Error: Invalid systemd setting, missing slice name'], - - ['systemd {\n\tInvalid = Invalid;\n}', - 'Error: Invalid systemd configuration Invalid'], - - ['systemd {\n\tslice = libcgroup.slice;\n\tsetdefault = yes;\n\t}', - 'Error: Invalid systemd setting, missing scope name'], - - ['systemd {\n\tscope = test060.scope;\n\tsetdefault = yes;\n\t}', - 'Error: Invalid systemd setting, missing slice name'], - - ['systemd {\n\tslice = libcgroup.slice;\n\tscope = test060.scope;\n\t' - 'setdefault = invalid;\n\t}', - 'Error: Invalid systemd configuration setdefault'], - - ['systemd {\n\tslice = libcgroup.slice;\n\tscope = test060.scope;\n\t' - 'setdefault = yes;\n\tpid = abc;\n}', - 'Error: Invalid systemd configuration pid'], -] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - pass - - -def write_conf_file(config, configurations): - f = open(CONFIG_FILE_NAME, 'w') - f.write(configurations) - f.close() - - -def test_invalid_configurations(config): - result = consts.TEST_PASSED - cause = None - - # Try parsing invalid systemd configurations from CONFIGURATION table - # and none of them is excepted to pass. - for configuration in CONFIGURATIONS: - write_conf_file(config, configuration[0]) - - try: - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - except RunError as re: - if configuration[1] not in re.stdout: - result = consts.TEST_FAILED - tmp_cause = ( - 'Unexpected error {}, while parsing configuration:' - '\n{}'.format(re.stdout, configuration[0]) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - else: - result = consts.TEST_FAILED - tmp_cause = ( - 'Creation of systemd default slice/scope, erroneously succeeded with' - 'configuration:\n{}'.format(configuration[0]) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - result, cause = test_invalid_configurations(config) - if result == consts.TEST_FAILED: - return result, cause - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - # Pass a valid configuration to the parser - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - if not Cgroup.exists(config, CONTROLLER, os.path.join(SLICE, SCOPE), ignore_systemd=True): - result = consts.TEST_FAILED - cause = 'Failed to create systemd slice/scope' - return result, cause - - # It's invalid to pass the same configuration file twice. The values - # were already read and slice/scope cgroups were created, unless - # something has gone wrong, this should fail. - try: - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - except RunError as re: - if 'already exists' not in re.stdout: - result = consts.TEST_FAILED - cause = 'Unexpected error {}'.format(re.stdout) - else: - result = consts.TEST_FAILED - cause = 'Creation of systemd default slice/scope erroneously succeeded' - - # killing the pid should remove the scope cgroup too. - Process.kill(config, pid) - - # Let's pause and wait for the systemd to remove the scope. - time.sleep(1) - - if Cgroup.exists(config, CONTROLLER, os.path.join(SLICE, SCOPE), ignore_systemd=True): - result = consts.TEST_FAILED - cause = 'Systemd failed to remove the scope {}'.format(SCOPE) - - return result, cause - - -def teardown(config): - # The scope is already removed, when the task was killed. - try: - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - except RunError as re: - if 'scope not loaded' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/061-sudo-g_flag_controller_only_systemd-v1.py b/lib/libcgroup-3.1.0/tests/ftests/061-sudo-g_flag_controller_only_systemd-v1.py deleted file mode 100755 index 078b18fdfa9..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/061-sudo-g_flag_controller_only_systemd-v1.py +++ /dev/null @@ -1,156 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - '-b' '-g' (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# Author: Kamalesh Babulal - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = 'cg_in_scope' -OTHER_CGNAME = 'cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test061.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '061cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, CONTROLLER, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/{}/'.format(SYSTEMD_CGNAME, CONTROLLER, SLICE, SCOPE) - ) - return result, cause - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=CONTROLLER, cgname=SYSTEMD_CGNAME) - if len(out.splitlines()) < 10: - # This cgget command gets all of the settings/values within the cgroup. - # We don't care about the exact data, but there should be at least 10 - # lines of settings/values - result = consts.TEST_FAILED - cause = ( - 'cgget failed to read at least 10 lines from ' - 'cgroup {}: {}'.format(SYSTEMD_CGNAME, out) - ) - - out = Cgroup.get(config, controller=CONTROLLER, cgname=OTHER_CGNAME, ignore_systemd=True) - if len(out.splitlines()) < 10: - result = consts.TEST_FAILED - tmp_cause = ( - 'cgget failed to read at least 10 lines from ' - 'cgroup {}: {}'.format(OTHER_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # This should fail because the wrong path should be built up - out = Cgroup.get(config, controller=CONTROLLER, cgname=SYSTEMD_CGNAME, ignore_systemd=True, - print_headers=False) - if len(out) > 0: - result = consts.TEST_FAILED - tmp_cause = ( - 'cgget erroneously read cgroup {} at the ' - 'wrong path: {}'.format(SYSTEMD_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # This should fail because the wrong path should be built up - out = Cgroup.get(config, controller=CONTROLLER, cgname=OTHER_CGNAME, print_headers=False) - if len(out) > 0: - result = consts.TEST_FAILED - tmp_cause = ( - 'cgget erroneously read cgroup {} at the ' - 'wrong path: {}'.format(OTHER_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - teardown(config) - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/062-sudo-g_flag_controller_only_systemd-v2.py b/lib/libcgroup-3.1.0/tests/ftests/062-sudo-g_flag_controller_only_systemd-v2.py deleted file mode 100755 index e77eb6aae37..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/062-sudo-g_flag_controller_only_systemd-v2.py +++ /dev/null @@ -1,167 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgget functionality test - '-b' '-g' (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = 'cg_in_scope' -OTHER_CGNAME = 'cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test062.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '062cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, None, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/'.format(SYSTEMD_CGNAME, SLICE, SCOPE) - ) - return result, cause - - # With cgroup v2, we can't enable controller for the child cgroup, while - # a task is attached to test062.scope. Attach the task from test062.scope - # to child cgroup SYSTEMD_CGNAME and then enable cpu controller in the parent, - # so that the cgroup.get() works - Cgroup.set(config, cgname=SYSTEMD_CGNAME, setting='cgroup.procs', value=pid) - - Cgroup.set( - config, cgname=(os.path.join(SLICE, SCOPE)), setting='cgroup.subtree_control', - value='+cpu', ignore_systemd=True - ) - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - out = Cgroup.get(config, controller=CONTROLLER, cgname=SYSTEMD_CGNAME) - if len(out.splitlines()) < 10: - # This cgget command gets all of the settings/values within the cgroup. - # We don't care about the exact data, but there should be at least 10 - # lines of settings/values - result = consts.TEST_FAILED - cause = ( - 'cgget failed to read at least 10 lines from ' - 'cgroup {}: {}'.format(SYSTEMD_CGNAME, out) - ) - - out = Cgroup.get(config, controller=CONTROLLER, cgname=OTHER_CGNAME, ignore_systemd=True) - if len(out.splitlines()) < 10: - result = consts.TEST_FAILED - tmp_cause = ( - 'cgget failed to read at least 10 lines from ' - 'cgroup {}: {}'.format(OTHER_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # This should fail because the wrong path should be built up - out = Cgroup.get(config, controller=CONTROLLER, cgname=SYSTEMD_CGNAME, - ignore_systemd=True, print_headers=False) - if len(out) > 0: - result = consts.TEST_FAILED - tmp_cause = ( - 'cgget erroneously read cgroup {} at the wrong ' - 'path: {}'.format(SYSTEMD_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # This should fail because the wrong path should be built up - out = Cgroup.get(config, controller=CONTROLLER, cgname=OTHER_CGNAME, print_headers=False) - if len(out) > 0: - result = consts.TEST_FAILED - cause = ( - 'cgget erroneously read cgroup {} at the wrong ' - 'path: {}'.format(OTHER_CGNAME, out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - teardown(config) - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/063-sudo-systemd_cgset-v1.py b/lib/libcgroup-3.1.0/tests/ftests/063-sudo-systemd_cgset-v1.py deleted file mode 100755 index bb615bf4fc1..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/063-sudo-systemd_cgset-v1.py +++ /dev/null @@ -1,137 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - '-b' '-g' (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# Author: Kamalesh Babulal - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '063_cg_in_scope' -OTHER_CGNAME = '063_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test063.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '063cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, CONTROLLER, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/{}/'.format(SYSTEMD_CGNAME, CONTROLLER, SLICE, SCOPE) - ) - return result, cause - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.set_and_validate(config, SYSTEMD_CGNAME, 'cpu.shares', '200') - Cgroup.set_and_validate(config, OTHER_CGNAME, 'cpu.shares', '300', ignore_systemd=True) - - try: - Cgroup.set(config, SYSTEMD_CGNAME, 'cpu.shares', '400', ignore_systemd=True) - except RunError as re: - if 'requested group parameter does not exist' not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = 'Setting cpu.shares on {} erroneously succeeded'.format(SYSTEMD_CGNAME) - - try: - Cgroup.set(config, OTHER_CGNAME, 'cpu.shares', '500') - except RunError as re: - if 'requested group parameter does not exist' not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - tmp_cause = 'Setting cpu.shares on {} erroneously succeeded'.format(OTHER_CGNAME) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/064-sudo-systemd_cgset-v2.py b/lib/libcgroup-3.1.0/tests/ftests/064-sudo-systemd_cgset-v2.py deleted file mode 100755 index c42bc5010ed..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/064-sudo-systemd_cgset-v2.py +++ /dev/null @@ -1,147 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgset functionality test - '-b' '-g' (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '064_cg_in_scope' -OTHER_CGNAME = '064_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test064.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '064cgconfig.conf') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, None, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/'.format(SYSTEMD_CGNAME, SLICE, SCOPE) - ) - return result, cause - - # With cgroup v2, we can't enable controller for the child cgroup, while - # a task is attached to test064.scope. Attach the task from test064.scope - # to child cgroup SYSTEMD_CGNAME and then enable cpu controller in the parent, - # so that the cgroup.get() works - Cgroup.set(config, cgname=SYSTEMD_CGNAME, setting='cgroup.procs', value=pid) - - Cgroup.set( - config, cgname=(os.path.join(SLICE, SCOPE)), setting='cgroup.subtree_control', - value='+cpu', ignore_systemd=True - ) - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.set_and_validate(config, SYSTEMD_CGNAME, 'cpu.weight', '200') - Cgroup.set_and_validate(config, OTHER_CGNAME, 'cpu.weight', '300', ignore_systemd=True) - - try: - Cgroup.set(config, SYSTEMD_CGNAME, 'cpu.weight', '400', ignore_systemd=True) - except RunError as re: - if 'requested group parameter does not exist' not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = 'Setting cpu.weight on {} erroneously succeeded'.format(SYSTEMD_CGNAME) - - try: - Cgroup.set(config, OTHER_CGNAME, 'cpu.weight', '500') - except RunError as re: - if 'requested group parameter does not exist' not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - tmp_cause = 'Setting cpu.weight on {} erroneously succeeded'.format(OTHER_CGNAME) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/065-sudo-systemd_cgclassify-v1.py b/lib/libcgroup-3.1.0/tests/ftests/065-sudo-systemd_cgclassify-v1.py deleted file mode 100755 index 850c1362ae4..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/065-sudo-systemd_cgclassify-v1.py +++ /dev/null @@ -1,195 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgclassify functionality test - '-b' '-g' (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from process import Process -from run import RunError -import consts -import ftests -import time -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '065_cg_in_scope' -OTHER_CGNAME = '065_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test065.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '065cgconfig.conf') - -SYSTEMD_PIDS = '' -OTHER_PIDS = '' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, CONTROLLER, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/{}/'.format(SYSTEMD_CGNAME, CONTROLLER, SLICE, SCOPE) - ) - return result, cause - - # create and check if the cgroup was created under the controller sub-tree - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def create_process_get_pid(config, CGNAME, SLICENAME='', ignore_systemd=False): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup( - config, CONTROLLER, CGNAME, - ignore_systemd=ignore_systemd - ) - - pids = Cgroup.get_pids_in_cgroup(config, os.path.join(SLICENAME, CGNAME), CONTROLLER) - if pids is None: - result = consts.TEST_FAILED - cause = 'No processes were found in cgroup {}'.format(CGNAME) - - return pids, result, cause - - -def test(config): - global SYSTEMD_PIDS, OTHER_PIDS - - result = consts.TEST_PASSED - cause = None - - # Test cgclassify, that creates a process and then uses cgclassify - # to migrate the task the cgroup. - SYSTEMD_PIDS, result, cause = create_process_get_pid( - config, SYSTEMD_CGNAME, - os.path.join(SLICE, SCOPE) - ) - if result == consts.TEST_FAILED: - return result, cause - - OTHER_PIDS, result, tmp_cause = create_process_get_pid( - config, OTHER_CGNAME, - ignore_systemd=True - ) - if result == consts.TEST_FAILED: - return result, cause - - # classify a task from the non-systemd scope cgroup (OTHER_CGNAME) to - # systemd scope cgroup (SYSTEMD_CGNAME). Migration should fail due to - # the incorrect destination cgroup path that gets constructed, without - # the systemd slice/scope when ignore_systemd=True) - try: - Cgroup.classify(config, CONTROLLER, SYSTEMD_CGNAME, OTHER_PIDS, ignore_systemd=True) - except RunError as re: - err_str = 'Error changing group of pid {}: Cgroup does not exist'.format(OTHER_PIDS[0]) - if re.stderr != err_str: - raise re - else: - result = consts.TEST_FAILED - cause = 'Changing group of pid {} erroneously succeeded'.format(OTHER_PIDS[0]) - - # classify a task from the systemd scope cgroup (SYSTEMD_CGNAME) to - # non-systemd scope cgroup (OTHER_CGNAME). Migration should fail due - # to the incorrect destination cgroup path that gets constructed, with - # the systemd slice/scope when ignore_systemd=False) - try: - Cgroup.classify(config, CONTROLLER, OTHER_CGNAME, SYSTEMD_PIDS) - except RunError as re: - err_str = 'Error changing group of pid {}: Cgroup does not exist'.format(SYSTEMD_PIDS[0]) - if re.stderr != err_str: - raise re - else: - result = consts.TEST_FAILED - tmp_cause = 'Changing group of pid {} erroneously succeeded'.format(SYSTEMD_PIDS[0]) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # classify the task from the non-systemd scope cgroup to systemd scope cgroup. - Cgroup.classify(config, CONTROLLER, SYSTEMD_CGNAME, OTHER_PIDS) - - return result, cause - - -def teardown(config): - global SYSTEMD_PIDS, OTHER_PIDS - - Process.kill(config, SYSTEMD_PIDS) - Process.kill(config, OTHER_PIDS) - - # We need a pause, so that cgroup.procs gets updated. - time.sleep(1) - - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/066-sudo-systemd_cgclassify-v2.py b/lib/libcgroup-3.1.0/tests/ftests/066-sudo-systemd_cgclassify-v2.py deleted file mode 100755 index 9f0fd3de8fb..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/066-sudo-systemd_cgclassify-v2.py +++ /dev/null @@ -1,213 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgclassify functionality test - '-b' '-g' (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from process import Process -from run import RunError -import consts -import ftests -import time -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '066_cg_in_scope' -OTHER_CGNAME = '066_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test066.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '066cgconfig.conf') - -SYSTEMD_PIDS = '' -OTHER_PIDS = '' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, None, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/'.format(SYSTEMD_CGNAME, SLICE, SCOPE) - ) - return result, cause - - # With cgroup v2, we can't enable controller for the child cgroup, while - # a task is attached to test066.scope. Attach the task from test066.scope - # to child cgroup SYSTEMD_CGNAME and then enable cpu controller in the parent, - # so that the cgroup.get() works - Cgroup.set(config, cgname=SYSTEMD_CGNAME, setting='cgroup.procs', value=pid) - - Cgroup.set( - config, cgname=(os.path.join(SLICE, SCOPE)), setting='cgroup.subtree_control', - value='+cpu', ignore_systemd=True - ) - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def create_process_get_pid(config, CGNAME, SLICENAME='', ignore_systemd=False): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup( - config, CONTROLLER, CGNAME, - ignore_systemd=ignore_systemd - ) - - pids = Cgroup.get_pids_in_cgroup(config, os.path.join(SLICENAME, CGNAME), CONTROLLER) - if pids is None: - result = consts.TEST_FAILED - cause = 'No processes were found in cgroup {}'.format(CGNAME) - - return pids, result, cause - - -def test(config): - global SYSTEMD_PIDS, OTHER_PIDS - - result = consts.TEST_PASSED - cause = None - - # Test cgclassify, that creates a process and then uses cgclassify - # to migrate the task the cgroup. - SYSTEMD_PIDS, result, cause = create_process_get_pid( - config, SYSTEMD_CGNAME, - os.path.join(SLICE, SCOPE) - ) - if result == consts.TEST_FAILED: - return result, cause - - OTHER_PIDS, result, tmp_cause = create_process_get_pid( - config, OTHER_CGNAME, - ignore_systemd=True - ) - if result == consts.TEST_FAILED: - return result, cause - - # classify a task from the non-systemd scope cgroup (OTHER_CGNAME) to - # systemd scope cgroup (SYSTEMD_CGNAME). Migration should fail due to - # the incorrect destination cgroup path that gets constructed, without - # the systemd slice/scope when ignore_systemd=True) - try: - Cgroup.classify(config, CONTROLLER, SYSTEMD_CGNAME, OTHER_PIDS, ignore_systemd=True) - except RunError as re: - err_str = 'Error changing group of pid {}: Cgroup does not exist'.format(OTHER_PIDS[0]) - if re.stderr != err_str: - raise re - else: - result = consts.TEST_FAILED - cause = 'Changing group of pid {} erroneously succeeded'.format(OTHER_PIDS[0]) - - # classify a task from the systemd scope cgroup (SYSTEMD_CGNAME) to - # non-systemd scope cgroup (OTHER_CGNAME). Migration should fail due - # to the incorrect destination cgroup path that gets constructed, with - # the systemd slice/scope when ignore_systemd=False) - try: - Cgroup.classify(config, CONTROLLER, OTHER_CGNAME, SYSTEMD_PIDS[1]) - except RunError as re: - err_str = 'Error changing group of pid {}: Cgroup does not exist'.format( - SYSTEMD_PIDS[1]) - if re.stderr != err_str: - raise re - else: - result = consts.TEST_FAILED - tmp_cause = 'Changing group of pid {} erroneously succeeded'.format(SYSTEMD_PIDS[1]) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # classify the task from the non-systemd scope cgroup to systemd scope cgroup. - Cgroup.classify(config, CONTROLLER, SYSTEMD_CGNAME, OTHER_PIDS) - - return result, cause - - -def teardown(config): - global SYSTEMD_PIDS, OTHER_PIDS - - Process.kill(config, SYSTEMD_PIDS) - Process.kill(config, OTHER_PIDS) - - # We need a pause, so that cgroup.procs gets updated. - time.sleep(1) - - os.remove(CONFIG_FILE_NAME) - - try: - Cgroup.delete(config, CONTROLLER, cgname=SLICE, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/067-sudo-systemd_cgexec-v1.py b/lib/libcgroup-3.1.0/tests/ftests/067-sudo-systemd_cgexec-v1.py deleted file mode 100755 index 3a452f65611..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/067-sudo-systemd_cgexec-v1.py +++ /dev/null @@ -1,163 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgexec functionality test - '-b' '-g' (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from process import Process -from run import RunError -import consts -import ftests -import time -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '067_cg_in_scope' -OTHER_CGNAME = '067_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test067.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '067cgconfig.conf') - -SYSTEMD_PIDS = '' -OTHER_PIDS = '' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, CONTROLLER, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/{}/'.format(SYSTEMD_CGNAME, CONTROLLER, SLICE, SCOPE) - ) - return result, cause - - # create and check if the cgroup was created under the controller sub-tree - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def create_process_get_pid(config, CGNAME, SLICENAME='', ignore_systemd=False): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup( - config, CONTROLLER, CGNAME, cgclassify=False, - ignore_systemd=ignore_systemd - ) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - pids = Cgroup.get_pids_in_cgroup(config, os.path.join(SLICENAME, CGNAME), CONTROLLER) - if pids is None: - result = consts.TEST_FAILED - cause = 'No processes were found in cgroup {}'.format(CGNAME) - - return pids, result, cause - - -def test(config): - global SYSTEMD_PIDS, OTHER_PIDS - - result = consts.TEST_PASSED - cause = None - - # Test cgclassify, that creates a process and then uses cgclassify - # to migrate the task the cgroup. - SYSTEMD_PIDS, result, cause = create_process_get_pid( - config, SYSTEMD_CGNAME, - os.path.join(SLICE, SCOPE) - ) - - OTHER_PIDS, result, tmp_cause = create_process_get_pid( - config, OTHER_CGNAME, - ignore_systemd=True - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - global SYSTEMD_PIDS, OTHER_PIDS - - Process.kill(config, SYSTEMD_PIDS) - Process.kill(config, OTHER_PIDS) - - # We need a pause, so that cgroup.procs gets updated. - time.sleep(1) - - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/068-sudo-systemd_cgexec-v2.py b/lib/libcgroup-3.1.0/tests/ftests/068-sudo-systemd_cgexec-v2.py deleted file mode 100755 index 78945f9afa5..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/068-sudo-systemd_cgexec-v2.py +++ /dev/null @@ -1,179 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgexec functionality test - '-b' '-g' (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from process import Process -from run import RunError -import consts -import ftests -import time -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '068_cg_in_scope' -OTHER_CGNAME = '068_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test068.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '068cgconfig.conf') - -SYSTEMD_PIDS = None -OTHER_PIDS = None - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, None, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/'.format(SYSTEMD_CGNAME, SLICE, SCOPE) - ) - return result, cause - - # With cgroup v2, we can't enable controller for the child cgroup, while - # a task is attached to test068.scope. Attach the task from test068.scope - # to child cgroup SYSTEMD_CGNAME and then enable cpu controller in the parent, - # so that the cgroup.get() works - Cgroup.set(config, cgname=SYSTEMD_CGNAME, setting='cgroup.procs', value=pid) - - Cgroup.set( - config, cgname=(os.path.join(SLICE, SCOPE)), setting='cgroup.subtree_control', - value='+cpu', ignore_systemd=True - ) - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def create_process_get_pid(config, CGNAME, SLICENAME='', ignore_systemd=False): - result = consts.TEST_PASSED - cause = None - - config.process.create_process_in_cgroup( - config, CONTROLLER, CGNAME, cgclassify=False, - ignore_systemd=ignore_systemd - ) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - pids = Cgroup.get_pids_in_cgroup(config, os.path.join(SLICENAME, CGNAME), CONTROLLER) - if pids is None: - result = consts.TEST_FAILED - cause = 'No processes were found in cgroup {}'.format(CGNAME) - - return pids, result, cause - - -def test(config): - global SYSTEMD_PIDS, OTHER_PIDS - - result = consts.TEST_PASSED - cause = None - - # Test cgclassify, that creates a process and then uses cgclassify - # to migrate the task the cgroup. - SYSTEMD_PIDS, result, cause = create_process_get_pid( - config, SYSTEMD_CGNAME, - os.path.join(SLICE, SCOPE) - ) - - OTHER_PIDS, result, tmp_cause = create_process_get_pid( - config, OTHER_CGNAME, - ignore_systemd=True - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # SYSTEMD_CGNAME already has the pid of the task, that scope was created - # with and killing it will remove the scope, be careful and pick the newly - # spawned task - SYSTEMD_PIDS = SYSTEMD_PIDS[1] - - return result, cause - - -def teardown(config): - global SYSTEMD_PIDS, OTHER_PIDS - - Process.kill(config, SYSTEMD_PIDS) - Process.kill(config, OTHER_PIDS) - - # We need a pause, so that cgroup.procs gets updated. - time.sleep(1) - - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/069-sudo-systemd_cgxget-cpu-settings-v1.py b/lib/libcgroup-3.1.0/tests/ftests/069-sudo-systemd_cgxget-cpu-settings-v1.py deleted file mode 100755 index 4faa507ff47..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/069-sudo-systemd_cgxget-cpu-settings-v1.py +++ /dev/null @@ -1,169 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgxget/cgxset functionality test - '-b' '-g' (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '069_cg_in_scope' -OTHER_CGNAME = '069_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test069.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '069cgconfig.conf') - -CGRP_VER_V1 = CgroupVersion.CGROUP_V1 -CGRP_VER_V2 = CgroupVersion.CGROUP_V2 - -TABLE = [ - # writesetting, writeval, writever, readsetting, readval, readver - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.shares', '512', CGRP_VER_V1], - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.weight', '50', CGRP_VER_V2], - - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.shares', '2048', CGRP_VER_V1], - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.weight', '200', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '10000', CGRP_VER_V1, - 'cpu.cfs_quota_us', '10000', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.cfs_period_us', '100000', CGRP_VER_V1], - ['cpu.cfs_period_us', '50000', CGRP_VER_V1, - 'cpu.max', '10000 50000', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '-1', CGRP_VER_V1, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.max', 'max 100000', CGRP_VER_V2], - - ['cpu.max', '5000 25000', CGRP_VER_V2, - 'cpu.max', '5000 25000', CGRP_VER_V2], - ['cpu.max', '6000 26000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '6000', CGRP_VER_V1], - ['cpu.max', '7000 27000', CGRP_VER_V2, - 'cpu.cfs_period_us', '27000', CGRP_VER_V1], - - ['cpu.max', 'max 40000', CGRP_VER_V2, - 'cpu.max', 'max 40000', CGRP_VER_V2], - ['cpu.max', 'max 41000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], -] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, CONTROLLER, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/{}/'.format(SYSTEMD_CGNAME, CONTROLLER, SLICE, SCOPE) - ) - return result, cause - - # create and check if the cgroup was created under the controller sub-tree - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cgrps = {SYSTEMD_CGNAME: False, OTHER_CGNAME: True} - for i in cgrps: - for entry in TABLE: - Cgroup.xset(config, cgname=i, setting=entry[0], value=entry[1], - version=entry[2], ignore_systemd=cgrps[i]) - - out = Cgroup.xget(config, cgname=i, setting=entry[3], - version=entry[5], values_only=True, - print_headers=False, ignore_systemd=cgrps[i]) - if out != entry[4]: - result = consts.TEST_FAILED - tmp_cause = ( - 'After setting {}={}, expected {}={}, but received ' - '{}={}'.format(entry[0], entry[1], entry[3], entry[4], - entry[3], out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/070-sudo-systemd_cgxget-cpu-settings-v2.py b/lib/libcgroup-3.1.0/tests/ftests/070-sudo-systemd_cgxget-cpu-settings-v2.py deleted file mode 100755 index 9e6fe05c394..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/070-sudo-systemd_cgxget-cpu-settings-v2.py +++ /dev/null @@ -1,180 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Advanced cgxget/cgxset functionality test - '-b' '-g' (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -from systemd import Systemd -from run import RunError -import consts -import ftests -import sys -import os - - -CONTROLLER = 'cpu' -SYSTEMD_CGNAME = '070_cg_in_scope' -OTHER_CGNAME = '070_cg_not_in_scope' - -SLICE = 'libcgtests.slice' -SCOPE = 'test070.scope' - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '070cgconfig.conf') - -CGRP_VER_V1 = CgroupVersion.CGROUP_V1 -CGRP_VER_V2 = CgroupVersion.CGROUP_V2 - -TABLE = [ - # writesetting, writeval, writever, readsetting, readval, readver - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.shares', '512', CGRP_VER_V1], - ['cpu.shares', '512', CGRP_VER_V1, 'cpu.weight', '50', CGRP_VER_V2], - - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.shares', '2048', CGRP_VER_V1], - ['cpu.weight', '200', CGRP_VER_V2, 'cpu.weight', '200', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '10000', CGRP_VER_V1, - 'cpu.cfs_quota_us', '10000', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.cfs_period_us', '100000', CGRP_VER_V1], - ['cpu.cfs_period_us', '50000', CGRP_VER_V1, - 'cpu.max', '10000 50000', CGRP_VER_V2], - - ['cpu.cfs_quota_us', '-1', CGRP_VER_V1, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], - ['cpu.cfs_period_us', '100000', CGRP_VER_V1, - 'cpu.max', 'max 100000', CGRP_VER_V2], - - ['cpu.max', '5000 25000', CGRP_VER_V2, - 'cpu.max', '5000 25000', CGRP_VER_V2], - ['cpu.max', '6000 26000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '6000', CGRP_VER_V1], - ['cpu.max', '7000 27000', CGRP_VER_V2, - 'cpu.cfs_period_us', '27000', CGRP_VER_V1], - - ['cpu.max', 'max 40000', CGRP_VER_V2, - 'cpu.max', 'max 40000', CGRP_VER_V2], - ['cpu.max', 'max 41000', CGRP_VER_V2, - 'cpu.cfs_quota_us', '-1', CGRP_VER_V1], -] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V2: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v2 cpu controller' - return result, cause - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - pid = Systemd.write_config_with_pid(config, CONFIG_FILE_NAME, SLICE, SCOPE) - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - # create and check if the cgroup was created under the systemd default path - if not Cgroup.create_and_validate(config, None, SYSTEMD_CGNAME): - result = consts.TEST_FAILED - cause = ( - 'Failed to create systemd delegated cgroup {} under ' - '/sys/fs/cgroup/{}/{}/'.format(SYSTEMD_CGNAME, SLICE, SCOPE) - ) - return result, cause - - # With cgroup v2, we can't enable controller for the child cgroup, while - # a task is attached to test070.scope. Attach the task from test070.scope - # to child cgroup SYSTEMD_CGNAME and then enable cpu controller in the parent, - # so that the cgroup.get() works - Cgroup.set(config, cgname=SYSTEMD_CGNAME, setting='cgroup.procs', value=pid) - - Cgroup.set( - config, cgname=(os.path.join(SLICE, SCOPE)), setting='cgroup.subtree_control', - value='+cpu', ignore_systemd=True - ) - - # create and check if the cgroup was created under the controller root - if not Cgroup.create_and_validate(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True): - result = consts.TEST_FAILED - cause = ( - 'Failed to create cgroup {} under ' - '/sys/fs/cgroup/{}/'.format(OTHER_CGNAME, CONTROLLER) - ) - - return result, cause - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cgrps = {SYSTEMD_CGNAME: False, OTHER_CGNAME: True} - for i in cgrps: - for entry in TABLE: - Cgroup.xset(config, cgname=i, setting=entry[0], value=entry[1], - version=entry[2], ignore_systemd=cgrps[i]) - - out = Cgroup.xget(config, cgname=i, setting=entry[3], - version=entry[5], values_only=True, - print_headers=False, ignore_systemd=cgrps[i]) - if out != entry[4]: - result = consts.TEST_FAILED - tmp_cause = ( - 'After setting {}={}, expected {}={}, but received ' - '{}={}'.format(entry[0], entry[1], entry[3], entry[4], - entry[3], out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Systemd.remove_scope_slice_conf(config, SLICE, SCOPE, CONTROLLER, CONFIG_FILE_NAME) - - # Incase the error occurs before the creation of OTHER_CGNAME, - # let's ignore the exception - try: - Cgroup.delete(config, CONTROLLER, OTHER_CGNAME, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause] = setup(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/071-sudo-set_default_systemd_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/071-sudo-set_default_systemd_cgroup.py deleted file mode 100755 index 2c45320375b..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/071-sudo-set_default_systemd_cgroup.py +++ /dev/null @@ -1,187 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# set_default_systemd_cgroup functionality test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# Author: Tom Hromatka -# - -from libcgroup import Version, Cgroup, Mode -from cgroup import Cgroup as CgroupCli -from process import Process -import consts -import ftests -import time -import sys -import os - - -OTHER_CGNAME = '071_cg_not_in_scope' -SLICE = 'libcgtests.slice' -SCOPE = 'test071.scope' - -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Test 1 - Ensure _set_default_systemd_cgroup() throws an exception if - # libcgroup doesn't set a default (slice/scope) cgroup path - # - try: - Cgroup._set_default_systemd_cgroup() - except RuntimeError as re: - if 'Failed to set' not in str(re): - result = consts.TEST_FAILED - cause = 'Expected \'Failed to set\' to be in the exception, ' \ - 'received {}'.format(str(re)) - else: - result = consts.TEST_FAILED - cause = '_set_default_systemd_cgroup() erroneously passed' - - # - # Test 2 - write_default_systemd_scope() should succeed if the slice/scope - # are invalid and we're not setting it as the default. If we - # create a cgroup at this point, it should be created at the root - # cgroup level, and the default slice/scope should have no bearing - # - Cgroup.write_default_systemd_scope(SLICE, SCOPE, False) - - pid = config.process.create_process(config) - cg = Cgroup(OTHER_CGNAME, Version.CGROUP_V2) - cg.add_controller(CONTROLLER) - cg.create() - Cgroup.move_process(pid, OTHER_CGNAME, CONTROLLER) - cg_pid = cg.get_processes()[0] - - if pid != cg_pid: - result = consts.TEST_FAILED - tmp_cause = 'Expected pid {} to be in {} cgroup, but received pid {} ' \ - 'via python bindings instead'.format(pid, OTHER_CGNAME, cg_pid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - cli_pid = CgroupCli.get_pids_in_cgroup(config, OTHER_CGNAME, CONTROLLER)[0] - - if pid != cli_pid: - result = consts.TEST_FAILED - tmp_cause = 'Expected pid {} to be in {} cgroup, but received pid {} ' \ - 'via CLI instead'.format(pid, OTHER_CGNAME, cli_pid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - Process.kill(config, pid) - cg.delete() - - # - # Test 3 - Write the slice/scope and attempt to set them as the default. - # This should fail because they haven't been created yet, and thus - # it's an invalid path - # - try: - Cgroup.write_default_systemd_scope(SLICE, SCOPE, True) - except RuntimeError as re: - if 'Failed to set' not in str(re): - result = consts.TEST_FAILED - tmp_cause = 'Expected \'Failed to set\' to be in the exception, ' \ - 'received {}'.format(str(re)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - else: - result = consts.TEST_FAILED - tmp_cause = 'write_default_systemd_scope() erroneously passed' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 4 - Create a systemd scope and set it as the default. Everything - # should work properly in this case - # - pid = None - if Cgroup.cgroup_mode() != Mode.CGROUP_MODE_LEGACY: - pid = config.process.create_process(config) - Cgroup.create_scope(SCOPE, SLICE, pid=pid) - Cgroup.write_default_systemd_scope(SLICE, SCOPE) - - cg = Cgroup('/', Version.CGROUP_V2) - cg_pid = cg.get_processes()[0] - - if pid != cg_pid: - result = consts.TEST_FAILED - tmp_cause = 'Expected pid {} to be in \'/\' cgroup, but received pid {} ' \ - 'instead'.format(pid, cg_pid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - path = Cgroup.get_current_controller_path(pid) - if path != os.path.join('/', SLICE, SCOPE): - result = consts.TEST_FAILED - tmp_cause = 'Expected pid path to be: {}, but received path {} ' \ - 'instead'.format(os.path.join('/', SLICE, SCOPE), path) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - cli_pid = CgroupCli.get_pids_in_cgroup(config, os.path.join(SLICE, SCOPE), CONTROLLER)[0] - - if pid != cli_pid: - result = consts.TEST_FAILED - tmp_cause = 'Expected pid {} to be in {} cgroup, but received pid {} ' \ - 'via CLI instead'.format(pid, os.path.join(SLICE, SCOPE), cli_pid) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause, pid - - -def teardown(config, pid): - if pid: - Process.kill(config, pid) - - # Give systemd a chance to remove the scope - time.sleep(0.5) - - Cgroup.clear_default_systemd_scope() - - try: - cg = Cgroup(SLICE, Version.CGROUP_V2) - cg.delete() - except RuntimeError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - try: - pid = None - [result, cause, pid] = test(config) - finally: - teardown(config, pid) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/072-pybindings-cgroup_get_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/072-pybindings-cgroup_get_cgroup.py deleted file mode 100755 index d2af60b3f2e..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/072-pybindings-cgroup_get_cgroup.py +++ /dev/null @@ -1,142 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_get_cgroup() test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, Mode -from libcgroup import Cgroup, Version -import consts -import ftests -import sys -import os - - -CGNAME = '072cggetcg/childcg' -CONTROLLERS = ['cpu', 'memory', 'io', 'pids'] - -CGNAME2 = '{}/grandchildcg'.format(CGNAME) - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.cgroup_mode() != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup v2 hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLERS, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Test 1 - Ensure all enabled controllers get populated - # - cgall = Cgroup(CGNAME, Version.CGROUP_V2) - cgall.get() - - if len(cgall.controllers) != len(CONTROLLERS): - result = consts.TEST_FAILED - tmp_cause = 'Expected {} controllers in cgall but received {}'.format( - len(CONTROLLERS), len(cgall.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 2 - Ensure the user can read the "cgroup" pseudo-controller - # - cgcg = Cgroup(CGNAME, Version.CGROUP_V2) - cgcg.add_controller('cgroup') - cgcg.get() - - if len(cgcg.controllers) != 1 or 'cgroup' not in cgcg.controllers.keys(): - result = consts.TEST_FAILED - tmp_cause = 'Expected 1 controller in cgcg but received {}'.format(len(cgcg.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 3 - Ensure the user can read a disabled controller - # - cgcpuset = Cgroup(CGNAME, Version.CGROUP_V2) - cgcpuset.add_controller('cpuset') - cgcpuset.get() - - if len(cgcpuset.controllers) != 1 or 'cpuset' not in cgcpuset.controllers.keys(): - result = consts.TEST_FAILED - tmp_cause = 'Expected 1 controller in cgcpuset but received {}'.format( - len(cgcpuset.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 4 - Ensure the user can read a cgroup with a mix of enabled and hidden controllers - # - cgmix = Cgroup(CGNAME, Version.CGROUP_V2) - cgmix.add_controller('cpuset') - cgmix.add_controller('cgroup') - cgmix.add_controller('memory') - cgmix.get() - - if len(cgmix.controllers) != 3 or 'cpuset' not in cgmix.controllers.keys() or \ - 'cgroup' not in cgmix.controllers.keys() or 'memory' not in cgmix.controllers.keys(): - result = consts.TEST_FAILED - tmp_cause = 'Expected 3 controller in cgmix but received {}'.format( - len(cgcpuset.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 5 - Create a parent/child cgroup with no controllers enabled. Ensure the user can get - # the cgroup with no errors. .get() should populate zero cgroups - # - CgroupCli.subtree_control(config, CGNAME, CONTROLLERS, enable=False, ignore_systemd=True) - CgroupCli.create(config, None, CGNAME2) - - cgempty = Cgroup(CGNAME2, Version.CGROUP_V2) - cgempty.get() - - if len(cgempty.controllers) != 0: - result = consts.TEST_FAILED - tmp_cause = 'Expected 0 controller in cgempty but received {}'.format( - len(cgcpuset.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLERS, CGNAME2, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/073-pybindings-cgroup_add_all_controllers-v2.py b/lib/libcgroup-3.1.0/tests/ftests/073-pybindings-cgroup_add_all_controllers-v2.py deleted file mode 100755 index f4ef20f51a6..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/073-pybindings-cgroup_add_all_controllers-v2.py +++ /dev/null @@ -1,100 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_add_all_controllers() test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from libcgroup import Cgroup, Version, Mode -from cgroup import Cgroup as CgroupCli -import consts -import ftests -import sys -import os - - -PARENTCG = '073cgggetcg' -CGNAME = '{}/child'.format(PARENTCG) -CONTROLLERS = ['cpu', 'memory', 'pids'] -SUBTREE_CONTROL = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupCli.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLERS, PARENTCG) - - # Ensure that the subtree control file differs from the cgroup.controllers file - CgroupCli.subtree_control(config, PARENTCG, CONTROLLERS, enable=False, ignore_systemd=True) - CgroupCli.subtree_control(config, PARENTCG, SUBTREE_CONTROL, enable=True, ignore_systemd=True) - CgroupCli.get_and_validate(config, PARENTCG, 'cgroup.subtree_control', SUBTREE_CONTROL, True) - - CgroupCli.create(config, CONTROLLERS, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cgget = Cgroup(CGNAME, Version.CGROUP_V2) - cgget.get() - - cgall = Cgroup(CGNAME, Version.CGROUP_V2) - cgall.add_all_controllers() - cgall.get() - - if len(CONTROLLERS) != len(cgall.controllers): - result = consts.TEST_FAILED - tmp_cause = 'Expected {} controllers in cgall but received {}'.format( - len(CONTROLLERS), len(cgall.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - if len(str(cgall)) != len(str(cgget)): - result = consts.TEST_FAILED - tmp_cause = 'Expected {} lines in cgall but received {}'.format( - len(str(cgget)), len(str(cgall))) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLERS, CGNAME) - CgroupCli.delete(config, CONTROLLERS, PARENTCG) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/074-pybindings-cgroup_add_all_controllers-v1.py b/lib/libcgroup-3.1.0/tests/ftests/074-pybindings-cgroup_add_all_controllers-v1.py deleted file mode 100755 index 1207bb29a20..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/074-pybindings-cgroup_add_all_controllers-v1.py +++ /dev/null @@ -1,90 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_add_all_controllers() test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from libcgroup import Cgroup, Version, Mode -from cgroup import Cgroup as CgroupCli -import consts -import ftests -import sys -import os - -CGNAME = '074cggetcg/child' -CONTROLLERS = ['cpu', 'memory', 'pids'] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupCli.get_cgroup_mode(config) != Mode.CGROUP_MODE_LEGACY: - result = consts.TEST_SKIPPED - cause = 'This test requires the legacy cgroup hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLERS, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - cgall = Cgroup(CGNAME, Version.CGROUP_V1) - cgall.add_all_controllers() - cgall.get() - - controllers = list() - with open('/proc/cgroups') as pc: - for i, line in enumerate(pc.readlines()): - if i == 0: - continue - if int(line.split()[1]) > 0: - # If the hierarchy is greater than zero, then use the controller - controllers.append(line.split()[0]) - - if len(controllers) != len(cgall.controllers): - result = consts.TEST_FAILED - tmp_cause = 'Expected {} controllers in cgall but received {}'.format( - len(CONTROLLERS), len(cgall.controllers)) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - for controller in CONTROLLERS: - if len(str(cgall.controllers[controller])) <= 1: - result = consts.TEST_FAILED - tmp_cause = 'Controller {} was not populated'.format(controller) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLERS, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/075-pybindings-cgroup_compare_cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/075-pybindings-cgroup_compare_cgroup.py deleted file mode 100755 index 21bf2bd4124..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/075-pybindings-cgroup_compare_cgroup.py +++ /dev/null @@ -1,197 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_compare_cgroup() test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli, Mode -from libcgroup import Cgroup, Version -import consts -import ftests -import sys -import os - -CGNAME = '075cgcompare/compare' -CONTROLLERS = ['cpu', 'memory', 'io', 'pids'] - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.cgroup_mode() != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup v2 hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLERS, CGNAME) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Test 1 - Compare matching empty cgroup instances - # - cgempty1 = Cgroup(CGNAME, Version.CGROUP_V2) - cgempty2 = Cgroup(CGNAME, Version.CGROUP_V2) - - if cgempty1 != cgempty2: - result = consts.TEST_FAILED - cause = 'Empty cgroups do not match' - - # - # Test 2 - Compare different empty cgroup instances - # - cgempty3 = Cgroup('foo', Version.CGROUP_V2) - cgempty4 = Cgroup('bar', Version.CGROUP_V2) - - if cgempty3 == cgempty4: - result = consts.TEST_FAILED - tmp_cause = 'Empty cgroups erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 3 - Compare different empty cgroup instances - # - cgempty5 = Cgroup('baz', Version.CGROUP_V1) - cgempty6 = Cgroup('baz', Version.CGROUP_V2) - - if cgempty5 == cgempty6: - result = consts.TEST_FAILED - tmp_cause = 'Empty cgroups erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 4 - Compare cgroups with only the controllers populated - # - cgctrl1 = Cgroup(CGNAME, Version.CGROUP_V2) - cgctrl1.add_all_controllers() - - cgctrl2 = Cgroup(CGNAME, Version.CGROUP_V2) - for controller in CONTROLLERS: - cgctrl2.add_controller(controller) - - if cgctrl1 != cgctrl2: - result = consts.TEST_FAILED - tmp_cause = 'Controller-only cgroups do not match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 5 - Compare populated cgroups - # - cgget1 = Cgroup(CGNAME, Version.CGROUP_V2) - cgget1.add_all_controllers() - cgget1.get() - - cgget2 = Cgroup(CGNAME, Version.CGROUP_V2) - cgget2.get() - - if cgget1 != cgget2: - result = consts.TEST_FAILED - tmp_cause = 'cgget1 and cgget2 cgroups do not match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 6 - Compare cgroups with differing uid/gids - # - cguid1 = Cgroup(CGNAME, Version.CGROUP_V2) - cguid1.set_uid_gid(123, 456, 789, 987) - cguid1.add_all_controllers() - - cguid2 = Cgroup(CGNAME, Version.CGROUP_V2) - cguid2.set_uid_gid(123, 456, 789, 9870) - cguid2.add_all_controllers() - - if cguid1 == cguid2: - result = consts.TEST_FAILED - tmp_cause = 'cguid1 and cguid2 erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - cguid2.set_uid_gid(123, 456, 7890, 987) - if cguid1 == cguid2: - result = consts.TEST_FAILED - tmp_cause = 'cguid1 and cguid2 erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - cguid2.set_uid_gid(123, 4560, 789, 987) - if cguid1 == cguid2: - result = consts.TEST_FAILED - tmp_cause = 'cguid1 and cguid2 erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - cguid2.set_uid_gid(1230, 456, 789, 987) - if cguid1 == cguid2: - result = consts.TEST_FAILED - tmp_cause = 'cguid1 and cguid2 erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 7 - Compare cgroups with matching uid/gids - # - cguid3 = Cgroup(CGNAME, Version.CGROUP_V2) - cguid3.set_uid_gid(2345, 678, 9012, 3456) - cguid3.add_all_controllers() - - cguid4 = Cgroup(CGNAME, Version.CGROUP_V2) - cguid4.set_uid_gid(2345, 678, 9012, 3456) - cguid4.add_all_controllers() - - if cguid3 != cguid4: - result = consts.TEST_FAILED - tmp_cause = 'cguid3 and cguid4 do not match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 8 - Compare cgroups with different controller counts - # - cgctrl3 = Cgroup(CGNAME, Version.CGROUP_V2) - cgctrl3.add_controller(CONTROLLERS[0]) - cgctrl3.add_controller(CONTROLLERS[1]) - - cgctrl4 = Cgroup(CGNAME, Version.CGROUP_V2) - cgctrl4.add_controller(CONTROLLERS[0]) - - if cgctrl3 == cgctrl4: - result = consts.TEST_FAILED - tmp_cause = 'controller-only cgroups erroneously match' - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - CgroupCli.delete(config, CONTROLLERS, CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/076-cgconfig-auto_convert.py b/lib/libcgroup-3.1.0/tests/ftests/076-cgconfig-auto_convert.py deleted file mode 100755 index 751feb2684a..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/076-cgconfig-auto_convert.py +++ /dev/null @@ -1,113 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgconfigparser auto convert functionality test using a configuration file -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup, CgroupVersion -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' - -CGNAME_V1 = '076cgconfig_v1' -CFS_PERIOD = '100000' -CFS_QUOTA = '50000' -CPU_SHARES = '1024' - -CGNAME_V2 = '076cgconfig_v2' -CFS_MAX = '"max 100000"' -CPU_WEIGHT = '50' - -CONFIG_FILE = ''' -group {} {{ - {} {{ - cpu.cfs_period_us = {}; - cpu.cfs_quota_us = {}; - cpu.shares = {}; - }} -}} -group {} {{ - {} {{ - cpu.max = {}; - cpu.weight = {}; - }} -}}'''.format( - CGNAME_V1, CONTROLLER, CFS_PERIOD, CFS_QUOTA, CPU_SHARES, - CGNAME_V2, CONTROLLER, CFS_MAX, CPU_WEIGHT - ) - -CONFIG_FILE_NAME = os.path.join(os.getcwd(), '078cgconfig.conf') - -TABLE = [ - [CGNAME_V1, 'cpu.weight', CgroupVersion.CGROUP_V2, '100'], - [CGNAME_V1, 'cpu.max', CgroupVersion.CGROUP_V2, '50000 100000'], - [CGNAME_V2, 'cpu.shares', CgroupVersion.CGROUP_V1, '512'], - [CGNAME_V2, 'cpu.cfs_period_us', CgroupVersion.CGROUP_V1, '100000'], - [CGNAME_V2, 'cpu.cfs_quota_us', CgroupVersion.CGROUP_V1, '-1'], - ] - - -def prereqs(config): - return consts.TEST_PASSED, None - - -def setup(config): - f = open(CONFIG_FILE_NAME, 'w') - f.write(CONFIG_FILE) - f.close() - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.configparser(config, load_file=CONFIG_FILE_NAME) - - for entry in TABLE: - out = Cgroup.xget( - config, cgname=entry[0], setting=entry[1], - version=entry[2], values_only=True, print_headers=False - ) - - if out != entry[3]: - result = consts.TEST_FAILED - tmp_cause = ( - 'Expected {}={}, received {}={} ' - ''.format(entry[1], entry[3], entry[1], out) - ) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, CGNAME_V1) - Cgroup.delete(config, CONTROLLER, CGNAME_V2) - os.remove(CONFIG_FILE_NAME) - - -def main(config): - [result, cause] = prereqs(config) - - try: - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/077-pybindings-cgroup_get_procs.py b/lib/libcgroup-3.1.0/tests/ftests/077-pybindings-cgroup_get_procs.py deleted file mode 100755 index f1557897963..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/077-pybindings-cgroup_get_procs.py +++ /dev/null @@ -1,111 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_get_procs() test using the python bindings -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Version -from process import Process -import consts -import ftests -import sys -import os - - -CGNAME = '077getprocs/cgwithpids' -EMPTY_CGNAME = '077getprocs/cgwithoutpids' -CONTROLLERS = ['cpu', 'pids'] -PID_CNT = 20 - -initial_pid_list = list() - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - global initial_pid_list - CgroupCli.create(config, CONTROLLERS, CGNAME) - CgroupCli.create(config, CONTROLLERS, EMPTY_CGNAME) - - for i in range(0, PID_CNT): - pid = config.process.create_process(config) - initial_pid_list.append(pid) - - CgroupCli.classify(config, CONTROLLERS, CGNAME, initial_pid_list, ignore_systemd=True) - initial_pid_list = initial_pid_list.sort() - - -def test(config): - global initial_pid_list - result = consts.TEST_PASSED - cause = None - - # - # Test 1 - verify pids are properly populated and retrieved from a cgroup - # - cg = Cgroup(CGNAME, Version.CGROUP_V2) - for controller in CONTROLLERS: - cg.add_controller(controller) - pid_list = cg.get_processes().sort() - - if pid_list != initial_pid_list: - result = consts.TEST_FAILED - tmp_cause = 'The pid lists do not match\n{}\n{}'.format(initial_pid_list, pid_list) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 2 - verify there are no pids in the empty cgroup - # - emptycg = Cgroup(EMPTY_CGNAME, Version.CGROUP_V2) - for controller in CONTROLLERS: - emptycg.add_controller(controller) - empty_pid_list = emptycg.get_processes() - - if len(empty_pid_list) != 0: - result = consts.TEST_FAILED - tmp_cause = 'The pid list unexpectedly was populated\n{}'.format(empty_pid_list) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - return result, cause - - -def teardown(config): - global initial_pid_list - - Process.kill(config, initial_pid_list) - CgroupCli.delete(config, CONTROLLERS, EMPTY_CGNAME) - CgroupCli.delete(config, CONTROLLERS, os.path.dirname(CGNAME), recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/078-sudo-cgcreate_systemd_scope.py b/lib/libcgroup-3.1.0/tests/ftests/078-sudo-cgcreate_systemd_scope.py deleted file mode 100755 index 48897d567b7..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/078-sudo-cgcreate_systemd_scope.py +++ /dev/null @@ -1,108 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to create a systemd scope using cgcreate -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -from process import Process -from libcgroup import Mode -from run import RunError -from log import Log -import consts -import ftests -import sys -import os - -CONTROLLERS = ['cpu', 'pids'] -SLICE = 'libcgroup.slice' -CGNAME = os.path.join(SLICE, '078cgcreate.scope') -IN_SCOPE_CHILD_CGNAME = os.path.join(CGNAME, 'in_scope_childcg') -OUT_OF_SCOPE_CHILD_CGNAME = '078outofscopechild' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.create_and_validate(config, CONTROLLERS, CGNAME, create_scope=True) - - # get the placeholder PID that libcgroup placed in the scope - try: - pid = int(Cgroup.get(config, None, CGNAME, setting='cgroup.procs', - print_headers=False, values_only=True, ignore_systemd=True)) - # use the pid variable so that lint is happy - Log.log_debug('Cgroup {} has pid {}'.format(CGNAME, pid)) - except RunError: - result = consts.TEST_FAILED - cause = 'Failed to read pid in {}\'s cgroup.procs'.format(CGNAME) - return result, cause - - # Since the scope was created without being made the default, we must specify - # the entire path to operate on a child cgroup below the scope. - Cgroup.create_and_validate(config, None, IN_SCOPE_CHILD_CGNAME) - Cgroup.create_and_validate(config, None, OUT_OF_SCOPE_CHILD_CGNAME) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, None, IN_SCOPE_CHILD_CGNAME) - Cgroup.delete(config, None, OUT_OF_SCOPE_CHILD_CGNAME) - - pid = int(Cgroup.get(config, None, CGNAME, setting='cgroup.procs', - print_headers=False, values_only=True, ignore_systemd=True)) - Process.kill(config, pid) - - # systemd will automatically remove the cgroup once there are no more pids in - # the cgroup, so we don't need to delete CGNAME. But let's try to remove the - # slice - try: - Cgroup.delete(config, CONTROLLERS, SLICE) - except RunError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/079-sudo-cgcreate_default_systemd_scope.py b/lib/libcgroup-3.1.0/tests/ftests/079-sudo-cgcreate_default_systemd_scope.py deleted file mode 100755 index c42d371a340..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/079-sudo-cgcreate_default_systemd_scope.py +++ /dev/null @@ -1,104 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to create a default systemd scope using cgcreate -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup -from process import Process -from libcgroup import Mode -from run import RunError -from log import Log -import consts -import ftests -import sys -import os - -CONTROLLERS = ['cpu', 'pids'] -SLICE = 'libcgroup.slice' -SCOPE_CGNAME = os.path.join(SLICE, '079cgcreate.scope') -CHILD_CGNAME = 'childcg' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.create_and_validate(config, CONTROLLERS, SCOPE_CGNAME, create_scope=True, - set_default_scope=True) - - # get the placeholder PID that libcgroup placed in the scope - try: - pid = int(Cgroup.get(config, None, SCOPE_CGNAME, setting='cgroup.procs', - print_headers=False, values_only=True, ignore_systemd=True)) - # use the pid variable so that lint is happy - Log.log_debug('Cgroup {} has pid {}'.format(SCOPE_CGNAME, pid)) - except RunError: - result = consts.TEST_FAILED - cause = 'Failed to read pid in {}\'s cgroup.procs'.format(SCOPE_CGNAME) - return result, cause - - Cgroup.create_and_validate(config, None, CHILD_CGNAME) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, None, CHILD_CGNAME) - - pid = int(Cgroup.get(config, None, SCOPE_CGNAME, setting='cgroup.procs', - print_headers=False, values_only=True, ignore_systemd=True)) - Process.kill(config, pid) - - # systemd will automatically remove the cgroup once there are no more pids in - # the cgroup, so we don't need to delete CGNAME. But let's try to remove the - # slice - try: - Cgroup.delete(config, CONTROLLERS, SLICE) - except RunError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/080-kernel-domain_invalid.py b/lib/libcgroup-3.1.0/tests/ftests/080-kernel-domain_invalid.py deleted file mode 100755 index 79fdf74c321..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/080-kernel-domain_invalid.py +++ /dev/null @@ -1,102 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to exercise that libcgroup properly handles cgroups that are marked as "domain invalid" -# -# Copyright (c) 2023 Oracle and/or its affiliates -# Author: Tom Hromatka -# - -from cgroup import Cgroup as Cgroup, Mode -from process import Process -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -PARENTCG = '080domaininvalid' -CHILDCG = os.path.join(PARENTCG, 'childcg') -GRANDCHILDCG = os.path.join(CHILDCG, 'grandchildcg') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if Cgroup.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup v2 hierarchy' - - return result, cause - - -def setup(config): - Cgroup.create(config, CONTROLLER, PARENTCG) - Cgroup.create(config, CONTROLLER, CHILDCG) - - config.process.create_process_in_cgroup(config, CONTROLLER, PARENTCG, ignore_systemd=True) - - -def test(config): - # - # test 1 - ensure that we can create and delete a cgroup (with no controllers) under a - # parent whose type is 'domain invalid' - # - Cgroup.create_and_validate(config, None, GRANDCHILDCG) - Cgroup.delete(config, None, GRANDCHILDCG) - - # - # test 2 - attempt to add a process to the child cgroup. the kernel should not allow this, - # and libcgroup needs to handle this - # - pid = config.process.create_process(config) - try: - Cgroup.classify(config, CONTROLLER, CHILDCG, pid) - except RunError as re: - if 'Operation not supported' not in re.stderr: - raise re - finally: - Process.kill(config, pid) - - # - # test 3 - attempt to enable a controller that enforces the no-processes-in-non-leaf-nodes - # rule. the kernel should not allow this - # - try: - Cgroup.subtree_control(config, CHILDCG, 'memory') - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - - return consts.TEST_PASSED, None - - -def teardown(config): - pids = Cgroup.get_pids_in_cgroup(config, PARENTCG, CONTROLLER) - Process.kill(config, pids) - - Cgroup.delete(config, CONTROLLER, CHILDCG) - Cgroup.delete(config, CONTROLLER, PARENTCG) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/081-pybindings-cgrp_get_curr_ctrl_path-v1.py b/lib/libcgroup-3.1.0/tests/ftests/081-pybindings-cgrp_get_curr_ctrl_path-v1.py deleted file mode 100755 index d4a07b732ab..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/081-pybindings-cgrp_get_curr_ctrl_path-v1.py +++ /dev/null @@ -1,133 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_get_current_controller_path() test using the python bindings (cgroup v1) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup as CgroupCli, Mode -from libcgroup import Cgroup, Version -from process import Process -import consts -import ftests -import sys -import os - - -CGNAME = '081getctrlpathv1' -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.cgroup_mode() == Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the legacy cgroup v1 hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLER, CGNAME) - - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, ignore_systemd=True) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - expected_path = "/" + CGNAME - pid = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - - cgrp = Cgroup(CGNAME, Version.CGROUP_V2) - # - # Test 1 - get the relative path of cgroup, for the pid's cpu controller. - # It's expected to pass because we had created cgroup on cpu - # hierarchy and moved the task to that group. - # - cgrp_path = cgrp.get_current_controller_path(pid, CONTROLLER) - if cgrp_path != expected_path: - result = consts.TEST_FAILED - cause = 'Expected cgroup path {} got {}'.format(expected_path, cgrp_path) - - # - # Test 2 - get the relative path of cgroup, for the pid's memory controller. - # It's expected to fail because we not had created cgroup. - # - cgrp_path = cgrp.get_current_controller_path(pid, "memory") - if cgrp_path == expected_path: - result = consts.TEST_FAILED - tmp_cause = 'cgroup path unexpectedly formed {}'.format(cgrp_path) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 3 - get the relative path of cgroup, for the pid's invalid controller. - # It's expected to fail because such controller doesn't exists. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, "invalid") - except RuntimeError as re: - if '50011' not in str(re): - raise re - - # - # Test 4 - get the relative path of cgroup, for the pid's pass NULL as - # controller. It's expected to fail because it's not supported - # cgroup v1. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, None) - except RuntimeError as re: - if '50016' not in str(re): - raise re - - # - # Test 5 - get the relative path of cgroup, for the pid's pass int as - # controller. It's expected to fail because string is expected - # for the controller name. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, 1234) - except TypeError as re: - if 'expected controller type string, but passed' not in str(re): - raise re - - return result, cause - - -def teardown(config): - pid = CgroupCli.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - Process.kill(config, pid) - - CgroupCli.delete(config, CONTROLLER, CGNAME) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/082-pybindings-cgrp_get_curr_ctrl_path-v2.py b/lib/libcgroup-3.1.0/tests/ftests/082-pybindings-cgrp_get_curr_ctrl_path-v2.py deleted file mode 100755 index 1426619fe74..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/082-pybindings-cgrp_get_curr_ctrl_path-v2.py +++ /dev/null @@ -1,134 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# cgroup_get_current_controller_path() test using the python bindings (cgroup v2) -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup as CgroupCli, Mode -from libcgroup import Cgroup, Version -from process import Process -import consts -import ftests -import sys -import os - - -CGNAME = '082getctrlpathv2' -CHILDCG = '082getctrlpathv2/childcg' -CONTROLLER = 'cpu' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.cgroup_mode() != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup v2 hierarchy' - - return result, cause - - -def setup(config): - CgroupCli.create(config, CONTROLLER, CGNAME) - CgroupCli.create(config, CONTROLLER, CHILDCG) - - config.process.create_process_in_cgroup(config, CONTROLLER, CHILDCG, ignore_systemd=True) - - -def test(config): - result = consts.TEST_PASSED - cause = None - - expected_path = "/" + CHILDCG - pid = CgroupCli.get_pids_in_cgroup(config, CHILDCG, CONTROLLER)[0] - cgrp = Cgroup(CGNAME, Version.CGROUP_V2) - - # - # Test 1 - get the relative path of cgroup, for the pid's cpu controller. - # It's expected to pass because we had created cgroup on cpu - # hierarchy and moved the task to that group. - # - cgrp_path = cgrp.get_current_controller_path(pid, CONTROLLER) - if cgrp_path != expected_path: - result = consts.TEST_FAILED - cause = 'Expected cgroup path {} got {}'.format(expected_path, cgrp_path) - - # - # Test 2 - get the relative path of cgroup, for the pid's memory controller. - # It's expected to fail because we not had created cgroup. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, "memory") - except RuntimeError as re: - if '50001' not in str(re): - raise re - - # - # Test 3 - get the relative path of cgroup, for the pid's invalid controller. - # It's expected to fail because such controller doesn't exists. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, "invalid") - except RuntimeError as re: - if '50011' not in str(re): - raise re - - # - # Test 4 - get the relative path of cgroup, for the pid's pass NULL as - # controller. It's expected to return the path with children. - # - cgrp_path = cgrp.get_current_controller_path(pid) - if cgrp_path != expected_path: - result = consts.TEST_FAILED - tmp_cause = 'Expected cgroup path {} got {}'.format(expected_path, cgrp_path) - cause = '\n'.join(filter(None, [cause, tmp_cause])) - - # - # Test 5 - get the relative path of cgroup, for the pid's pass int as - # controller. It's expected to fail because string is expected - # for the controller name. - # - try: - cgrp_path = cgrp.get_current_controller_path(pid, 1234) - except TypeError as re: - if 'expected controller type string, but passed' not in str(re): - raise re - - return result, cause - - -def teardown(config): - pid = CgroupCli.get_pids_in_cgroup(config, CHILDCG, CONTROLLER)[0] - Process.kill(config, pid) - - CgroupCli.delete(config, CONTROLLER, CGNAME, recursive=True) - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/083-pybindings-helpers_cgroup_mode.py b/lib/libcgroup-3.1.0/tests/ftests/083-pybindings-helpers_cgroup_mode.py deleted file mode 100755 index 8808a03be17..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/083-pybindings-helpers_cgroup_mode.py +++ /dev/null @@ -1,79 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to excerise cgroup_setup_mode() helpers -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup as CgroupCli -from libcgroup import Cgroup, Mode -import consts -import ftests -import sys -import os - - -def prereqs(config): - pass - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - mode1 = Cgroup.cgroup_mode() - mode2 = CgroupCli.get_cgroup_mode(config) - - if mode1 != mode2: - result = consts.TEST_FAILED - cause = 'mode mismatch: libcgroup mode: {}, tests mode: {}'.format(mode1, mode2) - return result, cause - - if mode1 == Mode.CGROUP_MODE_LEGACY: - ret = Cgroup.is_cgroup_mode_legacy() - if ret is False: - result = consts.TEST_FAILED - cause = 'mode mismatch: libcgroup mode: legacy (v1) check, returned false' - elif mode1 == Mode.CGROUP_MODE_HYBRID: - ret = Cgroup.is_cgroup_mode_hybrid() - if ret is False: - result = consts.TEST_FAILED - cause = 'mode mismatch: libcgroup mode: hybrid (v1/v2) check, returned false' - elif mode1 == Mode.CGROUP_MODE_UNIFIED: - ret = Cgroup.is_cgroup_mode_unified() - if ret is False: - result = consts.TEST_FAILED - cause = 'mode mismatch: libcgroup mode: unified (v2) check, returned false' - else: - result = consts.TEST_FAILED - cause = 'Unknown libcgroup mode: {}'.format(mode1) - - return result, cause - - -def teardown(config): - pass - - -def main(config): - prereqs(config) - setup(config) - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/084-sudo-cgcreate_systemd_scope_pid.py b/lib/libcgroup-3.1.0/tests/ftests/084-sudo-cgcreate_systemd_scope_pid.py deleted file mode 100755 index a418928b1fe..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/084-sudo-cgcreate_systemd_scope_pid.py +++ /dev/null @@ -1,141 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to create a systemd scope with pid using cgcreate -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import Cgroup -from process import Process -from libcgroup import Mode -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLERS = ['cpu', 'pids'] -SLICE = 'libcgroup.slice' -CGNAME1 = os.path.join(SLICE, '084cgcreate1.scope') -CGNAME2 = os.path.join(SLICE, '084cgcreate2.scope') - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if Cgroup.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Test 1: Pass invalid task pid as scope_pid and systemd scope creation - # should fail - # - try: - Cgroup.create_and_validate(config, CONTROLLERS, CGNAME1, create_scope=True, - scope_pid=1000000) - except RunError as re: - if 'Process with ID 1000000 does not exist' not in str(re): - raise re - - # - # Test 2: Pass a valid task pid as scope_pid and systemd scope creation - # will succeed. Read the scope cgroup.procs to find if the task - # passed by us was used as scope task. - # - scope_pid = config.process.create_process(config) - Cgroup.create_and_validate(config, CONTROLLERS, CGNAME1, create_scope=True, scope_pid=scope_pid) - - try: - pid = Cgroup.get_pids_in_cgroup(config, CGNAME1, CONTROLLERS[0])[0] - if scope_pid != pid: - result = consts.TEST_FAILED - cause = 'scope created with other pid {}, expected pid {}'.format(pid, scope_pid) - return result, cause - except RunError: - result = consts.TEST_FAILED - cause = 'Failed to read pid in {}\'s cgroup.procs'.format(CGNAME1) - return result, cause - - # - # Test 3: Pass the already created task pid as scope_pid for a new systemd - # scope. This would mean the CGNAME1 should be killed and the pid - # should be the default scope task of CGNAME2 - Cgroup.create_and_validate(config, CONTROLLERS, CGNAME2, create_scope=True, scope_pid=scope_pid) - - # CGNAME1 should be deleted by the systemd. - try: - pid = Cgroup.get_pids_in_cgroup(config, CGNAME1, CONTROLLERS[0])[0] - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = 'Erroneously succeeded reading cgroup.procs in {}'.format(CGNAME1) - return result, cause - - try: - pid = Cgroup.get_pids_in_cgroup(config, CGNAME2, CONTROLLERS[0])[0] - if scope_pid != pid: - result = consts.TEST_FAILED - cause = 'scope created with other pid {}, expected pid {}'.format(pid, scope_pid) - return result, cause - except RunError: - result = consts.TEST_FAILED - cause = 'Failed to read pid in {}\'s cgroup.procs'.format(CGNAME2) - - return result, cause - - -def teardown(config): - pid = Cgroup.get_pids_in_cgroup(config, CGNAME2, CONTROLLERS[0])[0] - Process.kill(config, pid) - - # systemd will automatically remove the cgroup once there are no more pids in - # the cgroup, so we don't need to delete CGNAME2. But let's try to remove the - # slice - try: - Cgroup.delete(config, CONTROLLERS, SLICE) - except RunError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/085-sudo-cgexec_systemd_scope.py b/lib/libcgroup-3.1.0/tests/ftests/085-sudo-cgexec_systemd_scope.py deleted file mode 100755 index 73fa088b680..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/085-sudo-cgexec_systemd_scope.py +++ /dev/null @@ -1,160 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to replace idle_thread of scope unit using cgexec -r -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from multiprocessing import active_children -from process import Process -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import time -import sys -import os - -CONTROLLER = 'cpu' -SLICE = 'libcgroup.slice' -CGNAME = os.path.join(SLICE, '085cgcreate.scope') -OUT_OF_SCOPE_CGNAME1 = '085outofscope' -OUT_OF_SCOPE_CGNAME2 = '085outofscope.scope' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - Cgroup.create_and_validate(config, CONTROLLER, CGNAME, create_scope=True) - - # - # Test 1: call cgexec -r to replace idle_thread with infinite while loop - # - idle_pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, cgclassify=False, - replace_idle=True) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - if idle_pid == pid: - result = consts.TEST_FAILED - cause = 'Failed to replace scope idle_thread pid {} {}'.format(idle_pid, pid) - return result, cause - - # - # Test 2: call cgexec -r to replace non-idle_thread (while loop, - # previously created) with another while loop. It's expected to fail, - # because only idle_thread is allowed to be replaced. - # - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, - cgclassify=False, replace_idle=True) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - replace_pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - if replace_pid != pid: - result = consts.TEST_FAILED - cause = ('Erroneously replaced scope non idle_thread pid {} with ' - 'pid {}'.format(pid, replace_pid)) - return result, cause - - # - # Test 3: create a non-scope cgroup, try creating a task with replace_idle - # set. It should fail way before creating a task, during cgroup name - # check. - Cgroup.create_and_validate(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1) - config.process.create_process_in_cgroup(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1, - cgclassify=False, replace_idle=True) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME1, CONTROLLER) - if len(pid) != 0: - result = consts.TEST_FAILED - cause = ('Erroneously succeeded in creating task in non scope cgroup: ' - 'pid {}'.format(pid)) - return result, cause - - # - # Test 4: create a non-scope cgroup with .scope suffix, try creating a task with - # replace_idle set. It should fail when trying to find idle_task - # check. - # - Cgroup.create_and_validate(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2) - config.process.create_process_in_cgroup(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2, - cgclassify=False, replace_idle=True) - - # We need pause, before the cgroups.procs gets updated, post cgexec - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME2, CONTROLLER) - if len(pid) != 0: - result = consts.TEST_FAILED - cause = ('Erroneously succeeded in creating task in non scope cgroup: ' - 'pid {}'.format(pid)) - - return result, cause - - -def teardown(config): - Cgroup.delete(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1) - Cgroup.delete(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2) - - pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - Process.kill(config, pid) - - # kill the process, that was created by us but failed to migrate to the cgroup - active = active_children() - active[0].terminate() - - # systemd will automatically remove the cgroup once there are no more pids in - # the cgroup, so we don't need to delete CGNAME. But let's try to remove the - # slice - try: - Cgroup.delete(config, CONTROLLER, SLICE) - except RunError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/086-sudo-systemd_cmdline_example.py b/lib/libcgroup-3.1.0/tests/ftests/086-sudo-systemd_cmdline_example.py deleted file mode 100755 index 801027d5c4a..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/086-sudo-systemd_cmdline_example.py +++ /dev/null @@ -1,200 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test cgcreate's handling of a failed creation and ensure the directory is deleted -# -# This test is designed to reproduce the steps in -# samples/cmdline/systemd-with-idle-process.md -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from cgroup import Cgroup as CgroupCli -from systemd import Systemd -from process import Process -from libcgroup import Mode -from run import RunError -import ftests -import consts -import sys -import os - -SLICE = 'libcgtests.slice' -SCOPE = '086example.scope' - -CONTROLLER_LIST = ['cpu', 'memory'] - -TMP_CGNAME = 'tmp' -HIGH_CGNAME = 'high-priority' -MED_CGNAME = 'medium-priority' -LOW_CGNAME = 'low-priority' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - return result, cause - - if CgroupCli.get_cgroup_mode(config) != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Step 1 in the example - # sudo cgcreate -c -S -g cpu,memory:mycompany.slice/database.scope - # - CgroupCli.create_and_validate(config, CONTROLLER_LIST, os.path.join(SLICE, SCOPE), - create_scope=True, set_default_scope=True) - - if not Systemd.is_delegated(config, SCOPE): - result = consts.TEST_FAILED - cause = 'Cgroup is not delegated' - return result, cause - - # - # Step 2 in the example - # $ sudo cgcreate -g cpu,memory:mycompany.slice/database.scope/high-priority - # cgcreate: can't create cgroup mycompany.slice/database.scope/high-priority: Operation not - # supported - # - try: - CgroupCli.create_and_validate(config, CONTROLLER_LIST, HIGH_CGNAME) - except RunError as re: - if re.ret != 96 or 'No such file or directory' not in re.stderr: - result = consts.TEST_FAILED - cause = 'Unexpected error when creating {}: {}'.format(HIGH_CGNAME, re.ret) - return result, cause - else: - result = consts.TEST_FAILED - cause = 'Unexpected success when creating {}'.format(HIGH_CGNAME) - return result, cause - - # - # Step 2.i in the example - # sudo cgset -r cgroup.subtree_control="-cpu -memory" / - # - CgroupCli.subtree_control(config, '/', CONTROLLER_LIST, enable=False) - - # - # Step 2.ii in the example - # sudo cgcreate -g :tmp - # sudo cgclassify -g :tmp $(cgget -nv -r cgroup.procs /) - # - CgroupCli.create_and_validate(config, None, TMP_CGNAME) - pids = CgroupCli.get_pids_in_cgroup(config, os.path.join(SLICE, SCOPE), CONTROLLER_LIST[0]) - CgroupCli.classify(config, None, TMP_CGNAME, pids) - - # - # Step 2.iii in the example - # sudo cgset -r cgroup.subtree_control="+cpu +memory" / - # - CgroupCli.subtree_control(config, '/', CONTROLLER_LIST, enable=True) - - # - # Step 2 (finally!) in the example - # sudo cgcreate -g cpu,memory:high-priority -g cpu,memory:medium-priority \ - # -g cpu,memory:low-priority - # - CgroupCli.create_and_validate(config, CONTROLLER_LIST, HIGH_CGNAME) - CgroupCli.create_and_validate(config, CONTROLLER_LIST, MED_CGNAME) - CgroupCli.create_and_validate(config, CONTROLLER_LIST, LOW_CGNAME) - - # - # Step 3.i in the example - # sudo cgset -r memory.low=1G high-priority - # - CgroupCli.set_and_validate(config, HIGH_CGNAME, 'memory.low', '1073741824') - - # - # Step 3.ii in the example - # sudo cgset -r memory.max=2G low-priority - # - CgroupCli.set_and_validate(config, LOW_CGNAME, 'memory.max', '2147483648') - - # - # Step 3.iii in the example - # sudo cgset -r memory.high=3G medium-priority - # - CgroupCli.set_and_validate(config, MED_CGNAME, 'memory.high', '3221225472') - - # - # Step 3.iv in the example - # sudo cgset -r cpu.weight=600 high-priority - # - CgroupCli.set_and_validate(config, HIGH_CGNAME, 'cpu.weight', '600') - - # - # Step 3.v in the example - # sudo cgset -r cpu.weight=300 medium-priority - # - CgroupCli.set_and_validate(config, MED_CGNAME, 'cpu.weight', '300') - - # - # Step 3.vi in the example - # sudo cgset -r cpu.weight=100 low-priority - # - CgroupCli.set_and_validate(config, LOW_CGNAME, 'cpu.weight', '100') - - return result, cause - - -def teardown(config, result): - pids = CgroupCli.get_pids_in_cgroup(config, os.path.join(SLICE, SCOPE, TMP_CGNAME), - CONTROLLER_LIST[0]) - Process.kill(config, pids) - - if result != consts.TEST_PASSED: - # Something went wrong. Let's force the removal of the cgroups just to be safe. - # Note that this should remove the cgroup, but it won't remove it from systemd's - # internal caches, so the system may not return to its 'pristine' prior-to-this-test - # state - try: - CgroupCli.delete(config, None, SLICE) - except RunError: - pass - else: - # There is no need to remove the scope. systemd should automatically remove it - # once there are no processes inside of it - pass - - return consts.TEST_PASSED, None - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config, result) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/087-sudo-move_pid.py b/lib/libcgroup-3.1.0/tests/ftests/087-sudo-move_pid.py deleted file mode 100755 index f5eee7d87da..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/087-sudo-move_pid.py +++ /dev/null @@ -1,91 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to move a pid to a cgroup -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from libcgroup import Cgroup, Mode, Version -from process import Process -import consts -import ftests -import sys -import os - -CGNAME = '087movepid' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if Cgroup.cgroup_mode() != Mode.CGROUP_MODE_UNIFIED: - result = consts.TEST_SKIPPED - cause = 'This test requires the unified cgroup hierarchy' - - return result, cause - - -def setup(config): - result = consts.TEST_PASSED - cause = None - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.create() - - pid = config.process.create_process(config) - - path = Cgroup.get_current_controller_path(pid) - if path == '/' + CGNAME: - result = consts.TEST_FAILED - cause = 'The PID was already in the destination cgroup {}'.format(CGNAME) - - return result, cause, pid - - -def test(config, pid): - result = consts.TEST_PASSED - cause = None - - Cgroup.move_process(pid, CGNAME) - - path = Cgroup.get_current_controller_path(pid) - if path != '/' + CGNAME: - result = consts.TEST_FAILED - cause = 'Expected the pid to be in {} cgroup, but was instead in {}'.format(CGNAME, path) - - return result, cause - - -def teardown(config, pid): - Process.kill(config, pid) - - cg = Cgroup(CGNAME, Version.CGROUP_V2) - cg.delete() - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - [result, cause, pid] = setup(config) - if result != consts.TEST_PASSED: - teardown(config, pid) - return [result, cause] - - [result, cause] = test(config, pid) - teardown(config, pid) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/088-sudo-cgclassify_systemd_scope.py b/lib/libcgroup-3.1.0/tests/ftests/088-sudo-cgclassify_systemd_scope.py deleted file mode 100755 index 6be897b7851..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/088-sudo-cgclassify_systemd_scope.py +++ /dev/null @@ -1,185 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Test to replace idle_thread of scope unit using cgclassify -r -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from process import Process -from cgroup import Cgroup -from run import RunError -import consts -import ftests -import time -import sys -import os - -CONTROLLER = 'cpu' -SLICE = 'libcgroup.slice' -CGNAME = os.path.join(SLICE, '088cgcreate.scope') -OUT_OF_SCOPE_CGNAME1 = '088outofscope' -OUT_OF_SCOPE_CGNAME2 = '088outofscope.scope' - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if config.args.container: - result = consts.TEST_SKIPPED - cause = 'This test cannot be run within a container' - - return result, cause - - -def setup(config): - pass - - -def test(config): - result = consts.TEST_PASSED - cause = None - - # - # Test 1: call cgclassify -r to replace idle_thread with infinite while loop - # - Cgroup.create_and_validate(config, CONTROLLER, CGNAME, create_scope=True) - idle_pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER)[0] - - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, - cgclassify=True, replace_idle=True) - - # We need pause, before the cgroups.procs gets updated, post cgclassify - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - if len(pid) > 1 and idle_pid == pid[0]: - result = consts.TEST_FAILED - cause = 'Failed to replace scope idle_thread pid {}'.format(idle_pid) - return result, cause - - # - # Test 2: call cgclassify -r to replace non-idle_thread (while loop, - # previously created) with another while loop. - # - try: - config.process.create_process_in_cgroup(config, CONTROLLER, CGNAME, - cgclassify=True, replace_idle=True) - except RunError as re: - if "Failed to find idle_thread task" not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = 'Erroneously classified a task in scope cgroup {}\n'.format(CGNAME) - return result, cause - - # We need pause, before the cgroups.procs gets updated, post cgclassify - time.sleep(1) - - replace_pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - if replace_pid[0] != pid[0]: - result = consts.TEST_FAILED - cause = ('Erroneously replaced scope non idle_thread pid {} with ' - 'pid {}'.format(pid[0], replace_pid[0])) - return result, cause - - # - # Test 3: create a non-scope cgroup, try creating a task with replace_idle - # set. - # - Cgroup.create_and_validate(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1) - try: - config.process.create_process_in_cgroup(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1, - cgclassify=True, replace_idle=True) - except RunError as re: - if "Failed to find idle_thread task" not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = ('Erroneously classified a task in non scope ' - 'cgroup {}\n'.format(OUT_OF_SCOPE_CGNAME1)) - return result, cause - - # We need pause, before the cgroups.procs gets updated, post cgclassify - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME1, CONTROLLER) - if len(pid) != 0: - result = consts.TEST_FAILED - cause = ('Erroneously classified a task in non scope ' - 'cgroup {}\n'.format(OUT_OF_SCOPE_CGNAME1)) - return result, cause - - # - # Test 4: create a non-scope cgroup with .scope suffix, try creating a task with - # replace_idle set. - # - Cgroup.create_and_validate(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2) - try: - config.process.create_process_in_cgroup(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2, - cgclassify=True, replace_idle=True) - except RunError as re: - if "Failed to find idle_thread task" not in re.stderr: - raise re - else: - result = consts.TEST_FAILED - cause = ('Erroneously classified a task in non scope ' - 'cgroup {}\n'.format(OUT_OF_SCOPE_CGNAME2)) - return result, cause - - # We need pause, before the cgroups.procs gets updated, post cgclassify - time.sleep(1) - - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME2, CONTROLLER) - if len(pid) != 0: - result = consts.TEST_FAILED - cause = ('Erroneously classified a task in non scope ' - 'cgroup {}\n'.format(OUT_OF_SCOPE_CGNAME2)) - - return result, cause - - -def teardown(config): - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME1, CONTROLLER) - Process.kill(config, pid) - - pid = Cgroup.get_pids_in_cgroup(config, OUT_OF_SCOPE_CGNAME2, CONTROLLER) - Process.kill(config, pid) - - Cgroup.delete(config, CONTROLLER, OUT_OF_SCOPE_CGNAME1) - Cgroup.delete(config, CONTROLLER, OUT_OF_SCOPE_CGNAME2) - - pid = Cgroup.get_pids_in_cgroup(config, CGNAME, CONTROLLER) - Process.kill(config, pid) - - # systemd will automatically remove the cgroup once there are no more pids in - # the cgroup, so we don't need to delete CGNAME. But let's try to remove the - # slice - try: - Cgroup.delete(config, CONTROLLER, SLICE) - except RunError: - pass - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - setup(config) - - [result, cause] = test(config) - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/998-cgdelete-non-existing-shared-mnt-cgroup-v1.py b/lib/libcgroup-3.1.0/tests/ftests/998-cgdelete-non-existing-shared-mnt-cgroup-v1.py deleted file mode 100755 index 7a969058774..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/998-cgdelete-non-existing-shared-mnt-cgroup-v1.py +++ /dev/null @@ -1,94 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup recursive cgdelete functionality test for shared mount point on cgroup v1 -# -# Copyright (c) 2023 Oracle and/or its affiliates. -# Author: Kamalesh Babulal -# - -from cgroup import CgroupVersion, Cgroup -from run import RunError -import consts -import ftests -import sys -import os - -CONTROLLER = 'cpu' -CGNAME = 'test' - -expected_err = "cgdelete: cannot remove group '%s': No such file or directory" % CGNAME - - -def prereqs(config): - result = consts.TEST_PASSED - cause = None - - if CgroupVersion.get_version('cpu') != CgroupVersion.CGROUP_V1: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpu controller' - return result, cause - - # cpuacct controller is only available on cgroup v1, if an exception - # gets raised, then no cgroup v1 controllers are mounted. - try: - CgroupVersion.get_version('cpuacct') - except IndexError: - result = consts.TEST_SKIPPED - cause = 'This test requires the cgroup v1 cpuacct controller' - - return result, cause - - -def setup(config): - return consts.TEST_PASSED, None - - -def test(config): - result = consts.TEST_PASSED - cause = None - - try: - Cgroup.delete(config, CONTROLLER, CGNAME) - except RunError as re: - if expected_err not in re.stderr and re.ret != 82: - result = consts.TEST_FAILED - cause = 'Expected {}'.format(expected_err) - return result, cause - - try: - Cgroup.delete(config, CONTROLLER, CGNAME, recursive=True) - except RunError as re: - if expected_err not in re.stderr and re.ret != 82: - result = consts.TEST_FAILED - cause = 'Expected {}'.format(expected_err) - - return result, cause - - -def teardown(config): - return consts.TEST_PASSED, None - - -def main(config): - [result, cause] = prereqs(config) - if result != consts.TEST_PASSED: - return [result, cause] - - try: - result = consts.TEST_FAILED - setup(config) - [result, cause] = test(config) - finally: - teardown(config) - - return [result, cause] - - -if __name__ == '__main__': - config = ftests.parse_args() - # this test was invoked directly. run only it - config.args.num = int(os.path.basename(__file__).split('-')[0]) - sys.exit(ftests.main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/Makefile.am b/lib/libcgroup-3.1.0/tests/ftests/Makefile.am deleted file mode 100644 index e38d641bbf9..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/Makefile.am +++ /dev/null @@ -1,122 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup functional tests Makefile.am -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -TESTS = ftests-wrapper.sh - -EXTRA_DIST_PYTHON_UTILS = \ - cgroup.py \ - config.py \ - consts.py \ - container.py \ - controller.py \ - ftests.py \ - __init__.py \ - log.py \ - process.py \ - run.py \ - systemd.py \ - utils.py - -EXTRA_DIST_PYTHON_TESTS = \ - 001-cgget-basic_cgget_v1.py \ - 002-cgdelete-recursive_delete.py \ - 003-cgget-basic_cgget_v2.py \ - 004-cgsnapshot-basic_snapshot_v1.py \ - 005-cgsnapshot-basic_snapshot_v2.py \ - 006-cgrules-basic_cgrules_v1.py \ - 007-cgrules-basic_cgrules_v2.py \ - 008-cgget-multiple_r_flags.py \ - 009-cgget-g_flag_controller_only.py \ - 010-cgget-g_flag_controller_and_cgroup.py \ - 011-cgget-r_flag_two_cgroups.py \ - 012-cgget-multiple_r_flags2.py \ - 013-cgget-multiple_g_flags.py \ - 014-cgget-a_flag.py \ - 015-cgget-multiline_r_flag.py \ - 016-cgget-invalid_options.py \ - 017-cgconfig-load_file.py \ - 018-cgconfig-load_dir.py \ - 019-cgconfig-uidgid_dperm_fperm.py \ - 020-cgconfig-tasks_perms_owner.py \ - 021-cgconfig-invalid_options.py \ - 022-cgset-multiple_r_flag.py \ - 023-cgset-copy_from.py \ - 025-cgset-multiple_cgroups.py \ - 026-cgset-multiple_r_multiple_cgroup.py \ - 027-cgset-invalid_options.py \ - 029-lssubsys-basic_lssubsys.py \ - 030-lssubsys-lssubsys_all.py \ - 031-lscgroup-g_flag.py \ - 032-lscgroup-multiple_g_flags.py \ - 033-cgget-no_flags.py \ - 034-cgexec-basic_cgexec.py \ - 035-cgset-set_cgroup_type.py \ - 036-cgset-multi_thread.py \ - 037-cgxget-cpu_settings.py \ - 038-cgxget-cpuset_settings.py \ - 039-pybindings-cgxget.py \ - 040-pybindings-cgxset.py \ - 041-pybindings-library_version.py \ - 042-cgxget-unmappable.py \ - 043-cgcreate-empty_controller.py \ - 044-pybindings-cgcreate_empty_controller.py \ - 045-pybindings-list_mount_points.py \ - 046-cgexec-empty_controller.py \ - 047-cgcreate-delete_cgrp_shared_mnt.py \ - 048-pybindings-get_cgroup_mode.py \ - 049-sudo-systemd_create_scope.py \ - 050-sudo-systemd_create_scope_w_pid.py \ - 051-sudo-cgroup_get_cgroup.py \ - 052-sudo-cgroup_attach_task.py \ - 053-sudo-cgroup_attach_task_pid.py \ - 054-sudo-set_uid_gid_v2.py \ - 055-sudo-set_uid_gid_v1.py \ - 056-sudo-set_permissions_v2.py \ - 057-sudo-set_permissions_v1.py \ - 058-sudo-systemd_create_scope2.py \ - 059-sudo-invalid_systemd_create_scope2.py \ - 060-sudo-cgconfigparser-systemd.py \ - 061-sudo-g_flag_controller_only_systemd-v1.py \ - 062-sudo-g_flag_controller_only_systemd-v2.py \ - 063-sudo-systemd_cgset-v1.py \ - 064-sudo-systemd_cgset-v2.py \ - 065-sudo-systemd_cgclassify-v1.py \ - 066-sudo-systemd_cgclassify-v2.py \ - 067-sudo-systemd_cgexec-v1.py \ - 068-sudo-systemd_cgexec-v2.py \ - 069-sudo-systemd_cgxget-cpu-settings-v1.py \ - 070-sudo-systemd_cgxget-cpu-settings-v2.py \ - 071-sudo-set_default_systemd_cgroup.py \ - 072-pybindings-cgroup_get_cgroup.py \ - 073-pybindings-cgroup_add_all_controllers-v2.py \ - 074-pybindings-cgroup_add_all_controllers-v1.py \ - 075-pybindings-cgroup_compare_cgroup.py \ - 076-cgconfig-auto_convert.py \ - 077-pybindings-cgroup_get_procs.py \ - 078-sudo-cgcreate_systemd_scope.py \ - 079-sudo-cgcreate_default_systemd_scope.py \ - 080-kernel-domain_invalid.py \ - 081-pybindings-cgrp_get_curr_ctrl_path-v1.py \ - 082-pybindings-cgrp_get_curr_ctrl_path-v2.py \ - 083-pybindings-helpers_cgroup_mode.py \ - 084-sudo-cgcreate_systemd_scope_pid.py \ - 085-sudo-cgexec_systemd_scope.py \ - 086-sudo-systemd_cmdline_example.py \ - 087-sudo-move_pid.py \ - 088-sudo-cgclassify_systemd_scope.py \ - 998-cgdelete-non-existing-shared-mnt-cgroup-v1.py -# Intentionally omit the stress test from the extra dist -# 999-stress-cgroup_init.py - -EXTRA_DIST = README.md ftests-wrapper.sh \ - ${EXTRA_DIST_PYTHON_UTILS} ${EXTRA_DIST_PYTHON_TESTS} - -clean-local: clean-local-check -.PHONY: clean-local-check -clean-local-check: - -rm -f *.pyc diff --git a/lib/libcgroup-3.1.0/tests/ftests/Makefile.in b/lib/libcgroup-3.1.0/tests/ftests/Makefile.in deleted file mode 100644 index eaa3afb1db7..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/Makefile.in +++ /dev/null @@ -1,971 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup functional tests Makefile.am -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = tests/ftests -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__tty_colors_dummy = \ - mgn= red= grn= lgn= blu= brg= std=; \ - am__color_tests=no -am__tty_colors = { \ - $(am__tty_colors_dummy); \ - if test "X$(AM_COLOR_TESTS)" = Xno; then \ - am__color_tests=no; \ - elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ - am__color_tests=yes; \ - elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ - am__color_tests=yes; \ - fi; \ - if test $$am__color_tests = yes; then \ - red=''; \ - grn=''; \ - lgn=''; \ - blu=''; \ - mgn=''; \ - brg=''; \ - std=''; \ - fi; \ -} -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__recheck_rx = ^[ ]*:recheck:[ ]* -am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* -am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* -# A command that, given a newline-separated list of test names on the -# standard input, print the name of the tests that are to be re-run -# upon "make recheck". -am__list_recheck_tests = $(AWK) '{ \ - recheck = 1; \ - while ((rc = (getline line < ($$0 ".trs"))) != 0) \ - { \ - if (rc < 0) \ - { \ - if ((getline line2 < ($$0 ".log")) < 0) \ - recheck = 0; \ - break; \ - } \ - else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ - { \ - recheck = 0; \ - break; \ - } \ - else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ - { \ - break; \ - } \ - }; \ - if (recheck) \ - print $$0; \ - close ($$0 ".trs"); \ - close ($$0 ".log"); \ -}' -# A command that, given a newline-separated list of test names on the -# standard input, create the global log from their .trs and .log files. -am__create_global_log = $(AWK) ' \ -function fatal(msg) \ -{ \ - print "fatal: making $@: " msg | "cat >&2"; \ - exit 1; \ -} \ -function rst_section(header) \ -{ \ - print header; \ - len = length(header); \ - for (i = 1; i <= len; i = i + 1) \ - printf "="; \ - printf "\n\n"; \ -} \ -{ \ - copy_in_global_log = 1; \ - global_test_result = "RUN"; \ - while ((rc = (getline line < ($$0 ".trs"))) != 0) \ - { \ - if (rc < 0) \ - fatal("failed to read from " $$0 ".trs"); \ - if (line ~ /$(am__global_test_result_rx)/) \ - { \ - sub("$(am__global_test_result_rx)", "", line); \ - sub("[ ]*$$", "", line); \ - global_test_result = line; \ - } \ - else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ - copy_in_global_log = 0; \ - }; \ - if (copy_in_global_log) \ - { \ - rst_section(global_test_result ": " $$0); \ - while ((rc = (getline line < ($$0 ".log"))) != 0) \ - { \ - if (rc < 0) \ - fatal("failed to read from " $$0 ".log"); \ - print line; \ - }; \ - printf "\n"; \ - }; \ - close ($$0 ".trs"); \ - close ($$0 ".log"); \ -}' -# Restructured Text title. -am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } -# Solaris 10 'make', and several other traditional 'make' implementations, -# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it -# by disabling -e (using the XSI extension "set +e") if it's set. -am__sh_e_setup = case $$- in *e*) set +e;; esac -# Default flags passed to test drivers. -am__common_driver_flags = \ - --color-tests "$$am__color_tests" \ - --enable-hard-errors "$$am__enable_hard_errors" \ - --expect-failure "$$am__expect_failure" -# To be inserted before the command running the test. Creates the -# directory for the log if needed. Stores in $dir the directory -# containing $f, in $tst the test, in $log the log. Executes the -# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and -# passes TESTS_ENVIRONMENT. Set up options for the wrapper that -# will run the test scripts (or their associated LOG_COMPILER, if -# thy have one). -am__check_pre = \ -$(am__sh_e_setup); \ -$(am__vpath_adj_setup) $(am__vpath_adj) \ -$(am__tty_colors); \ -srcdir=$(srcdir); export srcdir; \ -case "$@" in \ - */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ - *) am__odir=.;; \ -esac; \ -test "x$$am__odir" = x"." || test -d "$$am__odir" \ - || $(MKDIR_P) "$$am__odir" || exit $$?; \ -if test -f "./$$f"; then dir=./; \ -elif test -f "$$f"; then dir=; \ -else dir="$(srcdir)/"; fi; \ -tst=$$dir$$f; log='$@'; \ -if test -n '$(DISABLE_HARD_ERRORS)'; then \ - am__enable_hard_errors=no; \ -else \ - am__enable_hard_errors=yes; \ -fi; \ -case " $(XFAIL_TESTS) " in \ - *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ - am__expect_failure=yes;; \ - *) \ - am__expect_failure=no;; \ -esac; \ -$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) -# A shell command to get the names of the tests scripts with any registered -# extension removed (i.e., equivalently, the names of the test logs, with -# the '.log' extension removed). The result is saved in the shell variable -# '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, -# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", -# since that might cause problem with VPATH rewrites for suffix-less tests. -# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. -am__set_TESTS_bases = \ - bases='$(TEST_LOGS)'; \ - bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ - bases=`echo $$bases` -AM_TESTSUITE_SUMMARY_HEADER = ' for $(PACKAGE_STRING)' -RECHECK_LOGS = $(TEST_LOGS) -AM_RECURSIVE_TARGETS = check recheck -TEST_SUITE_LOG = test-suite.log -TEST_EXTENSIONS = @EXEEXT@ .test -LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver -LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) -am__set_b = \ - case '$@' in \ - */*) \ - case '$*' in \ - */*) b='$*';; \ - *) b=`echo '$@' | sed 's/\.log$$//'`; \ - esac;; \ - *) \ - b='$*';; \ - esac -am__test_logs1 = $(TESTS:=.log) -am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) -TEST_LOGS = $(am__test_logs2:.test.log=.log) -TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver -TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ - $(TEST_LOG_FLAGS) -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/test-driver README.md -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -TESTS = ftests-wrapper.sh -EXTRA_DIST_PYTHON_UTILS = \ - cgroup.py \ - config.py \ - consts.py \ - container.py \ - controller.py \ - ftests.py \ - __init__.py \ - log.py \ - process.py \ - run.py \ - systemd.py \ - utils.py - -EXTRA_DIST_PYTHON_TESTS = \ - 001-cgget-basic_cgget_v1.py \ - 002-cgdelete-recursive_delete.py \ - 003-cgget-basic_cgget_v2.py \ - 004-cgsnapshot-basic_snapshot_v1.py \ - 005-cgsnapshot-basic_snapshot_v2.py \ - 006-cgrules-basic_cgrules_v1.py \ - 007-cgrules-basic_cgrules_v2.py \ - 008-cgget-multiple_r_flags.py \ - 009-cgget-g_flag_controller_only.py \ - 010-cgget-g_flag_controller_and_cgroup.py \ - 011-cgget-r_flag_two_cgroups.py \ - 012-cgget-multiple_r_flags2.py \ - 013-cgget-multiple_g_flags.py \ - 014-cgget-a_flag.py \ - 015-cgget-multiline_r_flag.py \ - 016-cgget-invalid_options.py \ - 017-cgconfig-load_file.py \ - 018-cgconfig-load_dir.py \ - 019-cgconfig-uidgid_dperm_fperm.py \ - 020-cgconfig-tasks_perms_owner.py \ - 021-cgconfig-invalid_options.py \ - 022-cgset-multiple_r_flag.py \ - 023-cgset-copy_from.py \ - 025-cgset-multiple_cgroups.py \ - 026-cgset-multiple_r_multiple_cgroup.py \ - 027-cgset-invalid_options.py \ - 029-lssubsys-basic_lssubsys.py \ - 030-lssubsys-lssubsys_all.py \ - 031-lscgroup-g_flag.py \ - 032-lscgroup-multiple_g_flags.py \ - 033-cgget-no_flags.py \ - 034-cgexec-basic_cgexec.py \ - 035-cgset-set_cgroup_type.py \ - 036-cgset-multi_thread.py \ - 037-cgxget-cpu_settings.py \ - 038-cgxget-cpuset_settings.py \ - 039-pybindings-cgxget.py \ - 040-pybindings-cgxset.py \ - 041-pybindings-library_version.py \ - 042-cgxget-unmappable.py \ - 043-cgcreate-empty_controller.py \ - 044-pybindings-cgcreate_empty_controller.py \ - 045-pybindings-list_mount_points.py \ - 046-cgexec-empty_controller.py \ - 047-cgcreate-delete_cgrp_shared_mnt.py \ - 048-pybindings-get_cgroup_mode.py \ - 049-sudo-systemd_create_scope.py \ - 050-sudo-systemd_create_scope_w_pid.py \ - 051-sudo-cgroup_get_cgroup.py \ - 052-sudo-cgroup_attach_task.py \ - 053-sudo-cgroup_attach_task_pid.py \ - 054-sudo-set_uid_gid_v2.py \ - 055-sudo-set_uid_gid_v1.py \ - 056-sudo-set_permissions_v2.py \ - 057-sudo-set_permissions_v1.py \ - 058-sudo-systemd_create_scope2.py \ - 059-sudo-invalid_systemd_create_scope2.py \ - 060-sudo-cgconfigparser-systemd.py \ - 061-sudo-g_flag_controller_only_systemd-v1.py \ - 062-sudo-g_flag_controller_only_systemd-v2.py \ - 063-sudo-systemd_cgset-v1.py \ - 064-sudo-systemd_cgset-v2.py \ - 065-sudo-systemd_cgclassify-v1.py \ - 066-sudo-systemd_cgclassify-v2.py \ - 067-sudo-systemd_cgexec-v1.py \ - 068-sudo-systemd_cgexec-v2.py \ - 069-sudo-systemd_cgxget-cpu-settings-v1.py \ - 070-sudo-systemd_cgxget-cpu-settings-v2.py \ - 071-sudo-set_default_systemd_cgroup.py \ - 072-pybindings-cgroup_get_cgroup.py \ - 073-pybindings-cgroup_add_all_controllers-v2.py \ - 074-pybindings-cgroup_add_all_controllers-v1.py \ - 075-pybindings-cgroup_compare_cgroup.py \ - 076-cgconfig-auto_convert.py \ - 077-pybindings-cgroup_get_procs.py \ - 078-sudo-cgcreate_systemd_scope.py \ - 079-sudo-cgcreate_default_systemd_scope.py \ - 080-kernel-domain_invalid.py \ - 081-pybindings-cgrp_get_curr_ctrl_path-v1.py \ - 082-pybindings-cgrp_get_curr_ctrl_path-v2.py \ - 083-pybindings-helpers_cgroup_mode.py \ - 084-sudo-cgcreate_systemd_scope_pid.py \ - 085-sudo-cgexec_systemd_scope.py \ - 086-sudo-systemd_cmdline_example.py \ - 087-sudo-move_pid.py \ - 088-sudo-cgclassify_systemd_scope.py \ - 998-cgdelete-non-existing-shared-mnt-cgroup-v1.py - -# Intentionally omit the stress test from the extra dist -# 999-stress-cgroup_init.py -EXTRA_DIST = README.md ftests-wrapper.sh \ - ${EXTRA_DIST_PYTHON_UTILS} ${EXTRA_DIST_PYTHON_TESTS} - -all: all-am - -.SUFFIXES: -.SUFFIXES: .log .test .test$(EXEEXT) .trs -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign tests/ftests/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign tests/ftests/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - - -# Recover from deleted '.trs' file; this should ensure that -# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create -# both 'foo.log' and 'foo.trs'. Break the recipe in two subshells -# to avoid problems with "make -n". -.log.trs: - rm -f $< $@ - $(MAKE) $(AM_MAKEFLAGS) $< - -# Leading 'am--fnord' is there to ensure the list of targets does not -# expand to empty, as could happen e.g. with make check TESTS=''. -am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) -am--force-recheck: - @: - -$(TEST_SUITE_LOG): $(TEST_LOGS) - @$(am__set_TESTS_bases); \ - am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ - redo_bases=`for i in $$bases; do \ - am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ - done`; \ - if test -n "$$redo_bases"; then \ - redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ - redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ - if $(am__make_dryrun); then :; else \ - rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ - fi; \ - fi; \ - if test -n "$$am__remaking_logs"; then \ - echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ - "recursion detected" >&2; \ - elif test -n "$$redo_logs"; then \ - am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ - fi; \ - if $(am__make_dryrun); then :; else \ - st=0; \ - errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ - for i in $$redo_bases; do \ - test -f $$i.trs && test -r $$i.trs \ - || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ - test -f $$i.log && test -r $$i.log \ - || { echo "$$errmsg $$i.log" >&2; st=1; }; \ - done; \ - test $$st -eq 0 || exit 1; \ - fi - @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ - ws='[ ]'; \ - results=`for b in $$bases; do echo $$b.trs; done`; \ - test -n "$$results" || results=/dev/null; \ - all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ - pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ - fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ - skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ - xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ - xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ - error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ - if test `expr $$fail + $$xpass + $$error` -eq 0; then \ - success=true; \ - else \ - success=false; \ - fi; \ - br='==================='; br=$$br$$br$$br$$br; \ - result_count () \ - { \ - if test x"$$1" = x"--maybe-color"; then \ - maybe_colorize=yes; \ - elif test x"$$1" = x"--no-color"; then \ - maybe_colorize=no; \ - else \ - echo "$@: invalid 'result_count' usage" >&2; exit 4; \ - fi; \ - shift; \ - desc=$$1 count=$$2; \ - if test $$maybe_colorize = yes && test $$count -gt 0; then \ - color_start=$$3 color_end=$$std; \ - else \ - color_start= color_end=; \ - fi; \ - echo "$${color_start}# $$desc $$count$${color_end}"; \ - }; \ - create_testsuite_report () \ - { \ - result_count $$1 "TOTAL:" $$all "$$brg"; \ - result_count $$1 "PASS: " $$pass "$$grn"; \ - result_count $$1 "SKIP: " $$skip "$$blu"; \ - result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ - result_count $$1 "FAIL: " $$fail "$$red"; \ - result_count $$1 "XPASS:" $$xpass "$$red"; \ - result_count $$1 "ERROR:" $$error "$$mgn"; \ - }; \ - { \ - echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ - $(am__rst_title); \ - create_testsuite_report --no-color; \ - echo; \ - echo ".. contents:: :depth: 2"; \ - echo; \ - for b in $$bases; do echo $$b; done \ - | $(am__create_global_log); \ - } >$(TEST_SUITE_LOG).tmp || exit 1; \ - mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ - if $$success; then \ - col="$$grn"; \ - else \ - col="$$red"; \ - test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ - fi; \ - echo "$${col}$$br$${std}"; \ - echo "$${col}Testsuite summary"$(AM_TESTSUITE_SUMMARY_HEADER)"$${std}"; \ - echo "$${col}$$br$${std}"; \ - create_testsuite_report --maybe-color; \ - echo "$$col$$br$$std"; \ - if $$success; then :; else \ - echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ - if test -n "$(PACKAGE_BUGREPORT)"; then \ - echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ - fi; \ - echo "$$col$$br$$std"; \ - fi; \ - $$success || exit 1 - -check-TESTS: - @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list - @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - @set +e; $(am__set_TESTS_bases); \ - log_list=`for i in $$bases; do echo $$i.log; done`; \ - trs_list=`for i in $$bases; do echo $$i.trs; done`; \ - log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ - exit $$?; -recheck: all - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - @set +e; $(am__set_TESTS_bases); \ - bases=`for i in $$bases; do echo $$i; done \ - | $(am__list_recheck_tests)` || exit 1; \ - log_list=`for i in $$bases; do echo $$i.log; done`; \ - log_list=`echo $$log_list`; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ - am__force_recheck=am--force-recheck \ - TEST_LOGS="$$log_list"; \ - exit $$? -ftests-wrapper.sh.log: ftests-wrapper.sh - @p='ftests-wrapper.sh'; \ - b='ftests-wrapper.sh'; \ - $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ - --log-file $$b.log --trs-file $$b.trs \ - $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ - "$$tst" $(AM_TESTS_FD_REDIRECT) -.test.log: - @p='$<'; \ - $(am__set_b); \ - $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ - --log-file $$b.log --trs-file $$b.trs \ - $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ - "$$tst" $(AM_TESTS_FD_REDIRECT) -@am__EXEEXT_TRUE@.test$(EXEEXT).log: -@am__EXEEXT_TRUE@ @p='$<'; \ -@am__EXEEXT_TRUE@ $(am__set_b); \ -@am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ -@am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ -@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ -@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am - $(MAKE) $(AM_MAKEFLAGS) check-TESTS -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) - -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) - -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool clean-local mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: check-am install-am install-strip - -.PHONY: all all-am check check-TESTS check-am clean clean-generic \ - clean-libtool clean-local cscopelist-am ctags-am distclean \ - distclean-generic distclean-libtool distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-man install-pdf install-pdf-am \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am recheck tags-am \ - uninstall uninstall-am - -.PRECIOUS: Makefile - - -clean-local: clean-local-check -.PHONY: clean-local-check -clean-local-check: - -rm -f *.pyc - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/tests/ftests/README.md b/lib/libcgroup-3.1.0/tests/ftests/README.md deleted file mode 100644 index ed3dcb68655..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/README.md +++ /dev/null @@ -1,65 +0,0 @@ -## Functional Test Suite for libcgroup - -This folder contains the functional test suite for libcgroup. -The functional test suite utilizes lxc containers to guarantee -a non-destructive test environment. - -The tests can be invoked individually, as a group of related -tests, or from automake via the standard 'make check' -command. - -## Invocation - -Run a single test (first cd to tests/ftests): - - ./001-cgget-basic_cgget.py - or - ./ftests.py -N 15 # Run test #015 - -Run a suite of tests (first cd to tests/ftests): - - ./ftests.py -s cgget # Run all cgget tests - -Run all the tests by hand - - ./ftests.py - # This may be advantageous over running make check - # because it will try to re-use the same lxc - # container for all of the tests. This should - # provide a significant performance increase - -Run the tests from automake - - make check - # Then examine the *.trs and *.log files for - # specifics regarding each test result - -## Results - -The test suite will generate test results upon completion of -the test run. An example result is below: - -``` -Test Results: - Run Date: Jun 03 13:41:35 - Passed: 1 test - Skipped: 0 tests - Failed: 0 tests ------------------------------------------------------------------ -Timing Results: - Test Time (sec) - --------------------------------------------------------- - setup 6.95 - 001-cgget-basic_cgget.py 0.07 - teardown 0.00 - --------------------------------------------------------- - Total Run Time 7.02 -``` - -A log file can also be generated to help in debugging failed -tests. Run `ftests.py -h` to view the syntax. - -To generate a log file called foo.log at a debug level (8) run -the following: - - ./ftests.py -l 8 -L foo.log diff --git a/lib/libcgroup-3.1.0/tests/ftests/__init__.py b/lib/libcgroup-3.1.0/tests/ftests/__init__.py deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/lib/libcgroup-3.1.0/tests/ftests/cgroup.py b/lib/libcgroup-3.1.0/tests/ftests/cgroup.py deleted file mode 100644 index 57fb2a70d31..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/cgroup.py +++ /dev/null @@ -1,1199 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup class for the libcgroup functional tests -# -# Copyright (c) 2019-2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from container import ContainerError -from controller import Controller -from run import Run, RunError -import multiprocessing as mp -from libcgroup import Mode -from enum import Enum -import consts -import utils -import time -import copy -import os - - -class CgroupMount(object): - def __init__(self, mount_line, controller=None): - entries = mount_line.split() - - if entries[2] == 'cgroup': - self.version = CgroupVersion.CGROUP_V1 - elif entries[2] == 'cgroup2': - self.version = CgroupVersion.CGROUP_V2 - else: - raise ValueError('Unknown cgroup version') - - self.mount_point = entries[1] - - if controller: - self.controller = controller - else: - self.controller = None - if self.version == CgroupVersion.CGROUP_V1: - self.controller = entries[3].split(',')[-1] - - if self.controller == 'clone_children': - # the cpuset controller may append this option to the end - # rather than the controller name like all other controllers - self.controller = 'cpuset' - - def __str__(self): - out_str = 'CgroupMount' - out_str += '\n\tMount Point = {}'.format(self.mount_point) - out_str += '\n\tCgroup Version = {}'.format(self.version) - if self.controller is not None: - out_str += '\n\tController = {}'.format(self.controller) - - return out_str - - -class CgroupVersion(Enum): - CGROUP_UNK = 0 - CGROUP_V1 = 1 - CGROUP_V2 = 2 - - # given a controller name, get the cgroup version of the controller - @staticmethod - def get_version(controller): - with open('/proc/mounts', 'r') as mntf: - for line in mntf.readlines(): - mnt_path = line.split()[1] - - if line.split()[0] == 'cgroup': - for option in line.split()[3].split(','): - if option == controller: - return CgroupVersion.CGROUP_V1 - elif line.split()[0] == 'cgroup2': - ctrlf_path = os.path.join(mnt_path, 'cgroup.controllers') - with open(ctrlf_path, 'r') as ctrlf: - controllers = ctrlf.readline() - for ctrl in controllers.split(): - if ctrl == controller: - return CgroupVersion.CGROUP_V2 - - raise IndexError( - 'Unknown version for controller {}' - ''.format(controller) - ) - - -class Cgroup(object): - # This class is analogous to libcgroup's struct cgroup - def __init__(self, name): - self.name = name - # self.controllers maps to - # struct cgroup_controller *controller[CG_CONTROLLER_MAX]; - self.controllers = dict() - - self.children = list() - - def __str__(self): - out_str = 'Cgroup {}\n'.format(self.name) - for ctrl_key in self.controllers: - out_str += utils.indent(str(self.controllers[ctrl_key]), 4) - - return out_str - - def __eq__(self, other): - if not isinstance(other, Cgroup): - return False - - if not self.name == other.name: - return False - - if self.controllers != other.controllers: - return False - - return True - - @staticmethod - def build_cmd_path(cmd): - return os.path.join(consts.LIBCG_MOUNT_POINT, - 'src/tools/{}'.format(cmd)) - - @staticmethod - def build_daemon_path(cmd): - return os.path.join(consts.LIBCG_MOUNT_POINT, - 'src/daemon/{}'.format(cmd)) - - @staticmethod - def create(config, controller_list, cgname, user_name=None, - group_name=None, dperm=None, fperm=None, tperm=None, - tasks_user_name=None, tasks_group_name=None, cghelp=False, - ignore_systemd=False, create_scope=False, set_default_scope=False, - scope_pid=-1): - if isinstance(controller_list, str): - controller_list = [controller_list] - - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgcreate')) - - if user_name is not None and group_name is not None: - cmd.append('-a') - cmd.append('{}:{}'.format(user_name, group_name)) - - if dperm is not None: - cmd.append('-d') - cmd.append(dperm) - - if fperm is not None: - cmd.append('-f') - cmd.append(fperm) - - if tperm is not None: - cmd.append('-s') - cmd.append(tperm) - - if tasks_user_name is not None and tasks_group_name is not None: - cmd.append('-t') - cmd.append('{}:{}'.format(tasks_user_name, tasks_group_name)) - - if cghelp: - cmd.append('-h') - - # -b and -c are mutually exclusive but the safety check is done in libcgroup - # itself and thus doesn't need to be done here - - if ignore_systemd: - cmd.append('-b') - - if create_scope: - cmd.append('-c') - - # -S requires -c to be provided, but this is checked in libcgroup itself - - if set_default_scope: - cmd.append('-S') - - # -p requires -c to be provided, but this is too checked in libcgroup itself - - if scope_pid > 1: - cmd.append('-p') - cmd.append('{}'.format(scope_pid)) - - if controller_list: - controllers_and_path = '{}:{}'.format( - ','.join(controller_list), cgname) - else: - controllers_and_path = ':{}'.format(cgname) - - cmd.append('-g') - cmd.append(controllers_and_path) - - if config.args.container: - config.container.run(cmd) - else: - if create_scope: - # creating a scope causes libcgroup to create a child process. - # subprocess.Popen.communicate() will not return until the created - # process and all of its children complete. Get around this by - # timing out the operation - Run.run(cmd, timeout=5) - else: - Run.run(cmd) - - # This is a simple wrapper, that calls Cgroup.create() to create the - # cgroup and cgroup_exists(), which builds the cgroup path and returns - # True if the cgroup exists, False otherwise - @staticmethod - def create_and_validate(config, ctrl_name, cgroup_name, ignore_systemd=False, - create_scope=False, set_default_scope=False, scope_pid=-1): - Cgroup.create(config, ctrl_name, cgroup_name, ignore_systemd=ignore_systemd, - create_scope=create_scope, set_default_scope=set_default_scope, - scope_pid=scope_pid) - return Cgroup.exists(config, ctrl_name, cgroup_name, ignore_systemd=ignore_systemd) - - @staticmethod - def delete(config, controller_list, cgname, recursive=False, ignore_systemd=False): - if isinstance(controller_list, str): - controller_list = [controller_list] - - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgdelete')) - - if recursive: - cmd.append('-r') - - if controller_list: - controllers_and_path = '{}:{}'.format( - ','.join(controller_list), cgname) - else: - controllers_and_path = ':{}'.format(cgname) - - cmd.append('-g') - cmd.append(controllers_and_path) - - if ignore_systemd: - cmd.append('-b') - - if config.args.container: - config.container.run(cmd) - else: - Run.run(cmd) - - @staticmethod - def __set(config, cmd, cgname=None, setting=None, value=None, - copy_from=None, cghelp=False, ignore_systemd=False): - if setting is not None or value is not None: - if isinstance(setting, str) and (isinstance(value, str) or isinstance(value, int)): - cmd.append('-r') - cmd.append('{}={}'.format(setting, str(value))) - elif isinstance(setting, list) and isinstance(value, list): - if len(setting) != len(value): - raise ValueError( - 'Settings list length must equal ' - 'values list length' - ) - - for idx, stg in enumerate(setting): - cmd.append('-r') - cmd.append('{}={}'.format(stg, str(value[idx]))) - else: - raise ValueError( - 'Invalid inputs to cgget:\nsetting: {}\n' - 'value{}' - ''.format(setting, value) - ) - - if copy_from is not None: - cmd.append('--copy-from') - cmd.append(copy_from) - - if cgname is not None: - if isinstance(cgname, str): - # use the string as is - cmd.append(cgname) - elif isinstance(cgname, list): - for cg in cgname: - cmd.append(cg) - - if ignore_systemd: - cmd.append('-b') - - if cghelp: - cmd.append('-h') - - if config.args.container: - return config.container.run(cmd) - else: - return Run.run(cmd) - - @staticmethod - def set(config, cgname=None, setting=None, value=None, copy_from=None, - cghelp=False, ignore_systemd=False): - """cgset equivalent method - - The following variants of cgset are being tested by the - automated functional tests: - - Command Test Number - cgset -r setting=value cgname various - cgset -r setting1=val1 -r setting2=val2 - -r setting3=val2 cgname 022 - cgset --copy_from foo bar 023 - cgset --copy_from foo bar1 bar2 024 - cgset -r setting=value foo bar 025 - cgset -r setting1=value1 setting2=value2 foo bar 026 - various invalid flag combinations 027 - """ - cmd = list() - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgset')) - - return Cgroup.__set(config, cmd, cgname, setting, value, copy_from, - cghelp, ignore_systemd) - - @staticmethod - def xset(config, cgname=None, setting=None, value=None, copy_from=None, - version=CgroupVersion.CGROUP_UNK, cghelp=False, - ignore_unmappable=False, ignore_systemd=False): - """cgxset equivalent method - """ - cmd = list() - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgxset')) - - if version == CgroupVersion.CGROUP_V1: - cmd.append('-1') - elif version == CgroupVersion.CGROUP_V2: - cmd.append('-2') - - if ignore_unmappable: - cmd.append('-i') - - return Cgroup.__set(config, cmd, cgname, setting, value, copy_from, - cghelp, ignore_systemd) - - @staticmethod - def __get(config, cmd, controller=None, cgname=None, setting=None, - print_headers=True, values_only=False, - all_controllers=False, cghelp=False, ignore_systemd=False): - if not print_headers: - cmd.append('-n') - - if values_only: - cmd.append('-v') - - if ignore_systemd: - cmd.append('-b') - - if setting is not None: - if isinstance(setting, str): - # the user provided a simple string. use it as is - cmd.append('-r') - cmd.append(setting) - elif isinstance(setting, list): - for sttng in setting: - cmd.append('-r') - cmd.append(sttng) - else: - raise ValueError('Unsupported setting value') - - if controller is not None: - if isinstance(controller, str) and ':' in controller: - # the user provided a controller:cgroup. use it as is - cmd.append('-g') - cmd.append(controller) - elif isinstance(controller, str): - # the user provided a controller only. use it as is - cmd.append('-g') - cmd.append(controller) - elif isinstance(controller, list): - for ctrl in controller: - cmd.append('-g') - cmd.append(ctrl) - else: - raise ValueError('Unsupported controller value') - - if all_controllers: - cmd.append('-a') - - if cgname is not None: - if isinstance(cgname, str): - # use the string as is - cmd.append(cgname) - elif isinstance(cgname, list): - for cg in cgname: - cmd.append(cg) - - if cghelp: - cmd.append('-h') - - if config.args.container: - ret = config.container.run(cmd) - else: - ret = Run.run(cmd) - - return ret - - @staticmethod - def get(config, controller=None, cgname=None, setting=None, - print_headers=True, values_only=False, - all_controllers=False, cghelp=False, ignore_systemd=False): - """cgget equivalent method - - Returns: - str: The stdout result of cgget - - The following variants of cgget() are being tested by the - automated functional tests: - - Command Test Number - cgget -r cpuset.cpus mycg 001 - cgget -r cpuset.cpus -r cpuset.mems mycg 008 - cgget -g cpu mycg 009 - cgget -g cpu:mycg 010 - cgget -r cpuset.cpus mycg1 mycg2 011 - cgget -r cpuset.cpus -r cpuset.mems mycg1 mycg2 012 - cgget -g cpu -g freezer mycg 013 - cgget -a mycg 014 - cgget -r memory.stat mycg (multiline value read) 015 - various invalid flag combinations 016 - """ - cmd = list() - cmd.append(Cgroup.build_cmd_path('cgget')) - - return Cgroup.__get(config, cmd, controller, cgname, setting, - print_headers, values_only, all_controllers, - cghelp, ignore_systemd) - - @staticmethod - def xget(config, controller=None, cgname=None, setting=None, - print_headers=True, values_only=False, - all_controllers=False, version=CgroupVersion.CGROUP_UNK, - cghelp=False, ignore_unmappable=False, ignore_systemd=False): - """cgxget equivalent method - - Returns: - str: The stdout result of cgxget - """ - cmd = list() - cmd.append(Cgroup.build_cmd_path('cgxget')) - - if version == CgroupVersion.CGROUP_V1: - cmd.append('-1') - elif version == CgroupVersion.CGROUP_V2: - cmd.append('-2') - - if ignore_unmappable: - cmd.append('-i') - - return Cgroup.__get(config, cmd, controller, cgname, setting, - print_headers, values_only, all_controllers, - cghelp, ignore_systemd) - - @staticmethod - def classify(config, controller, cgname, pid_list, sticky=False, - cancel_sticky=False, ignore_systemd=False, replace_idle=False): - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgclassify')) - - if replace_idle: - cmd.append('-r') - - if ignore_systemd: - cmd.append('-b') - - if isinstance(controller, str): - cmd.append('-g') - cmd.append('{}:{}'.format(controller, cgname)) - elif isinstance(controller, list): - controller = ','.join(controller) - cmd.append('-g') - cmd.append('{}:{}'.format(controller, cgname)) - elif controller is None: - cmd.append('-g') - cmd.append(':{}'.format(cgname)) - else: - raise ValueError('Unsupported controller format: {}'.format(type(controller))) - - if isinstance(pid_list, str): - cmd.append(pid_list) - elif isinstance(pid_list, int): - cmd.append(str(pid_list)) - elif isinstance(pid_list, list): - for pid in pid_list: - cmd.append(str(pid)) - - if config.args.container: - config.container.run(cmd) - else: - Run.run(cmd) - - @staticmethod - # given a stdout of cgsnapshot-like data, create a dictionary of cgroup - # objects - def snapshot_to_dict(cgsnapshot_stdout): - cgdict = dict() - - class parsemode(Enum): - UNKNOWN = 0 - GROUP = 1 - CONTROLLER = 2 - SETTING = 3 - PERM = 4 - ADMIN = 5 - TASK = 6 - - mode = parsemode.UNKNOWN - - for line in cgsnapshot_stdout.splitlines(): - line = line.strip() - - if mode == parsemode.UNKNOWN: - if line.startswith('#'): - continue - - elif line.startswith('group') and line.endswith('{'): - cg_name = line.split()[1] - if cg_name in cgdict: - # We already have a cgroup with this name. This block - # of text contains the next controller for this cgroup - cg = cgdict[cg_name] - else: - cg = Cgroup(cg_name) - - mode = parsemode.GROUP - - elif mode == parsemode.GROUP: - if line.startswith('perm {'): - mode = parsemode.PERM - elif line.endswith('{'): - ctrl_name = line.split()[0] - cg.controllers[ctrl_name] = Controller(ctrl_name) - - mode = parsemode.CONTROLLER - elif line.endswith('}'): - # we've found the end of this group - cgdict[cg_name] = cg - - mode = parsemode.UNKNOWN - - elif mode == parsemode.CONTROLLER: - if line.endswith('";'): - # this is a setting on a single line - setting = line.split('=')[0] - value = line.split('=')[1] - - cg.controllers[ctrl_name].settings[setting] = value - - elif line.endswith('}'): - # we've found the end of this controller - mode = parsemode.GROUP - - else: - # this is a multi-line setting - setting = line.split('=')[0] - value = '{}\n'.format(line.split('=')[1]) - mode = parsemode.SETTING - - elif mode == parsemode.SETTING: - if line.endswith('";'): - # this is the last line of the multi-line setting - value += line - - cg.controllers[ctrl_name].settings[setting] = value - mode = parsemode.CONTROLLER - - else: - value += '{}\n'.format(line) - - elif mode == parsemode.PERM: - if line.startswith('admin {'): - mode = parsemode.ADMIN - elif line.startswith('task {'): - mode = parsemode.TASK - elif line.endswith('}'): - mode = parsemode.GROUP - - elif mode == parsemode.ADMIN or mode == parsemode.TASK: - # todo - handle these modes - if line.endswith('}'): - mode = parsemode.PERM - - return cgdict - - @staticmethod - def snapshot(config, controller=None): - cmd = list() - cmd.append(Cgroup.build_cmd_path('cgsnapshot')) - if controller is not None: - cmd.append(controller) - - # ensure the deny list file exists - if config.args.container: - try: - config.container.run( - ['sudo', - 'touch', - '/etc/cgsnapshot_denylist.conf'] - ) - except RunError as re: - if re.ret == 0 and 'unable to resolve host' in re.stderr: - pass - else: - Run.run(['sudo', 'touch', '/etc/cgsnapshot_denylist.conf']) - - try: - if config.args.container: - res = config.container.run(cmd) - else: - res = Run.run(cmd) - except RunError as re: - if re.ret == 0 and \ - 'neither deny nor allow list' in re.stderr: - res = re.stdout - elif re.ret == 0 and 'ERROR: can\'t get' in re.stderr: - res = re.stdout - else: - raise(re) - - # convert the cgsnapshot stdout to a dict of cgroup objects - return Cgroup.snapshot_to_dict(res) - - @staticmethod - def set_cgrules_conf(config, line, append=True): - cmd = list() - - cmd.append('sudo') - cmd.append('su') - cmd.append('-c') - - if append: - redirect_str = '>>' - else: - redirect_str = '>' - - subcmd = '"echo {} {} {}"'.format(line, redirect_str, - consts.CGRULES_FILE) - cmd.append(subcmd) - - if config.args.container: - config.container.run(cmd, shell_bool=True) - else: - Run.run(cmd, shell_bool=True) - - @staticmethod - def init_cgrules(config): - cmd = list() - - cmd.append('sudo') - cmd.append('mkdir') - cmd.append('-p') - cmd.append('/etc/cgconfig.d') - - try: - if config.args.container: - config.container.run(cmd, shell_bool=True) - else: - Run.run(cmd, shell_bool=True) - except RunError as re: - raise re - - cmd2 = list() - - cmd2.append('sudo') - cmd2.append('touch') - cmd2.append('/etc/cgconfig.conf') - - if config.args.container: - config.container.run(cmd2, shell_bool=True) - else: - Run.run(cmd2, shell_bool=True) - - # note that this runs cgrulesengd in this process and does not fork - # the daemon - @staticmethod - def __run_cgrules(config): - cmd = list() - - cmd.append('sudo') - cmd.append(Cgroup.build_daemon_path('cgrulesengd')) - cmd.append('-d') - cmd.append('-n') - - if config.args.container: - raise ValueError( - 'Running cgrules within a container is not ' - 'supported' - ) - else: - Run.run(cmd, shell_bool=True) - - def start_cgrules(self, config): - Cgroup.init_cgrules(config) - - p = mp.Process(target=Cgroup.__run_cgrules, - args=(config, )) - p.start() - time.sleep(2) - - self.children.append(p) - - def join_children(self, config): - # todo - make this smarter. this is ugly, but it works for now - cmd = ['sudo', 'killall', 'cgrulesengd'] - try: - if config.args.container: - config.container.run(cmd, shell_bool=True) - else: - Run.run(cmd, shell_bool=True) - except (RunError, ContainerError): - # ignore any errors during the kill command. this is belt - # and suspenders code - pass - - for child in self.children: - child.join(1) - - @staticmethod - def configparser(config, load_file=None, load_dir=None, dflt_usr=None, - dflt_grp=None, dperm=None, fperm=None, cghelp=False, - tperm=None, tasks_usr=None, tasks_grp=None): - """cgconfigparser equivalent method - - Returns: - str: The stdout result of cgconfigparser - - The following variants of cgconfigparser are being tested by the - automated functional tests: - - Command Test Number - cgconfigparser -l conf_file 017 - cgconfigparser -L conf_dir 018 - cgconfigparser -l conf_file -a usr:grp -d mode -f mode 019 - cgconfigparser -l conf_file -s mode -t usr:grp 020 - cgconfigparser -h 021 - cgconfigparser -l improper_conf_file 021 - """ - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgconfigparser')) - - if load_file is not None: - cmd.append('-l') - cmd.append(load_file) - - if load_dir is not None: - cmd.append('-L') - cmd.append(load_dir) - - if dflt_usr is not None and dflt_grp is not None: - cmd.append('-a') - cmd.append('{}:{}'.format(dflt_usr, dflt_grp)) - - if dperm is not None: - cmd.append('-d') - cmd.append(dperm) - - if fperm is not None: - cmd.append('-f') - cmd.append(fperm) - - if cghelp: - cmd.append('-h') - - if tperm is not None: - cmd.append('-s') - cmd.append(tperm) - - if tasks_usr is not None and tasks_grp is not None: - cmd.append('-t') - cmd.append('{}:{}'.format(tasks_usr, tasks_grp)) - - if config.args.container: - return config.container.run(cmd) - else: - return Run.run(cmd) - - @staticmethod - def __get_controller_mount_point_v1(ctrl_name): - with open('/proc/mounts', 'r') as mntf: - for line in mntf.readlines(): - mnt_path = line.split()[1] - - if ctrl_name is None: - if line.split()[0] == 'cgroup2': - return mnt_path - - if line.split()[0] == 'cgroup': - for option in line.split()[3].split(','): - if option == ctrl_name: - return mnt_path - - raise IndexError( - 'Unknown mount point for controller {}' - ''.format(ctrl_name) - ) - - @staticmethod - def __get_controller_mount_point_v2(ctrl_name): - with open('/proc/mounts', 'r') as mntf: - for line in mntf.readlines(): - mnt_path = line.split()[1] - - if line.split()[0] == 'cgroup2': - if ctrl_name is None: - return mnt_path - - ctrl_file = os.path.join(line.split()[1], - 'cgroup.controllers') - - with open(ctrl_file, 'r') as ctrlf: - controllers = ctrlf.readline() - for controller in controllers.split(): - if controller == ctrl_name: - return mnt_path - - raise IndexError( - 'Unknown mount point for controller {}' - ''.format(ctrl_name) - ) - - @staticmethod - def get_controller_mount_point(ctrl_name): - if ctrl_name is None: - mode = int(Cgroup.get_cgroup_mode(None)) - # map return modes: - # CGROUP_MODE_LEGACY/CGROUP_MODE_HYBRID -> CgroupVersion.CGROUP_V1 - # CGROUP_MODE_UNIFIED -> CgroupVersion.CGROUP_V2 - if mode >= 2: - mode = mode - 1 - vers = CgroupVersion(mode) - else: - vers = CgroupVersion.get_version(ctrl_name) - - if vers == CgroupVersion.CGROUP_V1: - return Cgroup.__get_controller_mount_point_v1(ctrl_name) - elif vers == CgroupVersion.CGROUP_V2: - return Cgroup.__get_controller_mount_point_v2(ctrl_name) - else: - raise ValueError('Unsupported cgroup version') - - @staticmethod - def clear(config, empty=False, cghelp=False, load_file=None, - load_dir=None): - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgclear')) - - if empty: - cmd.append('-e') - - if cghelp: - cmd.append('-h') - - if load_file is not None: - cmd.append('-l') - cmd.append(load_file) - - if load_dir is not None: - cmd.append('-L') - cmd.append(load_dir) - - if config.args.container: - return config.container.run(cmd) - else: - return Run.run(cmd) - - @staticmethod - def lssubsys(config, ls_all=False, cghelp=False, hierarchies=False, - mount_points=False, all_mount_points=False): - cmd = list() - - cmd.append(Cgroup.build_cmd_path('lssubsys')) - - if ls_all: - cmd.append('-a') - - if cghelp: - cmd.append('-h') - - if hierarchies: - cmd.append('-i') - - if mount_points: - cmd.append('-m') - - if all_mount_points: - cmd.append('-M') - - if config.args.container: - ret = config.container.run(cmd) - else: - ret = Run.run(cmd) - - return ret - - @staticmethod - def get_cgroup_mounts(config, expand_v2_mounts=True): - mount_list = list() - - with open('/proc/mounts') as mntf: - for line in mntf.readlines(): - entry = line.split() - - if entry[0] != 'cgroup' and entry[0] != 'cgroup2': - continue - - mount = CgroupMount(line) - - if mount.version == CgroupVersion.CGROUP_V1 or \ - expand_v2_mounts is False: - mount_list.append(mount) - - if entry[1].find(',') > 0: - # multiple controllers are mounted together. Also add the - # first controller to the mount_list - controller = os.path.basename(entry[1].split(',')[0]) - mount = CgroupMount(line, controller=controller) - mount_list.append(mount) - continue - - with open(os.path.join(mount.mount_point, - 'cgroup.controllers')) as ctrlf: - for ctrlf_line in ctrlf.readlines(): - for ctrl in ctrlf_line.split(): - mount_copy = copy.deepcopy(mount) - mount_copy.controller = ctrl - mount_list.append(mount_copy) - - return mount_list - - @staticmethod - def lscgroup(config, cghelp=False, controller=None, path=None): - cmd = list() - - cmd.append(Cgroup.build_cmd_path('lscgroup')) - - if cghelp: - cmd.append('-h') - - if controller is not None and path is not None: - if isinstance(controller, list): - for idx, ctrl in enumerate(controller): - cmd.append('-g') - cmd.append('{}:{}'.format(ctrl, path[idx])) - elif isinstance(controller, str): - cmd.append('-g') - cmd.append('{}:{}'.format(controller, path)) - else: - raise ValueError('Unsupported controller value') - - if config.args.container: - ret = config.container.run(cmd) - else: - ret = Run.run(cmd) - - return ret - - # exec is a keyword in python, so let's name this function cgexec - @staticmethod - def cgexec(config, controller, cgname, cmdline, sticky=False, - cghelp=False, ignore_systemd=False, replace_idle=False): - """cgexec equivalent method - """ - cmd = list() - - if not config.args.container: - cmd.append('sudo') - cmd.append(Cgroup.build_cmd_path('cgexec')) - - if (ignore_systemd): - cmd.append('-b') - - if (replace_idle): - cmd.append('-r') - - cmd.append('-g') - cmd.append('{}:{}'.format(controller, cgname)) - - if sticky: - cmd.append('--sticky') - - if isinstance(cmdline, str): - cmd.append(cmdline) - elif isinstance(cmdline, list): - for entry in cmdline: - cmd.append(str(entry)) - - if cghelp: - cmd.append('-h') - - if config.args.container: - return config.container.run(cmd, shell_bool=True) - else: - return Run.run(cmd, shell_bool=True) - - @staticmethod - def get_pids_in_cgroup(config, cgroup, controller): - mounts = Cgroup.get_cgroup_mounts(config) - - for mount in mounts: - if mount.controller == controller: - proc_file = os.path.join( - mount.mount_point, - cgroup, - 'cgroup.procs' - ) - cmd = ['cat', proc_file] - - if config.args.container: - pids = config.container.run(cmd, shell_bool=True) - else: - pids = Run.run(cmd, shell_bool=True) - - pid_list = list() - for pid in pids.splitlines(): - pid_list.append(int(pid)) - - return pid_list - - return None - - @staticmethod - def get_and_validate(config, cgname, setting, expected_value, ignore_systemd=False): - """get the requested setting and validate the value received - - This is a helper method for the functional tests and there is no - equivalent libcgroup command line interface. This method will - raise a CgroupError if the comparison fails - """ - value = Cgroup.get(config, controller=None, cgname=cgname, - setting=setting, print_headers=False, - values_only=True, ignore_systemd=ignore_systemd) - - if value != expected_value: - raise CgroupError('cgget expected {} but received {}'.format( - expected_value, value)) - - @staticmethod - def set_and_validate(config, cgname, setting, value, ignore_systemd=False): - """set the requested setting and validate the write - - This is a helper method for the functional tests and there is no - equivalent libcgroup command line interface. This method will - raise a CgroupError if the comparison fails - """ - Cgroup.set(config, cgname, setting, value, ignore_systemd=ignore_systemd) - Cgroup.get_and_validate(config, cgname, setting, value, ignore_systemd=ignore_systemd) - - @staticmethod - def get_cgroup_mode(config): - mount_list = Cgroup.get_cgroup_mounts(config, True) - - legacy = False - unified = False - - for mount in mount_list: - # As best I can tell, python doesn't have an easy way to access the statfs() f_type - # field. Let's make our best guess at the cgroup version (legacy, hybrid, or - # unified) by the presence of certain files/folders - - cpu_ctrl = os.path.join(os.path.dirname(mount.mount_point), 'cpu,cpuacct') - if os.path.exists(cpu_ctrl): - legacy = True - - limit_file = os.path.join(mount.mount_point, 'memory.limit_in_bytes') - if os.path.exists(limit_file): - legacy = True - - subtree_file = os.path.join(mount.mount_point, 'cgroup.subtree_control') - if os.path.exists(subtree_file): - unified = True - - subtree_file = os.path.join(os.path.dirname(mount.mount_point), - 'cgroup.subtree_control') - if os.path.exists(subtree_file): - unified = True - - subtree_file = os.path.join(os.path.dirname(mount.mount_point), 'unified', - 'cgroup.subtree_control') - if os.path.exists(subtree_file): - unified = True - - if legacy and unified: - return Mode.CGROUP_MODE_HYBRID - elif legacy: - return Mode.CGROUP_MODE_LEGACY - elif unified: - return Mode.CGROUP_MODE_UNIFIED - else: - raise CgroupError('Unknown cgroup mode') - - @staticmethod - def is_controller_enabled(config, cgroup_name, ctrl_name): - ctrl_path = Cgroup.__get_controller_mount_point_v2(ctrl_name) - parent_cgname = os.path.dirname(cgroup_name) - - subtree_path = os.path.join(ctrl_path, parent_cgname, 'cgroup.controllers') - cmd = ['cat', subtree_path] - - if config.args.container: - controllers = config.container.run(cmd, shell_bool=True) - else: - controllers = Run.run(cmd, shell_bool=True) - - for controller in controllers.split(): - if controller == ctrl_name: - return True - - return False - - @staticmethod - def __exists(config, ctrl_name, cgroup_name, ignore_systemd): - ctrl_mnt = Cgroup.get_controller_mount_point(ctrl_name) - - if (ignore_systemd): - cgrp_path = os.path.join(ctrl_mnt, cgroup_name) - else: - try: - cmd = ['cat', '/run/libcgroup/systemd'] - if config.args.container: - slice_scope_path = config.container.run(cmd, shell_bool=True) - else: - slice_scope_path = Run.run(cmd, shell_bool=True) - except RunError: - return False - - cgrp_path = os.path.join(ctrl_mnt, slice_scope_path, cgroup_name) - - # Every cgroup is populated with cgroup.procs (setup mode agnostic) - # It easier to check of the directory exist by tring to read it - proc_file = os.path.join(cgrp_path, 'cgroup.procs') - cmd = ['cat', proc_file] - try: - if config.args.container: - config.container.run(cmd, shell_bool=True) - else: - Run.run(cmd, shell_bool=True) - except RunError: - return False - - return True - - # This function builds absolute path of the cgroup, using the default - # systemd path and checks if the cgroup exists. The function can build - # path for all three cgroup setup modes, including empty cgroup v2. - @staticmethod - def exists(config, ctrl_name, cgroup_name, ignore_systemd=False): - if ctrl_name is None or type(ctrl_name) == str: - return Cgroup.__exists(config, ctrl_name, cgroup_name, ignore_systemd) - elif type(ctrl_name) == list: - for ctrl in ctrl_name: - if not Cgroup.__exists(config, ctrl, cgroup_name, ignore_systemd): - # if any of the controllers don't exist, fail the check - return False - - # all of the controllers exist, Yippee - return True - else: - raise ValueError("Unsupported type: {}".format(type(ctrl_name))) - - # Method to enable or disable controllers in the subtree control file - @staticmethod - def subtree_control(config, cgname, controllers, enable=True, ignore_systemd=False): - if isinstance(controllers, str): - controllers = [controllers] - elif isinstance(controllers, list): - pass - else: - raise ValueError('Unsupported controller value') - - if enable: - enable_char = '+' - else: - enable_char = '-' - - for ctrl in controllers: - Cgroup.set(config, cgname, 'cgroup.subtree_control', - '{}{}'.format(enable_char, ctrl), ignore_systemd=ignore_systemd) - - -class CgroupError(Exception): - def __init__(self, message): - super(CgroupError, self).__init__(message) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/config.py b/lib/libcgroup-3.1.0/tests/ftests/config.py deleted file mode 100644 index e14d28fe881..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/config.py +++ /dev/null @@ -1,58 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Config class for the libcgroup functional tests -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from container import Container -from process import Process -import consts -import utils -import os - - -class Config(object): - def __init__(self, args, container=None): - self.args = args - self.skip_list = [] - - if self.args.container: - if container: - self.container = container - else: - # Use the default container settings - self.container = Container(name=args.name, - stop_timeout=args.timeout, - arch=None, - distro=args.distro, - release=args.release) - - self.process = Process() - - self.ftest_dir = os.path.dirname(os.path.abspath(__file__)) - self.libcg_dir = os.path.dirname(self.ftest_dir) - - self.test_suite = consts.TESTS_RUN_ALL_SUITES - self.test_num = consts.TESTS_RUN_ALL - self.verbose = False - - def __str__(self): - out_str = 'Configuration\n' - if self.args.container: - out_str += utils.indent(str(self.container), 4) - out_str += utils.indent(str(self.process), 4) - - return out_str - - -class ConfigError(Exception): - def __init__(self, message): - super(ConfigError, self).__init__(message) - - def __str__(self): - out_str = 'ConfigError:\n\tmessage = {}'.format(self.message) - return out_str - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/consts.py b/lib/libcgroup-3.1.0/tests/ftests/consts.py deleted file mode 100644 index 7891aaceff1..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/consts.py +++ /dev/null @@ -1,36 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Constants for the libcgroup functional tests -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -import os - -DEFAULT_LOG_FILE = 'libcgroup-ftests.log' - -LOG_CRITICAL = 1 -LOG_WARNING = 5 -LOG_DEBUG = 8 -DEFAULT_LOG_LEVEL = 5 - -ftest_dir = os.path.dirname(os.path.abspath(__file__)) -tests_dir = os.path.dirname(ftest_dir) -LIBCG_MOUNT_POINT = os.path.dirname(tests_dir) - -DEFAULT_CONTAINER_NAME = 'TestLibcg' -DEFAULT_CONTAINER_DISTRO = 'ubuntu' -DEFAULT_CONTAINER_RELEASE = '22.04' -DEFAULT_CONTAINER_ARCH = 'amd64' -DEFAULT_CONTAINER_STOP_TIMEOUT = 5 - -TESTS_RUN_ALL = -1 -TESTS_RUN_ALL_SUITES = 'allsuites' -TEST_PASSED = 'passed' -TEST_FAILED = 'failed' -TEST_SKIPPED = 'skipped' - -CGRULES_FILE = '/etc/cgrules.conf' - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/container.py b/lib/libcgroup-3.1.0/tests/ftests/container.py deleted file mode 100644 index a54f6a3a4dd..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/container.py +++ /dev/null @@ -1,221 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Container class for the libcgroup functional tests -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from run import Run, RunError -from queue import Queue -import threading as tp -from log import Log -import consts -import time -import os - - -class Container(object): - def __init__(self, name, stop_timeout=None, arch=None, cfg_path=None, - distro=None, release=None): - self.name = name - self.privileged = True - - if stop_timeout: - self.stop_timeout = stop_timeout - else: - self.stop_timeout = consts.DEFAULT_CONTAINER_STOP_TIMEOUT - - if arch: - self.arch = arch - else: - self.arch = consts.DEFAULT_CONTAINER_ARCH - - if distro: - self.distro = distro - else: - self.distro = consts.DEFAULT_CONTAINER_DISTRO - - if release: - self.release = release - else: - self.release = consts.DEFAULT_CONTAINER_RELEASE - - ftest_dir = os.path.dirname(os.path.abspath(__file__)) - tests_dir = os.path.dirname(ftest_dir) - # save off the path to the libcgroup source code - self.libcg_dir = os.path.dirname(tests_dir) - - def __str__(self): - out_str = 'Container {}'.format(self.name) - out_str += '\n\tdistro = {}'.format(self.distro) - out_str += '\n\trelease = {}'.format(self.release) - out_str += '\n\tarch = {}'.format(self.arch) - out_str += '\n\tstop_timeout = {}\n'.format(self.stop_timeout) - - return out_str - - # configure the container to meet our needs - def config(self): - # map our UID and GID to the same UID/GID in the container - cmd = ( - 'printf "uid {} 1000\ngid {} 1000" | sudo lxc config set ' - '{} raw.idmap -' - ''.format(os.getuid(), os.getgid(), self.name) - ) - Run.run(cmd, shell_bool=True) - - # add the libcgroup root directory (where we did the build) into - # the container - cmd2 = list() - if self.privileged: - cmd2.append('sudo') - cmd2.append('lxc') - cmd2.append('config') - cmd2.append('device') - cmd2.append('add') - cmd2.append(self.name) - cmd2.append('libcgsrc') # arbitrary name of device - cmd2.append('disk') - # to appease gcov, mount the libcgroup source at the same path as we - # built it. This can be worked around someday by using - # GCOV_PREFIX_STRIP, but that was more difficult to setup than just - # doing this initially - cmd2.append('source={}'.format(self.libcg_dir)) - cmd2.append('path={}'.format(self.libcg_dir)) - - return Run.run(cmd2) - - def _init_container(self, q): - cmd = list() - - if self.privileged: - cmd.append('sudo') - - cmd.append('lxc') - cmd.append('init') - - cmd.append('{}:{}'.format(self.distro, self.release)) - - cmd.append(self.name) - - try: - Run.run(cmd) - q.put(True) - except Exception: # noqa: E722 - q.put(False) - except BaseException: # noqa: E722 - q.put(False) - - def create(self): - # Github Actions sometimes has timeout issues with the LXC sockets. - # Try this command multiple times in an attempt to work around this - # limitation - - queue = Queue() - sleep_time = 5 - ret = False - - for i in range(5): - thread = tp.Thread(target=self._init_container, args=(queue, )) - thread.start() - - time_cnt = 0 - while thread.is_alive(): - time.sleep(sleep_time) - time_cnt += sleep_time - Log.log_debug('Waiting... {}'.format(time_cnt)) - - ret = queue.get() - if ret: - break - else: - try: - self.delete() - except RunError: - pass - - thread.join() - - if not ret: - raise ContainerError('Failed to create the container') - - def delete(self): - cmd = list() - - if self.privileged: - cmd.append('sudo') - - cmd.append('lxc') - cmd.append('delete') - - cmd.append(self.name) - - return Run.run(cmd) - - def run(self, cntnr_cmd, shell_bool=False): - cmd = list() - - if self.privileged: - cmd.append('sudo') - - cmd.append('lxc') - cmd.append('exec') - - cmd.append(self.name) - - cmd.append('--') - - # concatenate the lxc exec command with the command to be run - # inside the container - if isinstance(cntnr_cmd, str): - cmd.append(cntnr_cmd) - elif isinstance(cntnr_cmd, list): - cmd = cmd + cntnr_cmd - else: - raise ContainerError('Unsupported command type') - - return Run.run(cmd, shell_bool=shell_bool) - - def start(self): - cmd = list() - - if self.privileged: - cmd.append('sudo') - - cmd.append('lxc') - cmd.append('start') - - cmd.append(self.name) - - return Run.run(cmd) - - def stop(self, force=True): - cmd = list() - - if self.privileged: - cmd.append('sudo') - - cmd.append('lxc') - cmd.append('stop') - - cmd.append(self.name) - - if force: - cmd.append('-f') - else: - cmd.append('--timeout') - cmd.append(str(self.stop_timeout)) - - return Run.run(cmd) - - -class ContainerError(Exception): - def __init__(self, message): - super(ContainerError, self).__init__(message) - - def __str__(self): - out_str = 'ContainerError:\n\tmessage = {}'.format(self.message) - return out_str - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/controller.py b/lib/libcgroup-3.1.0/tests/ftests/controller.py deleted file mode 100644 index b80b7c5cac8..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/controller.py +++ /dev/null @@ -1,69 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup class for the libcgroup functional tests -# -# Copyright (c) 2020 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from log import Log - - -class Controller(object): - # The controller class closely mirrors libcgroup's struct cgroup_controller - def __init__(self, name): - self.name = name - # self.settings maps to - # struct control_value *values[CG_NV_MAX]; - self.settings = dict() - - def __str__(self): - out_str = 'Controller {}\n'.format(self.name) - - for setting_key in self.settings: - out_str += ' {} = {}\n'.format(setting_key, - self.settings[setting_key]) - - return out_str - - def __eq__(self, other): - if not isinstance(other, Controller): - return False - - if not self.name == other.name: - return False - - if not self.settings == other.settings: - self_keys = set(self.settings.keys()) - other_keys = set(other.settings.keys()) - - added = other_keys - self_keys - if added is not None: - for key in added: - Log.log_critical( - 'Other contains {} = {}' - ''.format(key, other.settings[key]) - ) - - removed = self_keys - other_keys - if removed is not None: - for key in removed: - Log.log_critical( - 'Self contains {} = {}' - ''.format(key, self.settings[key]) - ) - - common = self_keys.intersection(other_keys) - for key in common: - if self.settings[key] != other.settings[key]: - Log.log_critical( - 'self{} = {} while other{} = {}' - ''.format(key, self.settings[key], - key, other.settings[key]) - ) - - return False - - return True - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/ftests-wrapper.sh b/lib/libcgroup-3.1.0/tests/ftests/ftests-wrapper.sh deleted file mode 100755 index 7a65de63a88..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/ftests-wrapper.sh +++ /dev/null @@ -1,111 +0,0 @@ -#!/bin/bash -# SPDX-License-Identifier: LGPL-2.1-only - -# the lock file is removed after all the tests complete -function cleanup() -{ - sudo rm -f "$RUNNER_LOCK_FILE" - exit "$1" -} - -AUTOMAKE_SKIPPED=77 -AUTOMAKE_HARD_ERROR=99 - -# synchronize between different github runners running on -# same VM's, this will stop runners from stomping over -# each other's run. -LIBCGROUP_RUN_DIR="/var/run/libcgroup/" -RUNNER_LOCK_FILE="/var/run/libcgroup/github-runner.lock" -RUNNER_SLEEP_SECS=300 # sleep for 5 minutes -RUNNER_MAX_TRIES=10 # Abort after 50 minutes, if we don't chance to run - -START_DIR=$PWD -SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) - -if [ "$START_DIR" != "$SCRIPT_DIR" ]; then - cp "$SCRIPT_DIR"/*.py "$START_DIR" -fi - -PYTHON_LIBRARY_PATH=(../../src/python/build/lib*) -if [ -d "${PYTHON_LIBRARY_PATH[0]}" ]; then - pushd "${PYTHON_LIBRARY_PATH[0]}" || cleanup $AUTOMAKE_HARD_ERROR - PYTHONPATH="$PYTHONPATH:$(pwd)" - export PYTHONPATH - popd || cleanup $AUTOMAKE_HARD_ERROR -fi - -# If other runners are running then the file exists -# let's wait for 5 minutes -time_waited=0 -pretty_time=0 -while [ -f "$RUNNER_LOCK_FILE" ]; do - if [ "$RUNNER_MAX_TRIES" -le 0 ]; then - echo "Unable to get lock to run the ftests, aborting" - exit 1 - fi - - RUNNER_MAX_TRIES=$(( RUNNER_MAX_TRIES - 1 )) - sleep "$RUNNER_SLEEP_SECS" - - time_waited=$(( time_waited + RUNNER_SLEEP_SECS )) - pretty_time=$(echo $time_waited | awk '{printf "%d:%02d:%02d", $1/3600, ($1/60)%60, $1%60}') - echo "[$pretty_time] Waiting on other runners to complete, $RUNNER_MAX_TRIES retries left" -done - -# take the lock and start executing -sudo mkdir -p "$LIBCGROUP_RUN_DIR" -sudo touch "$RUNNER_LOCK_FILE" - -./ftests.py -l 10 -L "$START_DIR/ftests.py.log" -n Libcg"$RANDOM" -RET1=$? - -./ftests.py -l 10 -L "$START_DIR/ftests-nocontainer.py.log" --no-container \ - -n Libcg"$RANDOM" -RET2=$? - -if [ -z "$srcdir" ]; then - # $srcdir is set by automake but will likely be empty when run by hand and - # that's fine - srcdir="" -else - srcdir=$srcdir"/" -fi - -sudo cp $srcdir../../src/libcgroup_systemd_idle_thread /bin -sudo PYTHONPATH="$PYTHONPATH" ./ftests.py -l 10 -s "sudo" \ - -L "$START_DIR/ftests-nocontainer.py.sudo.log" --no-container -n Libcg"$RANDOM" -RET3=$? -sudo rm /bin/libcgroup_systemd_idle_thread - -if [ "$START_DIR" != "$SCRIPT_DIR" ]; then - rm -f "$START_DIR"/*.py - rm -fr "$START_DIR"/__pycache__ - rm -f ftests.py.log - rm -f ftests-nocontainer.py.log - rm -f ftests-nocontainer.py.sudo.log -fi - -if [[ $RET1 -ne $AUTOMAKE_SKIPPED ]] && [[ $RET1 -ne 0 ]]; then - # always return errors from the first test run - cleanup $RET1 -fi -if [[ $RET2 -ne $AUTOMAKE_SKIPPED ]] && [[ $RET2 -ne 0 ]]; then - # return errors from the second test run - cleanup $RET2 -fi -if [[ $RET3 -ne $AUTOMAKE_SKIPPED ]] && [[ $RET3 -ne 0 ]]; then - # return errors from the third test run - cleanup $RET3 -fi - -if [[ $RET1 -eq 0 ]] || [[ $RET2 -eq 0 ]] || [[ $RET3 -eq 0 ]]; then - cleanup 0 -fi - -if [[ $RET1 -eq $AUTOMAKE_SKIPPED ]] || [[ $RET2 -eq $AUTOMAKE_SKIPPED ]] || - [[ $RET3 -eq $AUTOMAKE_SKIPPED ]]; then - cleanup $AUTOMAKE_SKIPPED -fi - -# I don't think we should ever get here, but better safe than sorry -cleanup $AUTOMAKE_HARD_ERROR diff --git a/lib/libcgroup-3.1.0/tests/ftests/ftests.py b/lib/libcgroup-3.1.0/tests/ftests/ftests.py deleted file mode 100755 index a6aa6af0e90..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/ftests.py +++ /dev/null @@ -1,475 +0,0 @@ -#!/usr/bin/env python3 -# SPDX-License-Identifier: LGPL-2.1-only -# -# Main entry point for the libcgroup functional tests -# -# Copyright (c) 2019-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from config import Config -from run import Run -import datetime -import argparse -import consts -import time -import log -import sys -import os - -setup_time = 0.0 -teardown_time = 0.0 - -Log = log.Log - - -def parse_args(): - parser = argparse.ArgumentParser("Libcgroup Functional Tests") - parser.add_argument( - '-n', '--name', - help='name of the container', - required=False, - type=str, - default=consts.DEFAULT_CONTAINER_NAME - ) - parser.add_argument( - '-d', '--distro', - help='linux distribution to use as a template', - required=False, - type=str, - default=None - ) - parser.add_argument( - '-r', '--release', - help="distribution release, e.g.'trusty'", - required=False, - type=str, - default=None - ) - parser.add_argument( - '-a', '--arch', - help='processor architecture', - required=False, - type=str, - default=None - ) - parser.add_argument( - '-t', '--timeout', - help='wait timeout (sec) before stopping the ' - 'container', - required=False, - type=int, - default=None - ) - - parser.add_argument( - '-l', '--loglevel', - help='log level', - required=False, - type=int, - default=None - ) - parser.add_argument( - '-L', '--logfile', - help='log file', - required=False, - type=str, - default=None - ) - - parser.add_argument( - '-N', '--num', - help='Test number to run. If unspecified, all ' - 'tests are run', - required=False, - default=consts.TESTS_RUN_ALL, - type=int - ) - parser.add_argument( - '-S', '--skip', - help="Test number(s) to skip. If unspecified, all" - " tests are run. To skip multiple tests, " - "separate them via a ',', e.g. '5,7,12'", - required=False, - default='', - type=str - ) - parser.add_argument( - '-s', '--suite', - help='Test suite to run, e.g. cpuset', - required=False, - default=consts.TESTS_RUN_ALL_SUITES, - type=str - ) - - container_parser = parser.add_mutually_exclusive_group(required=False) - container_parser.add_argument( - '--container', - action='store_true', - help='Run the tests in a container. Note ' - 'that some tests cannot be run in a ' - 'container.', - dest='container' - ) - container_parser.add_argument( - '--no-container', - action='store_false', - help='Do not run the tests in a container.' - ' Note that some tests are ' - 'destructive and will modify your ' - 'cgroup hierarchy.', - dest='container' - ) - parser.set_defaults(container=True) - - parser.add_argument( - '-v', '--verbose', - help='Print all information about this test run', - default=True, - required=False, - action="store_false" - ) - - config = Config(parser.parse_args()) - - if config.args.skip is None or config.args.skip == '': - pass - elif config.args.skip.find(',') < 0: - config.skip_list.append(int(config.args.skip)) - else: - # multiple tests are being skipped - for test_num in config.args.skip.split(','): - config.skip_list.append(int(test_num)) - - if config.args.loglevel: - log.log_level = config.args.loglevel - if config.args.logfile: - log.log_file = config.args.logfile - - return config - - -# this function maps the container UID to the host UID. By doing -# this, we can write to a bind-mounted device - and thus generate -# code coverage data in the LXD container -def update_host_subuid(): - subuid_line1 = 'lxd:{}:1'.format(os.getuid()) - subuid_line2 = 'root:{}:1'.format(os.getuid()) - found_line1 = False - found_line2 = False - - with open('/etc/subuid') as ufile: - for line in ufile.readlines(): - if line.strip() == subuid_line1: - found_line1 = True - elif line.strip() == subuid_line2: - found_line2 = True - - if not found_line1: - Run.run('sudo sh -c "echo {} >> /etc/subuid"'.format( - subuid_line1), shell_bool=True) - if not found_line2: - Run.run('sudo sh -c "echo {} >> /etc/subuid"'.format( - subuid_line2), shell_bool=True) - - -# this function maps the container GID to the host GID. By doing -# this, we can write to a bind-mounted device - and thus generate -# code coverage data in the LXD container -def update_host_subgid(): - subgid_line1 = 'lxd:{}:1'.format(os.getgid()) - subgid_line2 = 'root:{}:1'.format(os.getgid()) - found_line1 = False - found_line2 = False - - with open('/etc/subgid') as ufile: - for line in ufile.readlines(): - if line.strip() == subgid_line1: - found_line1 = True - elif line.strip() == subgid_line2: - found_line2 = True - - if not found_line1: - Run.run('sudo sh -c "echo {} >> /etc/subgid"'.format( - subgid_line1), shell_bool=True) - if not found_line2: - Run.run('sudo sh -c "echo {} >> /etc/subgid"'.format( - subgid_line2), shell_bool=True) - - -def setup(config, do_teardown=True, record_time=False): - global setup_time - - start_time = time.time() - if do_teardown: - # belt and suspenders here. In case a previous run wasn't properly - # cleaned up, let's try and clean it up here - try: - teardown(config) - except Exception as e: - # log but ignore all exceptions - Log.log_debug(e) - - if config.args.container: - # this command initializes the lxd storage, networking, etc. - Run.run(['sudo', 'lxd', 'init', '--auto']) - update_host_subuid() - update_host_subgid() - - config.container.create() - config.container.config() - config.container.start() - - # add the libcgroup library to the container's ld - libcgrp_lib_path = os.path.join(consts.LIBCG_MOUNT_POINT, 'src/.libs') - echo_cmd = ([ - 'bash', - '-c', - 'echo {} >> /etc/ld.so.conf.d/libcgroup.conf' - ''.format(libcgrp_lib_path) - ]) - config.container.run(echo_cmd) - config.container.run('ldconfig') - - if record_time: - setup_time = time.time() - start_time - - -def run_tests(config): - passed_tests = [] - failed_tests = [] - skipped_tests = [] - filename_max = 0 - - for root, dirs, filenames in os.walk(config.ftest_dir): - for filename in filenames: - if os.path.splitext(filename)[-1] != ".py": - # ignore non-python files - continue - - filenum = filename.split('-')[0] - - try: - filenum_int = int(filenum) - except ValueError: - # D'oh. This file must not be a test. Skip it - Log.log_debug( - 'Skipping {}. It doesn\'t start with an int' - ''.format(filename) - ) - continue - - try: - filesuite = filename.split('-')[1] - except IndexError: - Log.log_error( - 'Skipping {}. It doesn\'t conform to the ' - 'filename format' - ''.format(filename) - ) - continue - - if config.args.suite == consts.TESTS_RUN_ALL_SUITES or \ - config.args.suite == filesuite: - if config.args.num == consts.TESTS_RUN_ALL or \ - config.args.num == filenum_int: - - if config.args.suite == consts.TESTS_RUN_ALL_SUITES and \ - filesuite == 'sudo': - # Don't run the 'sudo' tests if all tests have been specified. - # The sudo tests must be run as sudo and thus need to be separately - # invoked. - continue - - if filenum_int in config.skip_list: - continue - - if len(filename) > filename_max: - filename_max = len(filename) - - test = __import__(os.path.splitext(filename)[0]) - - failure_cause = None - start_time = time.time() - try: - Log.log_debug('Running test {}.'.format(filename)) - [ret, failure_cause] = test.main(config) - except Exception as e: - # catch all exceptions. you never know when there's - # a crummy test - failure_cause = e - Log.log_debug(e) - ret = consts.TEST_FAILED - finally: - run_time = time.time() - start_time - if ret == consts.TEST_PASSED: - passed_tests.append([filename, run_time]) - elif ret == consts.TEST_FAILED: - failed_tests.append([ - filename, - run_time, - failure_cause - ]) - elif ret == consts.TEST_SKIPPED: - skipped_tests.append([ - filename, - run_time, - failure_cause - ]) - else: - raise ValueError('Unexpected ret: {}'.format(ret)) - - passed_cnt = len(passed_tests) - failed_cnt = len(failed_tests) - skipped_cnt = len(skipped_tests) - - print("-----------------------------------------------------------------") - print("Test Results:") - date_str = datetime.datetime.now().strftime('%b %d %H:%M:%S') - print( - '\t{}{}'.format( - '{0: <35}'.format("Run Date:"), - '{0: >15}'.format(date_str) - ) - ) - - test_str = "{} test(s)".format(passed_cnt) - print( - '\t{}{}'.format( - '{0: <35}'.format("Passed:"), - '{0: >15}'.format(test_str) - ) - ) - - test_str = "{} test(s)".format(skipped_cnt) - print( - '\t{}{}'.format( - '{0: <35}'.format("Skipped:"), - '{0: >15}'.format(test_str) - ) - ) - - test_str = "{} test(s)".format(failed_cnt) - print( - '\t{}{}'.format( - '{0: <35}'.format("Failed:"), - '{0: >15}'.format(test_str) - ) - ) - - for test in failed_tests: - print( - "\t\tTest:\t\t\t\t{} - {}" - ''.format(test[0], str(test[2])) - ) - print("-----------------------------------------------------------------") - - global setup_time - global teardown_time - if config.args.verbose: - print("Timing Results:") - print( - '\t{}{}'.format( - '{0: <{1}}'.format("Test", filename_max), - '{0: >15}'.format("Time (sec)") - ) - ) - print( - # 15 is padding space of "Time (sec)" - '\t{}'.format('-' * (filename_max + 15)) - ) - time_str = "{0: 2.2f}".format(setup_time) - print( - '\t{}{}'.format( - '{0: <{1}}'.format('setup', filename_max), - '{0: >15}'.format(time_str) - ) - ) - - all_tests = passed_tests + skipped_tests + failed_tests - all_tests.sort() - for test in all_tests: - time_str = "{0: 2.2f}".format(test[1]) - print( - '\t{}{}'.format( - '{0: <{1}}'.format(test[0], - filename_max), - '{0: >15}'.format(time_str) - ) - ) - time_str = "{0: 2.2f}".format(teardown_time) - print( - '\t{}{}' - ''.format( - '{0: <{1}}'.format('teardown', filename_max), - '{0: >15}'.format(time_str) - ) - ) - - total_run_time = setup_time + teardown_time - for test in passed_tests: - total_run_time += test[1] - for test in failed_tests: - total_run_time += test[1] - total_str = "{0: 5.2f}".format(total_run_time) - print('\t{}'.format('-' * (filename_max + 15))) - print( - '\t{}{}' - ''.format( - '{0: <{1}}' - ''.format("Total Run Time", filename_max), - '{0: >15}'.format(total_str) - ) - ) - - return [passed_cnt, failed_cnt, skipped_cnt] - - -def teardown(config, record_time=False): - global teardown_time - start_time = time.time() - - config.process.join_children(config) - - if config.args.container: - try: - config.container.stop() - except Exception as e: - # log but ignore all exceptions - Log.log_debug(e) - try: - config.container.delete() - except Exception as e: - # log but ignore all exceptions - Log.log_debug(e) - - if record_time: - teardown_time = time.time() - start_time - - -def main(config): - AUTOMAKE_SKIPPED = 77 - AUTOMAKE_HARD_ERROR = 99 - AUTOMAKE_PASSED = 0 - - try: - setup(config, record_time=True) - [passed_cnt, failed_cnt, skipped_cnt] = run_tests(config) - finally: - teardown(config, record_time=True) - - if failed_cnt > 0: - return failed_cnt - if passed_cnt > 0: - return AUTOMAKE_PASSED - if skipped_cnt > 0: - return AUTOMAKE_SKIPPED - - return AUTOMAKE_HARD_ERROR - - -if __name__ == '__main__': - config = parse_args() - sys.exit(main(config)) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/log.py b/lib/libcgroup-3.1.0/tests/ftests/log.py deleted file mode 100644 index b1763c17ae0..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/log.py +++ /dev/null @@ -1,48 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Log class for the libcgroup functional tests -# -# Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. -# Author: Tom Hromatka -# - -import datetime -import consts - -log_level = consts.DEFAULT_LOG_LEVEL -log_file = consts.DEFAULT_LOG_FILE -log_fd = None - - -class Log(object): - - @staticmethod - def log(msg, msg_level=consts.DEFAULT_LOG_LEVEL): - global log_level, log_file, log_fd - - if log_level >= msg_level: - if log_fd is None: - Log.open_logfd(log_file) - - timestamp = datetime.datetime.now().strftime('%b %d %H:%M:%S') - log_fd.write('{}: {}\n'.format(timestamp, msg)) - - @staticmethod - def open_logfd(log_file): - global log_fd - - log_fd = open(log_file, 'a') - - @staticmethod - def log_critical(msg): - Log.log('CRITICAL: {}'.format(msg), consts.LOG_CRITICAL) - - @staticmethod - def log_warning(msg): - Log.log('WARNING: {}'.format(msg), consts.LOG_WARNING) - - @staticmethod - def log_debug(msg): - Log.log('DEBUG: {}'.format(msg), consts.LOG_DEBUG) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/process.py b/lib/libcgroup-3.1.0/tests/ftests/process.py deleted file mode 100644 index d03de98f0f1..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/process.py +++ /dev/null @@ -1,279 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Cgroup class for the libcgroup functional tests -# -# Copyright (c) 2020-2021 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from container import ContainerError -from cgroup import CgroupVersion -import multiprocessing as mp -from cgroup import Cgroup -from run import RunError -import threading as tp -from run import Run -import time - - -class Process(object): - def __init__(self): - self.children = list() - self.children_pids = list() - - def __str__(self): - out_str = 'Process Class\n' - out_str += '\tchildren = {}\n'.format(self.children) - out_str += '\tchildren_pids = {}\n'.format(self.children_pids) - - return out_str - - @staticmethod - def __thread_infinite_loop(config, sleep_time=1): - while 1: - time.sleep(sleep_time) - - @staticmethod - def __infinite_loop(config, sleep_time=1): - cmd = ["/usr/bin/perl", - "-e", - "'while(1){{sleep({})}};'".format(sleep_time) - ] - - try: - if config.args.container: - config.container.run(cmd, shell_bool=True) - else: - Run.run(cmd, shell_bool=True) - except RunError: - # when the process is killed, a RunError will be thrown. let's - # catch and suppress it - pass - - @staticmethod - def __cgexec_infinite_loop(config, controller, cgname, sleep_time=1, - ignore_systemd=False, replace_idle=False): - cmd = ["/usr/bin/perl", - "-e", - "'while(1){{sleep({})}};'".format(sleep_time) - ] - - try: - Cgroup.cgexec(config, controller, cgname, cmd, ignore_systemd=ignore_systemd, - replace_idle=replace_idle) - except RunError: - # When this process is killed, it will throw a run error. - # Ignore it. - pass - - def __save_child_pid(self, config, sleep_time): - # get the PID of the newly spawned infinite loop - cmd = ( - "ps x | grep perl | grep 'sleep({})' | awk '{{print $1}}'" - "".format(sleep_time) - ) - - if config.args.container: - pid = config.container.run(cmd, shell_bool=True) - else: - pid = Run.run(cmd, shell_bool=True) - - for _pid in pid.splitlines(): - self.children_pids.append(int(_pid)) - - if pid.find('\n') >= 0: - # The second pid in the list contains the actual perl process - pid = pid.splitlines()[1] - - if pid == '' or int(pid) <= 0: - raise ValueError( - 'Failed to get the pid of the child process:' - '{}' - ''.format(pid) - ) - - return int(pid) - - def create_process(self, config): - # To allow for multiple processes to be created, each new process - # sleeps for a different amount of time. This lets us uniquely find - # each process later in this function - sleep_time = len(self.children) + 1 - - p = mp.Process(target=Process.__infinite_loop, - args=(config, sleep_time, )) - p.start() - - # wait for the process to start. If we don't wait, then the getpid - # logic below may not find the process - time.sleep(2) - - pid = self.__save_child_pid(config, sleep_time) - self.children.append(p) - - return pid - - # Create a simple process in the requested cgroup - def create_process_in_cgroup(self, config, controller, cgname, - cgclassify=True, ignore_systemd=False, replace_idle=False): - if cgclassify: - child_pid = self.create_process(config) - Cgroup.classify(config, controller, cgname, child_pid, - ignore_systemd=ignore_systemd, replace_idle=replace_idle) - else: - # use cgexec - - # To allow for multiple processes to be created, each new process - # sleeps for a different amount of time. This lets us uniquely - # find each process later in this function - sleep_time = len(self.children) + 1 - - p = mp.Process(target=Process.__cgexec_infinite_loop, - args=(config, controller, cgname, sleep_time, ignore_systemd, - replace_idle, )) - p.start() - - self.children.append(p) - - def create_threaded_process(self, config, threads_cnt): - threads = list() - - for n in range(threads_cnt): - sleep_time = n + 1 - thread = tp.Thread(target=Process.__thread_infinite_loop, - args=(config, sleep_time, )) - threads.append(thread) - - for thread in threads: - thread.start() - - def create_threaded_process_in_cgroup(self, config, controller, cgname, - threads=2, cgclassify=True, ignore_systemd=False, - replace_idle=False): - - p = mp.Process(target=self.create_threaded_process, - args=(config, threads, )) - p.start() - - if cgclassify: - Cgroup.classify(config, controller, cgname, p.pid, - ignore_systemd=ignore_systemd, replace_idle=replace_idle) - - self.children.append(p) - self.children_pids.append(p.pid) - - return p.pid - - # The caller will block until all children are stopped. - def join_children(self, config): - for child in self.children: - child.join(1) - - for child in self.children_pids: - try: - if config.args.container: - config.container.run(['kill', str(child)]) - else: - Run.run(['kill', str(child)]) - except (RunError, ContainerError): - # ignore any errors during the kill command. this is belt - # and suspenders code - pass - - @staticmethod - def __get_cgroup_v1(config, pid, controller): - cmd = list() - - cmd.append('cat') - cmd.append('/proc/{}/cgroup'.format(pid)) - - if config.args.container: - ret = config.container.run(cmd) - else: - ret = Run.run(cmd) - - for line in ret.splitlines(): - # cgroup v1 appears in /proc/{pid}/cgroup like the following: - # $ cat /proc/1/cgroup - # 12:memory:/ - # 11:hugetlb:/ - # 10:perf_event:/ - # 9:rdma:/ - # 8:devices:/ - # 7:cpuset:/ - # 6:blkio:/ - # 5:cpu,cpuacct:/ - # 4:pids:/ - # 3:freezer:/ - # 2:net_cls,net_prio:/ - # 1:name=systemd:/init.scope - # 0::/init.scope - proc_controllers = line.split(':')[1] - if proc_controllers.find(',') >= 0: - for proc_controller in proc_controllers.split(','): - if controller == proc_controller: - return line.split(':')[2] - else: - if controller == proc_controllers: - return line.split(':')[2] - - raise ValueError('Could not get cgroup for pid {} and controller {}'. - format(pid, controller)) - - @staticmethod - def __get_cgroup_v2(config, pid, controller): - cmd = list() - - cmd.append('cat') - cmd.append('/proc/{}/cgroup'.format(pid)) - - if config.args.container: - ret = config.container.run(cmd) - else: - ret = Run.run(cmd) - - for line in ret.splitlines(): - # cgroup v2 appears in /proc/{pid}/cgroup like the following: - # $ cat /proc/1/cgroup - # 0::/init.scope - if line.find('::') < 0: - # we have identified this controller is cgroup v2, - # ignore any cgroup v1 controllers - continue - - return line.split(':')[2] - - raise ValueError( - 'Could not get cgroup for pid {} and controller {}' - ''.format(pid, controller) - ) - - # given a PID and a cgroup controller, what cgroup is this PID a member of - @staticmethod - def get_cgroup(config, pid, controller): - version = CgroupVersion.get_version(controller) - - if version == CgroupVersion.CGROUP_V1: - return Process.__get_cgroup_v1(config, pid, controller) - elif version == CgroupVersion.CGROUP_V2: - return Process.__get_cgroup_v2(config, pid, controller) - - raise ValueError("get_cgroup() shouldn't reach this point") - - @staticmethod - def kill(config, pids): - if not pids: - return - - if type(pids) == str: - pids = [int(pid) for pid in pids.splitlines()] - elif type(pids) == int: - pids = [pids] - - for pid in pids: - if config.args.container: - config.container.run(['kill', '-9', str(pid)]) - else: - Run.run(['kill', '-9', str(pid)]) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/run.py b/lib/libcgroup-3.1.0/tests/ftests/run.py deleted file mode 100644 index c985162d00d..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/run.py +++ /dev/null @@ -1,119 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Run class for the libcgroup functional tests -# -# Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. -# Author: Tom Hromatka -# - -from subprocess import TimeoutExpired -from log import Log -import subprocess -import time - - -class Run(object): - @staticmethod - def __run(command, shell_bool, timeout): - if shell_bool: - if isinstance(command, str): - # nothing to do. command is already formatted as a string - pass - elif isinstance(command, list): - command = ' '.join(command) - else: - raise ValueError('Unsupported command type') - - subproc = subprocess.Popen(command, shell=shell_bool, - stdout=subprocess.PIPE, - stderr=subprocess.PIPE) - - if timeout: - try: - out, err = subproc.communicate(timeout=timeout) - ret = subproc.returncode - - out = out.strip().decode('UTF-8') - err = err.strip().decode('UTF-8') - except TimeoutExpired as te: - if te.stdout: - out = te.stdout.strip().decode('UTF-8') - else: - out = '' - if te.stderr: - err = te.stderr.strip().decode('UTF-8') - else: - err = '' - - if len(err): - ret = -1 - else: - ret = 0 - else: - out, err = subproc.communicate() - ret = subproc.returncode - - out = out.strip().decode('UTF-8') - err = err.strip().decode('UTF-8') - - if shell_bool: - Log.log_debug( - 'run:\n\tcommand = {}\n\tret = {}\n\tstdout = {}' - '\n\tstderr = {}' - ''.format(command, ret, out, err) - ) - else: - Log.log_debug( - 'run:\n\tcommand = {}\n\tret = {}\n\tstdout = {}' - '\n\tstderr = {}' - ''.format(' '.join(command), ret, out, err) - ) - - return ret, out, err - - @staticmethod - def run(command, shell_bool=False, ignore_profiling_errors=True, timeout=None): - ret, out, err = Run.__run(command, shell_bool, timeout) - - if err.find('Error: websocket: bad handshake') >= 0: - # LXD sometimes throws this error on underpowered machines. - # Wait a bit, then try the request again - Log.log_error('Received \'{}\' error. Re-running command'.format(err)) - time.sleep(5) - ret, out, err = Run.__run(command, shell_bool, timeout) - - if ret != 0: - raise RunError("Command '{}' failed".format(''.join(command)), - command, ret, out, err) - if ret != 0 or len(err) > 0: - if err.find('WARNING: cgroup v2 is not fully supported yet') >= 0: - # LXD throws the above warning on systems that are fully - # running cgroup v2. Ignore this warning, but fail if any - # other warnings/errors are raised - pass - elif ignore_profiling_errors and err.find('profiling') >= 0: - pass - else: - raise RunError("Command '{}' failed".format(''.join(command)), - command, ret, out, err) - - return out - - -class RunError(Exception): - def __init__(self, message, command, ret, stdout, stderr): - super(RunError, self).__init__(message) - - self.command = command - self.ret = ret - self.stdout = stdout - self.stderr = stderr - - def __str__(self): - out_str = 'RunError:\n\tcommand = {}\n\tret = {}'.format( - self.command, self.ret) - out_str += '\n\tstdout = {}\n\tstderr = {}'.format(self.stdout, - self.stderr) - return out_str - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/ftests/systemd.py b/lib/libcgroup-3.1.0/tests/ftests/systemd.py deleted file mode 100644 index 826f3c4032c..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/systemd.py +++ /dev/null @@ -1,76 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Systemd class for the libcgroup functional tests -# -# Copyright (c) 2022 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from run import Run, RunError -from cgroup import Cgroup -import os - - -class Systemd(object): - @staticmethod - def is_delegated(config, scope_name): - cmd = ['systemctl', 'show', '-P', 'Delegate', scope_name] - try: - out = Run.run(cmd, shell_bool=True) - - if out == 'yes': - return True - else: - return False - except RunError as re: - if re.stderr.find('invalid option') >= 0: - # This version of systemd is too old for the '-P' flag. At this time, I don't - # think there's a way to verify the scope is delegated. Lie and return true - # until we figure out something better :( - return True - raise re - - # This function creates a task and writes its pid into systemd - # configuration file, that gets passed to the cgconfigparser tool to - # create systemd slice/scope. - @staticmethod - def write_config_with_pid(config, config_fname, _slice, scope, setdefault="yes"): - pid = config.process.create_process(config) - config_file = '''systemd {{ - slice = {}; - scope = {}; - setdefault = {}; - pid = {}; - }}'''.format(_slice, scope, setdefault, pid) - - f = open(config_fname, 'w') - f.write(config_file) - f.close() - - return pid - - # Stopping the systemd scope, will kill the default task in the scope - # and remove scope cgroup but will not remove the slice, that needs to - # removed manually. - @staticmethod - def remove_scope_slice_conf(config, _slice, scope, controller, config_fname=None): - if config_fname: - os.remove(config_fname) - - try: - if config.args.container: - config.container.run(['systemctl', 'stop', '{}'.format(scope)], - shell_bool=True) - else: - Run.run(['sudo', 'systemctl', 'stop', '{}'.format(scope)], shell_bool=True) - except RunError as re: - if 'scope not loaded' in re.stderr: - raise re - - # In case the error occurs before the creation of slice/scope and - # we may very well be on the teardown path, ignore the exception - try: - Cgroup.delete(config, controller, cgname=_slice, ignore_systemd=True) - except RunError as re: - if 'No such file or directory' not in re.stderr: - raise re diff --git a/lib/libcgroup-3.1.0/tests/ftests/utils.py b/lib/libcgroup-3.1.0/tests/ftests/utils.py deleted file mode 100644 index a0fb6ee4293..00000000000 --- a/lib/libcgroup-3.1.0/tests/ftests/utils.py +++ /dev/null @@ -1,82 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# Utility functions for the libcgroup functional tests -# -# Copyright (c) 2020 Oracle and/or its affiliates. -# Author: Tom Hromatka -# - -from run import Run - - -# function to indent a block of text by cnt number of spaces -def indent(in_str, cnt): - leading_indent = cnt * ' ' - return ''.join(leading_indent + line for line in in_str.splitlines(True)) - - -def get_file_owner_uid(config, filename): - cmd = list() - cmd.append('stat') - cmd.append('-c') - cmd.append("'%u'") - cmd.append(filename) - - if config.args.container: - return int(config.container.run(cmd, shell_bool=True)) - else: - return int(Run.run(cmd, shell_bool=True)) - - -def get_file_owner_username(config, filename): - cmd = list() - cmd.append('stat') - cmd.append('-c') - cmd.append("'%U'") - cmd.append(filename) - - if config.args.container: - return config.container.run(cmd, shell_bool=True) - else: - return Run.run(cmd, shell_bool=True) - - -def get_file_owner_gid(config, filename): - cmd = list() - cmd.append('stat') - cmd.append('-c') - cmd.append("'%g'") - cmd.append(filename) - - if config.args.container: - return int(config.container.run(cmd, shell_bool=True)) - else: - return int(Run.run(cmd, shell_bool=True)) - - -def get_file_owner_group_name(config, filename): - cmd = list() - cmd.append('stat') - cmd.append('-c') - cmd.append("'%G'") - cmd.append(filename) - - if config.args.container: - return config.container.run(cmd, shell_bool=True) - else: - return Run.run(cmd, shell_bool=True) - - -def get_file_permissions(config, filename): - cmd = list() - cmd.append('stat') - cmd.append('-c') - cmd.append("'%a'") - cmd.append(filename) - - if config.args.container: - return config.container.run(cmd, shell_bool=True) - else: - return Run.run(cmd, shell_bool=True) - -# vim: set et ts=4 sw=4: diff --git a/lib/libcgroup-3.1.0/tests/gunit/001-path.cpp b/lib/libcgroup-3.1.0/tests/gunit/001-path.cpp deleted file mode 100644 index 5bf853244f3..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/001-path.cpp +++ /dev/null @@ -1,164 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cg_build_path() - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class BuildPathV1Test : public ::testing::Test { - protected: - - /** - * Setup this test case - * - * This test case calls cg_build_path() to generate various - * cgroup paths. The SetUp() routine creates a simple mount - * table that can be used to verify cg_build_path() behavior. - * - * cg_mount_table for this test is as follows: - * name mount_point index - * ----------------------------------------------------- - * controller0 /sys/fs/cgroup/controller0 0 - * controller1 /sys/fs/cgroup/controller1 1 - * controller2 /sys/fs/cgroup/controller2 2 - * controller3 /sys/fs/cgroup/controller3 3 - * controller4 /sys/fs/cgroup/controller4 4 - * controller5 /sys/fs/cgroup/controller5 5 - * - * Note that controllers 1 and 5 are also given namespaces - */ - void SetUp() override { - char NAMESPACE1[] = "ns1"; - char NAMESPACE5[] = "ns5"; - const int ENTRY_CNT = 6; - int i, ret; - - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(cg_namespace_table, 0, - CG_CONTROLLER_MAX * sizeof(cg_namespace_table[0])); - - // Populate the mount table - for (i = 0; i < ENTRY_CNT; i++) { - snprintf(cg_mount_table[i].name, CONTROL_NAMELEN_MAX, - "controller%d", i); - cg_mount_table[i].index = i; - - ret = snprintf(cg_mount_table[i].mount.path, FILENAME_MAX, - "/sys/fs/cgroup/%s", cg_mount_table[i].name); - ASSERT_LT(ret, sizeof(cg_mount_table[i].mount.path)); - - cg_mount_table[i].mount.next = NULL; - } - - // Give a couple of the entries a namespace as well - cg_namespace_table[1] = NAMESPACE1; - cg_namespace_table[5] = NAMESPACE5; - } -}; - -/** - * No matching controller test - * @param BuildPathV1Test googletest test case name - * @param BuildPathV1_ControllerMismatch test name - * - * This test will walk through the entire controller mount table - * and fail to find a match. - * https://github.com/libcgroup/libcgroup/blob/62f76650db84c0a25f76ece3a79d9d16a1e9f931/src/api.c#L1300 - */ -TEST_F(BuildPathV1Test, BuildPathV1_ControllerMismatch) -{ - char *name = NULL; - char path[FILENAME_MAX]; - /* type intentionally _does not_ match any controllers */ - char type[] = "FOO"; - char *out; - - out = cg_build_path(name, path, type); - ASSERT_STREQ(out, NULL); -} - -/** - * Matching controller test - * @param BuildPathV1Test googletest test case name - * @param BuildPathV1_ControllerMatch test name - * - * This test finds a matching controller in the mount table. Both the - * namespace and the cgroup name are NULL. - */ -TEST_F(BuildPathV1Test, BuildPathV1_ControllerMatch) -{ - char *name = NULL; - char path[FILENAME_MAX]; - char type[] = "controller0"; - char *out; - - out = cg_build_path(name, path, type); - ASSERT_STREQ(out, "/sys/fs/cgroup/controller0/"); -} - -/** - * Matching controller test with a cgroup name - * @param BuildPathV1Test googletest test case name - * @param BuildPathV1_ControllerMatchWithName test name - * - * This test finds a matching controller in the mount table. The - * namespace is NULL, but a valid cgroup name is provided. This - * exercises the `if (name)` statement - * https://github.com/libcgroup/libcgroup/blob/62f76650db84c0a25f76ece3a79d9d16a1e9f931/src/api.c#L1289 - */ -TEST_F(BuildPathV1Test, BuildPathV1_ControllerMatchWithName) -{ - char name[] = "TomsCgroup1"; - char path[FILENAME_MAX]; - char type[] = "controller3"; - char *out; - - out = cg_build_path(name, path, type); - ASSERT_STREQ(out, "/sys/fs/cgroup/controller3/TomsCgroup1/"); -} - -/** - * Matching controller test with a namespace - * @param BuildPathV1Test googletest test case name - * @param BuildPathV1_ControllerMatchWithNs test name - * - * This test finds a matching controller in the mount table. The - * namespace is valid, but the cgroup name is NULL. This exercises - * exercises the `if (cg_namespace_table[i])` statement - * https://github.com/libcgroup/libcgroup/blob/62f76650db84c0a25f76ece3a79d9d16a1e9f931/src/api.c#L1278 - */ -TEST_F(BuildPathV1Test, BuildPathV1_ControllerMatchWithNs) -{ - char *name = NULL; - char path[FILENAME_MAX]; - char type[] = "controller1"; - char *out; - - out = cg_build_path(name, path, type); - ASSERT_STREQ(out, "/sys/fs/cgroup/controller1/ns1/"); -} - -/** - * Matching controller test with a namespace and a cgroup name - * @param BuildPathV1Test googletest test case name - * @param BuildPathV1_ControllerMatchWithNameAndNs test name - * - * This test finds a matching controller in the mount table. Both the - * namespace and the cgroup name are valid. This exercises both if - * statements in cg_build_path_locked(). - */ -TEST_F(BuildPathV1Test, BuildPathV1_ControllerMatchWithNameAndNs) -{ - char name[] = "TomsCgroup2"; - char path[FILENAME_MAX]; - char type[] = "controller5"; - char *out; - - out = cg_build_path(name, path, type); - ASSERT_STREQ(out, "/sys/fs/cgroup/controller5/ns5/TomsCgroup2/"); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/002-cgroup_parse_rules_options.cpp b/lib/libcgroup-3.1.0/tests/gunit/002-cgroup_parse_rules_options.cpp deleted file mode 100644 index 63d3c6263e0..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/002-cgroup_parse_rules_options.cpp +++ /dev/null @@ -1,92 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_parse_rules_options() - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class ParseRulesOptionsTest : public ::testing::Test { -}; - -TEST_F(ParseRulesOptionsTest, RulesOptions_Ignore) -{ - struct cgroup_rule rule; - char options[] = "ignore"; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, 0); - ASSERT_EQ(rule.is_ignore, true); -} - -TEST_F(ParseRulesOptionsTest, RulesOptions_IgnoreWithComma) -{ - struct cgroup_rule rule; - char options[] = "ignore,"; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, 0); - ASSERT_EQ(rule.is_ignore, true); -} - -TEST_F(ParseRulesOptionsTest, RulesOptions_InvalidOption) -{ - struct cgroup_rule rule; - char options[] = "ignoretypo"; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, -EINVAL); - ASSERT_EQ(rule.is_ignore, false); -} - -TEST_F(ParseRulesOptionsTest, RulesOptions_InvalidOption2) -{ - struct cgroup_rule rule; - char options[] = "ignore,foobar"; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, -EINVAL); - ASSERT_EQ(rule.is_ignore, true); -} - -TEST_F(ParseRulesOptionsTest, RulesOptions_EmptyOptions) -{ - struct cgroup_rule rule; - char options[] = ""; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, -EINVAL); - ASSERT_EQ(rule.is_ignore, false); -} - -TEST_F(ParseRulesOptionsTest, RulesOptions_NullOptions) -{ - struct cgroup_rule rule; - char *options = NULL; - int ret; - - rule.is_ignore = false; - - ret = cgroup_parse_rules_options(options, &rule); - ASSERT_EQ(ret, -EINVAL); - ASSERT_EQ(rule.is_ignore, false); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/003-cg_get_cgroups_from_proc_cgroups.cpp b/lib/libcgroup-3.1.0/tests/gunit/003-cg_get_cgroups_from_proc_cgroups.cpp deleted file mode 100644 index e03139f2048..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/003-cg_get_cgroups_from_proc_cgroups.cpp +++ /dev/null @@ -1,162 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cg_get_cgroups_from_proc_cgroups() - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class GetCgroupsFromProcCgroupsTest : public ::testing::Test { -}; - -static void CreateCgroupProcFile(const char * const contents) -{ - FILE *f; - - f = fopen(TEST_PROC_PID_CGROUP_FILE, "w"); - ASSERT_NE(f, nullptr); - - fprintf(f, "%s", contents); - fclose(f); -} - - -TEST_F(GetCgroupsFromProcCgroupsTest, ReadSingleLine) -{ -#undef LIST_LEN -#define LIST_LEN 3 - char contents[] = - "5:pids:/user.slice/user-1000.slice/session-1.scope\n"; - char *controller_list[LIST_LEN]; - char *cgroup_list[LIST_LEN]; - pid_t pid = 1234; - int ret, i; - - for (i = 0; i < LIST_LEN; i++) { - controller_list[i] = NULL; - cgroup_list[i] = NULL; - } - - CreateCgroupProcFile(contents); - - ret = cg_get_cgroups_from_proc_cgroups(pid, cgroup_list, - controller_list, LIST_LEN); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(controller_list[0], "pids"); - ASSERT_STREQ(cgroup_list[0], - "user.slice/user-1000.slice/session-1.scope"); -} - -TEST_F(GetCgroupsFromProcCgroupsTest, ReadSingleLine2) -{ -#undef LIST_LEN -#define LIST_LEN 1 - char contents[] = - "5:cpu,cpuacct:/\n"; - char *controller_list[LIST_LEN]; - char *cgroup_list[LIST_LEN]; - pid_t pid = 1234; - int ret, i; - - for (i = 0; i < LIST_LEN; i++) { - controller_list[i] = NULL; - cgroup_list[i] = NULL; - } - - CreateCgroupProcFile(contents); - - ret = cg_get_cgroups_from_proc_cgroups(pid, cgroup_list, - controller_list, LIST_LEN); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(controller_list[0], "cpu,cpuacct"); - ASSERT_STREQ(cgroup_list[0], "/"); -} - -TEST_F(GetCgroupsFromProcCgroupsTest, ReadEmptyController) -{ -#undef LIST_LEN -#define LIST_LEN 1 - char contents[] = - "0::/user.slice/user-1000.slice/session-1.scope\n"; - char *controller_list[LIST_LEN]; - char *cgroup_list[LIST_LEN]; - pid_t pid = 1234; - int ret, i; - - for (i = 0; i < LIST_LEN; i++) { - controller_list[i] = NULL; - cgroup_list[i] = NULL; - } - - CreateCgroupProcFile(contents); - - ret = cg_get_cgroups_from_proc_cgroups(pid, cgroup_list, - controller_list, LIST_LEN); - ASSERT_EQ(ret, 0); - ASSERT_EQ(controller_list[0], nullptr); - ASSERT_EQ(cgroup_list[0], nullptr); -} - -TEST_F(GetCgroupsFromProcCgroupsTest, ReadExampleFile) -{ - char contents[] = - "12:memory:/user/johndoe/0\n" - "11:perf_event:/\n" - "10:rdma:/\n" - "9:blkio:/user.slice\n" - "8:cpu,cpuacct:/myCgroup\n" - "7:freezer:/user/johndoe/0\n" - "6:net_cls,net_prio:/\n" - "5:pids:/user.slice/user-1000.slice/session-1.scope\n" - "4:devices:/user.slice\n" - "3:cpuset:/\n" - "2:hugetlb:/\n" - "1:name=systemd:/user.slice/user-1000.slice/session-1.scope\n" - "0::/user.slice/user-1000.slice/session-1.scope\n"; - char *controller_list[MAX_MNT_ELEMENTS]; - char *cgroup_list[MAX_MNT_ELEMENTS]; - pid_t pid = 5678; - int ret, i; - - for (i = 0; i < MAX_MNT_ELEMENTS; i++) { - controller_list[i] = NULL; - cgroup_list[i] = NULL; - } - - CreateCgroupProcFile(contents); - - ret = cg_get_cgroups_from_proc_cgroups(pid, cgroup_list, - controller_list, MAX_MNT_ELEMENTS); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(controller_list[0], "memory"); - ASSERT_STREQ(cgroup_list[0], "user/johndoe/0"); - ASSERT_STREQ(controller_list[1], "perf_event"); - ASSERT_STREQ(cgroup_list[1], "/"); - ASSERT_STREQ(controller_list[2], "rdma"); - ASSERT_STREQ(cgroup_list[2], "/"); - ASSERT_STREQ(controller_list[3], "blkio"); - ASSERT_STREQ(cgroup_list[3], "user.slice"); - ASSERT_STREQ(controller_list[4], "cpu,cpuacct"); - ASSERT_STREQ(cgroup_list[4], "myCgroup"); - ASSERT_STREQ(controller_list[5], "freezer"); - ASSERT_STREQ(cgroup_list[5], "user/johndoe/0"); - ASSERT_STREQ(controller_list[6], "net_cls,net_prio"); - ASSERT_STREQ(cgroup_list[6], "/"); - ASSERT_STREQ(controller_list[7], "pids"); - ASSERT_STREQ(cgroup_list[7], "user.slice/user-1000.slice/session-1.scope"); - ASSERT_STREQ(controller_list[8], "devices"); - ASSERT_STREQ(cgroup_list[8], "user.slice"); - ASSERT_STREQ(controller_list[9], "cpuset"); - ASSERT_STREQ(cgroup_list[9], "/"); - ASSERT_STREQ(controller_list[10], "hugetlb"); - ASSERT_STREQ(cgroup_list[10], "/"); - ASSERT_STREQ(controller_list[11], "name=systemd"); - ASSERT_STREQ(cgroup_list[11], "user.slice/user-1000.slice/session-1.scope"); - - ASSERT_EQ(controller_list[12], nullptr); - ASSERT_EQ(cgroup_list[12], nullptr); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/004-cgroup_compare_ignore_rule.cpp b/lib/libcgroup-3.1.0/tests/gunit/004-cgroup_compare_ignore_rule.cpp deleted file mode 100644 index 13d6f481f86..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/004-cgroup_compare_ignore_rule.cpp +++ /dev/null @@ -1,371 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_compare_ignore_rule() - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class CgroupCompareIgnoreRuleTest : public ::testing::Test { -}; - -static void CreateCgroupProcFile(const char * const contents) -{ - FILE *f; - - f = fopen(TEST_PROC_PID_CGROUP_FILE, "w"); - ASSERT_NE(f, nullptr); - - fprintf(f, "%s", contents); - fclose(f); -} - -TEST_F(CgroupCompareIgnoreRuleTest, NotAnIgnore) -{ - char procname[] = "myprocess"; - struct cgroup_rule rule; - pid_t pid = 1234; - bool ret; - - rule.is_ignore = false; - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, SimpleMatch) -{ - char proc_file_contents[] = - "7:cpuacct:/SimpleMatchCgroup"; - char rule_controller[] = "cpuacct"; - char procname[] = "procfoo"; - struct cgroup_rule rule; - pid_t pid = 2345; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = NULL; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "SimpleMatchCgroup"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, CgroupsDontMatch) -{ - char proc_file_contents[] = - "2:cpuacct:CloseButNotQuite"; - char rule_controller[] = "cpuacct"; - char procname[] = "procfoo2"; - struct cgroup_rule rule; - pid_t pid = 4567; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "CloseButNotQuit"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, ControllersDontMatch) -{ - char proc_file_contents[] = - "5:memory:MyCgroup"; - char rule_controller[] = "cpuacct"; - char procname[] = "procfoo3"; - struct cgroup_rule rule; - pid_t pid = 5678; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "MyCgroup"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, CombinedControllers) -{ - char proc_file_contents[] = - "13:cpu,cpuacct:/containercg"; - char rule_controller[] = "cpuacct"; - char procname[] = "docker"; - struct cgroup_rule rule = {0}; - pid_t pid = 6789; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - rule.controllers[1] = NULL; - sprintf(rule.destination, "containercg"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, MatchChildFolder) -{ - char proc_file_contents[] = - "7:cpuset:/parentcg/childcg/grandchildcg"; - char rule_controller[] = "cpuset"; - char procname[] = "childprocess"; - struct cgroup_rule rule; - pid_t pid = 7890; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "parentcg/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, MatchGrandchildFolder) -{ - char proc_file_contents[] = - "1:hugetlb:/parentcg/childcg/grandchildcg"; - char rule_controller[] = "hugetlb"; - char procname[] = "granchildprocess"; - struct cgroup_rule rule; - pid_t pid = 8901; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = NULL; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "parentcg/childcg/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -/** - * This test is designed to highlight the case where the user has not put a - * trailing slash at the end of the rule's destination. By design, this will - * cause the rule to match a wide variety of cases. - * - * For example, given the rule destination of "Folder". The following - * behavior would be observed: - * Process Location Matches the rule? - * Folder Yes - * Folders Yes - * Folder/AnotherFolder Yes - * Folder2 Yes - * Folder3/ChildFolder Yes - * Folde No - */ -TEST_F(CgroupCompareIgnoreRuleTest, MatchSimilarChildFolder) -{ - char proc_file_contents[] = - "1:hugetlb:/parentcg/childcg2"; - char rule_controller[] = "hugetlb"; - char procname[] = "granchildprocess"; - struct cgroup_rule rule; - pid_t pid = 8901; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = NULL; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "parentcg/childcg"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, RealWorldMatch) -{ - char proc_file_contents[] = - "12:memory:/user/johndoe/0\n" - "11:perf_event:/\n" - "10:rdma:/\n" - "9:blkio:/user.slice\n" - "8:cpu,cpuacct:/myCgroup\n" - "7:freezer:/user/johndoe/0\n" - "6:net_cls,net_prio:/\n" - "5:pids:/user.slice/user-1000.slice/session-1.scope\n" - "4:devices:/user.slice\n" - "3:cpuset:/\n" - "2:hugetlb:/\n" - "1:name=systemd:/user.slice/user-1000.slice/session-1.scope\n" - "0::/user.slice/user-1000.slice/session-1.scope\n"; - char rule_controller[] = "cpu"; - char procname[] = "granchildprocess"; - struct cgroup_rule rule; - pid_t pid = 8901; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = NULL; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "myCgroup/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, RealWorldNoMatch) -{ - char proc_file_contents[] = - "12:memory:/user/johndoe/0\n" - "11:perf_event:/\n" - "10:rdma:/\n" - "9:blkio:/user.slice\n" - "8:cpu,cpuacct:/myCgroup\n" - "7:freezer:/user/johndoe/0\n" - "6:net_cls,net_prio:/NetCgroup\n" - "5:pids:/user.slice/user-1000.slice/session-1.scope\n" - "4:devices:/user.slice\n" - "3:cpuset:/\n" - "2:hugetlb:/\n" - "1:name=systemd:/user.slice/user-1000.slice/session-1.scope\n" - "0::/user.slice/user-1000.slice/session-1.scope\n"; - char rule_controller[] = "net_cls"; - char procname[] = "NotMatching"; - struct cgroup_rule rule; - pid_t pid = 9012; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = NULL; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "NetCgroup2"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, SimilarFolderNoMatch) -{ - char proc_file_contents[] = - "4:memory:/folder1"; - char rule_controller[] = "memory"; - char procname[] = "childprocess"; - struct cgroup_rule rule; - pid_t pid = 2345; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "folder/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, RootDestinationMatch) -{ - char proc_file_contents[] = - "2:freezer:/"; - char rule_controller[] = "freezer"; - char procname[] = "ANewProcess"; - struct cgroup_rule rule; - pid_t pid = 3456; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, RootDestinationNoMatch) -{ - char proc_file_contents[] = - "2:freezer:/somerandomcg"; - char rule_controller[] = "freezer"; - char procname[] = "ANewProcess"; - struct cgroup_rule rule; - pid_t pid = 3456; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "/"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(CgroupCompareIgnoreRuleTest, WildcardProcnameSimpleMatch) -{ - char proc_file_contents[] = - "7:cpuacct:/MatchCgroup"; - char rule_controller[] = "cpuacct"; - char rule_procname[] = "ssh*"; - char procname[] = "sshd"; - struct cgroup_rule rule; - pid_t pid = 1234; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = rule_procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "MatchCgroup"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(CgroupCompareIgnoreRuleTest, WildcardProcnameNoMatch) -{ - char proc_file_contents[] = - "7:cpuacct:/AnotherCgroup"; - char rule_controller[] = "cpuacct"; - char rule_procname[] = "httpd*"; - char procname[] = "httpx"; - struct cgroup_rule rule; - pid_t pid = 1234; - bool ret; - - CreateCgroupProcFile(proc_file_contents); - - rule.procname = rule_procname; - rule.is_ignore = true; - rule.controllers[0] = rule_controller; - sprintf(rule.destination, "AnotherCgroup"); - - ret = cgroup_compare_ignore_rule(&rule, pid, procname); - ASSERT_EQ(ret, false); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/005-cgroup_compare_wildcard_procname.cpp b/lib/libcgroup-3.1.0/tests/gunit/005-cgroup_compare_wildcard_procname.cpp deleted file mode 100644 index cea19eabe21..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/005-cgroup_compare_wildcard_procname.cpp +++ /dev/null @@ -1,84 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_compare_wildcard_procname() - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class ProcnameWildcardTest : public ::testing::Test { -}; - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_NoAsterisk) -{ - char rule_procname[] = "systemd"; - char procname[] = "bash"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_AsteriskNoMatch) -{ - char rule_procname[] = "BobIsYour*"; - char procname[] = "Linda"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_AsteriskMatch) -{ - char rule_procname[] = "HelloWorl*"; - char procname[] = "HelloWorld"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_AsteriskNoMatch2) -{ - char rule_procname[] = "HelloW*"; - char procname[] = "Hello"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_AsteriskMatchExactly) -{ - char rule_procname[] = "strace*"; - char procname[] = "strace"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, true); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_NoAsteriskMatchExactly) -{ - char rule_procname[] = "systemd-cgls"; - char procname[] = "systemd-cgls"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, false); -} - -TEST_F(ProcnameWildcardTest, ProcnameWildcard_AsteriskFirstChar) -{ - char rule_procname[] = "*"; - char procname[] = "tomcat"; - bool ret; - - ret = cgroup_compare_wildcard_procname(rule_procname, procname); - ASSERT_EQ(ret, true); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/006-cgroup_get_cgroup.cpp b/lib/libcgroup-3.1.0/tests/gunit/006-cgroup_get_cgroup.cpp deleted file mode 100644 index e2f43f97c8b..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/006-cgroup_get_cgroup.cpp +++ /dev/null @@ -1,259 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_get_cgroup() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include -#include -#include -using namespace std; - -#include - -#include "gtest/gtest.h" -#include "libcgroup-internal.h" - -#define MAX_NAMES 5 - -enum ctrl_enum { - CTRL_CPU, - CTRL_FREEZER, - CTRL_MEMORY, - CTRL_CPUSET, - CTRL_NAMESPACES, - CTRL_NETNS, - - CTRL_CNT -}; - -static const char * const PARENT_DIR = "test006cgroup"; - -static const char * const CONTROLLERS[] = { - "cpu", - "freezer", - "memory", - "cpuset", - "namespaces", - "netns", -}; -static const int CONTROLLERS_CNT = - sizeof(CONTROLLERS) / sizeof(CONTROLLERS[0]); - -static const char * const NAMES[][MAX_NAMES] = { - {"tasks", "cpu.shares", "cpu.weight", "cpu.foo", NULL}, - {"tasks", NULL, NULL, NULL, NULL}, - {"tasks", "memory.limit_in_bytes", "memory.memsw.limit_in_bytes", NULL, NULL}, - {"tasks", "cpuset.exclusive", "cpuset.foo", "cpuset.bar", "cpuset.x"}, - {"tasks", "namespaces.blah", NULL, NULL, NULL}, - {"tasks", "netns.foo", "netns.bar", "netns.baz", NULL}, -}; -static const int NAMES_CNT = sizeof(NAMES) / sizeof(NAMES[0]); - -static const char * const VALUES[][MAX_NAMES] = { - {"1234", "512", "100", "abc123", NULL}, - {"2345\n3456", NULL, NULL, NULL, NULL}, - {"456\n678\n890", "8675309", "1024000", NULL, NULL}, - {"\0", "1", "limit=32412039", "9223372036854771712", "partition"}, - {"59832", "The Quick Brown Fox", NULL, NULL, NULL}, - {"987\n654", "root", "/sys/fs", "0xdeadbeef", NULL}, -}; -static const int VALUES_CNT = sizeof(VALUES) / sizeof(VALUES[0]); - -static const char * const CG_NAME = "tomcatcg"; -static const mode_t MODE = S_IRWXU | S_IRWXG | S_IRWXO; - -class CgroupGetCgroupTest : public ::testing::Test { - protected: - - void CreateNames(const char * const names[], - const char * const values[], - const char * const ctrl_name) - { - char tmp_path[FILENAME_MAX]; - FILE *f; - int i; - - for (i = 0; i < NAMES_CNT; i++) { - if (names[i] == NULL) - break; - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s/%s/%s", - PARENT_DIR, ctrl_name, CG_NAME, names[i]); - - f = fopen(tmp_path, "w"); - ASSERT_NE(f, nullptr); - - fprintf(f, "%s", values[i]); - fclose(f); - } - } - - void SetUp() override - { - char tmp_path[FILENAME_MAX]; - int i, j, names_len, ret; - - ASSERT_EQ(NAMES_CNT, CONTROLLERS_CNT); - ASSERT_EQ(NAMES_CNT, VALUES_CNT); - - ret = cgroup_init(); - ASSERT_EQ(ret, 0); - - ret = mkdir(PARENT_DIR, MODE); - ASSERT_EQ(ret, 0); - - /* - * Artificially populate the mount table with local - * directories - */ - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(&cg_namespace_table, 0, sizeof(cg_namespace_table)); - - for (i = 0; i < CONTROLLERS_CNT; i++) { - snprintf(cg_mount_table[i].name, CONTROL_NAMELEN_MAX, - "%s", CONTROLLERS[i]); - snprintf(cg_mount_table[i].mount.path, FILENAME_MAX, - "%s/%s", PARENT_DIR, CONTROLLERS[i]); - cg_mount_table[i].version = CGROUP_V1; - - ret = mkdir(cg_mount_table[i].mount.path, MODE); - ASSERT_EQ(ret, 0); - - /* - * arbitrarily don't make the cgroup directory in - * the freezer controller - */ - if (i == CTRL_FREEZER) - continue; - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s/%s", - PARENT_DIR, CONTROLLERS[i], CG_NAME); - ret = mkdir(tmp_path, MODE); - ASSERT_EQ(ret, 0); - - CreateNames(NAMES[i], VALUES[i], CONTROLLERS[i]); - } - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override - { - int ret = 0; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -static void vectorize_cg(const struct cgroup * const cg, - vector& cg_vec) -{ - const char *cgname, *cgcname, *value; - int i, j; - - for (i = 0; i < cg->index; i++) { - for (j = 0; j < cg->controller[i]->index; j++) { - string cgname(cg->name); - string cgcname(cg->controller[i]->name); - string name(cg->controller[i]->values[j]->name); - string value(cg->controller[i]->values[j]->value); - - cg_vec.push_back(cgcname + "+" + cgname + "+" + - name + "+" + value); - } - } - - sort(cg_vec.begin(), cg_vec.end()); -} - -static void vectorize_testdata(vector& test_vec) -{ - string cgname(CG_NAME); - int i, j; - - for (i = 0; i < CTRL_CNT; i++) { - for (j = 0; j < MAX_NAMES; j++) { - if (NAMES[i][j] == NULL) - continue; - - if (strcmp(NAMES[i][j], "tasks") == 0) - /* - * The tasks files isn't listed by - * cgroup_get_cgroup() - */ - continue; - - string cgcname(CONTROLLERS[i]); - string name(NAMES[i][j]); - string value(VALUES[i][j]); - - test_vec.push_back(cgcname + "+" + cgname + "+" + - name + "+" + value); - } - } - - sort(test_vec.begin(), test_vec.end()); -} - -TEST_F(CgroupGetCgroupTest, CgroupGetCgroup1) -{ - vector cg_vec, test_vec; - struct cgroup *cg = NULL; - int ret; - - cg = cgroup_new_cgroup(CG_NAME); - ASSERT_NE(cg, nullptr); - - ret = cgroup_get_cgroup(cg); - ASSERT_EQ(ret, 0); - - vectorize_cg(cg, cg_vec); - vectorize_testdata(test_vec); - - ASSERT_EQ(cg_vec, test_vec); - - if (cg) - free(cg); -} - -/* - * This test must be last because it makes destructive changes to the cgroup hierarchy - */ -TEST_F(CgroupGetCgroupTest, CgroupGetCgroup_NoTasksFile) -{ - char tmp_path[FILENAME_MAX]; - struct cgroup *cg = NULL; - int ret; - - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s/%s/tasks", - PARENT_DIR, CONTROLLERS[CONTROLLERS_CNT - 1], CG_NAME); - ret = rmrf(tmp_path); - ASSERT_EQ(ret, 0); - - cg = cgroup_new_cgroup(CG_NAME); - ASSERT_NE(cg, nullptr); - - ret = cgroup_get_cgroup(cg); - ASSERT_EQ(ret, ECGOTHER); - - if (cg) - free(cg); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/007-cgroup_process_v1_mount.cpp b/lib/libcgroup-3.1.0/tests/gunit/007-cgroup_process_v1_mount.cpp deleted file mode 100644 index f661e70aa9b..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/007-cgroup_process_v1_mount.cpp +++ /dev/null @@ -1,81 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_process_v1_mnt() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include - -#include "gtest/gtest.h" -#include "libcgroup-internal.h" - -static int mnt_tbl_idx = 0; - -class CgroupProcessV1MntTest : public ::testing::Test { -}; - -TEST_F(CgroupProcessV1MntTest, AddV1Mount) -{ - char *controllers[] = {"cpu", "memory", NULL}; - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup", - .mnt_dir = "/sys/fs/cgroup/memory", - .mnt_type = "cgroup", - .mnt_opts = "rw,nosuid,nodev,noexec,relatime,seclabel,memory", - }; - int ret; - - ret = cgroup_process_v1_mnt(controllers, &ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, 0); - ASSERT_EQ(mnt_tbl_idx, 1); - ASSERT_STREQ(cg_mount_table[0].name, "memory"); - ASSERT_STREQ(cg_mount_table[0].mount.path, ent.mnt_dir); -} - -/* The AddV1Mount() test above added the memory controller to the - * cg_mount_table[]. Now let's add another mount point of the - * memory controller to test the duplicate mount handling - */ -TEST_F(CgroupProcessV1MntTest, AddV1Mount_Duplicate) -{ - char *controllers[] = {"cpu", "cpuset", "memory", NULL}; - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup", - .mnt_dir = "/cgroup/memory", - .mnt_type = "cgroup", - .mnt_opts = "rw,nosuid,nodev,noexec,relatime,seclabel,memory", - }; - int ret; - - ASSERT_EQ(NULL, cg_mount_table[0].mount.next); - - ret = cgroup_process_v1_mnt(controllers, &ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, 0); - ASSERT_EQ(mnt_tbl_idx, 1); - ASSERT_STREQ(cg_mount_table[0].mount.next->path, ent.mnt_dir); -} - -TEST_F(CgroupProcessV1MntTest, AddV1NamedMount) -{ - char *controllers[] = {"cpu", "memory", "systemd", NULL}; - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup", - .mnt_dir = "/sys/fs/cgroup/systemd", - .mnt_type = "cgroup", - .mnt_opts = "rw,nosuid,nodev,noexec,relatime,seclabel,name=systemd", - }; - int ret; - - ret = cgroup_process_v1_mnt(controllers, &ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, 0); - ASSERT_EQ(mnt_tbl_idx, 1); - ASSERT_STREQ(cg_mount_table[0].name, "memory"); - /* The systemd hierarchy should not be mounted due to it being - * excluded by the OPAQUE_HIERARCHY option - */ -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/008-cgroup_process_v2_mount.cpp b/lib/libcgroup-3.1.0/tests/gunit/008-cgroup_process_v2_mount.cpp deleted file mode 100644 index a68c8ed72d1..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/008-cgroup_process_v2_mount.cpp +++ /dev/null @@ -1,191 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_process_v2_mnt() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include -#include - -#include "gtest/gtest.h" -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test008cgroup"; -static const char * const PARENT2_DIR = "test008cgroup2"; -static const mode_t MODE = S_IRWXU | S_IRWXG | S_IRWXO; - -static const char * const CONTROLLERS[] = { - "cpuset", - "cpu", - "io", - "memory", - "pids", - "rdma", -}; -static const int CONTROLLERS_CNT = - sizeof(CONTROLLERS) / sizeof(CONTROLLERS[0]); - -static int mnt_tbl_idx = 0; - -class CgroupProcessV2MntTest : public ::testing::Test { - protected: - - void CreateHierarchy(const char * const dir) - { - char tmp_path[FILENAME_MAX]; - int i, ret; - FILE *f; - - ret = mkdir(dir, MODE); - ASSERT_EQ(ret, 0); - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, "%s/cgroup.controllers", - dir); - - f = fopen(tmp_path, "w"); - ASSERT_NE(f, nullptr); - - for (i = 0; i < CONTROLLERS_CNT; i++) - fprintf(f, "%s ", CONTROLLERS[i]); - - fclose(f); - } - - void SetUp() override - { - char tmp_path[FILENAME_MAX]; - int i, ret; - FILE *f; - - CreateHierarchy(PARENT_DIR); - - /* make another directory to test the duplicate logic */ - CreateHierarchy(PARENT2_DIR); - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override - { - int ret = 0; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - - ret = rmrf(PARENT2_DIR); - ASSERT_EQ(ret, 0); - } -}; - -TEST_F(CgroupProcessV2MntTest, AddV2Mount) -{ - char *mnt_dir = strdup(PARENT_DIR); - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup2", - .mnt_dir = mnt_dir, - .mnt_type = "cgroup2", - .mnt_opts = "rw,relatime,seclabel", - }; - int ret; - - ret = cgroup_process_v2_mnt(&ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, 0); - ASSERT_EQ(mnt_tbl_idx, 7); - ASSERT_STREQ(cg_mount_table[0].name, "cpuset"); - ASSERT_STREQ(cg_mount_table[1].name, "cpu"); - ASSERT_STREQ(cg_mount_table[2].name, "io"); - ASSERT_STREQ(cg_mount_table[3].name, "memory"); - ASSERT_STREQ(cg_mount_table[4].name, "pids"); - ASSERT_STREQ(cg_mount_table[5].name, "rdma"); - ASSERT_STREQ(cg_mount_table[6].name, "cgroup"); - - ASSERT_STREQ(cg_mount_table[0].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[1].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[2].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[3].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[4].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[5].mount.path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[6].mount.path, ent.mnt_dir); -} - -TEST_F(CgroupProcessV2MntTest, AddV2Mount_Duplicate) -{ - char *mnt_dir = strdup(PARENT2_DIR); - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup2", - .mnt_dir = mnt_dir, - .mnt_type = "cgroup2", - .mnt_opts = "rw,relatime,seclabel", - }; - int ret; - - ret = cgroup_process_v2_mnt(&ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, 0); - ASSERT_EQ(mnt_tbl_idx, 7); - ASSERT_STREQ(cg_mount_table[0].name, "cpuset"); - ASSERT_STREQ(cg_mount_table[1].name, "cpu"); - ASSERT_STREQ(cg_mount_table[2].name, "io"); - ASSERT_STREQ(cg_mount_table[3].name, "memory"); - ASSERT_STREQ(cg_mount_table[4].name, "pids"); - ASSERT_STREQ(cg_mount_table[5].name, "rdma"); - ASSERT_STREQ(cg_mount_table[6].name, "cgroup"); - - ASSERT_STREQ(cg_mount_table[0].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[1].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[2].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[3].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[4].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[5].mount.next->path, ent.mnt_dir); - ASSERT_STREQ(cg_mount_table[6].mount.next->path, ent.mnt_dir); -} - -/* - * This test must be last because it makes destructive changes to the cgroup hierarchy - */ -TEST_F(CgroupProcessV2MntTest, EmptyControllersFile) -{ - char tmp_path[FILENAME_MAX]; - char *mnt_dir = strdup(PARENT_DIR); - struct mntent ent = (struct mntent) { - .mnt_fsname = "cgroup2", - .mnt_dir = mnt_dir, - .mnt_type = "cgroup2", - .mnt_opts = "rw,relatime,seclabel", - }; - FILE *f; - int ret; - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, "%s/cgroup.controllers", - PARENT_DIR); - - /* clear the cgroup.controllers file */ - f = fopen(tmp_path, "w"); - ASSERT_NE(f, nullptr); - fclose(f); - - /* reset the mount table count */ - mnt_tbl_idx = 0; - - ret = cgroup_process_v2_mnt(&ent, &mnt_tbl_idx); - - ASSERT_EQ(ret, ECGEOF); - ASSERT_EQ(mnt_tbl_idx, 0); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/009-cgroup_set_values_recursive.cpp b/lib/libcgroup-3.1.0/tests/gunit/009-cgroup_set_values_recursive.cpp deleted file mode 100644 index 7e6bad9ccc7..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/009-cgroup_set_values_recursive.cpp +++ /dev/null @@ -1,123 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_set_values_recursive() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test009cgroup/"; - -static const char * const NAMES[] = { - "cpu.weight", - "cpu.weight.nice", - "cpu.foo", - "cpu.bar" -}; -static const int NAMES_CNT = sizeof(NAMES) / sizeof(NAMES[0]); - -static const char * const VALUES[] = { - "999", - "15", - "random", - "data" -}; -static const int VALUES_CNT = sizeof(VALUES) / sizeof(VALUES[0]); - - -class SetValuesRecursiveTest : public ::testing::Test { - protected: - - void SetUp() override { - char tmp_path[FILENAME_MAX]; - int ret, i; - FILE *f; - - ASSERT_EQ(NAMES_CNT, VALUES_CNT); - - ret = mkdir(PARENT_DIR, S_IRWXU | S_IRWXG | S_IRWXO); - ASSERT_EQ(ret, 0); - - for (i = 0; i < NAMES_CNT; i++) { - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, NAMES[i]); - ASSERT_GT(ret, 0); - - f = fopen(tmp_path, "w"); - fclose(f); - } - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override { - int ret; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -TEST_F(SetValuesRecursiveTest, SuccessfulSetValues) -{ - char tmp_path[FILENAME_MAX], buf[4092]; - struct cgroup_controller ctrlr = {0}; - int ret, i; - char *val; - FILE *f; - - ret = snprintf(ctrlr.name, CONTROL_NAMELEN_MAX, "cpu"); - ASSERT_GT(ret, 0); - - for (i = 0; i < NAMES_CNT; i++) { - ctrlr.values[i] = (struct control_value *)calloc(1, - sizeof(struct control_value)); - ASSERT_NE(ctrlr.values[i], nullptr); - - strncpy(ctrlr.values[i]->name, NAMES[i], FILENAME_MAX); - strncpy(ctrlr.values[i]->value, VALUES[i], - CG_CONTROL_VALUE_MAX); - if (i == 0) - ctrlr.values[i]->dirty = true; - else - ctrlr.values[i]->dirty = false; - ctrlr.index++; - } - - ret = cgroup_set_values_recursive(PARENT_DIR, &ctrlr, false); - ASSERT_EQ(ret, 0); - - for (i = 0; i < NAMES_CNT; i++) { - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, NAMES[i]); - ASSERT_GT(ret, 0); - - f = fopen(tmp_path, "r"); - ASSERT_NE(f, nullptr); - - val = fgets(buf, sizeof(buf), f); - ASSERT_NE(val, nullptr); - ASSERT_STREQ(buf, VALUES[i]); - fclose(f); - } -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/010-cgroup_chown_chmod_tasks.cpp b/lib/libcgroup-3.1.0/tests/gunit/010-cgroup_chown_chmod_tasks.cpp deleted file mode 100644 index 7ad351e3aba..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/010-cgroup_chown_chmod_tasks.cpp +++ /dev/null @@ -1,83 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_chown_chmod_tasks() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test010cgroup"; -static const mode_t MODE = S_IRWXU | S_IRWXG | S_IRWXO; - -class ChownChmodTasksTest : public ::testing::Test { - protected: - - void SetUp() override { - char tasks_path[FILENAME_MAX]; - int ret; - FILE *f; - - ret = mkdir(PARENT_DIR, MODE); - ASSERT_EQ(ret, 0); - - memset(tasks_path, 0, sizeof(tasks_path)); - ret = snprintf(tasks_path, FILENAME_MAX - 1, "%s/tasks", - PARENT_DIR); - ASSERT_GT(ret, 0); - - f = fopen(tasks_path, "w"); - fclose(f); - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override { - int ret; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -TEST_F(ChownChmodTasksTest, SuccessfulChownChmod) -{ - mode_t mode = S_IRUSR | S_IWUSR | S_IWGRP | S_IROTH; - char tasks_path[FILENAME_MAX]; - uid_t uid = getuid(); - gid_t gid = getgid(); - struct stat statbuf; - int ret; - - ret = cgroup_chown_chmod_tasks(PARENT_DIR, uid, gid, mode); - ASSERT_EQ(ret, 0); - - memset(tasks_path, 0, sizeof(tasks_path)); - ret = snprintf(tasks_path, FILENAME_MAX - 1, "%s/tasks", - PARENT_DIR); - ASSERT_GT(ret, 0); - - ret = stat(tasks_path, &statbuf); - ASSERT_EQ(ret, 0); - - ASSERT_EQ(statbuf.st_uid, uid); - ASSERT_EQ(statbuf.st_gid, gid); - ASSERT_EQ(statbuf.st_mode & 0777, mode); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/011-cgroupv2_subtree_control.cpp b/lib/libcgroup-3.1.0/tests/gunit/011-cgroupv2_subtree_control.cpp deleted file mode 100644 index 05ab8f5a29c..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/011-cgroupv2_subtree_control.cpp +++ /dev/null @@ -1,112 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroupv2_subtree_control() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test011cgroup/"; -static const char * const SUBTREE_FILE = "cgroup.subtree_control"; - - -class SubtreeControlTest : public ::testing::Test { - protected: - - void SetUp() override { - char tmp_path[FILENAME_MAX]; - int ret, i; - FILE *f; - - ret = mkdir(PARENT_DIR, S_IRWXU | S_IRWXG | S_IRWXO); - ASSERT_EQ(ret, 0); - - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, SUBTREE_FILE); - ASSERT_GT(ret, 0); - - f = fopen(tmp_path, "w"); - fclose(f); - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) { - return remove(fpath); - } - - int rmrf(const char * const path) -{ - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override { - int ret; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -TEST_F(SubtreeControlTest, AddController) -{ - char tmp_path[FILENAME_MAX], buf[4092]; - char ctrlr_name[] = "cpu"; - int ret; - FILE *f; - - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, SUBTREE_FILE); - ASSERT_GT(ret, 0); - - /* erase the contents of the file */ - f = fopen(tmp_path, "w"); - fclose(f); - - ret = cgroupv2_subtree_control(PARENT_DIR, ctrlr_name, true); - ASSERT_EQ(ret, 0); - - f = fopen(tmp_path, "r"); - ASSERT_NE(f, nullptr); - - while (fgets(buf, sizeof(buf), f)) - ASSERT_STREQ(buf, "+cpu"); - fclose(f); -} - -TEST_F(SubtreeControlTest, RemoveController) -{ - char tmp_path[FILENAME_MAX], buf[4092]; - char ctrlr_name[] = "memory"; - int ret; - FILE *f; - - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, SUBTREE_FILE); - ASSERT_GT(ret, 0); - - /* erase the contents of the file */ - f = fopen(tmp_path, "w"); - fclose(f); - - ret = cgroupv2_subtree_control(PARENT_DIR, ctrlr_name, false); - ASSERT_EQ(ret, 0); - - f = fopen(tmp_path, "r"); - ASSERT_NE(f, nullptr); - - while (fgets(buf, sizeof(buf), f)) - ASSERT_STREQ(buf, "-memory"); - fclose(f); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/012-cgroup_create_cgroup.cpp b/lib/libcgroup-3.1.0/tests/gunit/012-cgroup_create_cgroup.cpp deleted file mode 100644 index dbe7c534281..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/012-cgroup_create_cgroup.cpp +++ /dev/null @@ -1,219 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_create_cgroup() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include -#include - -#include "gtest/gtest.h" -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test012cgroup"; -static const mode_t MODE = S_IRWXU | S_IRWXG | S_IRWXO; - -static const char * const CONTROLLERS[] = { - "cpu", - "freezer", - "memory", - "cpuset", - "namespaces", - "netns", -}; -static const int CONTROLLERS_CNT = - sizeof(CONTROLLERS) / sizeof(CONTROLLERS[0]); - -static cg_version_t VERSIONS[] = { - CGROUP_V1, - CGROUP_V2, - CGROUP_V2, - CGROUP_V1, - CGROUP_V1, - CGROUP_V2, -}; -static const int VERSIONS_CNT = - sizeof(VERSIONS) / sizeof(VERSIONS[0]); - -class CgroupCreateCgroupTest : public ::testing::Test { - protected: - - void SetUp() override - { - char tmp_path[FILENAME_MAX]; - int ret, i; - FILE *f; - - ASSERT_EQ(VERSIONS_CNT, CONTROLLERS_CNT); - - ret = mkdir(PARENT_DIR, MODE); - ASSERT_EQ(ret, 0); - - /* - * Artificially populate the mount table with local - * directories - */ - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(&cg_namespace_table, 0, sizeof(cg_namespace_table)); - - for (i = 0; i < CONTROLLERS_CNT; i++) { - snprintf(cg_mount_table[i].name, CONTROL_NAMELEN_MAX, - "%s", CONTROLLERS[i]); - cg_mount_table[i].version = VERSIONS[i]; - - switch (VERSIONS[i]) { - case CGROUP_V1: - snprintf(cg_mount_table[i].mount.path, - FILENAME_MAX, "%s/%s", PARENT_DIR, - CONTROLLERS[i]); - - ret = mkdir(cg_mount_table[i].mount.path, MODE); - ASSERT_EQ(ret, 0); - break; - case CGROUP_V2: - snprintf(cg_mount_table[i].mount.path, - FILENAME_MAX, "%s", PARENT_DIR); - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, - "%s/cgroup.subtree_control", - PARENT_DIR); - - f = fopen(tmp_path, "w"); - ASSERT_NE(f, nullptr); - fclose(f); - break; - default: - /* we shouldn't get here. fail the test */ - ASSERT_TRUE(false); - } - } - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override - { - int ret = 0; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -static void verify_cgroup_created(const char * const cg_name, - const char * const ctrl) -{ - char tmp_path[FILENAME_MAX]; - DIR *dir; - - memset(tmp_path, 0, sizeof(tmp_path)); - - if (ctrl) - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s/%s", - PARENT_DIR, ctrl, cg_name); - else - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s", - PARENT_DIR, cg_name); - - dir = opendir(tmp_path); - ASSERT_NE(dir, nullptr); - closedir(dir); -} - -static void verify_subtree_contents(const char * const expected) -{ - char tmp_path[FILENAME_MAX], buf[4092]; - FILE *f; - - memset(tmp_path, 0, sizeof(tmp_path)); - snprintf(tmp_path, FILENAME_MAX - 1, "%s/cgroup.subtree_control", - PARENT_DIR); - f = fopen(tmp_path, "r"); - ASSERT_NE(f, nullptr); - - while (fgets(buf, sizeof(buf), f)) - ASSERT_STREQ(buf, expected); - fclose(f); -} - -TEST_F(CgroupCreateCgroupTest, CgroupCreateCgroupV1) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg = NULL; - const char * const ctrl_name = "cpu"; - const char * const cg_name = "MyV1Cgroup"; - int ret; - - cg = cgroup_new_cgroup(cg_name); - ASSERT_NE(cg, nullptr); - - ctrl = cgroup_add_controller(cg, ctrl_name); - ASSERT_NE(ctrl, nullptr); - - ret = cgroup_create_cgroup(cg, 1); - ASSERT_EQ(ret, 0); - - verify_cgroup_created(cg_name, ctrl_name); -} - -TEST_F(CgroupCreateCgroupTest, CgroupCreateCgroupV2) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg = NULL; - const char * const ctrl_name = "freezer"; - const char * const cg_name = "MyV2Cgroup"; - int ret; - - cg = cgroup_new_cgroup(cg_name); - ASSERT_NE(cg, nullptr); - - ctrl = cgroup_add_controller(cg, ctrl_name); - ASSERT_NE(ctrl, nullptr); - - ret = cgroup_create_cgroup(cg, 0); - ASSERT_EQ(ret, 0); - - verify_cgroup_created(cg_name, NULL); - verify_subtree_contents("+freezer"); -} - -TEST_F(CgroupCreateCgroupTest, CgroupCreateCgroupV1AndV2) -{ - struct cgroup_controller *ctrl; - struct cgroup *cg = NULL; - const char * const ctrl1_name = "memory"; - const char * const ctrl2_name = "cpuset"; - const char * const cg_name = "MyV1AndV2Cgroup"; - int ret; - - cg = cgroup_new_cgroup(cg_name); - ASSERT_NE(cg, nullptr); - - ctrl = cgroup_add_controller(cg, ctrl1_name); - ASSERT_NE(ctrl, nullptr); - ctrl = NULL; - ctrl = cgroup_add_controller(cg, ctrl2_name); - ASSERT_NE(ctrl, nullptr); - - ret = cgroup_create_cgroup(cg, 1); - ASSERT_EQ(ret, 0); - - verify_cgroup_created(cg_name, NULL); - verify_cgroup_created(cg_name, ctrl2_name); - verify_subtree_contents("+memory"); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/013-cgroup_build_tasks_procs_path.cpp b/lib/libcgroup-3.1.0/tests/gunit/013-cgroup_build_tasks_procs_path.cpp deleted file mode 100644 index d5392cdcc5f..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/013-cgroup_build_tasks_procs_path.cpp +++ /dev/null @@ -1,149 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroup_build_tasks_procs_path() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class BuildTasksProcPathTest : public ::testing::Test { - protected: - - /** - * Setup this test case - * - * This test case calls cg_build_path() to generate various - * cgroup paths. The SetUp() routine creates a simple mount - * table that can be used to verify cg_build_path() behavior. - * - * cg_mount_table for this test is as follows: - * name mount_point index version - * ---------------------------------------------------------- - * controller0 /sys/fs/cgroup/controller0 0 UNK - * controller1 /sys/fs/cgroup/controller1 1 2 - * controller2 /sys/fs/cgroup/controller2 2 1 - * controller3 /sys/fs/cgroup/controller3 3 2 - * controller4 /sys/fs/cgroup/controller4 4 1 - * controller5 /sys/fs/cgroup/controller5 5 2 - * - * Note that controllers 1 and 4 are also given namespaces - */ - void SetUp() override { - char NAMESPACE1[] = "ns1"; - char NAMESPACE4[] = "ns4"; - const int ENTRY_CNT = 6; - int i, ret; - - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(cg_namespace_table, 0, - CG_CONTROLLER_MAX * sizeof(cg_namespace_table[0])); - - // Populate the mount table - for (i = 0; i < ENTRY_CNT; i++) { - snprintf(cg_mount_table[i].name, CONTROL_NAMELEN_MAX, - "controller%d", i); - cg_mount_table[i].index = i; - - ret = snprintf(cg_mount_table[i].mount.path, FILENAME_MAX, - "/sys/fs/cgroup/%s", cg_mount_table[i].name); - ASSERT_LT(ret, sizeof(cg_mount_table[i].mount.path)); - - cg_mount_table[i].mount.next = NULL; - - if (i == 0) - cg_mount_table[i].version = CGROUP_UNK; - else - cg_mount_table[i].version = - (cg_version_t)((i % 2) + 1); - } - - // Give a couple of the entries a namespace as well - cg_namespace_table[1] = NAMESPACE1; - cg_namespace_table[4] = NAMESPACE4; - } -}; - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_ControllerNotFound) -{ - char ctrlname[] = "InvalidCtrlr"; - char path[FILENAME_MAX]; - char cgname[] = "foo"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, ECGOTHER); - ASSERT_STREQ(path, "\0"); -} - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_UnknownCgVersion) -{ - char ctrlname[] = "controller0"; - char path[FILENAME_MAX]; - char cgname[] = "bar"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, ECGOTHER); - ASSERT_STREQ(path, "\0"); -} - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_CgV1) -{ - char ctrlname[] = "controller2"; - char path[FILENAME_MAX]; - char cgname[] = "Container7"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(path, "/sys/fs/cgroup/controller2/Container7/tasks"); -} - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_CgV2) -{ - char ctrlname[] = "controller3"; - struct cgroup_controller ctrlr = {0}; - char path[FILENAME_MAX]; - char cgname[] = "tomcat"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(path, "/sys/fs/cgroup/controller3/tomcat/cgroup.procs"); -} - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_CgV1WithNs) -{ - char ctrlname[] = "controller4"; - struct cgroup_controller ctrlr = {0}; - char path[FILENAME_MAX]; - char cgname[] = "database12"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(path, "/sys/fs/cgroup/controller4/ns4/database12/tasks"); -} - -TEST_F(BuildTasksProcPathTest, BuildTasksProcPathTest_CgV2WithNs) -{ - char ctrlname[] = "controller1"; - struct cgroup_controller ctrlr = {0}; - char path[FILENAME_MAX]; - char cgname[] = "server"; - int ret; - - ret = cgroup_build_tasks_procs_path(path, sizeof(path), cgname, - ctrlname); - ASSERT_EQ(ret, 0); - ASSERT_STREQ(path, "/sys/fs/cgroup/controller1/ns1/server/cgroup.procs"); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/014-cgroupv2_get_subtree_control.cpp b/lib/libcgroup-3.1.0/tests/gunit/014-cgroupv2_get_subtree_control.cpp deleted file mode 100644 index a0b8e226903..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/014-cgroupv2_get_subtree_control.cpp +++ /dev/null @@ -1,157 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroupv2_get_subtree_control() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include -#include -#include -#include -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test013cgroup/"; -static const char * const SUBTREE_FILE = "cgroup.subtree_control"; - - -class GetSubtreeControlTest : public ::testing::Test { - protected: - - void SetUp() override { - char tmp_path[FILENAME_MAX]; - int ret, i; - FILE *f; - - ret = mkdir(PARENT_DIR, S_IRWXU | S_IRWXG | S_IRWXO); - ASSERT_EQ(ret, 0); - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) { - return remove(fpath); - } - - int rmrf(const char * const path) -{ - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override { - int ret; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -static void write_subtree_file(const char * const contents, ssize_t len) -{ - char tmp_path[FILENAME_MAX]; - ssize_t bytes_written; - int ret, fd; - - memset(tmp_path, 0, sizeof(tmp_path)); - ret = snprintf(tmp_path, FILENAME_MAX - 1, "%s%s", - PARENT_DIR, SUBTREE_FILE); - ASSERT_GT(ret, 0); - - fd = open(tmp_path, O_WRONLY | O_TRUNC | O_CREAT, S_IRWXU | S_IRWXG); - ASSERT_GT(fd, 0); - - bytes_written = write(fd, contents, len); - ASSERT_EQ(bytes_written, len); - close(fd); -} - -TEST_F(GetSubtreeControlTest, SingleControllerEnabled) -{ - char ctrlr_name[] = "cpu"; - char subtree_contents[] = "cpu\n"; - bool enabled = false; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, 0); - ASSERT_EQ(enabled, true); -} - -TEST_F(GetSubtreeControlTest, SingleControllerNoMatch) -{ - char ctrlr_name[] = "cpu"; - char subtree_contents[] = "cpuset\n"; - bool enabled = true; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, ECGROUPNOTMOUNTED); - ASSERT_EQ(enabled, false); -} - -TEST_F(GetSubtreeControlTest, SingleControllerNoMatch2) -{ - char ctrlr_name[] = "cpuset"; - char subtree_contents[] = "cpu\n"; - bool enabled = true; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, ECGROUPNOTMOUNTED); - ASSERT_EQ(enabled, false); -} - -TEST_F(GetSubtreeControlTest, MultipleControllersEnabled) -{ - char ctrlr_name[] = "cpu"; - char subtree_contents[] = "cpu cpuset io memory pids\n"; - bool enabled = false; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, 0); - ASSERT_EQ(enabled, true); -} - -TEST_F(GetSubtreeControlTest, MultipleControllersEnabled2) -{ - char ctrlr_name[] = "pids"; - char subtree_contents[] = "cpu cpuset io memory pids\n"; - bool enabled = false; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, 0); - ASSERT_EQ(enabled, true); -} - -TEST_F(GetSubtreeControlTest, MultipleControllersNoMatch) -{ - char ctrlr_name[] = "network"; - char subtree_contents[] = "cpu cpuset io memory pids\n"; - bool enabled = true; - int ret; - - write_subtree_file(subtree_contents, strlen(subtree_contents)); - - ret = cgroupv2_get_subtree_control(PARENT_DIR, ctrlr_name, &enabled); - ASSERT_EQ(ret, ECGROUPNOTMOUNTED); - ASSERT_EQ(enabled, false); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/015-cgroupv2_controller_enabled.cpp b/lib/libcgroup-3.1.0/tests/gunit/015-cgroupv2_controller_enabled.cpp deleted file mode 100644 index f5ad47c2fde..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/015-cgroupv2_controller_enabled.cpp +++ /dev/null @@ -1,172 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for cgroupv2_controller_enabled() - * - * Copyright (c) 2020 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include -#include -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -static const char * const PARENT_DIR = "test015cgroup"; -static const mode_t MODE = S_IRWXU | S_IRWXG | S_IRWXO; - -static const char * const CHILD_DIRS[] = { - "test1-v1cgroup", - "test2-rootcgroup", - "test3-ctrlrenabled", - "test4-ctrlrdisabled", -}; -static const int CHILD_DIRS_CNT = - sizeof(CHILD_DIRS) / sizeof(CHILD_DIRS[0]); - -static const char * const CONTROLLERS[] = { - "cpu", - "cpuset", - "io", - "memory", - "net_cls", - "pids", -}; -static const int CONTROLLERS_CNT = - sizeof(CONTROLLERS) / sizeof(CONTROLLERS[0]); - -static const enum cg_version_t VERSIONS[] = { - CGROUP_V2, - CGROUP_V1, - CGROUP_V2, - CGROUP_V2, - CGROUP_V2, - CGROUP_V2, -}; -static const int VERSIONS_CNT = - sizeof(VERSIONS) / sizeof(VERSIONS[0]); - -class CgroupV2ControllerEnabled : public ::testing::Test { - protected: - - void InitChildDir(const char dirname[]) - { - char tmp_path[FILENAME_MAX] = {0}; - int ret; - - /* create the directory */ - snprintf(tmp_path, FILENAME_MAX - 1, "%s/%s", - PARENT_DIR, dirname); - ret = mkdir(tmp_path, MODE); - ASSERT_EQ(ret, 0); - } - - void InitMountTable(void) - { - char tmp_path[FILENAME_MAX] = {0}; - int ret, i; - FILE *f; - - ASSERT_EQ(VERSIONS_CNT, CONTROLLERS_CNT); - - snprintf(tmp_path, FILENAME_MAX - 1, - "%s/cgroup.subtree_control", PARENT_DIR); - - f = fopen(tmp_path, "w"); - ASSERT_NE(f, nullptr); - fprintf(f, "cpu io memory pids\n"); - fclose(f); - - /* - * Artificially populate the mount table with local - * directories - */ - memset(&cg_mount_table, 0, sizeof(cg_mount_table)); - memset(&cg_namespace_table, 0, sizeof(cg_namespace_table)); - - for (i = 0; i < CONTROLLERS_CNT; i++) { - snprintf(cg_mount_table[i].name, CONTROL_NAMELEN_MAX, - "%s", CONTROLLERS[i]); - snprintf(cg_mount_table[i].mount.path, FILENAME_MAX, - "%s", PARENT_DIR); - cg_mount_table[i].version = VERSIONS[i]; - } - } - - void SetUp() override - { - int ret, i; - - ret = mkdir(PARENT_DIR, MODE); - ASSERT_EQ(ret, 0); - - InitMountTable(); - - for (i = 0; i < CHILD_DIRS_CNT; i++) - InitChildDir(CHILD_DIRS[i]); - } - - /* - * https://stackoverflow.com/questions/5467725/how-to-delete-a-directory-and-its-contents-in-posix-c - */ - static int unlink_cb(const char *fpath, const struct stat *sb, int typeflag, - struct FTW *ftwbuf) - { - return remove(fpath); - } - - int rmrf(const char * const path) - { - return nftw(path, unlink_cb, 64, FTW_DEPTH | FTW_PHYS); - } - - void TearDown() override - { - int ret = 0; - - ret = rmrf(PARENT_DIR); - ASSERT_EQ(ret, 0); - } -}; - -TEST_F(CgroupV2ControllerEnabled, CgroupV1Controller) -{ - char ctrlr_name[] = "cpuset"; - char cg_name[] = "foo"; - int ret; - - ret = cgroupv2_controller_enabled(cg_name, ctrlr_name); - ASSERT_EQ(ret, 0); -} - -TEST_F(CgroupV2ControllerEnabled, RootCgroup) -{ - char ctrlr_name[] = "cpu"; - char cg_name[] = "/"; - int ret; - - ret = cgroupv2_controller_enabled(cg_name, ctrlr_name); - ASSERT_EQ(ret, 0); -} - -TEST_F(CgroupV2ControllerEnabled, ControllerEnabled) -{ - char ctrlr_name[] = "pids"; - char cg_name[] = "test3-ctrlrenabled"; - int ret; - - ret = cgroupv2_controller_enabled(cg_name, ctrlr_name); - ASSERT_EQ(ret, 0); -} - -TEST_F(CgroupV2ControllerEnabled, ControllerDisabled) -{ - char ctrlr_name[] = "net_cls"; - char cg_name[] = "test4-ctrlrdisabled"; - int ret; - - ret = cgroupv2_controller_enabled(cg_name, ctrlr_name); - ASSERT_EQ(ret, ECGROUPNOTMOUNTED); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/016-cgset_parse_r_flag.cpp b/lib/libcgroup-3.1.0/tests/gunit/016-cgset_parse_r_flag.cpp deleted file mode 100644 index 728c98b6936..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/016-cgset_parse_r_flag.cpp +++ /dev/null @@ -1,39 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for parse_r_flag() in cgset - * - * Copyright (c) 2021 Oracle and/or its affiliates. - * Author: Tom Hromatka - */ - -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" -#include "tools-common.h" - -static const char * const PARENT_DIR = "test016cgset/"; - -static const char * const NAME = "io.max"; -static const char * const VALUE = "\"8:16 wbps=1024\""; - -class CgsetParseRFlagTest : public ::testing::Test { -}; - -TEST_F(CgsetParseRFlagTest, EqualCharInValue) -{ - struct control_value name_value; - char name_value_str[4092]; - int ret; - - ret = snprintf(name_value_str, sizeof(name_value_str) -1, - "%s=%s", NAME, VALUE); - ASSERT_GT(ret, 0); - - ret = parse_r_flag("cgset", name_value_str, &name_value); - ASSERT_EQ(ret, 0); - - ASSERT_STREQ(name_value.name, NAME); - ASSERT_STREQ(name_value.value, VALUE); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/017-API_fuzz_test.cpp b/lib/libcgroup-3.1.0/tests/gunit/017-API_fuzz_test.cpp deleted file mode 100644 index 969cfdb6324..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/017-API_fuzz_test.cpp +++ /dev/null @@ -1,650 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest for fuzz testing APIs with negative values. - * - * Copyright (c) 2023 Oracle and/or its affiliates. All rights reserved. - * Author: Kamalesh Babulal - */ - -#include - -#include "gtest/gtest.h" - -#include "libcgroup-internal.h" - -class APIArgsTest: public :: testing:: Test { - protected: - - void SetUp() override { - /* Stub */ - } -}; - -/** - * Pass NULL cgroup for setting permissions - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_permissions test name - * - * This test will pass NULL cgroup to the cgroup_set_permissions() - * and check it handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_set_permissions) -{ - mode_t dir_mode, ctrl_mode, task_mode; - struct cgroup * cgroup = NULL; - - dir_mode = (S_IRWXU | S_IXGRP | S_IXOTH); - ctrl_mode = (S_IRUSR | S_IWUSR | S_IRGRP); - task_mode = (S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP); - - testing::internal::CaptureStdout(); - - cgroup_set_permissions(cgroup, dir_mode, ctrl_mode, task_mode); - - std::string result = testing::internal::GetCapturedStdout(); - ASSERT_EQ(result, "Error: Cgroup, operation not allowed\n"); -} - -/** - * Pass NULL cgroup name for creating a cgroup - * @param APIArgsTest googletest test case name - * @param API_cgroup_new_cgroup test name - * - * This test will pass NULL cgroup name to the cgroup_new_cgroup() - * and check it handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_new_cgroup) -{ - struct cgroup *cgroup = NULL; - char *name = NULL; - - cgroup = cgroup_new_cgroup(name); - ASSERT_EQ(cgroup, nullptr); -} - -/** - * Test arguments passed to set a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_string test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_set_value_string() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_set_value_string) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - char * name = NULL, *value = NULL; - struct cgroup *cgroup = NULL; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_set_value_string(cgc, name, value); - ASSERT_EQ(ret, 50011); - - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // case 2 - // cgc = valid, name = NULL, value = NULL - ret = cgroup_set_value_string(cgc, name, value); - ASSERT_EQ(ret, 50011); - - name = strdup("cgroup.shares"); - ASSERT_NE(name, nullptr); - - // case 3 - // cgc = valid, name = valid, value = NULL - ret = cgroup_set_value_string(cgc, name, value); - ASSERT_EQ(ret, 50011); - - free(name); - name = NULL; - - value = strdup("1024"); - ASSERT_NE(value, nullptr); - - // case 4 - // cgc = valid, name = NULL, value = valid - ret = cgroup_set_value_string(cgc, name, value); - ASSERT_EQ(ret, 50011); - - free(value); -} - -/** - * Test arguments passed to get a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_get_value_string test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_get_value_string() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_get_value_string) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - char *name = NULL, *value = NULL; - struct cgroup *cgroup = NULL; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_get_value_string(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // case 2 - // cgc = valid, name = NULL, value = NULL - ret = cgroup_get_value_string(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - name = strdup("cgroup.shares"); - ASSERT_NE(name, nullptr); - - // case 3 - // cgc = valid, name = valid, value = NULL - ret = cgroup_get_value_string(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - free(name); - name = NULL; - - // case 4 - // cgc = valid, name = valid, value = NULL - ret = cgroup_get_value_string(cgc, name, &value); - ASSERT_EQ(ret, 50011); - - free(value); -} - -/** - * Test arguments passed to add controller to a cgroup - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_string test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_add_controller() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_add_controller) -{ - const char * const cg_name = "FuzzerCgroup"; - const char * const cg_ctrl = "cpu"; - const char * const new_cg_ctrl = NULL; - struct cgroup_controller *cgc = NULL; - struct cgroup *cgroup = NULL; - int ret; - - // case 1 - // cgrp = NULL, name = NULL - cgc = cgroup_add_controller(cgroup, new_cg_ctrl); - ASSERT_EQ(cgroup, nullptr); - - // case 2 - // cgrp = NULL, name = valid - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_EQ(cgroup, nullptr); - - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // case 3 - // cgrp = valid, name = NULL - cgc = cgroup_add_controller(cgroup, new_cg_ctrl); - ASSERT_EQ(cgc, nullptr); -} - -/** - * Test arguments passed to add a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_string test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_add_value_string() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_add_value_string) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller *cgc = NULL; - const char * const cg_ctrl = "cpu"; - struct cgroup *cgroup = NULL; - char * ctrl_value = NULL; - char * ctrl_name = NULL; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_add_value_string(cgc, ctrl_name, ctrl_value); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = NULL - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - ret = cgroup_add_value_string(cgc, ctrl_name, ctrl_value); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = NULL - ctrl_name = strdup("cpu.shares"); - ASSERT_NE(ctrl_name, nullptr); - - ret = cgroup_add_value_string(cgc, ctrl_name, ctrl_value); - ASSERT_EQ(ret, 0); - - // case 4 - // cgc = valid, name = NULL, value = valid - free(ctrl_name); - ctrl_name = NULL; - - ctrl_value = strdup("1024"); - ASSERT_NE(ctrl_value, nullptr); - - ret = cgroup_add_value_string(cgc, ctrl_name, ctrl_value); - ASSERT_EQ(ret, 50011); - - free(ctrl_value); -} - -TEST_F(APIArgsTest, API_cgroup_get_uid_gid) -{ - const char * const cg_name = "FuzzerCgroup"; - uid_t tasks_uid, control_uid; - gid_t tasks_gid, control_gid; - - struct cgroup *cgroup = NULL; - int ret; - // case 1 - // cgroup = NULL, tasks_uid = NULL, tasks_gid = NULL, control_uid = NULL, - // control_uid = NULL - ret = cgroup_get_uid_gid(cgroup, NULL, NULL, NULL, NULL); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgroup = valid, tasks_uid = NULL, tasks_gid = NULL, control_uid = NULL, - // control_uid = NULL - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - ret = cgroup_get_uid_gid(cgroup, NULL, NULL, NULL, NULL); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgroup = valid, tasks_uid = valid, tasks_gid = NULL, control_uid = NULL, - // control_uid = NULL - ret = cgroup_get_uid_gid(cgroup, &tasks_uid, NULL, NULL, NULL); - ASSERT_EQ(ret, 50011); - - // case 4 - // cgroup = valid, tasks_uid = valid, tasks_gid = valid, control_uid = NULL, - // control_uid = NULL - ret = cgroup_get_uid_gid(cgroup, &tasks_uid, &tasks_gid, NULL, NULL); - ASSERT_EQ(ret, 50011); - - // case 5 - // cgroup = valid, tasks_uid = valid, tasks_gid = valid, control_uid = valid, - // control_uid = NULL - ret = cgroup_get_uid_gid(cgroup, &tasks_uid, &tasks_gid, &control_uid, NULL); - ASSERT_EQ(ret, 50011); - - // case 6 - // cgroup = valid, tasks_uid = valid, tasks_gid = valid, control_uid = valid, - // control_uid = valid - ret = cgroup_get_uid_gid(cgroup, &tasks_uid, &tasks_gid, &control_uid, &control_gid); - ASSERT_EQ(ret, 0); -} - -/** - * Test arguments passed to set a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_int64 test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_set_value_int64() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_set_value_int64) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - struct cgroup *cgroup = NULL; - int64_t value = 1024; - char * name = NULL; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = valid - ret = cgroup_set_value_int64(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = valid - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpu.shares, so that cgc->index > 0 - ret = cgroup_set_value_int64(cgc, "cpu.shares", 1024); - ASSERT_EQ(ret, 0); - - ret = cgroup_set_value_int64(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = valid - name = strdup("cpu.shares"); - ASSERT_NE(name, nullptr); - - ret = cgroup_set_value_int64(cgc, name, value); - ASSERT_EQ(ret, 0); - - // check if the value was set right - ret = cgroup_get_value_int64(cgc, name, &value); - ASSERT_EQ(ret, 0); - ASSERT_EQ(value, 1024); - - free(name); -} - -/** - * Test arguments passed to get a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_get_value_int64 test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_get_value_int64() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_get_value_int64) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - struct cgroup *cgroup = NULL; - char * name = NULL; - int64_t value; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_get_value_int64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = NULL - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpu.shares, so that cgc->index > 0 - ret = cgroup_set_value_int64(cgc, "cpu.shares", 1024); - ASSERT_EQ(ret, 0); - - ret = cgroup_get_value_int64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = NULL - name = strdup("cpu.shares"); - ASSERT_NE(name, nullptr); - - ret = cgroup_get_value_int64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 4 - // cgc = valid, name = valid, value = NULL - free(name); - name = NULL; - - ret = cgroup_get_value_int64(cgc, name, &value); - ASSERT_EQ(ret, 50011); -} - -/** - * Test arguments passed to set a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_uint64 test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_set_value_uint64() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_set_value_uint64) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - struct cgroup *cgroup = NULL; - u_int64_t value = 1024; - char * name = NULL; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = valid - ret = cgroup_set_value_uint64(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = valid - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpu.shares, so that cgc->index > 0 - ret = cgroup_set_value_uint64(cgc, "cpu.shares", 1024); - ASSERT_EQ(ret, 0); - - ret = cgroup_set_value_uint64(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = valid - name = strdup("cpu.shares"); - ASSERT_NE(name, nullptr); - - ret = cgroup_set_value_uint64(cgc, name, value); - ASSERT_EQ(ret, 0); - - // check if the value was set right - ret = cgroup_get_value_uint64(cgc, name, &value); - ASSERT_EQ(ret, 0); - ASSERT_EQ(value, 1024); - - free(name); -} - -/** - * Test arguments passed to get a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_get_value_uint64 test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_get_value_uint64() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_get_value_uint64) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpu"; - struct cgroup *cgroup = NULL; - char * name = NULL; - u_int64_t value; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_get_value_uint64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = NULL - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpu.shares, so that cgc->index > 0 - ret = cgroup_set_value_uint64(cgc, "cpu.shares", 1024); - ASSERT_EQ(ret, 0); - - ret = cgroup_get_value_uint64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = NULL - name = strdup("cpu.shares"); - ASSERT_NE(name, nullptr); - - ret = cgroup_get_value_uint64(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 4 - // cgc = valid, name = NULL, value = valid - free(name); - name = NULL; - - ret = cgroup_get_value_uint64(cgc, name, &value); - ASSERT_EQ(ret, 50011); -} - -/** - * Test arguments passed to set a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_set_value_bool test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_set_value_bool() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_set_value_bool) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpuset"; - struct cgroup *cgroup = NULL; - char * name = NULL; - bool value = 1; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = valid - ret = cgroup_set_value_bool(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = valid - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpuset.cpu_exclusive, so that cgc->index > 0 - ret = cgroup_set_value_bool(cgc, "cpuset.cpu_exclusive", 0); - ASSERT_EQ(ret, 0); - - ret = cgroup_set_value_bool(cgc, name, value); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = valid - name = strdup("cpuset.cpu_exclusive"); - ASSERT_NE(name, nullptr); - - ret = cgroup_set_value_bool(cgc, name, value); - ASSERT_EQ(ret, 0); - - // check if the value was set right - ret = cgroup_get_value_bool(cgc, name, &value); - ASSERT_EQ(ret, 0); - ASSERT_EQ(value, 1); - - free(name); -} - -/** - * Test arguments passed to get a controller's setting - * @param APIArgsTest googletest test case name - * @param API_cgroup_get_value_bool test name - * - * This test will pass a combination of valid and NULL as - * arguments to cgroup_get_value_bool() and check if it - * handles it gracefully. - */ -TEST_F(APIArgsTest, API_cgroup_get_value_bool) -{ - const char * const cg_name = "FuzzerCgroup"; - struct cgroup_controller * cgc = NULL; - const char * const cg_ctrl = "cpuset"; - struct cgroup *cgroup = NULL; - char * name = NULL; - bool value; - int ret; - - // case 1 - // cgc = NULL, name = NULL, value = NULL - ret = cgroup_get_value_bool(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 2 - // cgc = valid, name = NULL, value = NULL - cgroup = cgroup_new_cgroup(cg_name); - ASSERT_NE(cgroup, nullptr); - - cgc = cgroup_add_controller(cgroup, cg_ctrl); - ASSERT_NE(cgroup, nullptr); - - // set cpuset.cpu_exclusive, so that cgc->index > 0 - ret = cgroup_set_value_bool(cgc, "cpuset.cpu_exclusive", 0); - ASSERT_EQ(ret, 0); - - ret = cgroup_get_value_bool(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 3 - // cgc = valid, name = valid, value = NULL - name = strdup("cpuset.cpu_exclusive"); - ASSERT_NE(name, nullptr); - - ret = cgroup_get_value_bool(cgc, name, NULL); - ASSERT_EQ(ret, 50011); - - // case 4 - // cgc = valid, name = NULL, value = valid - free(name); - name = NULL; - - ret = cgroup_get_value_bool(cgc, name, &value); - ASSERT_EQ(ret, 50011); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/Makefile.am b/lib/libcgroup-3.1.0/tests/gunit/Makefile.am deleted file mode 100644 index 353567b47ea..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/Makefile.am +++ /dev/null @@ -1,52 +0,0 @@ -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup googletests Makefile.am -# -# Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. -# Author: Tom Hromatka -# - -AM_CPPFLAGS = -I$(top_srcdir)/include \ - -I$(top_srcdir)/src \ - -I$(top_srcdir)/src/tools \ - -I$(top_srcdir)/googletest/googletest/include \ - -I$(top_srcdir)/googletest/googletest \ - -std=c++11 \ - -Wno-write-strings \ - -DSTATIC= \ - -DUNIT_TEST -LDADD = $(top_builddir)/src/.libs/libcgroupfortesting.la \ - $(top_builddir)/src/tools/.libs/libcgset.la - -EXTRA_DIST = $(top_srcdir)/googletest/googletest/libgtest.so \ - $(top_srcdir)/googletest/googletest/libgtest_main.so \ - $(top_srcdir)/googletest/googletest/include \ - libcgroup_unittest.map - -check_PROGRAMS = gtest -TESTS = gtest - -gtest_SOURCES = gtest.cpp \ - 001-path.cpp \ - 002-cgroup_parse_rules_options.cpp \ - 003-cg_get_cgroups_from_proc_cgroups.cpp \ - 004-cgroup_compare_ignore_rule.cpp \ - 005-cgroup_compare_wildcard_procname.cpp \ - 006-cgroup_get_cgroup.cpp \ - 007-cgroup_process_v1_mount.cpp \ - 008-cgroup_process_v2_mount.cpp \ - 009-cgroup_set_values_recursive.cpp \ - 010-cgroup_chown_chmod_tasks.cpp \ - 011-cgroupv2_subtree_control.cpp \ - 012-cgroup_create_cgroup.cpp \ - 013-cgroup_build_tasks_procs_path.cpp \ - 014-cgroupv2_get_subtree_control.cpp \ - 015-cgroupv2_controller_enabled.cpp \ - 016-cgset_parse_r_flag.cpp \ - 017-API_fuzz_test.cpp - -gtest_LDFLAGS = -L$(top_srcdir)/googletest/googletest -l:libgtest.so \ - -rpath $(abs_top_srcdir)/googletest/googletest - -clean-local: - ${RM} test-procpidcgroup diff --git a/lib/libcgroup-3.1.0/tests/gunit/Makefile.in b/lib/libcgroup-3.1.0/tests/gunit/Makefile.in deleted file mode 100644 index 15eeb00ceeb..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/Makefile.in +++ /dev/null @@ -1,1141 +0,0 @@ -# Makefile.in generated by automake 1.16.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2021 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# SPDX-License-Identifier: LGPL-2.1-only -# -# libcgroup googletests Makefile.am -# -# Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. -# Author: Tom Hromatka -# -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -check_PROGRAMS = gtest$(EXEEXT) -TESTS = gtest$(EXEEXT) -subdir = tests/gunit -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_code_coverage.m4 \ - $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ - $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ - $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am_gtest_OBJECTS = gtest.$(OBJEXT) 001-path.$(OBJEXT) \ - 002-cgroup_parse_rules_options.$(OBJEXT) \ - 003-cg_get_cgroups_from_proc_cgroups.$(OBJEXT) \ - 004-cgroup_compare_ignore_rule.$(OBJEXT) \ - 005-cgroup_compare_wildcard_procname.$(OBJEXT) \ - 006-cgroup_get_cgroup.$(OBJEXT) \ - 007-cgroup_process_v1_mount.$(OBJEXT) \ - 008-cgroup_process_v2_mount.$(OBJEXT) \ - 009-cgroup_set_values_recursive.$(OBJEXT) \ - 010-cgroup_chown_chmod_tasks.$(OBJEXT) \ - 011-cgroupv2_subtree_control.$(OBJEXT) \ - 012-cgroup_create_cgroup.$(OBJEXT) \ - 013-cgroup_build_tasks_procs_path.$(OBJEXT) \ - 014-cgroupv2_get_subtree_control.$(OBJEXT) \ - 015-cgroupv2_controller_enabled.$(OBJEXT) \ - 016-cgset_parse_r_flag.$(OBJEXT) 017-API_fuzz_test.$(OBJEXT) -gtest_OBJECTS = $(am_gtest_OBJECTS) -gtest_LDADD = $(LDADD) -gtest_DEPENDENCIES = $(top_builddir)/src/.libs/libcgroupfortesting.la \ - $(top_builddir)/src/tools/.libs/libcgset.la -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -gtest_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ - $(CXXFLAGS) $(gtest_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/001-path.Po \ - ./$(DEPDIR)/002-cgroup_parse_rules_options.Po \ - ./$(DEPDIR)/003-cg_get_cgroups_from_proc_cgroups.Po \ - ./$(DEPDIR)/004-cgroup_compare_ignore_rule.Po \ - ./$(DEPDIR)/005-cgroup_compare_wildcard_procname.Po \ - ./$(DEPDIR)/006-cgroup_get_cgroup.Po \ - ./$(DEPDIR)/007-cgroup_process_v1_mount.Po \ - ./$(DEPDIR)/008-cgroup_process_v2_mount.Po \ - ./$(DEPDIR)/009-cgroup_set_values_recursive.Po \ - ./$(DEPDIR)/010-cgroup_chown_chmod_tasks.Po \ - ./$(DEPDIR)/011-cgroupv2_subtree_control.Po \ - ./$(DEPDIR)/012-cgroup_create_cgroup.Po \ - ./$(DEPDIR)/013-cgroup_build_tasks_procs_path.Po \ - ./$(DEPDIR)/014-cgroupv2_get_subtree_control.Po \ - ./$(DEPDIR)/015-cgroupv2_controller_enabled.Po \ - ./$(DEPDIR)/016-cgset_parse_r_flag.Po \ - ./$(DEPDIR)/017-API_fuzz_test.Po ./$(DEPDIR)/gtest.Po -am__mv = mv -f -CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CXXFLAGS) $(CXXFLAGS) -AM_V_CXX = $(am__v_CXX_@AM_V@) -am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) -am__v_CXX_0 = @echo " CXX " $@; -am__v_CXX_1 = -CXXLD = $(CXX) -CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ - $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) -am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) -am__v_CXXLD_0 = @echo " CXXLD " $@; -am__v_CXXLD_1 = -SOURCES = $(gtest_SOURCES) -DIST_SOURCES = $(gtest_SOURCES) -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -am__tty_colors_dummy = \ - mgn= red= grn= lgn= blu= brg= std=; \ - am__color_tests=no -am__tty_colors = { \ - $(am__tty_colors_dummy); \ - if test "X$(AM_COLOR_TESTS)" = Xno; then \ - am__color_tests=no; \ - elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ - am__color_tests=yes; \ - elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ - am__color_tests=yes; \ - fi; \ - if test $$am__color_tests = yes; then \ - red=''; \ - grn=''; \ - lgn=''; \ - blu=''; \ - mgn=''; \ - brg=''; \ - std=''; \ - fi; \ -} -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__recheck_rx = ^[ ]*:recheck:[ ]* -am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* -am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* -# A command that, given a newline-separated list of test names on the -# standard input, print the name of the tests that are to be re-run -# upon "make recheck". -am__list_recheck_tests = $(AWK) '{ \ - recheck = 1; \ - while ((rc = (getline line < ($$0 ".trs"))) != 0) \ - { \ - if (rc < 0) \ - { \ - if ((getline line2 < ($$0 ".log")) < 0) \ - recheck = 0; \ - break; \ - } \ - else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ - { \ - recheck = 0; \ - break; \ - } \ - else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ - { \ - break; \ - } \ - }; \ - if (recheck) \ - print $$0; \ - close ($$0 ".trs"); \ - close ($$0 ".log"); \ -}' -# A command that, given a newline-separated list of test names on the -# standard input, create the global log from their .trs and .log files. -am__create_global_log = $(AWK) ' \ -function fatal(msg) \ -{ \ - print "fatal: making $@: " msg | "cat >&2"; \ - exit 1; \ -} \ -function rst_section(header) \ -{ \ - print header; \ - len = length(header); \ - for (i = 1; i <= len; i = i + 1) \ - printf "="; \ - printf "\n\n"; \ -} \ -{ \ - copy_in_global_log = 1; \ - global_test_result = "RUN"; \ - while ((rc = (getline line < ($$0 ".trs"))) != 0) \ - { \ - if (rc < 0) \ - fatal("failed to read from " $$0 ".trs"); \ - if (line ~ /$(am__global_test_result_rx)/) \ - { \ - sub("$(am__global_test_result_rx)", "", line); \ - sub("[ ]*$$", "", line); \ - global_test_result = line; \ - } \ - else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ - copy_in_global_log = 0; \ - }; \ - if (copy_in_global_log) \ - { \ - rst_section(global_test_result ": " $$0); \ - while ((rc = (getline line < ($$0 ".log"))) != 0) \ - { \ - if (rc < 0) \ - fatal("failed to read from " $$0 ".log"); \ - print line; \ - }; \ - printf "\n"; \ - }; \ - close ($$0 ".trs"); \ - close ($$0 ".log"); \ -}' -# Restructured Text title. -am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } -# Solaris 10 'make', and several other traditional 'make' implementations, -# pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it -# by disabling -e (using the XSI extension "set +e") if it's set. -am__sh_e_setup = case $$- in *e*) set +e;; esac -# Default flags passed to test drivers. -am__common_driver_flags = \ - --color-tests "$$am__color_tests" \ - --enable-hard-errors "$$am__enable_hard_errors" \ - --expect-failure "$$am__expect_failure" -# To be inserted before the command running the test. Creates the -# directory for the log if needed. Stores in $dir the directory -# containing $f, in $tst the test, in $log the log. Executes the -# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and -# passes TESTS_ENVIRONMENT. Set up options for the wrapper that -# will run the test scripts (or their associated LOG_COMPILER, if -# thy have one). -am__check_pre = \ -$(am__sh_e_setup); \ -$(am__vpath_adj_setup) $(am__vpath_adj) \ -$(am__tty_colors); \ -srcdir=$(srcdir); export srcdir; \ -case "$@" in \ - */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ - *) am__odir=.;; \ -esac; \ -test "x$$am__odir" = x"." || test -d "$$am__odir" \ - || $(MKDIR_P) "$$am__odir" || exit $$?; \ -if test -f "./$$f"; then dir=./; \ -elif test -f "$$f"; then dir=; \ -else dir="$(srcdir)/"; fi; \ -tst=$$dir$$f; log='$@'; \ -if test -n '$(DISABLE_HARD_ERRORS)'; then \ - am__enable_hard_errors=no; \ -else \ - am__enable_hard_errors=yes; \ -fi; \ -case " $(XFAIL_TESTS) " in \ - *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ - am__expect_failure=yes;; \ - *) \ - am__expect_failure=no;; \ -esac; \ -$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) -# A shell command to get the names of the tests scripts with any registered -# extension removed (i.e., equivalently, the names of the test logs, with -# the '.log' extension removed). The result is saved in the shell variable -# '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, -# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", -# since that might cause problem with VPATH rewrites for suffix-less tests. -# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. -am__set_TESTS_bases = \ - bases='$(TEST_LOGS)'; \ - bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ - bases=`echo $$bases` -AM_TESTSUITE_SUMMARY_HEADER = ' for $(PACKAGE_STRING)' -RECHECK_LOGS = $(TEST_LOGS) -AM_RECURSIVE_TARGETS = check recheck -TEST_SUITE_LOG = test-suite.log -TEST_EXTENSIONS = @EXEEXT@ .test -LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver -LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) -am__set_b = \ - case '$@' in \ - */*) \ - case '$*' in \ - */*) b='$*';; \ - *) b=`echo '$@' | sed 's/\.log$$//'`; \ - esac;; \ - *) \ - b='$*';; \ - esac -am__test_logs1 = $(TESTS:=.log) -am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) -TEST_LOGS = $(am__test_logs2:.test.log=.log) -TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/build-aux/test-driver -TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ - $(TEST_LOG_FLAGS) -am__DIST_COMMON = $(srcdir)/Makefile.in \ - $(top_srcdir)/build-aux/depcomp \ - $(top_srcdir)/build-aux/test-driver -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CODE_COVERAGE_CFLAGS = @CODE_COVERAGE_CFLAGS@ -CODE_COVERAGE_CPPFLAGS = @CODE_COVERAGE_CPPFLAGS@ -CODE_COVERAGE_CXXFLAGS = @CODE_COVERAGE_CXXFLAGS@ -CODE_COVERAGE_ENABLED = @CODE_COVERAGE_ENABLED@ -CODE_COVERAGE_LDFLAGS = @CODE_COVERAGE_LDFLAGS@ -CODE_COVERAGE_LIBS = @CODE_COVERAGE_LIBS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CSCOPE = @CSCOPE@ -CTAGS = @CTAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ETAGS = @ETAGS@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -FILECMD = @FILECMD@ -GCOV = @GCOV@ -GENHTML = @GENHTML@ -GREP = @GREP@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LCOV = @LCOV@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LEX = @LEX@ -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBOBJS = @LIBOBJS@ -LIBRARY_VERSION_MAJOR = @LIBRARY_VERSION_MAJOR@ -LIBRARY_VERSION_MINOR = @LIBRARY_VERSION_MINOR@ -LIBRARY_VERSION_RELEASE = @LIBRARY_VERSION_RELEASE@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PYTHON = @PYTHON@ -PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ -PYTHON_PLATFORM = @PYTHON_PLATFORM@ -PYTHON_PREFIX = @PYTHON_PREFIX@ -PYTHON_VERSION = @PYTHON_VERSION@ -RANLIB = @RANLIB@ -REALLY_YACC = @REALLY_YACC@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -YACC = @YACC@ -YFLAGS = @YFLAGS@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pamlibdir = @pamlibdir@ -pdfdir = @pdfdir@ -pkgpyexecdir = @pkgpyexecdir@ -pkgpythondir = @pkgpythondir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -pyexecdir = @pyexecdir@ -pythondir = @pythondir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -AM_CPPFLAGS = -I$(top_srcdir)/include \ - -I$(top_srcdir)/src \ - -I$(top_srcdir)/src/tools \ - -I$(top_srcdir)/googletest/googletest/include \ - -I$(top_srcdir)/googletest/googletest \ - -std=c++11 \ - -Wno-write-strings \ - -DSTATIC= \ - -DUNIT_TEST - -LDADD = $(top_builddir)/src/.libs/libcgroupfortesting.la \ - $(top_builddir)/src/tools/.libs/libcgset.la - -EXTRA_DIST = $(top_srcdir)/googletest/googletest/libgtest.so \ - $(top_srcdir)/googletest/googletest/libgtest_main.so \ - $(top_srcdir)/googletest/googletest/include \ - libcgroup_unittest.map - -gtest_SOURCES = gtest.cpp \ - 001-path.cpp \ - 002-cgroup_parse_rules_options.cpp \ - 003-cg_get_cgroups_from_proc_cgroups.cpp \ - 004-cgroup_compare_ignore_rule.cpp \ - 005-cgroup_compare_wildcard_procname.cpp \ - 006-cgroup_get_cgroup.cpp \ - 007-cgroup_process_v1_mount.cpp \ - 008-cgroup_process_v2_mount.cpp \ - 009-cgroup_set_values_recursive.cpp \ - 010-cgroup_chown_chmod_tasks.cpp \ - 011-cgroupv2_subtree_control.cpp \ - 012-cgroup_create_cgroup.cpp \ - 013-cgroup_build_tasks_procs_path.cpp \ - 014-cgroupv2_get_subtree_control.cpp \ - 015-cgroupv2_controller_enabled.cpp \ - 016-cgset_parse_r_flag.cpp \ - 017-API_fuzz_test.cpp - -gtest_LDFLAGS = -L$(top_srcdir)/googletest/googletest -l:libgtest.so \ - -rpath $(abs_top_srcdir)/googletest/googletest - -all: all-am - -.SUFFIXES: -.SUFFIXES: .cpp .lo .log .o .obj .test .test$(EXEEXT) .trs -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign tests/gunit/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign tests/gunit/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -clean-checkPROGRAMS: - @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list - -gtest$(EXEEXT): $(gtest_OBJECTS) $(gtest_DEPENDENCIES) $(EXTRA_gtest_DEPENDENCIES) - @rm -f gtest$(EXEEXT) - $(AM_V_CXXLD)$(gtest_LINK) $(gtest_OBJECTS) $(gtest_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/001-path.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/002-cgroup_parse_rules_options.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/003-cg_get_cgroups_from_proc_cgroups.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/004-cgroup_compare_ignore_rule.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/005-cgroup_compare_wildcard_procname.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/006-cgroup_get_cgroup.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/007-cgroup_process_v1_mount.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/008-cgroup_process_v2_mount.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/009-cgroup_set_values_recursive.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/010-cgroup_chown_chmod_tasks.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/011-cgroupv2_subtree_control.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/012-cgroup_create_cgroup.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/013-cgroup_build_tasks_procs_path.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/014-cgroupv2_get_subtree_control.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/015-cgroupv2_controller_enabled.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/016-cgset_parse_r_flag.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/017-API_fuzz_test.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gtest.Po@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.cpp.o: -@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\ -@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< - -.cpp.obj: -@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\ -@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\ -@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Po -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.cpp.lo: -@am__fastdepCXX_TRUE@ $(AM_V_CXX)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\ -@am__fastdepCXX_TRUE@ $(LTCXXCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\ -@am__fastdepCXX_TRUE@ $(am__mv) $$depbase.Tpo $$depbase.Plo -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-am -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-am - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-am - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -# Recover from deleted '.trs' file; this should ensure that -# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create -# both 'foo.log' and 'foo.trs'. Break the recipe in two subshells -# to avoid problems with "make -n". -.log.trs: - rm -f $< $@ - $(MAKE) $(AM_MAKEFLAGS) $< - -# Leading 'am--fnord' is there to ensure the list of targets does not -# expand to empty, as could happen e.g. with make check TESTS=''. -am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) -am--force-recheck: - @: - -$(TEST_SUITE_LOG): $(TEST_LOGS) - @$(am__set_TESTS_bases); \ - am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ - redo_bases=`for i in $$bases; do \ - am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ - done`; \ - if test -n "$$redo_bases"; then \ - redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ - redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ - if $(am__make_dryrun); then :; else \ - rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ - fi; \ - fi; \ - if test -n "$$am__remaking_logs"; then \ - echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ - "recursion detected" >&2; \ - elif test -n "$$redo_logs"; then \ - am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ - fi; \ - if $(am__make_dryrun); then :; else \ - st=0; \ - errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ - for i in $$redo_bases; do \ - test -f $$i.trs && test -r $$i.trs \ - || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ - test -f $$i.log && test -r $$i.log \ - || { echo "$$errmsg $$i.log" >&2; st=1; }; \ - done; \ - test $$st -eq 0 || exit 1; \ - fi - @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ - ws='[ ]'; \ - results=`for b in $$bases; do echo $$b.trs; done`; \ - test -n "$$results" || results=/dev/null; \ - all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ - pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ - fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ - skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ - xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ - xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ - error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ - if test `expr $$fail + $$xpass + $$error` -eq 0; then \ - success=true; \ - else \ - success=false; \ - fi; \ - br='==================='; br=$$br$$br$$br$$br; \ - result_count () \ - { \ - if test x"$$1" = x"--maybe-color"; then \ - maybe_colorize=yes; \ - elif test x"$$1" = x"--no-color"; then \ - maybe_colorize=no; \ - else \ - echo "$@: invalid 'result_count' usage" >&2; exit 4; \ - fi; \ - shift; \ - desc=$$1 count=$$2; \ - if test $$maybe_colorize = yes && test $$count -gt 0; then \ - color_start=$$3 color_end=$$std; \ - else \ - color_start= color_end=; \ - fi; \ - echo "$${color_start}# $$desc $$count$${color_end}"; \ - }; \ - create_testsuite_report () \ - { \ - result_count $$1 "TOTAL:" $$all "$$brg"; \ - result_count $$1 "PASS: " $$pass "$$grn"; \ - result_count $$1 "SKIP: " $$skip "$$blu"; \ - result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ - result_count $$1 "FAIL: " $$fail "$$red"; \ - result_count $$1 "XPASS:" $$xpass "$$red"; \ - result_count $$1 "ERROR:" $$error "$$mgn"; \ - }; \ - { \ - echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ - $(am__rst_title); \ - create_testsuite_report --no-color; \ - echo; \ - echo ".. contents:: :depth: 2"; \ - echo; \ - for b in $$bases; do echo $$b; done \ - | $(am__create_global_log); \ - } >$(TEST_SUITE_LOG).tmp || exit 1; \ - mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ - if $$success; then \ - col="$$grn"; \ - else \ - col="$$red"; \ - test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ - fi; \ - echo "$${col}$$br$${std}"; \ - echo "$${col}Testsuite summary"$(AM_TESTSUITE_SUMMARY_HEADER)"$${std}"; \ - echo "$${col}$$br$${std}"; \ - create_testsuite_report --maybe-color; \ - echo "$$col$$br$$std"; \ - if $$success; then :; else \ - echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ - if test -n "$(PACKAGE_BUGREPORT)"; then \ - echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ - fi; \ - echo "$$col$$br$$std"; \ - fi; \ - $$success || exit 1 - -check-TESTS: $(check_PROGRAMS) - @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list - @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - @set +e; $(am__set_TESTS_bases); \ - log_list=`for i in $$bases; do echo $$i.log; done`; \ - trs_list=`for i in $$bases; do echo $$i.trs; done`; \ - log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ - exit $$?; -recheck: all $(check_PROGRAMS) - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - @set +e; $(am__set_TESTS_bases); \ - bases=`for i in $$bases; do echo $$i; done \ - | $(am__list_recheck_tests)` || exit 1; \ - log_list=`for i in $$bases; do echo $$i.log; done`; \ - log_list=`echo $$log_list`; \ - $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ - am__force_recheck=am--force-recheck \ - TEST_LOGS="$$log_list"; \ - exit $$? -gtest.log: gtest$(EXEEXT) - @p='gtest$(EXEEXT)'; \ - b='gtest'; \ - $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ - --log-file $$b.log --trs-file $$b.trs \ - $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ - "$$tst" $(AM_TESTS_FD_REDIRECT) -.test.log: - @p='$<'; \ - $(am__set_b); \ - $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ - --log-file $$b.log --trs-file $$b.trs \ - $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ - "$$tst" $(AM_TESTS_FD_REDIRECT) -@am__EXEEXT_TRUE@.test$(EXEEXT).log: -@am__EXEEXT_TRUE@ @p='$<'; \ -@am__EXEEXT_TRUE@ $(am__set_b); \ -@am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ -@am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ -@am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ -@am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am - $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) - $(MAKE) $(AM_MAKEFLAGS) check-TESTS -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) - -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) - -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-checkPROGRAMS clean-generic clean-libtool clean-local \ - mostlyclean-am - -distclean: distclean-am - -rm -f ./$(DEPDIR)/001-path.Po - -rm -f ./$(DEPDIR)/002-cgroup_parse_rules_options.Po - -rm -f ./$(DEPDIR)/003-cg_get_cgroups_from_proc_cgroups.Po - -rm -f ./$(DEPDIR)/004-cgroup_compare_ignore_rule.Po - -rm -f ./$(DEPDIR)/005-cgroup_compare_wildcard_procname.Po - -rm -f ./$(DEPDIR)/006-cgroup_get_cgroup.Po - -rm -f ./$(DEPDIR)/007-cgroup_process_v1_mount.Po - -rm -f ./$(DEPDIR)/008-cgroup_process_v2_mount.Po - -rm -f ./$(DEPDIR)/009-cgroup_set_values_recursive.Po - -rm -f ./$(DEPDIR)/010-cgroup_chown_chmod_tasks.Po - -rm -f ./$(DEPDIR)/011-cgroupv2_subtree_control.Po - -rm -f ./$(DEPDIR)/012-cgroup_create_cgroup.Po - -rm -f ./$(DEPDIR)/013-cgroup_build_tasks_procs_path.Po - -rm -f ./$(DEPDIR)/014-cgroupv2_get_subtree_control.Po - -rm -f ./$(DEPDIR)/015-cgroupv2_controller_enabled.Po - -rm -f ./$(DEPDIR)/016-cgset_parse_r_flag.Po - -rm -f ./$(DEPDIR)/017-API_fuzz_test.Po - -rm -f ./$(DEPDIR)/gtest.Po - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/001-path.Po - -rm -f ./$(DEPDIR)/002-cgroup_parse_rules_options.Po - -rm -f ./$(DEPDIR)/003-cg_get_cgroups_from_proc_cgroups.Po - -rm -f ./$(DEPDIR)/004-cgroup_compare_ignore_rule.Po - -rm -f ./$(DEPDIR)/005-cgroup_compare_wildcard_procname.Po - -rm -f ./$(DEPDIR)/006-cgroup_get_cgroup.Po - -rm -f ./$(DEPDIR)/007-cgroup_process_v1_mount.Po - -rm -f ./$(DEPDIR)/008-cgroup_process_v2_mount.Po - -rm -f ./$(DEPDIR)/009-cgroup_set_values_recursive.Po - -rm -f ./$(DEPDIR)/010-cgroup_chown_chmod_tasks.Po - -rm -f ./$(DEPDIR)/011-cgroupv2_subtree_control.Po - -rm -f ./$(DEPDIR)/012-cgroup_create_cgroup.Po - -rm -f ./$(DEPDIR)/013-cgroup_build_tasks_procs_path.Po - -rm -f ./$(DEPDIR)/014-cgroupv2_get_subtree_control.Po - -rm -f ./$(DEPDIR)/015-cgroupv2_controller_enabled.Po - -rm -f ./$(DEPDIR)/016-cgset_parse_r_flag.Po - -rm -f ./$(DEPDIR)/017-API_fuzz_test.Po - -rm -f ./$(DEPDIR)/gtest.Po - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: check-am install-am install-strip - -.PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \ - check-am clean clean-checkPROGRAMS clean-generic clean-libtool \ - clean-local cscopelist-am ctags ctags-am distclean \ - distclean-compile distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am recheck tags tags-am uninstall \ - uninstall-am - -.PRECIOUS: Makefile - - -clean-local: - ${RM} test-procpidcgroup - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/lib/libcgroup-3.1.0/tests/gunit/gtest.cpp b/lib/libcgroup-3.1.0/tests/gunit/gtest.cpp deleted file mode 100644 index b48200b09f9..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/gtest.cpp +++ /dev/null @@ -1,16 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-only */ -/** - * libcgroup googletest main entry point - * - * Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved. - * Author: Tom Hromatka - */ - -#include "gtest/gtest.h" - -int main(int argc, char **argv) -{ - ::testing::InitGoogleTest(&argc, argv); - - return RUN_ALL_TESTS(); -} diff --git a/lib/libcgroup-3.1.0/tests/gunit/libcgroup_unittest.map b/lib/libcgroup-3.1.0/tests/gunit/libcgroup_unittest.map deleted file mode 100644 index d2af56c2bb1..00000000000 --- a/lib/libcgroup-3.1.0/tests/gunit/libcgroup_unittest.map +++ /dev/null @@ -1,130 +0,0 @@ -CGROUP_0.32 { -global: - cgroup_init; - cgroup_attach_task; - cgroup_modify_cgroup; - cgroup_create_cgroup; - cgroup_delete_cgroup; - cgroup_attach_task_pid; - cgroup_get_cgroup; - cgroup_create_cgroup_from_parent; - cgroup_copy_cgroup; - cgroup_change_cgroup_uid_gid; - cgroup_change_cgroup_path; - cgroup_new_cgroup; - cgroup_add_controller; - cgroup_free; - cgroup_free_controllers; - cgroup_add_value_string; - cgroup_add_value_int64; - cgroup_add_value_uint64; - cgroup_add_value_bool; - cgroup_compare_cgroup; - cgroup_compare_controllers; - cgroup_set_uid_gid; - cgroup_get_uid_gid; - cgroup_get_value_string; - cgroup_set_value_string; - cgroup_get_value_int64; - cgroup_set_value_int64; - cgroup_get_value_uint64; - cgroup_set_value_uint64; - cgroup_get_value_bool; - cgroup_set_value_bool; - cgroup_change_cgroup_uid_gid_flags; - cgroup_print_rules_config; - cgroup_reload_cached_rules; - cgroup_init_rules_cache; - cgroup_get_current_controller_path; - cgroup_config_load_config; - *; -}; - -CGROUP_0.32.1 { -global: - cgroup_strerror; -} CGROUP_0.32; - -CGROUP_0.33 { -global: - cgroup_get_last_errno; - cgroup_walk_tree_begin; - cgroup_walk_tree_next; - cgroup_walk_tree_end; -} CGROUP_0.32.1; - -CGROUP_0.34 { -global: - cgroup_get_task_begin; - cgroup_get_task_end; - cgroup_get_task_next; - cgroup_read_stats_begin; - cgroup_read_stats_next; - cgroup_read_stats_end; - cgroup_walk_tree_set_flags; - cgroup_get_controller_end; - cgroup_get_controller_next; - cgroup_get_controller_begin; - cgroup_unload_cgroups; - cgroup_get_controller; - cgroup_get_uid_gid_from_procfs; - cgroup_get_subsys_mount_point; - cgroup_get_procname_from_procfs; - cgroup_register_unchanged_process; - cgroup_change_cgroup_flags; -} CGROUP_0.33; - -CGROUP_0.35 { -global: - create_cgroup_from_name_value_pairs; - cgroup_delete_cgroup_ext; - cgroup_get_all_controller_begin; - cgroup_get_all_controller_next; - cgroup_get_all_controller_end; - cgroup_get_value_name_count; - cgroup_get_value_name; -} CGROUP_0.34; - -CGROUP_0.36 { -} CGROUP_0.35; - -CGROUP_0.37 { - cgroup_get_procs; - cgroup_read_value_begin; - cgroup_read_value_next; - cgroup_read_value_end; - cg_chmod_recursive; -} CGROUP_0.36; - -CGROUP_0.38 { - cgroup_get_subsys_mount_point_begin; - cgroup_get_subsys_mount_point_next; - cgroup_get_subsys_mount_point_end; - cgroup_set_permissions; - cgroup_config_unload_config; - cgroup_config_set_default; -} CGROUP_0.37; - -CGROUP_0.39 { - cgroup_reload_cached_templates; - cgroup_init_templates_cache; - cgroup_config_create_template_group; - cgroup_change_all_cgroups; - cgroup_set_logger; - cgroup_set_default_logger; - cgroup_set_loglevel; - cgroup_log; - cgroup_parse_log_level_str; -} CGROUP_0.38; - -CGROUP_0.40 { - cgroup_templates_cache_set_source_files; - cgroup_load_templates_cache_from_files; -} CGROUP_0.39; - -CGROUP_0.41 { -} CGROUP_0.40; - -CGROUP_0.42 { - cgroup_add_all_controllers; -} CGROUP_0.41;